COSA
An Object-Oriented Platform for Arduino Programming
|
#include <FAT16.hh>
Public Member Functions | |
time_t (uint16_t h, uint8_t m, uint8_t s) | |
time_t (uint16_t now) | |
uint16_t | HOURS () |
uint8_t | MINUTES () |
uint8_t | SECONDS () |
operator uint16_t () | |
Public Attributes | |
uint16_t | as_uint16 |
struct { | |
uint8_t seconds:5 | |
uint8_t minutes:6 | |
uint8_t hours:5 | |
}; | |
FAT Time Format. A FAT directory entry time stamp is a 16-bit field that has a granularity of 2 seconds. Here is the format (bit 0 is the LSB of the 16-bit word, bit 15 is the MSB of the 16-bit word).
Bits 0-4: 2-second count, valid value range 0-29 inclusive (0-58 seconds). Bits 5-10: Minutes, valid value range 0-59 inclusive. Bits 11-15: Hours, valid value range 0-23 inclusive.
The valid time range is from Midnight 00:00:00 to 23:59:58.
|
inline |
struct { ... } |