Servo motors are often driven using the PWM outputs available on most embedded MCUs. But while the Pi does have native HW support for PWM, there is only one PWM channel available to users at GPIO18. That kind of limits your options if you need to drive more than one servo or if you also want to dim an LED or do some sort of other PWM goodness as well. Thankfully ... the PI does have HW I2C available, which we can use to communicate with a PWM driver like the PCA9685, used on Adafruit's 16-channel 12-bit PWM/Servo Driver!
Using this breakout, you can easily drive up to 16 servo motors on your Raspberry Pi using our painless Python library and this tutorial.
Note this cannot be used for driving anything other than analog (1-2 millisecond pulse drive) servos. DC motors, AC motors and digital servos are not going to work.
What you'll need
We'll be using the following items in this tutorial:
Last updated on 2013-05-06 at 09.01.04 PM