add warm up counter control for self boot up

This commit is contained in:
Yunhorn 2025-04-09 16:17:08 +08:00
parent d80a543d23
commit 66033b8db6
2 changed files with 5 additions and 2 deletions

View File

@ -141,7 +141,7 @@ volatile sts_cfg_nvm_t sts_cfg_nvm = {
// below 20 bytes for RFAC code
{0x0,0x0,0x0,0x0,0x0, 0x0,0x0,0x0,0x0,0x0, 0x0,0x0,0x0,0x0,0x0, 0x0,0x0,0x0,0x0,0x0}
};
static uint32_t sts_warm_up_count = 0;
#if defined(STS_O6)||defined(STS_O7)
extern volatile uint8_t sensor_data_ready;
extern volatile STS_OO_SensorStatusDataTypeDef sts_o7_sensorData;
@ -1129,6 +1129,8 @@ static void OnTxTimerEvent(void *context)
{
/* USER CODE BEGIN OnTxTimerEvent_1 */
if (sts_warm_up_count < 10)
{
/* USER CODE END OnTxTimerEvent_1 */
//if ((sensor_data_ready ==1)) //|| (sts_reed_hall_changed_flag)) //||(sts_rss_result_changed_flag)||(sts_fall_rising_detected_result_changed_flag))
//if ((sensor_data_ready ==1) || (sts_reed_hall_changed_flag) || (sts_rss_result_changed_flag)||(sts_fall_rising_detected_result_changed_flag))
@ -1136,7 +1138,8 @@ static void OnTxTimerEvent(void *context)
UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0);
}
/*Wait for next tx slot*/
sts_warm_up_count++;
}
UTIL_TIMER_Start(&TxTimer);
//}

Binary file not shown.