UM1728
3.2.6
lite_timer_8bit.c
These files are the timing module. They contain all virtual timers which are needed for DALI
timing such as intervals for the dimming function and DALI timeouts. Reference timer ticks
come from the DALI I/O pin driver layer.
void Timer_Lite_Init(void)
This function:
•
Initializes the timing module
•
Initializes the internal variables to their default state
void RTC_LaunchTimer(timer_value)
This function:
•
Initializes a timeout for DALI command repetition
void RTC_LaunchUserTimer(TimerCount),
void RTC_DoneUserTimer(void)
This set of functions:
•
Dims the update intervals (start and stop)
void RTC_LaunchBigTimer(mins)
This function:
•
Initializes the timeout (usually 15 minutes) - expiration of the DALI "Initialize" command
void RTC_LaunchDAPCTimer(void)
This function:
•
Initializes the timeout (200 ms) - expiration of the DALI "DAPC sequence" command
void PowerOnTimerReset(void)
This function:
•
Stops the power-on timeout (600 ms) which was started during power-on (using the
Timer_Lite_Init() function)
void Lite_timer_Interrupt(void)
This function is the main timer function servicing all timers. It:
•
Is a callback function that receives 1 ms timer ticks from the DALI I/O pin driver layer
•
Runs in interrupt
•
Updates the timer event flag used for updating the virtual timers (1 ms each)
u8 Process_Lite_timer_IT(void)
This function is called cyclically from the user main program loop in 1 ms intervals when the
timer event flag is signalled. It:
•
Services timer events (if necessary)
•
Calls callbacks or updates virtual timer values
DocID025866 Rev 1
Function description
19/31
31
Need help?
Do you have a question about the STM32F1 Series and is the answer not in the manual?
Questions and answers