RTC on CARME mainboard.
More...
|
file | rtc_ext.h |
| Communication interface to use the RTC on the CARME mainboard.
|
|
file | rtc_ext.c |
| Communication interface to use the RTC on the CARME mainboard.
|
|
RTC on CARME mainboard.
#define CARME_RTC_I2C_ADDR 0xD0 |
RTC I2C slave address
Definition at line 92 of file rtc_ext.h.
#define CARME_RTC_REG_CTRL 0x07 |
Register address for control
Definition at line 90 of file rtc_ext.h.
#define CARME_RTC_REG_DAY 0x04 |
Register address for day
Definition at line 87 of file rtc_ext.h.
#define CARME_RTC_REG_HOUR 0x02 |
Register address for hour
Definition at line 85 of file rtc_ext.h.
#define CARME_RTC_REG_MIN 0x01 |
Register address for minute
Definition at line 84 of file rtc_ext.h.
#define CARME_RTC_REG_MONTH 0x05 |
Register address for month
Definition at line 88 of file rtc_ext.h.
#define CARME_RTC_REG_SEC 0x00 |
Register address for second
Definition at line 83 of file rtc_ext.h.
#define CARME_RTC_REG_WDAY 0x03 |
Register address for day of week
Definition at line 86 of file rtc_ext.h.
#define CARME_RTC_REG_YEAR 0x06 |
Register address for year
Definition at line 89 of file rtc_ext.h.
Get the Time from the external RTC on mainboard.
- Parameters
-
[out] | time | The current time is stored in this struct. |
- Returns
- None
Definition at line 184 of file rtc_ext.c.
void CARME_RTC_Ext_Init |
( |
void |
| ) |
|
Initialize the RTC on the CARME mainboard.
- Returns
- None
Definition at line 100 of file rtc_ext.c.
Set the Time of the external RTC on the mainboard.
- Parameters
-
[in] | time | This time will be set as the new system time.
The user has to verify that the given date is valid. |
- Returns
- None
Definition at line 121 of file rtc_ext.c.