What Is It
The sliding potentiometer is commonly used for controlling electrical devices such as an indoor LED dimmer or a volume fader of an audio equipment.
How It Works
The sliding potentiometer is a type of resistors for controlling current in the circuit by changing its resistence.
When the sliding contact moves from one end to another, the output voltage (Vcc) will vary from 0 to 3.3V. The change of voltage is converted into a digital signal by the microcontroller which ranges from 0-1023.
Real World Analogy
Codecraft
You can find blocks that control the sliding potentiometer in the tab Sensing in Codecraft.
Extension Knowledge
Up to 4 sliding potentiometers can be connected to one mainboard in a time. We can order their numbers according to the switch contacts on the back of them.
Below are the contact images and their number order.