[beagleboard] Unable to control a servo via Beaglebone Black

This may be a dumb question but have you level shifted the 3.3 volt
output of the BBB to the 5 volts the servo requires? It sounds like the
servo is just barely picking up a peak pulse every so often.

Do you have a scope? Can you look at what is coming out of the BBB.


Assuming I can get the other stuff working (wireless connection…), one of the next things I also want to tackle is to control 2 servos. So I thought I would take a look.

So I went up to the lesson you mentioned. http://www.phys-x.org/rbots/index.php?option=com_content&view=article&id=106:lesson-3-beaglebone-black-pwm&catid=46:beaglebone-black&Itemid=81

Got to the step:
echo 20000000 > /sys/devices/ocp.2/pwm_test_P8_13.15/period
Failed, I looked and the device name is now:
echo 20000000 > /sys/devices/ocp.2/pwm_test_P8_13.14/period

So for a servo that centers at 1500us, I output:
echo 1500000 > /sys/devices/ocp.2/pwm_test_P8_13.14/duty

I looked at output from my Logic Analyzer (www.saleae.com), and I think the output was reversed. Looking at the other values for this device, I then:
echo 0 > /sys/devices/ocp.2/pwm_test_P8_13.14/polarity

Now the output looks correct. I have not wired up a power buss yet, so won’t test it with a servo. Also may look at moving to other PWM pins? Not sure if this pin interferes with the mmc? Also want a second one as well, so I can have both Pan and Tilt servos