mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-04-21 22:11:57 -04:00
Correct the auto reload value.
This commit is contained in:
parent
26bf0da04e
commit
0db3b5c258
|
@ -212,7 +212,7 @@ TB_InitTypeDef TB_InitStructure;
|
|||
TB_InitStructure.TB_Mode = TB_Mode_Timing;
|
||||
TB_InitStructure.TB_CounterMode = TB_CounterMode_Down;
|
||||
TB_InitStructure.TB_Prescaler = portPRESCALE - 1;
|
||||
TB_InitStructure.TB_AutoReload = ( ( configCPU_CLOCK_HZ / ( portPRESCALE + 1 ) ) / configTICK_RATE_HZ ) + 1;
|
||||
TB_InitStructure.TB_AutoReload = ( ( configCPU_CLOCK_HZ / portPRESCALE ) / configTICK_RATE_HZ );
|
||||
TB_Init(&TB_InitStructure);
|
||||
|
||||
/* Enable TB Update interrupt */
|
||||
|
|
Loading…
Reference in a new issue