New HardwareTimer for STM32 5.7.0 (#15655)
This commit is contained in:
committed by
Scott Lahteine
parent
4762dfe797
commit
ac71cdc265
@ -99,7 +99,7 @@ void HAL_timer_start(const uint8_t timer_num, const uint32_t frequency) {
|
||||
SYNC(tc->COUNT32.SYNCBUSY.bit.CTRLB);
|
||||
|
||||
// Set compare value
|
||||
tc->COUNT32.COUNT.reg = tc->COUNT32.CC[0].reg = HAL_TIMER_RATE / frequency;
|
||||
tc->COUNT32.COUNT.reg = tc->COUNT32.CC[0].reg = (HAL_TIMER_RATE) / frequency;
|
||||
|
||||
// And start timer
|
||||
tc->COUNT32.CTRLA.bit.ENABLE = true;
|
||||
|
Reference in New Issue
Block a user