#define RTC_STATUS_PF 0x00000001
#define RTC_STATUS_AL0 0x00000020
#define RTC_STATUS_AL1 0x00000040
#define RTC_ALARM_SECOND 0x00000001
#define RTC_ALARM_MINUTE 0x00000002
#define RTC_ALARM_HOUR 0x00000004
#define RTC_ALARM_MDAY 0x00000008
#define RTC_ALARM_MONTH 0x00000010
#define RTC_ALARM_WDAY 0x00000080
#define RTC_ALARM_YEAR 0x00000100
#define RTC_ALARM_YDAY 0x00000200
#define BCD2BIN( x )
#define BIN2BCD( x )
See: | Type struct _NUTRTC |
struct _NUTRTC | |
{ | |
void* dcb; | |
int (*rtc_init)(NUTRTC* rtc); | |
int (*rtc_gettime)(NUTRTC* rtc,struct _tm*); | |
int (*rtc_settime)(NUTRTC* rtc,const struct _tm*); | |
int (*rtc_getalarm)(NUTRTC* rtc,int idx,struct _tm*,int*); | |
int (*rtc_setalarm)(NUTRTC* rtc,int idx,const struct _tm*,int); | |
int (*rtc_getstatus)(NUTRTC* rtc,uint32_t*); | |
int (*rtc_clrstatus)(NUTRTC* rtc,uint32_t); | |
HANDLE alarm; | |
} |