931 uint32_t rtc_set_time(Rtc *p_rtc, uint32_t ul_hour, uint32_t ul_minute, uint32_t ul_second)
Set the RTC time value.
#define RTC_TIMR_MIN_Msk
(RTC_TIMR) Current Minute
#define RTC_MR_HRMOD
(RTC_MR) 12-/24-hour Mode
#define RTC_MR_OUT0_FREQ64HZ
(RTC_MR) 64 Hz square wave
__O uint32_t RTC_IDR
(Rtc Offset: 0x24) Interrupt Disable Register
#define RTC_TIMALR_HOUREN
(RTC_TIMALR) Hour Alarm Enable
#define RTC_MR_OUT1_NO_WAVE
(RTC_MR) No waveform, stuck at '0'
#define RTC_CALR_CENT_Msk
(RTC_CALR) Current Century
#define RTC_MR_OUT1_FREQ512HZ
(RTC_MR) 512 Hz square wave
__IO uint32_t RTC_CALALR
(Rtc Offset: 0x14) Calendar Alarm Register
#define RTC_VER_NVCALALR
(RTC_VER) Non-valid Calendar Alarm
#define RTC_MR_OUT0_NO_WAVE
(RTC_MR) No waveform, stuck at '0'
void rtc_enable_interrupt(Rtc *p_rtc, uint32_t ul_sources)
Enable RTC interrupts.
uint32_t rtc_get_hour_mode(Rtc *p_rtc)
Get the RTC hour mode.
#define RTC_CR_TIMEVSEL_Msk
(RTC_CR) Time Event Selection
__I uint32_t RTC_VER
(Rtc Offset: 0x2C) Valid Entry Register
#define RTC_CALR_MONTH_Pos
void rtc_get_time(Rtc *p_rtc, uint32_t *pul_hour, uint32_t *pul_minute, uint32_t *pul_second)
Get the RTC time value.
#define RTC_CR_UPDCAL
(RTC_CR) Update Request Calendar Register
#define RTC_MR_OUT0_PROG_PULSE
(RTC_MR) Duty cycle programmable pulse
#define RTC_CALALR_MONTH(value)
uint32_t rtc_get_status(Rtc *p_rtc)
Get the RTC status.
#define RTC_CALALR_DATEEN
(RTC_CALALR) Date Alarm Enable
#define RTC_TIMALR_MINEN
(RTC_TIMALR) Minute Alarm Enable
__IO uint32_t RTC_CR
(Rtc Offset: 0x00) Control Register
#define RTC_TIMR_AMPM
(RTC_TIMR) Ante Meridiem Post Meridiem Indicator
void rtc_clear_time_alarm(Rtc *p_rtc)
Clear the RTC time alarm setting.
#define RTC_CALR_YEAR_Msk
(RTC_CALR) Current Year
#define RTC_CALR_DATE_Msk
(RTC_CALR) Current Day in Current Month
#define RTC_MR_OUT1_FREQ32HZ
(RTC_MR) 32 Hz square wave
#define RTC_MR_HIGHPPM
(RTC_MR) HIGH PPM Correction
#define RTC_CR_CALEVSEL_Pos
__IO uint32_t RTC_WPMR
(Rtc Offset: 0xE4) Write Protection Mode Register
void rtc_clear_date_alarm(Rtc *p_rtc)
Clear the RTC date alarm setting.
void rtc_set_calendar_event(Rtc *p_rtc, uint32_t ul_selection)
Set the RTC calendar event selection.
#define RTC_CALR_DATE_Pos
uint32_t rtc_set_time_alarm(Rtc *p_rtc, uint32_t ul_hour_flag, uint32_t ul_hour, uint32_t ul_minute_flag, uint32_t ul_minute, uint32_t ul_second_flag, uint32_t ul_second)
Set the RTC alarm time value.
#define RTC_MR_THIGH_Msk
(RTC_MR) High Duration of the Output Pulse
#define RTC_MR_OUT1_ALARM_TOGGLE
(RTC_MR) Output toggles when alarm flag rises
__IO uint32_t RTC_CALR
(Rtc Offset: 0x0C) Calendar Register
#define RTC_MR_TPERIOD_Msk
(RTC_MR) Period of the Output Pulse
#define RTC_CALALR_DATE(value)
#define RTC_VER_NVTIM
(RTC_VER) Non-valid Time
__O uint32_t RTC_IER
(Rtc Offset: 0x20) Interrupt Enable Register
#define RTC_CALR_DAY_Msk
(RTC_CALR) Current Day in Current Week
#define RTC_CALR_YEAR_Pos
#define RTC_MR_OUT0_FREQ1HZ
(RTC_MR) 1 Hz square wave
__I uint32_t RTC_SR
(Rtc Offset: 0x18) Status Register
#define RTC_MR_OUT1_Msk
(RTC_MR) RTCOUT1 Output Source Selection
#define RTC_CR_CALEVSEL_Msk
(RTC_CR) Calendar Event Selection
#define RTC_CALR_MONTH_Msk
(RTC_CALR) Current Month
#define RTC_MR_OUT0_FREQ32HZ
(RTC_MR) 32 Hz square wave
#define RTC_TIMR_SEC_Msk
(RTC_TIMR) Current Second
__IO uint32_t RTC_TIMR
(Rtc Offset: 0x08) Time Register
#define RTC_WPMR_WPEN
(RTC_WPMR) Write Protection Enable
uint32_t rtc_set_date(Rtc *p_rtc, uint32_t ul_year, uint32_t ul_month, uint32_t ul_day, uint32_t ul_week)
Set the RTC date.
uint32_t rtc_set_date_alarm(Rtc *p_rtc, uint32_t ul_month_flag, uint32_t ul_month, uint32_t ul_day_flag, uint32_t ul_day)
Set the RTC alarm date value.
__IO uint32_t RTC_MR
(Rtc Offset: 0x04) Mode Register
#define RTC_MR_OUT0_FREQ512HZ
(RTC_MR) 512 Hz square wave
#define RTC_CR_UPDTIM
(RTC_CR) Update Request Time Register
#define RTC_TIMALR_SECEN
(RTC_TIMALR) Second Alarm Enable
#define RTC_MR_OUT1_PROG_PULSE
(RTC_MR) Duty cycle programmable pulse
#define RTC_WPMR_WPKEY(value)
#define RTC_MR_OUT1_ALARM_FLAG
(RTC_MR) Output is a copy of the alarm flag
#define RTC_SR_ACKUPD
(RTC_SR) Acknowledge for Update
#define RTC_MR_OUT0_ALARM_FLAG
(RTC_MR) Output is a copy of the alarm flag
void rtc_set_time_event(Rtc *p_rtc, uint32_t ul_selection)
Set the RTC time event selection.
#define RTC_VER_NVTIMALR
(RTC_VER) Non-valid Time Alarm
void rtc_disable_interrupt(Rtc *p_rtc, uint32_t ul_sources)
Disable RTC interrupts.
#define RTC_TIMR_HOUR_Pos
__IO uint32_t RTC_TIMALR
(Rtc Offset: 0x10) Time Alarm Register
__O uint32_t RTC_SCCR
(Rtc Offset: 0x1C) Status Clear Command Register
#define RTC_SCCR_SECCLR
(RTC_SCCR) Second Clear
void rtc_get_date(Rtc *p_rtc, uint32_t *pul_year, uint32_t *pul_month, uint32_t *pul_day, uint32_t *pul_week)
Get the RTC date value.
#define RTC_MR_OUT0_Msk
(RTC_MR) RTCOUT0 OutputSource Selection
#define RTC_MR_PERSIAN
(RTC_MR) PERSIAN Calendar
#define RTC_SCCR_ACKCLR
(RTC_SCCR) Acknowledge Clear
void rtc_set_hour_mode(Rtc *p_rtc, uint32_t ul_mode)
Set the RTC hour mode.
Real-Time Clock (RTC) driver for SAM.
#define RTC_CALALR_MTHEN
(RTC_CALALR) Month Alarm Enable
#define RTC_CR_TIMEVSEL_Pos
#define RTC_SR_SEC
(RTC_SR) Second Event
#define RTC_MR_OUT0_ALARM_TOGGLE
(RTC_MR) Output toggles when alarm flag rises
#define RTC_MR_CORRECTION(value)
#define RTC_TIMR_HOUR_Msk
(RTC_TIMR) Current Hour
uint32_t rtc_get_interrupt_mask(Rtc *p_rtc)
Read RTC interrupt mask.
uint32_t rtc_get_valid_entry(Rtc *p_rtc)
Get the RTC valid entry.
#define RTC_MR_CORRECTION_Msk
(RTC_MR) Slow Clock Correction
void rtc_clear_status(Rtc *p_rtc, uint32_t ul_clear)
Set the RTC SCCR to clear status bits.
#define RTC_MR_OUT1_FREQ1HZ
(RTC_MR) 1 Hz square wave
#define RTC_MR_NEGPPM
(RTC_MR) NEGative PPM Correction
#define RTC_VER_NVCAL
(RTC_VER) Non-valid Calendar
__I uint32_t RTC_IMR
(Rtc Offset: 0x28) Interrupt Mask Register
#define RTC_CALR_CENT_Pos
#define RTC_MR_OUT1_FREQ64HZ
(RTC_MR) 64 Hz square wave
#define RTC_MR_TPERIOD_Pos