Other Parts Discussed in Thread: CONTROLSUITE
Dear All,
as title.
I use "controlSUITE\device_support\f2802x\v210\f2802x_examples\cpu_timer" to test CPU Timer0.
TIMER_setPreScaler(myTimer0, 40); didn't make TPR of Timer0 change to 40, why?
The source code of this function from timer.c as below:
=================================================
void TIMER_setPreScaler(TIMER_Handle timerHandle,
const uint16_t preScaler)
{
TIMER_Obj *timer = (TIMER_Obj *)timerHandle;
// set the bits
timer->TPR |=
((uint32_t)(preScaler & 0xFF00) << 16) | ((uint32_t)(preScaler & 0x00FF) << 8);
return;
} // end of TIMER_setPreScaler() function
===============================================
Thank you.
Abby