LEADS
LEADS copied to clipboard
Implement a Hardware Low Pass Filter
Function
Input
A PWM analog input
Output
The average voltage of the PWM input
@ATATC can you point me to the codeset instruction where you are generating the input to the LPF? Are you sure it is a PWM signal? The signal you are showing on the diagram is not a PWM signal. Anyway, assuming it is a PWM signal, a single pole RC (passive) LPF should suffice.
That blog seems to be what we want. I did not really look into the diagram.
This is how we control the motor: https://gpiozero.readthedocs.io/en/stable/api_output.html#motor