To whom it may concern,
Hello. I have a question about how to smooth out the noise/messy signal using a capacitor when it comes to controlling a joystick with an Arduino.
The link is pasted down below to view a photo. There are three photos within a link; Arduino/joystick diagram, photo, and signal wave.
LINK : https://imgur.com/a/dARk6hX
As you can know, the signal is not always constant as shown in one of the photos. The signal is received by a pin A4 (Analog Pin) on Arduino Mega.
My goal here is to get rid of the unstable-messy signal wave and to smooth it out using a capacitor.
Does anyone have any ideas on how to wire a capacitor to smooth out the messy signal? And also, what type of capacitor should I use?
If someone could paste the diagram on how to wire a capacitor and also show an electrical calculation with a detailed explanation, that would be very helpful.
Best Regards,
Alex