PDA

View Full Version : Arbotix<>Sanguino



Shredder
03-24-2011, 06:35 PM
Let me start by saying, I purchased a Arbotix.. and I LOVE it.. its awesome.. I have it on my humanoid right now. The only problem I have with it, is its size. Now mind you, its actually pretty small.. very nicely designed. I just had to use some standoffs on the back of the stock robotis torso.
My goal is to move the arbotix inside the chest of the humanoid.. now I dont need the motor controllers, so I was thinking I could just take a Sanguino and put the arbotix bootloader on it and stuff the basic sanguino inside, then mouth the xbee somewhere on its own.

I guess the main question is, is this possible? Just loading the arbotix bootloader on the sanguino and using it? Id think you had to wire pin 11 of the sanguino to the dynamixel connector since pin 11 on sanguino is connected to pin 17 on the 644P? Also adjusting the pins on the xbee to match the right pins?

p.s. The Arbotix is going to go on my quad I am designing for next years mech war.. as soon as I get my Zen Tool Works 12x12 working I start cutting the parts ;)

Shredder
03-26-2011, 04:23 PM
hmm no ones tried this?

Upgrayd
03-26-2011, 05:35 PM
If I understand what you are asking then yes you could remove the microcontroller from the arbotix board and use it as you wish.

As far as I understand the Arbotix and the Sanguino are both AVR Atmega644 microchips with versions of the Arduino bootloader on them.

tician
03-26-2011, 10:59 PM
Although Fergs would have the far greater knowledge/experience to say with certainty... If you were to properly rewire the relevant pins of the Sanguino to match the Arbotix, I do not foresee any problems using the Arbotix bootloader on the Sanguino (they are both Arduino compatible, are they not?). You would have to get an AVR-ISP dongle to upload it.

Shredder
03-28-2011, 03:35 PM
Over the weekend I tried.. The arbotix boatloader seemed to install fine, pypose seemed to install fine.
I connect my external power supply to the dynamixels and pin 11 of the sanguino to the dynamixel bus and I get read errors when trying to capture a pose.
I cant even think of how to start trouble shooting this lol

tician
03-28-2011, 06:35 PM
I think it is rather humorous for me (a guy who has wasted two weeks trying to get a simple ATmega168 to function on a dynamixel bus for more than one consecutive byte of data) to be attempting to give out advice, but...

Looking at the respective schematics, I have two questions to ask of you:
Are pins 11 (TXD1/INT1) and 10 (RXD1/INT0) of the Sanguino both connected to the data line of the dynamixel bus?
Are your connections to the dynamixel bus correct (pin assignment of the connector, see the AX-12+ diagram (http://support.robotis.com/en/techsupport_eng.htm#product/dynamixel/dxl_ax_main.htm))?

Shredder
03-29-2011, 04:01 PM
I think it is rather humorous for me (a guy who has wasted two weeks trying to get a simple ATmega168 to function on a dynamixel bus for more than one consecutive byte of data) to be attempting to give out advice, but...

Looking at the respective schematics, I have two questions to ask of you:
Are pins 11 (TXD1/INT1) and 10 (RXD1/INT0) of the Sanguino both connected to the data line of the dynamixel bus?
Are your connections to the dynamixel bus correct (pin assignment of the connector, see the AX-12+ diagram (http://support.robotis.com/en/techsupport_eng.htm#product/dynamixel/dxl_ax_main.htm))?
No they are not.. and here is why (I believe) ;)

I am not sure if its the RS-485 protocol that is bidirectional.. but I do believe the way the dynamixel uses it, is.
I read over the code and the header files and noticed that the code sets the serial into either a TX or RX mode. Also if you look at the schematic of the arbotix, I dont think the RX line is connected to anything. Pypose doesnt use the standard Serial1 library to communicate with the dynamixels.. it uses its own I think.

tician
03-30-2011, 02:02 PM
If you look at your Arbotix there should be a three pin header named J1 with a small jumper between two of the pins. That is where the RXD1 and TXD1 lines are shorted together. They were not connected together by a trace on the board to allow the use of the RX-bridge (the RS-485 dynamixel bus is half-duplex just like the TTL level dynamixel bus) which has a level converter/driver chip with independent RXD and TXD pins. There is a third pin on the driver chip that switches between the two modes and I believe it is connected to the SERVOB signal.

Bottom line, you must connect both RXD1 and TXD1 signals to the TTL data line of the dynamixel bus. The microcontroller turns off the TXD1 UART hardware functions while it is receiving and turns off the RXD1 UART hardware functions while transmitting (thus requiring no external hardware to make the UART half-duplex). When the UART hardware is turned off, the pins return to whatever their previous functions/states were (by default they should tri-state inputs, and it is a bad idea to change the RXD1 and TXD1 pins to outputs as it will lock the data line either high or low).

UART1 (RXD1 and TXD1) is dedicated to the dynamixel bus (at either TTL or RS-485 levels). The XBee and FTDI cable are connected to UART0 (RXD0 and TXD0) allowing communication with the PC to be completely independent from the dynamixel bus.