circuit diagram servos...

hi all,

the arduino example of having a servo and potentiometer looks simple, however i have different wire outputs on my servo and potentiomenter (refer to photo), can anyone help me on how to wire the ardiuno with these different output things?

Thank you very much.


Forgive me if I misunderstood your original post.

Presuming you are using the ‘Knob’ example from the IDE, hook up the white wire from the servo to Digital Pin 9, and the red and black to 5v (if your servo runs on 5v) and GND respectively. Connect one of the outside posts of the potentiometer to 5v and the other to GND, and the middle (typically the wiper) to Analog Pin 0.

Then run the Knob sketch, and it should (hopefully) work!


What do you mean "different wire outputs on my servo"? Servos have three terminals, one for the positive supply, one for ground, and one for PWM control (usually color white or yellow).

apologies, what i meant (refer to photo) is that the wires on the servo are combined into a plastic box like structure at the end, and can only enter the circuit via a three pin header. The potentiometer has three pins, not three wires therefore I'm struggling to follow the 'knob' tutorial.

thank you for your help.

You connect the white servo wire to the arduino servo pin, the red servo wire to the servo power supply (do not use the arduino to power the servo), and the black servo wire to the servo power supply ground and to the arduino ground.

Sorry if this sounds condescending but sometimes you just have to ask. In your photo I see only a servo and a pot. You also need an Arduino (I'm sure you knew that), a breadboard, some hookup wire (jumpers) and a power supply of some sort. Do you have all this? You'll need it.