![]() |
MAX32672 Peripheral Driver API
Peripheral Driver API for the MAX32672
|
Modules | |
| TMR_Registers | |
Data Structures | |
| struct | mxc_tmr_cfg_t |
Enumerations | |
| enum | mxc_tmr_pres_t |
| enum | mxc_tmr_mode_t |
| enum | mxc_tmr_bit_mode_t |
| enum | mxc_tmr_unit_t |
| enum | mxc_tmr_clock_t |
| struct mxc_tmr_cfg_t |
Timer Configuration.
Data Fields | |
| mxc_tmr_pres_t | pres |
| mxc_tmr_mode_t | mode |
| mxc_tmr_bit_mode_t | bitMode |
| mxc_tmr_clock_t | clock |
| uint32_t | cmp_cnt |
| unsigned | pol |
| enum mxc_tmr_bit_mode_t |
| enum mxc_tmr_clock_t |
Clock settings.
| enum mxc_tmr_mode_t |
Timer modes.
| enum mxc_tmr_pres_t |
Timer prescaler values.
| enum mxc_tmr_unit_t |
| void MXC_TMR_ClearFlags | ( | mxc_tmr_regs_t * | tmr | ) |
Clear the timer interrupt.
| tmr | Pointer to timer module to initialize. |
| void MXC_TMR_Delay | ( | mxc_tmr_regs_t * | tmr, |
| uint32_t | us | ||
| ) |
Dealay for a set periord of time measured in microseconds.
| tmr | The timer |
| us | microseconds to delay for |
| void MXC_TMR_DisableInt | ( | mxc_tmr_regs_t * | tmr | ) |
disable interupt
| tmr | Pointer to timer module to initialize. |
| void MXC_TMR_DisableWakeup | ( | mxc_tmr_regs_t * | tmr, |
| mxc_tmr_cfg_t * | cfg | ||
| ) |
Disable wakeup from sleep.
| tmr | Pointer to timer module to initialize. |
| cfg | System configuration object |
| void MXC_TMR_EnableInt | ( | mxc_tmr_regs_t * | tmr | ) |
enable interupt
| tmr | Pointer to timer module to initialize. |
| void MXC_TMR_EnableWakeup | ( | mxc_tmr_regs_t * | tmr, |
| mxc_tmr_cfg_t * | cfg | ||
| ) |
Enable wakeup from sleep.
| tmr | Pointer to timer module to initialize. |
| cfg | System configuration object |
| uint32_t MXC_TMR_GetCapture | ( | mxc_tmr_regs_t * | tmr | ) |
Get the timer capture count.
| tmr | Pointer to timer module to initialize. |
| uint32_t MXC_TMR_GetCompare | ( | mxc_tmr_regs_t * | tmr | ) |
Get the timer compare count.
| tmr | Pointer to timer module to initialize. |
| uint32_t MXC_TMR_GetCount | ( | mxc_tmr_regs_t * | tmr | ) |
Get the timer count.
| tmr | Pointer to timer module to initialize. |
| uint32_t MXC_TMR_GetFlags | ( | mxc_tmr_regs_t * | tmr | ) |
Get the timer interrupt status.
| tmr | Pointer to timer module to initialize. |
| uint32_t MXC_TMR_GetPeriod | ( | mxc_tmr_regs_t * | tmr, |
| mxc_tmr_clock_t | clock, | ||
| uint32_t | prescalar, | ||
| uint32_t | frequency | ||
| ) |
Calculate count for required frequency.
| tmr | Timer |
| clock | Clock source. |
| prescalar | prescalar |
| frequency | required frequency. |
| int MXC_TMR_GetTime | ( | mxc_tmr_regs_t * | tmr, |
| uint32_t | ticks, | ||
| uint32_t * | time, | ||
| mxc_tmr_unit_t * | units | ||
| ) |
Get time from timer.
| tmr | The timer |
| ticks | The ticks |
| time | The time |
| units | The units |
| int MXC_TMR_Init | ( | mxc_tmr_regs_t * | tmr, |
| mxc_tmr_cfg_t * | cfg, | ||
| bool | init_pins | ||
| ) |
Initialize timer module clock.
| tmr | Pointer to timer module to initialize. |
| cfg | System configuration object |
| bool | True will initialize pins corresponding to the TMR and False will not if pins are pinned out otherwise it will not be used, has no effect incase of MSDK_NO_GPIO_CLK_INIT has been defined. |
| void MXC_TMR_SetCompare | ( | mxc_tmr_regs_t * | tmr, |
| uint32_t | cmp_cnt | ||
| ) |
Set the timer compare count.
| tmr | Pointer to timer module to initialize. |
| cmp_cnt | New compare count. |
| void MXC_TMR_SetCount | ( | mxc_tmr_regs_t * | tmr, |
| uint32_t | cnt | ||
| ) |
Set the timer count.
| tmr | Pointer to timer module to initialize. |
| cnt | New count. |
| int MXC_TMR_SetPWM | ( | mxc_tmr_regs_t * | tmr, |
| uint32_t | pwm | ||
| ) |
Set the value of the first transition in PWM mode.
| tmr | Pointer to timer module to initialize. |
| pwm | New pwm count. |
| void MXC_TMR_Shutdown | ( | mxc_tmr_regs_t * | tmr | ) |
Shutdown timer module clock.
| tmr | Pointer to timer module to initialize. |
| void MXC_TMR_Start | ( | mxc_tmr_regs_t * | tmr | ) |
Start the timer counting.
| tmr | Pointer to timer module to initialize. |
| void MXC_TMR_Stop | ( | mxc_tmr_regs_t * | tmr | ) |
Stop the timer.
| tmr | Pointer to timer module to initialize. |
| void MXC_TMR_SW_Start | ( | mxc_tmr_regs_t * | tmr | ) |
Start stopwatch.
| tmr | The timer |
| unsigned int MXC_TMR_SW_Stop | ( | mxc_tmr_regs_t * | tmr | ) |
Stopwatch stop.
| tmr | The timer |
| int MXC_TMR_TO_Check | ( | mxc_tmr_regs_t * | tmr | ) |
Check on time out timer.
| tmr | The timer |
| void MXC_TMR_TO_Clear | ( | mxc_tmr_regs_t * | tmr | ) |
Clear timeout timer back to zero.
| tmr | The timer |
| unsigned int MXC_TMR_TO_Elapsed | ( | mxc_tmr_regs_t * | tmr | ) |
Get elapsed time of timeout timer.
| tmr | The timer |
| unsigned int MXC_TMR_TO_Remaining | ( | mxc_tmr_regs_t * | tmr | ) |
Amount of time remaining until timeour.
| tmr | The timer |
| void MXC_TMR_TO_Start | ( | mxc_tmr_regs_t * | tmr, |
| uint32_t | us | ||
| ) |
Start a timer that will time out after a certain number of microseconds.
| tmr | The timer |
| us | microseconds to time out after |
| void MXC_TMR_TO_Stop | ( | mxc_tmr_regs_t * | tmr | ) |
Stop the Timeout timer.
| tmr | The timer |