diff --git a/STM32CubeIDE/Release/WLE5CC_NODE_STS.elf b/STM32CubeIDE/Release/WLE5CC_NODE_STS.elf index c927508..1fe7746 100644 Binary files a/STM32CubeIDE/Release/WLE5CC_NODE_STS.elf and b/STM32CubeIDE/Release/WLE5CC_NODE_STS.elf differ diff --git a/STS/Core/Src/yunhorn_sts_process.c b/STS/Core/Src/yunhorn_sts_process.c index 8e8bb2d..0ab3589 100644 --- a/STS/Core/Src/yunhorn_sts_process.c +++ b/STS/Core/Src/yunhorn_sts_process.c @@ -644,30 +644,37 @@ void USER_APP_Parse_CMD_P(uint8_t *parse_buffer, uint8_t parse_buffer_size) switch (sts_fhmos_cfg_index) { case 1: // head level height threshold sts_fhmos_cfg.sts_head_level_height_threshold_cm = sts_fhmos_cfg_value; - sts_cfg_nvm.fhmos_cfg_1 = sts_fhmos_cfg.sts_head_level_height_threshold_cm; + break; case 2: sts_fhmos_cfg.sts_fall_duration_threshold_potential_15sec = sts_fhmos_cfg_value; - sts_cfg_nvm.fhmos_cfg_2 =sts_fhmos_cfg.sts_fall_duration_threshold_potential_15sec; + break; case 3: sts_fhmos_cfg.sts_fall_duration_threshold_confirm_15sec = sts_fhmos_cfg_value; - sts_cfg_nvm.fhmos_cfg_3 = sts_fhmos_cfg.sts_fall_duration_threshold_confirm_15sec; + break; case 4: sts_fhmos_cfg.sts_motionless_threshold_short_15sec = sts_fhmos_cfg_value; - sts_cfg_nvm.fhmos_cfg_4 = sts_fhmos_cfg.sts_motionless_threshold_short_15sec; + break; case 5: sts_fhmos_cfg.sts_motionless_threshold_long_15sec = sts_fhmos_cfg_value; - sts_cfg_nvm.fhmos_cfg_5 = sts_fhmos_cfg.sts_motionless_threshold_long_15sec; + break; case 6: sts_fhmos_cfg.sts_occupancy_threshold_overstay_15sec = sts_fhmos_cfg_value; - sts_cfg_nvm.fhmos_cfg_6 = sts_fhmos_cfg.sts_occupancy_threshold_overstay_15sec; + break; } - + /* + sts_cfg_nvm.fhmos_cfg_1 = sts_fhmos_cfg.sts_head_level_height_threshold_cm; + sts_cfg_nvm.fhmos_cfg_2 = sts_fhmos_cfg.sts_fall_duration_threshold_potential_15sec; + sts_cfg_nvm.fhmos_cfg_3 = sts_fhmos_cfg.sts_fall_duration_threshold_confirm_15sec; + sts_cfg_nvm.fhmos_cfg_4 = sts_fhmos_cfg.sts_motionless_threshold_short_15sec; + sts_cfg_nvm.fhmos_cfg_5 = sts_fhmos_cfg.sts_motionless_threshold_long_15sec; + sts_cfg_nvm.fhmos_cfg_6 = sts_fhmos_cfg.sts_occupancy_threshold_overstay_15sec; + */ OnStoreSTSCFGContextRequest(); // 2024-11-18