This library contains functions that provide simple time utilities in conjunction with the RTC C Library. The time base is variable for this library, meaning that the value '0 seconds' can be assigned to 12:00:00am of January 1st for a specific year. Note that this library does not currently support daylight savings time computations or the concept of time zones.
Note that this library will not return correct values for dates before the year 1901 or after the year 2099.
For detailed information on the DS80C400 please see the High-Speed Microcontroller User's Guide: DS80C400 Supplement.
Go to the source code of this file.
Data Structures | |
| struct | tm |
Defines | |
| #define | TINI400_TIME_VERSION 2 |
Typedefs | |
| typedef unsigned long | time_t |
Functions | |
| unsigned int | time_version (void) |
| Returns the version number of this TIME library. | |
| void | time_settimebase (unsigned int year) |
| Sets the time base year for the RTC. | |
| time_t | mktime (struct tm *timeptr) |
| mktime | |
| time_t | time (time_t *timer) |
| time | |
| tm * | gmtime (time_t *timer) |
| gmtime | |
|
|
Version number associated with this header file. Should be the same as the version number returned by the time_version function.
|
|
|
Type used for representing time. Our RTC is assumed to be 4 bytes of seconds.
|
|
|
gmtime Converts the native time formatted input into a calendar representation.
|
|
|
mktime Converts a tm structure (calendar time) into the native time representation of time_t. The tiem is computed using the hour, minute, second, day of month, month, and year fields of the input structure. The day of year, day of week, and daylight savings time flag are ignored. No bounds checking is performed on the input data.
|
|
|
time Gets the current time in its native representation format. Use the function gmtime to get a calendar representation of this time.
|
|
|
Sets the time base year for the RTC. Sets the time base year for the real time clock. The recommended time base is the year 2000. The time base must be set before meaningful calculations can occur.
|
|
|
Returns the version number of this TIME library.
|
| Copyright 2004 Dallas Semiconductor, Inc.. | Documentation generated by Doxygen. |