fusion-zauberstab/firmware/include/dc_cancelation.h
Thomas Schmid 32f3f3c273 add dc_cancelation filter
Signed-off-by: Thomas Schmid <tom@lfence.de>
2022-06-18 11:17:06 +02:00

11 lines
310 B
C

#pragma once
struct dc_cancelation_state {
float x_n1;
float y_n1;
float R;
};
void dc_cancelation_init(struct dc_cancelation_state *state, float R);
void dc_cancelation_set_R(struct dc_cancelation_state *state, float R);
float dc_cancelation_update(struct dc_cancelation_state *state, float x);