MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / SysTick_CLKSourceConfig

Function SysTick_CLKSourceConfig

bsp/efm32/board.c:123–134  ·  view source on GitHub ↗

/ * @brief * Configure the SysTick clock source * * @details * * @note * * @param[in] SysTick_CLKSource * Specifies the SysTick clock source. * * @arg SysTick_CLKSource_HCLK_Div8 * AHB clock divided by 8 selected as SysTick clock source. * * @arg SysTick_CLKSource_HCLK * AHB clock selected as SysTick clock source. *************************************************************

Source from the content-addressed store, hash-verified

121 * AHB clock selected as SysTick clock source.
122 ******************************************************************************/
123static void SysTick_CLKSourceConfig(rt_uint32_t SysTick_CLKSource)
124{
125 /* Check the parameters */
126 RT_ASSERT(IS_SYSTICK_CLK_SOURCE(SysTick_CLKSource));
127
128 rt_uint32_t ctrl = SysTick->CTRL;
129
130 ctrl &= ~SysTick_CLKSource_MASK;
131 ctrl |= SysTick_CLKSource;
132
133 SysTick->CTRL = ctrl;
134}
135
136/***************************************************************************//**
137 * @brief

Callers 1

SysTick_ConfigurationFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected