I'm testing the TIMER CAPTURE function.
All other functions have been tested, but the prescale function does not work well.
All other functions have been tested, but the prescale function does not work well.
The source code as follows.
MAP_SysCtlPeripheralEnable(SYSCTL_PERIPH_TIMER3);
MAP_TimerConfigure(TIMER3_BASE, TIMER_CFG_SPLIT_PAIR | TIMER_CFG_A_ONE_SHOT | TIMER_CFG_B_ONE_SHOT);
MAP_TimerPrescaleSet(TIMER3_BASE, TIMER_A, 10);
MAP_TimerPrescaleSet(TIMER3_BASE, TIMER_B, 20);
Since the prescale value of TIMER_A is half that of TIMER_B, the value obtained through the MAP_TimerValueGet () function is twice that of TIMER_B.
But if i set the timer to capture mode ...
MAP_TimerConfigure (TIMER3_BASE, TIMER_CFG_SPLIT_PAIR | TIMER_CFG_A_CAP_COUNT | TIMER_CFG_B_CAP_COUNT);
The same value is read.
Does prescale not work in capture mode?
I want to know more about capture mode and prescale behavior.