Driving a servo with a Beaglebone Blue

How can I drive a servo motor on the BeagleBone Blue using Nerves?

Do I need to add a device tree overlay for PWM support in a custom Nerves system?

There are premade BeagleBone device tree overlays are located in /lib/firmware, and there is likely one for PWM. This means you don’t have to create a custom Nerves system unless you want to. The overlay can be applied at runtime with the BeagleBone config-pin utility (see this elixir wrapper), or applied to the Nerves system by adding the overlay to provisioning.conf.

The easiest way to drive servos is to use an I2C servo controller. That way you could use circuits_i2c.

2 Likes