libws libws
WSwan hardware library for the Wonderful toolchain
Loading...
Searching...
No Matches
Functions - RTC

Data Structures

struct  ws_rtc_date_t
 
struct  ws_rtc_time_t
 
struct  ws_rtc_datetime_t
 

Macros

#define RTC_MONTH_AMPM   0x80
 
#define RTC_MONTH_AM   0x80
 
#define RTC_MONTH_PM   0x80
 
#define RTC_STATUS_POWER_LOST   0x80
 
#define RTC_STATUS_12_HOUR   0x00
 
#define RTC_STATUS_24_HOUR   0x40
 
#define RTC_STATUS_INTAE   0x20
 
#define RTC_STATUS_INTME   0x08
 
#define RTC_STATUS_INTFE   0x02
 
#define RTC_STATUS_INT_OFF   0
 
#define RTC_STATUS_INT_FREQ_STEADY   (RTC_STATUS_INTFE)
 
#define RTC_STATUS_INT_MINUTE_EDGE   (RTC_STATUS_INTME)
 
#define RTC_STATUS_INT_MINUTE_STEADY   (RTC_STATUS_INTME | RTC_STATUS_INTFE)
 
#define RTC_STATUS_INT_ALARM   (RTC_STATUS_INTAE)
 

Functions

int16_t ws_rtc_low_read_byte (uint16_t timeout)
 
bool ws_rtc_low_write_byte (uint8_t value, uint16_t timeout)
 
bool ws_rtc_low_write_ctrl (uint8_t value, uint16_t timeout)
 

Detailed Description

Macro Definition Documentation

◆ RTC_MONTH_AM

#define RTC_MONTH_AM   0x80

Definition at line 41 of file rtc.h.

◆ RTC_MONTH_AMPM

#define RTC_MONTH_AMPM   0x80

Definition at line 40 of file rtc.h.

◆ RTC_MONTH_PM

#define RTC_MONTH_PM   0x80

Definition at line 42 of file rtc.h.

◆ RTC_STATUS_12_HOUR

#define RTC_STATUS_12_HOUR   0x00

Definition at line 63 of file rtc.h.

◆ RTC_STATUS_24_HOUR

#define RTC_STATUS_24_HOUR   0x40

Definition at line 64 of file rtc.h.

◆ RTC_STATUS_INT_ALARM

#define RTC_STATUS_INT_ALARM   (RTC_STATUS_INTAE)

Definition at line 72 of file rtc.h.

◆ RTC_STATUS_INT_FREQ_STEADY

#define RTC_STATUS_INT_FREQ_STEADY   (RTC_STATUS_INTFE)

Definition at line 69 of file rtc.h.

◆ RTC_STATUS_INT_MINUTE_EDGE

#define RTC_STATUS_INT_MINUTE_EDGE   (RTC_STATUS_INTME)

Definition at line 70 of file rtc.h.

◆ RTC_STATUS_INT_MINUTE_STEADY

#define RTC_STATUS_INT_MINUTE_STEADY   (RTC_STATUS_INTME | RTC_STATUS_INTFE)

Definition at line 71 of file rtc.h.

◆ RTC_STATUS_INT_OFF

#define RTC_STATUS_INT_OFF   0

Definition at line 68 of file rtc.h.

◆ RTC_STATUS_INTAE

#define RTC_STATUS_INTAE   0x20

Definition at line 65 of file rtc.h.

◆ RTC_STATUS_INTFE

#define RTC_STATUS_INTFE   0x02

Definition at line 67 of file rtc.h.

◆ RTC_STATUS_INTME

#define RTC_STATUS_INTME   0x08

Definition at line 66 of file rtc.h.

◆ RTC_STATUS_POWER_LOST

#define RTC_STATUS_POWER_LOST   0x80

Definition at line 62 of file rtc.h.

Function Documentation

◆ ws_rtc_low_read_byte()

int16_t ws_rtc_low_read_byte ( uint16_t timeout)

◆ ws_rtc_low_write_byte()

bool ws_rtc_low_write_byte ( uint8_t value,
uint16_t timeout )

◆ ws_rtc_low_write_ctrl()

bool ws_rtc_low_write_ctrl ( uint8_t value,
uint16_t timeout )