A soft pot works just like a regular potentiometer; however, instead of turning a dial, you slide (your finger) up and down the strip to change the values. This post details how to hook up to an Arduino.
- Soft Pot
- 3 Jumper wires (yellow, red & black)
- USB cable (A to B)
If you’ve already read my post on How to Hook Up A Potentiometer, then all you need to know is which lead is which (You can even use the same code). See step 1 below.
- A typical soft pot has 3 leads. Like a regular potentiometer, the outer leads are for power and the middle lead is for the value. However, unlike a regular potentiometer, the outer leads are predetermined as positive and negative. On my soft pot (by Spectra Symbol), the film is clear and you can see the traces from the leads. The one that traces all the way to the opposite end of the leads is positive. Obviously, the other one is negative.
- With each lead in separate rows on the breadboard, place (red) wire from the positive lead of the soft pot to a 5V pin on the Arduino.
- Place (black) wire from the negative lead of the soft pot to a Ground pin on the Arduino.
- Place (yellow) wire from the middle lead of the soft pot to an Analog pin (0) on the Arduino.
- Connect the Arduino to your computer using the USB cable (A to B).
- The code below reads in the value of the soft pot’s pin and prints it to the Serial Monitor (within the Arduino software). Upload it to your board. Lay the soft pot on a firm, flat surface and slowly slide your finger up and down while watching the values change in the Serial Monitor.
int softPot = 0;
The soft pot works by changing the resistance depending on where pressure is positioned along the strip. For more information: http://www.spectrasymbol.com/how-it-works-softpot
Leave a Reply
You must be logged in to post a comment.