Simplify distance sensor filtering
The throttle filter has a side effect of not updating the value when measurements are out of range. switching to throttle_average is simpler and solves this problem
This commit is contained in:
parent
d45c4dcf11
commit
dc796e6b00
|
@ -132,12 +132,7 @@ sensor:
|
|||
ratgdo_id: ${id_prefix}
|
||||
unit_of_measurement: "mm"
|
||||
filters:
|
||||
- throttle: 1s
|
||||
- filter_out: -1
|
||||
- median:
|
||||
window_size: 20
|
||||
send_every: 5
|
||||
send_first_at: 5
|
||||
- throttle_average: 1s
|
||||
- platform: adc
|
||||
pin: GPIO34
|
||||
name: "Voltage"
|
||||
|
|
Loading…
Reference in New Issue