//Timebase timers init: void init_tb_timers(void) { //Timer 1: 1ms (LEDs, PID) Timer_1_Init(); Timer_1_Start(); isr_t1_Start(); }
/******************************************************************************* * Function Name: Timer_1_Start ******************************************************************************** * * Summary: * The start function initializes the timer with the default values, the * enables the timerto begin counting. It does not enable interrupts, * the EnableInt command should be called if interrupt generation is required. * * Parameters: * void * * Return: * void * * Global variables: * Timer_1_initVar: Is modified when this function is called for the * first time. Is used to ensure that initialization happens only once. * *******************************************************************************/ void Timer_1_Start(void) { if(Timer_1_initVar == 0u) { Timer_1_Init(); Timer_1_initVar = 1u; /* Clear this bit for Initialization */ } /* Enable the Timer */ Timer_1_Enable(); }