![]() |
MAX32675 Peripheral Driver API
Peripheral Driver API for the MAX32675
|
Modules | |
RTC_Registers | |
Enumerations | |
enum | mxc_rtc_freq_sel_t |
enum | mxc_rtc_int_en_t |
enum | mxc_rtc_int_fl_t |
Functions | |
int | MXC_RTC_SetTimeofdayAlarm (uint32_t ras) |
int | MXC_RTC_SetSubsecondAlarm (uint32_t rssa) |
int | MXC_RTC_Start (void) |
int | MXC_RTC_Stop (void) |
int | MXC_RTC_Init (uint32_t sec, uint8_t ssec) |
int | MXC_RTC_SquareWaveStart (mxc_rtc_freq_sel_t fq) |
int | MXC_RTC_SquareWaveStop (void) |
int | MXC_RTC_Trim (int8_t trm) |
int | MXC_RTC_EnableInt (uint32_t mask) |
int | MXC_RTC_DisableInt (uint32_t mask) |
int | MXC_RTC_GetFlags (void) |
int | MXC_RTC_ClearFlags (int flags) |
int | MXC_RTC_GetSubSecond (void) |
int | MXC_RTC_GetSecond (void) |
int | MXC_RTC_GetTime (uint32_t *sec, uint32_t *subsec) |
enum mxc_rtc_freq_sel_t |
enum mxc_rtc_int_en_t |
enum mxc_rtc_int_fl_t |
int MXC_RTC_ClearFlags | ( | int | flags | ) |
Clear interrupt flags.
flags | The bitwise OR of the interrupts flags to cleear. See mxc_rtc_int_fl_t for the list of possible flags. |
returns | Success or Fail, see Error Codes |
int MXC_RTC_DisableInt | ( | uint32_t | mask | ) |
Disable Interurpts.
mask | The mask of interrupts to disable. See mxc_rtc_int_en_t for available choices. |
returns | Success or Fail, see Error Codes |
int MXC_RTC_EnableInt | ( | uint32_t | mask | ) |
Enable Interurpts.
mask | The bitwise OR of interrupts to enable. See mxc_rtc_int_en_t for available choices. |
returns | Success or Fail, see Error Codes |
int MXC_RTC_GetFlags | ( | void | ) |
Gets interrupt flags.
The | bitwise OR of any interrupts flags that are currently set. See mxc_rtc_int_fl_t for the list of possible flags. |
int MXC_RTC_GetSecond | ( | void | ) |
Get Second.
returns | second value |
int MXC_RTC_GetSubSecond | ( | void | ) |
Get SubSecond.
Returns | subsecond value |
int MXC_RTC_GetTime | ( | uint32_t * | sec, |
uint32_t * | subsec | ||
) |
Get the time using nuclear fusion. Or atomically. Something like that.
sec | pointer to store seconds value |
subsec | pointer to store subseconds value |
returns | Success or Fail, see Error Codes |
int MXC_RTC_Init | ( | uint32_t | sec, |
uint8_t | ssec | ||
) |
Initialize the sec and ssec registers and enable RTC.
sec | set the RTC Sec counter (32-bit) |
ssec | set the RTC Sub-second counter (8-bit) |
returns | Success or Fail, see Error Codes |
int MXC_RTC_SetSubsecondAlarm | ( | uint32_t | rssa | ) |
Set Sub-Second alarm value and enable interrupt,.
this is to be called after the init_rtc() function
rssa | 32-bit value 0-0xFFFFFFFF |
returns | Success or Fail, see Error Codes |
int MXC_RTC_SetTimeofdayAlarm | ( | uint32_t | ras | ) |
Set Time-of-Day alarm value and enable Interrupt.
ras | 20-bit value 0-0xFFFFF |
returns | Success or Fail, see Error Codes |
int MXC_RTC_SquareWaveStart | ( | mxc_rtc_freq_sel_t | fq | ) |
Allow generation of Square Wave on the SQW pin.
fq | Frequency output selection |
returns | Success or Fail, see Error Codes |
int MXC_RTC_SquareWaveStop | ( | void | ) |
Stop the generation of square wave.
returns | Success or Fail, see Error Codes |
int MXC_RTC_Start | ( | void | ) |
Start the Real Time Clock.
returns | Success or Fail, see Error Codes |
int MXC_RTC_Stop | ( | void | ) |
Stop the Real Time Clock.
returns | Success or Fail, see Error Codes |
int MXC_RTC_Trim | ( | int8_t | trm | ) |
Set Trim register value.
trm | set the RTC Trim (8-bit, +/- 127) |
returns | Success or Fail, see Error Codes |