refine tx and heart-beat period
This commit is contained in:
parent
2551f86d85
commit
3601f4a51a
|
@ -540,9 +540,9 @@ void LoRaWAN_Init(void)
|
|||
UTIL_TIMER_Start(&YunhornSTSWakeUpScanTimer);
|
||||
#endif
|
||||
|
||||
//UTIL_TIMER_Create(&YunhornSTSHeartBeatTimer, 1000*STS_HeartBeatTimerPeriod_sec, UTIL_TIMER_PERIODIC, OnYunhornSTSHeartBeatTimerEvent, NULL);
|
||||
UTIL_TIMER_Create(&YunhornSTSHeartBeatTimer, 1000*STS_HeartBeatTimerPeriod_sec, UTIL_TIMER_PERIODIC, OnYunhornSTSHeartBeatTimerEvent, NULL);
|
||||
// UTIL_TIMER_Create(&YunhornSTSHeartBeatTimer, 1000*STS_HeartBeatTimerPeriod_sec, UTIL_TIMER_ONESHOT, OnYunhornSTSHeartBeatTimerEvent, NULL);
|
||||
// UTIL_TIMER_Start(&YunhornSTSHeartBeatTimer);
|
||||
UTIL_TIMER_Start(&YunhornSTSHeartBeatTimer);
|
||||
|
||||
/* USER CODE END LoRaWAN_Init_Last */
|
||||
}
|
||||
|
|
|
@ -1236,7 +1236,7 @@ void USER_APP_AUTO_RESPONDER_Parse(uint8_t *parse_buffer, uint8_t parse_buffer_s
|
|||
APP_LOG(TS_OFF,VLEVEL_M, "\nSTS Tx Periodicty changed to %u sec\n\r", STS_TxPeriod_sec);
|
||||
#ifdef STS_R4
|
||||
OnYunhornSTSTxPeriodicityChanged(STS_TxPeriod_sec*1000);
|
||||
#elif defined(STS_R1D)||defined(STS_R1)||defined(STS_R5)||defined(STS_P2)||defined(STS_O6T)||defined(STS_R2)||defined(STS_R3)||defined(STS_R6)
|
||||
#elif defined(STS_R1D)||defined(STS_R1)||defined(STS_R5)||defined(STS_P2)||defined(STS_O6T)||defined(STS_R2)||defined(STS_R3)||defined(STS_R6)||defined(STS_O5)
|
||||
OnYunhornSTSTxPeriodicityChanged(STS_TxPeriod_sec*1000);
|
||||
#elif defined(STS_O6)||defined(STS_O7)
|
||||
OnYunhornSTSHeartBeatPeriodicityChanged(periodicity_length);
|
||||
|
@ -1282,7 +1282,7 @@ void USER_APP_AUTO_RESPONDER_Parse(uint8_t *parse_buffer, uint8_t parse_buffer_s
|
|||
|
||||
STS_HeartBeatTimerPeriod_sec = heart_beat_or_sampling_periodicity_length;
|
||||
|
||||
#if defined(STS_P2)||defined(STS_R4)||defined(STS_T6)||defined(STS_R1D)||defined(STS_R5)
|
||||
#if defined(STS_P2)||defined(STS_R4)||defined(STS_T6)||defined(STS_R1D)||defined(STS_R5)||defined(STS_O5)
|
||||
OnYunhornSTSHeartBeatPeriodicityChanged(STS_HeartBeatTimerPeriod_sec*1000);
|
||||
#endif
|
||||
// LEGACY CODE, TO BE XXX LATER =============
|
||||
|
|
Loading…
Reference in New Issue