50 #ifndef ti_dl_m0p_dl_systick__include 51 #define ti_dl_m0p_dl_systick__include 56 #include <ti/devices/msp/msp.h> 67 #define DL_SYSTICK_config(x) SysTick_Config(x) 83 SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk;
84 SysTick->LOAD = period - (uint32_t) 1;
100 SysTick->LOAD = period - (uint32_t) 1;
123 return (SysTick->LOAD + (uint32_t) 1);
143 SysTick->CTRL |= SysTick_CTRL_TICKINT_Msk;
151 SysTick->CTRL &= ~(SysTick_CTRL_TICKINT_Msk);
163 SysTick->CTRL |= (SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk);
171 SysTick->CTRL &= ~(SysTick_CTRL_ENABLE_Msk);
185 (SysTick->CTRL & SysTick_CTRL_ENABLE_Msk) == SysTick_CTRL_ENABLE_Msk);
__STATIC_INLINE uint32_t DL_SYSTICK_getPeriod(void)
Get the period for the SysTick.
Definition: dl_systick.h:121
__STATIC_INLINE uint32_t DL_SYSTICK_getValue(void)
Get the current value of SysTick counter.
Definition: dl_systick.h:133
__STATIC_INLINE void DL_SYSTICK_enable(void)
Enable the SysTick, starts counting once enabled.
Definition: dl_systick.h:161
__STATIC_INLINE void DL_SYSTICK_disable(void)
Disable the SysTick, stops counting once disabled.
Definition: dl_systick.h:169
__STATIC_INLINE void DL_SYSTICK_disableInterrupt(void)
Disable the SysTick interrupt.
Definition: dl_systick.h:149
__STATIC_INLINE bool DL_SYSTICK_isEnabled(void)
Checks if the SysTick is enabled.
Definition: dl_systick.h:182
__STATIC_INLINE void DL_SYSTICK_setPeriod(uint32_t period)
Set the period for the SysTick.
Definition: dl_systick.h:98
__STATIC_INLINE void DL_SYSTICK_init(uint32_t period)
Initializes the System Tick Timer (SysTick)
Definition: dl_systick.h:81
__STATIC_INLINE void DL_SYSTICK_enableInterrupt(void)
Enable the SysTick interrupt.
Definition: dl_systick.h:141
__STATIC_INLINE void DL_SYSTICK_resetValue(void)
Reset the current value of the SysTick.
Definition: dl_systick.h:109