time.h 409 B

12345678910111213141516
  1. #ifndef TIME_H
  2. #define TIME_H
  3. typedef uint32_t time_t;
  4. struct tm {
  5. uint8_t tm_sec; // 0..59
  6. uint8_t tm_min; // 0..59
  7. uint8_t tm_hour; // 0..23
  8. uint8_t tm_mday; // 1..[28..31]
  9. uint8_t tm_mon; // 0..11
  10. uint8_t tm_year; // since 1900, i.e. 2000 is 100
  11. uint8_t tm_wday; // 0 to 6, sunday is 6
  12. // A Unix struct tm has a few more fields we don't need in this application
  13. };
  14. #endif /* TIME_H */