fix: update_moving_average window 参数 uint8_t→uint16_t (同步 DLD154V4B)

This commit is contained in:
wangfq
2026-06-29 15:55:59 +08:00
parent 1ca7f01cdf
commit 23f33d9af5
2 changed files with 2 additions and 2 deletions

View File

@@ -203,7 +203,7 @@ void poll_yellow_led_single(Loop154_Unit *unit);
uint32_t get_flt_value(uint32_t new_value, uint32_t last_Value);
uint8_t update_moving_average(uint32_t* p_sum, uint16_t* p_cnt,
uint32_t* p_origin, uint32_t new_value,
uint8_t window);
uint16_t window);
void set_loops_relay_on(uint8_t loop_num);
void set_loops_relay_off(uint8_t loop_num);

View File

@@ -49,7 +49,7 @@ uint32_t get_flt_value(uint32_t new_value, uint32_t last_Value)
*===========================================================================*/
uint8_t update_moving_average(uint32_t* p_sum, uint16_t* p_cnt,
uint32_t* p_origin, uint32_t new_value,
uint8_t window)
uint16_t window)
{
if (!p_sum || !p_cnt || !p_origin || window == 0) return 0;