---temp fix not sending after join issue... way to go
This commit is contained in:
parent
b1de2c6e20
commit
c800e4522a
|
@ -1412,19 +1412,19 @@ static void OnJoinRequest(LmHandlerJoinParams_t *joinParams)
|
|||
if (STS_LoRa_WAN_Joined)
|
||||
{
|
||||
heart_beat_timer = 1;
|
||||
SendTxData();
|
||||
//SendTxData();
|
||||
|
||||
//UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
|
||||
UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
|
||||
|
||||
//UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
|
||||
UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
|
||||
|
||||
//UTIL_TIMER_Start(&TxTimer);
|
||||
//UTIL_TIMER_Start(&STSDurationCheckTimer);
|
||||
OnYunhornSTSHeartBeatPeriodicityChanged(HeartBeatPeriodicity);
|
||||
|
||||
//UTIL_TIMER_Create(&YunhornSTSRSSWakeUpTimer, YUNHORN_STS_RSS_WAKEUP_CHECK_TIME, UTIL_TIMER_PERIODIC, OnYunhornSTSOORSSWakeUpTimerEvent, NULL);
|
||||
UTIL_TIMER_Create(&YunhornSTSRSSWakeUpTimer, YUNHORN_STS_RSS_WAKEUP_CHECK_TIME, UTIL_TIMER_ONESHOT, OnYunhornSTSOORSSWakeUpTimerEvent, NULL);
|
||||
UTIL_TIMER_Start(&YunhornSTSRSSWakeUpTimer);
|
||||
//UTIL_TIMER_Create(&YunhornSTSRSSWakeUpTimer, YUNHORN_STS_RSS_WAKEUP_CHECK_TIME, UTIL_TIMER_ONESHOT, OnYunhornSTSOORSSWakeUpTimerEvent, NULL);
|
||||
//UTIL_TIMER_Start(&YunhornSTSRSSWakeUpTimer);
|
||||
|
||||
STS_SENSOR_Distance_Test_Process();
|
||||
|
||||
|
@ -1689,12 +1689,11 @@ static void OnYunhornSTSOORSSWakeUpTimerEvent(void *context)
|
|||
|
||||
if ((sts_rss_result_changed_flag == 1) || (sts_fall_rising_detected_result_changed_flag == 1))
|
||||
{
|
||||
SendTxData();
|
||||
//SendTxData();
|
||||
sts_rss_result_changed_flag = 0;
|
||||
sts_fall_rising_detected_result_changed_flag = 0;
|
||||
|
||||
|
||||
//UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
|
||||
UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
|
||||
//if ((last_sts_rss_result ==STS_RESULT_NO_MOTION)&& (sts_rss_result==STS_RESULT_MOTION))
|
||||
{
|
||||
//OnSensor3StateChanged();
|
||||
|
@ -1738,7 +1737,7 @@ static void OnYunhornSTSHeartBeatPeriodicityChanged(uint32_t periodicity)
|
|||
/* USER CODE BEGIN OnTxPeriodicityChanged_1 */
|
||||
|
||||
/* USER CODE END OnTxPeriodicityChanged_1 */
|
||||
#if 0
|
||||
#if 1
|
||||
HeartBeatPeriodicity = periodicity;
|
||||
|
||||
if (HeartBeatPeriodicity == 0)
|
||||
|
@ -1750,7 +1749,7 @@ static void OnYunhornSTSHeartBeatPeriodicityChanged(uint32_t periodicity)
|
|||
/* Update timer periodicity */
|
||||
|
||||
UTIL_TIMER_Stop(&YunhornSTSHeartBeatTimer);
|
||||
UTIL_TIMER_SetPeriod(&YunhornSTSHeartBeatTimer, periodicity);
|
||||
UTIL_TIMER_SetPeriod(&YunhornSTSHeartBeatTimer, HeartBeatPeriodicity);
|
||||
UTIL_TIMER_Start(&YunhornSTSHeartBeatTimer);
|
||||
|
||||
/* USER CODE BEGIN OnTxPeriodicityChanged_2 */
|
||||
|
@ -2887,12 +2886,13 @@ void OnRestoreSTSCFGContextProcess(void)
|
|||
HeartBeatPeriodicity = samplingperiodicity*1000;
|
||||
#endif
|
||||
#if defined(STS_O7)|| defined(STS_O6) ||defined(STS_O5)
|
||||
if (STS_LoRa_WAN_Joined !=0) {
|
||||
//if (STS_LoRa_WAN_Joined !=0)
|
||||
{
|
||||
HeartBeatPeriodicity = periodicity;
|
||||
OnYunhornSTSHeartBeatPeriodicityChanged(HeartBeatPeriodicity);
|
||||
} else {
|
||||
OnYunhornSTSHeartBeatPeriodicityChanged(APP_TX_DUTYCYCLE);
|
||||
}
|
||||
} //else {
|
||||
//OnYunhornSTSHeartBeatPeriodicityChanged(APP_TX_DUTYCYCLE);
|
||||
//}
|
||||
|
||||
OnYunhornSTSSamplingPeriodicityChanged(sampling); // in m-sec unit
|
||||
#endif
|
||||
|
@ -2931,7 +2931,7 @@ void OnRestoreSTSCFGContextProcess(void)
|
|||
// if ((sts_version == sts_cfg_nvm.version)&& (NVM_CFG_PARAMETER_SIZE == sts_cfg_nvm.length))
|
||||
{
|
||||
STS_PRESENCE_SENSOR_Init();
|
||||
STS_PRESENCE_SENSOR_RSS_Init();
|
||||
//STS_PRESENCE_SENSOR_RSS_Init();
|
||||
}
|
||||
#endif
|
||||
//STS_SENSOR_Distance_Test_Process();
|
||||
|
|
|
@ -154,6 +154,7 @@
|
|||
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.optimization.level.1119592399" name="Optimization level" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.optimization.level" useByScannerDiscovery="false" value="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.optimization.level.value.os" valueType="enumerated"/>
|
||||
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.definedsymbols.2024044405" name="Define symbols (-D)" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.tool.c.compiler.option.definedsymbols" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="CORE_CM4"/>
|
||||
<listOptionValue builtIn="false" value="CLOCK_SYNC"/>
|
||||
<listOptionValue builtIn="false" value="RM2_1"/>
|
||||
<listOptionValue builtIn="false" value="STS_O7"/>
|
||||
<listOptionValue builtIn="false" value="YUNHORN_STS_RANDOM"/>
|
||||
|
|
Loading…
Reference in New Issue