Wobble smoothing
To reduce high frequency noise.
Algorithm: Wobble smoothing
Input :
,
(from wobble_smoother_timeout),
(from wobble_smoother_speed_floor) and
( from wobble_smoother_speed_ceiling)
Compute a weighted moving average of the positions
Calculate a moving average
velocity
Interpolate between the
average position and the raw ones based on the average speed
where
Output:
the filtered positions.
Hence for low local speeds, the smoothing is maximum (we take exactly
the average position over the time
)
and for high speed there is no smoothing. We also note that the first
position is thus never filtered.