COSA
An Object-Oriented Platform for Arduino Programming
|
#include <Time.hh>
Public Member Functions | |
void | to_binary () |
void | to_bcd () |
time_t () | |
time_t (clock_t c, int8_t zone=0) | |
operator clock_t () const | |
void | set_day () |
uint16_t | days () const |
uint16_t | day_of_year () const |
uint16_t | full_year () const |
bool | is_leap () const |
bool | is_valid () const |
bool | parse (str_P s) |
Static Public Member Functions | |
static uint16_t | full_year (uint8_t year) |
static bool | is_leap (uint16_t year) |
static uint16_t | days_per (uint16_t year) |
static uint8_t | weekday_for (uint16_t dayno) |
static void | epoch_year (uint16_t y) |
static uint16_t | epoch_year () |
static void | use_fastest_epoch () |
Public Attributes | |
uint8_t | seconds |
00-59 Seconds. More... | |
uint8_t | minutes |
00-59 Minutes. More... | |
uint8_t | hours |
00-23 Hours. More... | |
uint8_t | day |
01-07 Day. More... | |
uint8_t | date |
01-31 Date. More... | |
uint8_t | month |
01-12 Month. More... | |
uint8_t | year |
00-99 Year. More... | |
Static Public Attributes | |
static uint8_t | epoch_weekday = Y2K_EPOCH_WEEKDAY |
static uint8_t | pivot_year = 0 |
static const uint8_t | days_in [] |
Static Protected Attributes | |
static uint16_t | s_epoch_year = Y2K_EPOCH_YEAR |
static uint8_t | epoch_offset = 0 |
Common date/time structure for real-time clocks. Data on some devices is stored in BCD (DS1307/DS3231), although internal representation is binary. Conversion methods are provided to convert to/from the BCD representation. It is up the caller to keep track of the representation. All time_t methods (except /to_binary/) expect the internal representation to be binary.
time_t::time_t | ( | clock_t | c, |
int8_t | zone = 0 |
||
) |
uint16_t time_t::day_of_year | ( | ) | const |
uint16_t time_t::days | ( | ) | const |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inline |
|
inlinestatic |
|
inline |
|
inlinestatic |
|
inline |
time_t::operator clock_t | ( | ) | const |
bool time_t::parse | ( | str_P | s | ) |
|
inline |
|
inline |
|
inline |
|
static |
|
inlinestatic |
|
static |
|
static |
|
static |
|
staticprotected |