Smooth Potentiometer Input




About: I am an electrical engineer and an Arduino and electronics enthusiasts. I believe working with electricity should be fun as well as beneficial to engineers and the world at large. Twitter handle: @arduinoha...

Potentiometers come in handy when you want to control outputs with an arduino board or basic electronics. Recently, i embarked on a certain project that required me to adjust the brightness and speed of LED strip patterns. So, i used two potentiometers to control both parameters. I will show you how to do that in my next tutorial. However, right now, i want to tackle a challenge that i faced - getting a smooth potentiometer input.

Sometimes, actually in most cases, potentiometers produce a jittery signal. This can be due to low quality material used to make the potentiometers. The jittery signal can be very irritating, especially if you are using the pot to control a sensitive output. That is why you need to look for a way to make the input smooth.


Step 1: Low Pass Filter

To smooth out the pot input, you should use a low-pass filter. It removes all signals that have a frequency that is above the set cut-off frequency. You determine the cut-off frequency by adjusting the values of capacitance and resistance in the circuit.

The formula for getting the cut off frequency is:


Fc- cutoff frequency



Therefore, you can calculate the value of resistance and capacitance you need by substituting the value of your cutoff frequency on the formula.

Since i needed a cutoff frequency of 1, I used a 10µF capacitor and a 16kΩ resistor

Step 2: Connection

The signal from the potentiometer is fed to the resistor; the capacitor is connected in parallel with the resistor and then to the ground; the signal is tapped from between the resistor and capacitor and fed to the arduino analogue pin as shown in the pictures.

Thats how you smooth out your pot output. For more on this topic, visit the following page.



    • Colors of the Rainbow Contest

      Colors of the Rainbow Contest
    • Woodworking Contest

      Woodworking Contest
    • Party Challenge

      Party Challenge



    2 years ago

    Nice showing that kind of filter. When I started with arduino, I had a lot of problems working with leds, but I used to solve it in code instead. In the code I stored the last pot value in a variable witch I used to compare with the actual value, if this value is smaller than 2, it's considered as a jitter and then descarted.