Making robots with AX-12A servos

I’ve been getting my head around Robotis AX-12A servos, and am so far at the stage where I can control a weird robot arm with an arduino. It was a bit difficult to navigate to this point, and there was some interest from a friend (Les), so I thought I’d share what I needed to get and do. Please note that I otherwise have no knowledge of robots and this is all based on naive guesswork. But it works!

Motivation

I’m talking/working with algorithmic choreographer Kate Sicchio about patterns in choreography, and although she is already way ahead working with robots herself on her ongoing projects, I thought it would be good to start from scratch exploring patterns of movement, with simple robots that we could duplicate in both of our labs.

AX-12A servos a handy modules for this, I think it’s what Patrick Tresset uses for his drawing robots. You can link them together with standard parts, screwing them together into arms etc a bit like lego.

The aesthetic is of course very post industrial engineering, all gray and black modules. It’s well designed, fitting together nicely, and with some nice feedback data – it’ll be interesting to explore two-way interaction with the servos. So it’s a nice platform for prototyping, but nonetheless longer term we will likely want to explore cheaper, more textile approaches to robots, following from Dave’s earlier work on his Penelopean maypole dancers.

Warning

Please see the note below about the very damaging potential of connecting a 12v supply up to your laptop. Please be careful!

Shopping list

So what do you need to start making custom robot arms?

  • The AX-12A servos themselves. You can get them in a bulk box of six, which is better value, but they don’t come with anything else so it takes a while to find out what else you need. Read on
  • Bits of plastic for connecting the servos together into something like an arm. I got a pack of FP04-F3 (flat panels for making twisty type joints) and FP04-F2 (‘c’ shapes for making elbow type joints). I realised after that to make use of the latter I also needed a “BPF WA/BU set”.
  • Screws/bolts and nuts. You’ll need M2x6 bolts (a standard size meaning 2mm across and 6mm long) and matching M2 nuts (I got 50 of each) for connecting the servos together and M3x10 bolts (I got 20) for attaching the FP04-F2 to the servos with the “BPF WA/BU set” bits.
  • Something for telling the servos what to do. I already had arduinos for this, but needed to get a “dynamixel shield” as well.
  • Something for communicating with the dynamixel board while it’s running. Unfortunately this can’t be the arduino that the shield is sitting on. I used a second arduino, following the EXCELLENT instructions in the video below.
  • Cables! This took ages to work out.
    • You need “Robot cable-3P” for connecting the servos together, I got a pack of 10, 140mm long. This was guesswork, but they’re just about long enough when using the plastic bits to connect the servos fairly closely together.
    • Annoyingly, the 3P has the wrong connector for the dynamixel shield. Luckily, I’d originally bought the “Robot cable-X3P” cables which happened to have the right connector for the shield (but the wrong one for the servos). So I ended up splicing an X3P and 3P cable together. But that’s an expensive way to do it. Alternatively you could just use some male-female jumper cables or something to go between a 3P cable and the board.
  • A power supply for the servos, between 9v-12v. I used a 12v, 2250mA power supply that I had lying around.

In terms of getting it all to work, the below fantastically explained video helped massively and probably saved me days worth of stress:

First test

Here’s my first test:

Notes / tips

Important: There was a jumper on the board, that should be removed otherwise I think it’ll try to get power from the arduino, and in the process connect up the 12v power supply with somewhere bad (like a laptop).

Again, the above video is super helpful. They talk through a lot of stuff, including how to use a second arduino to get a serial connection to the dynamixel shield for debugging.

The example dynamixel arduino code needs the baud rate changing to 1000000, and protocol to 1.0.

0 thoughts on “Making robots with AX-12A servos”

Leave a Reply

Your email address will not be published.