Other Parts Discussed in Thread: SYSBIOS
Tool/software: TI C/C++ Compiler
Hi:
I use mcu timer with 10 seconds period,but the real value only has 768ms,my code just like this:
int main(void)
{
#ifdef UART_ENABLED
AppUtils_Init();
#endif
TimerP_Params timerParams;
TimerP_Handle timer;
/* Initialize the timer params */
TimerP_Params_init(&timerParams);
timerParams.startMode = TimerP_StartMode_USER;
timerParams.periodType = TimerP_PeriodType_MICROSECS;
timerParams.period = 10000000;
timerParams.arg = NULL;
timerParams.runMode = TimerP_RunMode_CONTINUOUS;
timer = TimerP_create(TimerP_ANY, App_TimerFxn, &timerParams);
if(NULL != timer)
{
TimerP_start(timer);
}
else
{
BIOS_exit(0);
}
BIOS_start(); /* does not return */
return(0);
}
static Void App_TimerFxn(UArg a0)
{
AppUtils_Printf(APP_UTILS_PRINT_MSG_NORMAL, "Hello world!\r\n");
}