tm(3avr)

πŸ¦‹ NAME πŸ¦‹

tm β€” it's the struct, bestie πŸ’–

(quick vibe check: this is page tm(3avr) from the AVR-LibC manuals, and it's here to tell u everything about the tm structure. no gatekeeping, we're spilling it all 🫢)


πŸ’… SYNOPSIS πŸ’…

#include <time.h>

πŸ“ Data Fields πŸ“

  • int8_t tm_sec
  • int8_t tm_min
  • int8_t tm_hour
  • int8_t tm_mday
  • int8_t tm_wday
  • int8_t tm_mon
  • int16_t tm_year
  • int16_t tm_yday
  • int16_t tm_isdst

✨ Detailed Description ✨

okay so the tm structure is literally just a vibe: it holds a representation of time that's been 'broken down' into the components of the Gregorian calendar. like somebody took a whole clock and did a little βœ‚οΈ and now every piece is its own lil field. iconic behavior tbh πŸ‘‘

The value of tm_isdst is zero if Daylight Saving Time is not in effect, and it's negative if the information is not available. πŸ’€ (not available?? we love a mystery)

When Daylight Saving Time is in effect, that value represents the number of seconds the clock is advanced. yes fr, it's a count of seconds, not just a lil yes/no flag.

if u want the full tea on Daylight Saving, go peek at the set_dst() function β€” it's the source of truth for all that β˜€οΈ

πŸ“– Field Documentation πŸ“–

int8_t tm::tm_hour πŸ•›

hours since midnight β€” [ 0 to 23 ]

int16_t tm::tm_isdst 🌞

Daylight Saving Time flag

int8_t tm::tm_mday πŸ“…

day of the month β€” [ 1 to 31 ]

int8_t tm::tm_min ⏱️

minutes after the hour β€” [ 0 to 59 ]

int8_t tm::tm_mon πŸ—“οΈ

months since January β€” [ 0 to 11 ]

int8_t tm::tm_sec ✨

seconds after the minute β€” [ 0 to 59 ]

int8_t tm::tm_wday 🌈

days since Sunday β€” [ 0 to 6 ]

int16_t tm::tm_yday πŸ“

days since January 1 β€” [ 0 to 365 ]

int16_t tm::tm_year πŸ‘‘

years since 1900


πŸ‘‘ Author πŸ‘‘

Generated automatically by Doxygen for AVR-LibC from the source code. (not a human girlboss, just a robot doing its best 🫢)


and that's the whole page, bestie!! this one came straight from AVR-LibC, Version 2.2.1, on the tm(3avr) manual page. mwah, go forth and break down some time πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from