github.com / descampsa
Arduino shield to connect Dynamixel servomotors

Dynamixel shield

This is an arduino shield to control dynamixel servo motors from Robotis. AX and MX series (TTL version) are supported. Thanks to their half-duplex serial control protocol, you can chain them and control a lot of motor simultaneously (up to 254 in theory). It is possible to control those motors with an arduino without additionnal hardware, but this board makes it easier and cleaner.

First install the ardyno library, using the Arduino Library Manager, or directly from the github repository. Then open the "test_led" example and upload it. The shield can not be installed when you install the program. Install the shield, check that the jumpers are on 'HW' position, connect the motor and a 12v power supply, and voila, the motor "led" should start blinking! To get the motor moving (that's the point, after all), check the "test_motor" exemple. The documentation is still lacking, but by browsing examples and code, you should be able to do understand how it works. If you have any question, just ask.

The default mode explained above is to use the first hardware UART (Serial) of the board to communicate with the motors. This has the advantage that you can usethe full communication speed (up to 2Mbaud, by default 1Mbaud) of the protocol. However, boards that only have one hardaware uart (e.g. Uno), that means that you can't simultaneously use the USB port to communicate with the external world, since it also uses this UART. If you want to do that, you have to use the SoftwareSerial mode. The disadvantage is that you are limited to low baud rates (check the SoftwareSerial library documentation). You will have to change the baud rate of the motor using the hardware serial before (see "test_speed" example).

To use the SoftwareSerial mode, change the jumper to 'SW' position, and replace the line

HardwareDynamixelInterface interface(Serial,2);


SoftwareDynamixelInterface interface(4,3,2);

The first version take the hardware serial instance, and the direction pin as parameters, while the second one take rx pin, tx pin and direction pin.

For boards that have multiple hardware uart, you may use any of those ports by connecting the corresponding pins to the 'EXT' connector. Just set the jumper to 'EXT ONLY' position, and connect RX/TX/DIR pins to the rx/tx pins of the uart and the direction pin configured in your code.

Most of the code is platform independent, but it has only been tested with AVR boards. If you want to use another platform and find a bug, open an issue in ardyno repository. The shield supports both 5V and 3.3V boards.

I also successfully tested it with the Arduino 101, but there are still a few shortcomings in the serial libray of this board, so this is experimental.

The good news is that all is open source, the kicad project, gerber file, code, bom, all you need to make your own. Gerber and bom are also available on kitnic, where you may order the parts very easily. The bad news is that you can't buy one, i do not sell it for now. I have a few unpopulated pcb left, however, so if you are interested, just ask and i will send you one for shipping cost.

This board is functionnal, but has not yet been tested extensively, especially for high loads. Make sure you know what you are doing if you use it.

Q11MOSFET N TO-252-2LeadON semiconductorNTD4904NT4GNTD4904NT4GOSCT-ND863NTD4904NT4G
F12F Small Fuse Fuseholder5x20 horiz lateralLittelfuse01110501ZF4189-ND57601110501Z69R77051848686
F1_10A1Fuse 5x20 10ALittelfuse5ST 10-R507-1256-ND5305ST10R
F1_5A1Fuse 5x20 5ALittelfuse5ST 5-R507-1253-ND5305ST5R
P11BARREL JACK DC Barrel JackCUI Inc.PJ-102AHCP-102AH-ND490PJ102AH
P21CONN 01X02 Connector 01x02 bornier2 5.08mmTE Connectivity1776493-2A122765-ND5711776493295Y9029
U1174AHCT1G126 SOT-353Diodes Incorporated74AHCT1G126SE-774AHCT1G126SE-7DICT-ND62174AHCT1G126SE72057393
U2174AHC1G125 SOT-353Diodes Incorporated74AHC1G125SE-774AHC1G125SE-7DICT-ND62174AHC1G125SE747T38811893809
C11CP 47uF Polarised capacitor c elec 6.3x5.8 25V 20%PanasonicEEE-1EA470WPPCE3908CT-ND667EEE1EA470WP49W50882284803
R1,R2,R3,R4,R65R 10K Resistor 0603PanasonicERJ-3GEYJ103VP10KGDKR-ND667ERJ3GEYJ103V732565697W74702059627
R51R 200 Resistor 0603PanasonicERJ-3GEYJ201VP200GCT-ND667ERJ3GEYJ201V732576965T85972059582
D11LED 0603 RedOSRAM Opto SemiconductorsLS Q976-NR-1475-2512-1-ND720LSQ976NR1
P31CONN 01X03 Connector 01x03 Pin Header Angled 1x03 2.54mmMolex22-28-8030WM50013-03-ND5382228803091M6511
P4,P5,P6,P74CONN 01X03 Connector 01x03 Molex spox 1x3 right 2.5mmMolex22-05-7035WM18901-ND53822057035687809557R9151
P8,P92CONN 01X03 Connector 01x03 Molex spox 1x3 straight 2.5mmMolex22-03-5035WM18887-ND53822035035687804898K65529979620
JP1,JP2,JP33JUMPER4 Pin Header Straight 1x04 2.54mmMolex22-28-4030WM50014-03-ND5382228403056H1960
JP41JUMPER3 Pin Header Straight 1x03 2.54mmMolex22-28-4040WM50014-04-ND5382228404029X19622381172
JP1_,JP2_,JP3_,JP4_4SHUNT 1x2 2.54mmAmphenol FCI68786-102LF609-3121-ND64968786102LF53K14692579771
SHIELD11Arduino Shield stacking headers for Arduino (R3 Compatible)1528-1074-ND48585