Fahad Mirza
/
Nucleo_HXC900
A demo application for HXC900 LoRaWAN module using Nucleo-L053R8.
Diff: Utilities/time_server.c
- Revision:
- 32:2d0678039a09
- Parent:
- 5:53302861bfea
--- a/Utilities/time_server.c Mon Dec 10 19:54:23 2018 +0000 +++ b/Utilities/time_server.c Thu Jan 24 21:57:23 2019 +0000 @@ -112,14 +112,6 @@ static void TimerSetTimeout( TimerEvent_t *obj ); /*! - * \brief Set timer new timeout value - * - * \param [IN] obj Structure containing the timer object parameters - * \param [IN] value New timer timeout value - */ -static void TimerSetValue( TimerEvent_t *obj, uint32_t value ); - -/*! * \brief Check if the Object to be added is not already in the list * * \param [IN] timestamp Delay duration @@ -140,9 +132,8 @@ obj->Next = NULL; } -void TimerStart( TimerEvent_t *obj, uint32_t timeoutMs ) +void TimerStart( TimerEvent_t *obj) { - TimerSetValue(obj, timeoutMs); uint32_t elapsedTime = 0; BACKUP_PRIMASK(); @@ -377,11 +368,11 @@ return false; } -//void TimerReset( TimerEvent_t *obj ) -//{ -// TimerStop( obj ); -// TimerStart( obj ); -//} +void TimerReset( TimerEvent_t *obj ) +{ + TimerStop( obj ); + TimerStart( obj ); +} /****************************************************************************** * @Brief : Set timer new timeout value @@ -389,7 +380,7 @@ * value - timeout value * @Return : None ******************************************************************************/ -static void TimerSetValue( TimerEvent_t *obj, uint32_t timeoutMs ) +void TimerSetValue( TimerEvent_t *obj, uint32_t timeoutMs ) { uint32_t minValue = 0; uint32_t ticks = HW_RTC_ms2Tick( timeoutMs );