Home
Robotis DX-113 Automobile Electronics User Manual
Contents
1. Motor Curve No reduction gear state n rpm 14000 12000 10000 8000 6000 4000 2000 DYNAMIXEL eI rm ROBOTIS Optional Frame Application Example OF 116H OF116S OF116B Body to Body Mount 40 DYNAMIXEL B CTI T ROBOTIS Full Option frame The CM 2 Board A dedicated board designed for controlling Dynamixel actuators Available optional parts Blue tooth module RS232 UART and 6 button blue tooth remote controller an be directly mounted on a multi degrees of freedom robot 41 DYNAMIXEL eI rm ROBOTIS Dynamixel Application Example
2. 4 0X0 Baud Rate RD WR 5 0X0 Return Delay Time RD WR 6 0X0 CW Angle Limit L 7 0 0 CW Angle Limit H RD WR 8 0X08 CCW Angle Limit L RD WR 9 0X09 CCW Angle Limit H D WR L H 2 TO OXOA 1 0X0B the Highest Limit Temperature RD WR 2 0X0C the Lowest Limit Voltage RD WR 3 0X0D the Highest Limit Voltage RD WR 5 0XOF Max Torque H RD WR 6 0X10 Status Return Level RD WR 7 0X11 Alarm LED RD WR 8 0X12 Alarm Shutdown RD WR 2 4 0 0 Max Torque L RD WR ESE DWR 20 0 14 210X15 22 0X16 23 0X17 Up Calibration H 0 0x00 0 0x00 0 0x00 0 0x00 32 0x20 32 0x20 Addr36 value Addr37 value Z4 0X18 Torque Enable _RD WR 250X19 RDWR 26 0 RD WR 27 0X15 RDWR BOXIT RD WR 9 0X1D RD WR 30 0X1E RD WR HOT RD WR 32 0X20 Moving Speed L RD WR Addr14 value Addr15 value A Z Z Z Z Z z Z D 34 0X22 RD WR 35 0X2 DWR 36 0X2 37 0X2 38 0X2 39 0X2 1000 2 TO S2 0X2A Present Voltage 13025 amp 0X2C 5 0 2 16 0 2 RW 1810530 RD WR 19100531 WR e 0 0x00 0 0x00 0 0x00 0 0x00 32 0x20 0 0x00 33 0X21 Moving Speed H RD WR Address 11 DYNAMIXEL Bp STI T ROBOTIS Control Table The Control Table consists of data for conditions and movement of the Dynamixel By writing the values in the control table you can move the Dynamixel and detect the condition of the Dy
3. Respond only to READ DATA instruction Respond to all instructions 13 DYNAMIXEL Bp STI T ROBOTIS In the case of an instruction which uses the Broadcast ID OXFE regardless of the Address 0x10 value the Status Packet will not be returned Address 0X11 Alarm LED When an Error occurs if the corresponding Bit is set to 1 then the LED blinks Be This function operates as the logical OR ing of all set bits For example when the register is set to 0X05 the LED will blink when a Voltage Error occurs or when an Overheating Error occurs Upon returning to a normal condition from an error state the LED stops blinking after 2 seconds Address 0X12 Alarm Shutdown When an Error occurs if the corresponding Bit is set to a 1 then the Dynamixel will shut down Torque off C C This function operates as the logical OR ing of all set bits However unlike the Alarm LED after returning to a normal condition it maintains a torque off status To remove this restriction Torque Enable AddressOX18 is required to be set to 1 Address 0x14 0x17 Calibration Data used for compensating for the differences between Robotis products Users cannot change this area 14 DYNAMIXEL Bp STI T ROBOTIS From Address 0x18 in the RAM area Address 0x18 Torque Enable When power is first applied the Dynamixel enters the Torque Free Run condition To allow torque to be applied Address 0x18 must be set
4. needs port Baud rate Interrupt value void Seriallnitialize byte bPort byte bBaudrate byte blnterrupt if bPort SERIAL PORTO UBRROH 0 UBRROL bBaudrate UCSROA 0x02 UCSROB 0x18 if bInterrupt amp RX_INTERRUPT sbi UCSROB 7 RxD interrupt enable UCSROC 0x06 UDRO OxFF sbi UCSROA 6 SET TXDO FINISH Note set 1 then 0 is read else if bPort SERIAL PORT1 UBRR1H 0 UBRRIL bBaudrate UCSRIA 0x02 UCSRIB 0x18 if bInterrupt amp RX_INTERRUPT sbi UCSR1B 7 RxD interrupt enable UCSR1C 0x06 UDR1 OxFF sbi UCSRIA 6 SET TXD1 FINISH Note set 1 then 0 is read 8 print data seperatly gt 1 void TxD8Hex byte bSentData byte bTmp bTmp byte bSentData gt gt 4 amp 0x0f byte 0 if bTmp gt 9 bTmp 7 TxD8 bTmp bTmp byte bSentData amp OxOf byte 0 if bTmp gt 9 bTmp 7 TxD8 bTmp Jk TxD80 send data to USART 0 void TxD80 byte bTxdData whi le TXDO_READY TXDO DATA bTxdData 81 0 send data to USART 1 void TxD81 byte bTxdData while TXD1_READY TXD1 DATA bTxdData TXD32DexO change data to decimal number system void TxD32Dec long Long byte bCount bPrinted ong IDigit bPrinted 0 if ILong lt 0 TxD8 Digit 100000000
5. 8 is necessary since an interrupt here may cause a delay longer than the return delay time and corruption to the front of the status packet may occur Byte to Byte Time The delay time between bytes when sending an instruction packet If the delay time is over 100ms then the Dynamixel actuator recognizes this as a communication problem and waits for the next header Oxff Oxff of a packet again Byte To Byte Time The following is the source code of a program Example c that accesses the Dynamixel actuator using the Atmega 128 29 DYNAMIXEL B GSE TES C Language Example Dinamixel access with Atmega128 define INST READ 0x02 The Example of Dynamixel Evaluation with Atmegal28 define INST WRITE 0x03 Date 2004 7 20 define INST REG WRITE 0x04 INST ACTION 0x05 define INST RESET 0x06 define ENABLE DEFINITIONS define INST DIGITAL RESET 0x07 include lt io h gt define INST SYSTEM READ 0 0 include lt inttypes h gt define INST SYSTEM WRITE 000 include lt avr io h gt define INST SYNC WRITE 0x83 amp include lt avr interrupt h gt define INST SYNC REG WRITE 0x84 amp include lt avr signal h gt ine CLEAR BUFFER gbRxBufferReadPointer gbRxBufferWr itePointer typedef unsigned char byte define DEFAULT RETURN PACKET SIZE 6 typedef unsigned int word define BROADCASTING ID Oxfe define ON 1 define OFF 0 define 1708 TxD
6. as the following TXD BUFFER READY BIT Indicates that the transmission DATA can be loaded into the Buffer Note that this only means that the SERIAL TX BUFFER is empty and does not necessarily mean that the all the data transmitted before has left the CPU TXD SHIFT REGISTER EMPTY BIT Set when all the Transmission Data has completed its transmission and left the CPU The TXD BUFFER READY BIT is used when one byte is to be transmitted via the serial communication channel and an example is shown below TxDByte byte bData while ITXD BUFFER READY wait until data can be loaded SerialTxDBuffer bData data load to TxD buffer 28 DYNAMIXEL Bp STI T ROBOTIS When changing the direction of RS 485 the TXD_SHIFT_REGISTER_EMPTY_BIT must be checked The following is an example program that sends an Instruction Packet LINE 1 PORT_485_DIRECTION TX_DIRECTION LINE 2 TxDByte Oxff LINE 3 TxDByte Oxff LINE 4 TxDByte bID LINE 5 TxDByte bLength LINE 6 TxDByte bInstruction LINE 7 TxDByte Parameter0 TxDByte Parameter1 LINE 8 Disablelnterrupt interrupt should be disable LINE 9 TxDByte Checksum last TxD LINE 10 while ITXD SHIFT REGISTER Wait till last data bit has been sent LINE 11 PORT 485 DIRECTION RX DIRECTION 485 direction change to RXD LINE 12 Enablelnterrupt enable interrupt again Please note the important lines between LINE 8 and LINE 12 Line
7. of Dynamixel from 1 to 0 Instruction Packet Instruction WRITE DATA Address 0x03 DATA 0x00 Communication gt Dynamixel FF FF 01 04 03 03 00 F4 LEN 008 lt Dynamixel FF FF 01 02 00 FC LEN 006 Status Packet Result NO ERROR Example 8 Change Baud Rate of Dynamixel to 1M bps Instruction Packet Instruction WRITE DATA Address 0x04 DATA 0 01 Communication gt Dynamixel FF FF 00 04 03 04 01 LEN 008 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR Example 9 Reset Return Delay Time of Dynamixel with ID 0 to 4us A Return Delay Time Value of 1 corresponds to 2us Instruction Packet Instruction WRITE DATA Address 0x05 DATA 0x02 22 DYNAMIXEL Bp CTI T ROBOTIS Communication gt Dynamixel FF FF 00 04 03 05 02 F1 LEN 008 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR The best approach is to set the Return Delay Time to the minimum value the Main Controller will allow Example 10 Limit the the operative angles of a Dynamixel with ID 0 to 0 150 If CCW Angle Limit is Ox3ff it is 300 therefore the values for 150 is Ox1ff Instruction Packet Instruction WRITE DATA Address 0x08 DATA Oxff 0x01 Communication gt Dynamixel FF FF 00 05 03 08 FF 01 EF LEN 009 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR Example 11 Reset the
8. sure both Dynamixels start at the same time If you use WRITE DATA instruction two Dynamixel can not start at the same time therefore use WRITE and ACTION Instruction Packet ID 0 Instruction WRITE Address Ox1E DATA 0x00 0x00 ID 1 Instruction REG WRITE Address Ox1E DATA Oxff 0x03 ID Oxfe Broadcasting ID Instruction ACTION Communication gt Dynamixel FF FF 00 05 04 1E 00 00 D8 LEN 009 lt Dynamixel FF FF 00 02 00 FD LEN 006 gt Dynamixel FF FF 01 05 04 1E FF 03 D5 LEN 009 lt Dynamixel FF FF 01 02 00 FC LEN 006 gt Dynamixel FF FF FE 02 05 FA LEN 006 Dynamixel No return packet against broadcasting ID Status Packet Result NO ERROR 26 DYNAMIXEL Bp ROBOTIS Example 20 Prevent the Dynamixel with ID 0 from changing values other than within the range between Address 0x18 and Address 0x23 Set Address 0x2F Lock to 1 Instruction Packet Instruction WRITE DATA Address 0x2F DATA 0x01 Communication gt Dynamixel FF FF 00 04 03 2F 01 C8 LEN 008 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR If Locked it can only be unlocked by removing power If trying to access other data areas whilst locked an error will be returned gt Dynamixell FF FF 00 05 03 30 40 00 87 LEN 009 lt Dynamixel FF FF 00 02 08 F5 LEN 006 Range Error Example 21 Set the minimum punch output in th
9. upper limit temperature of the Dynamixel with ID 1 to 80 Instruction Packet Instruction WRITE DATA Address 0x0B DATA 0x50 Communication gt Dynamixel FF FF 00 04 03 50 9D LEN 008 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR Example 12 Set the operative voltage of a Dynamixel with ID 0 to 10V gt 17V 10V is expressed as 100 0x64 and 17V as 170 0xAA Instruction Packet Instruction WRITE DATA Address DATA 0x64 OxAA Communication gt Dynamixel FF FF 00 05 03 64 AA DD LEN 009 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR 23 DYNAMIXEL Bp STI T ROBOTIS Example 13 Make the Dynamixel with ID 0 perform only 50 of the maximum torque Set the max torque values within the EEPROM area to 50 Ox1ff of the maximum value Ox3ff Instruction Packet Instruction WRITE DATA Address OxOE DATA Oxff 0x01 Communication gt Dynamixel FF FF 00 05 03 OE FF 01 E9 LEN 009 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR After a power off and on you can check the effect of the changes in max torque Example 14 Stop the Dynamixel with ID 0 from returning a Status Packet Instruction Packet Instruction WRITE DATA Address 0x10 DATA 0x00 Communication gt Dynamixel FF FF 00 04 03 10 00 E8 LEN 008 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Resul
10. 01 or bCount 0 bCount lt 9 bCount ITmp byte ILong IDigit if 1Tmp TxD8 byte Tmp 0 bPrinted lt 1 else if bPrinted TxD8 byte ITmp 0 ILong long ITmp IDigit IDigit IDigit 10 ITmp byte ILong IDigit if ITmp TxD8 byte 0 TxDStringO prints data in ACSII code void TxDString byte bData whi le xbData TxD8 bData RxD81 read data from Port 1 RxD810 return Read data byte RxD81 void whi le RXD1_READY RXD1 RESET return DATA SIGNAL UARTO Rx Interrupt write data to buffer SIGNAL SIG UARTO RECV gbpRxInterruptBuffer gbRxBufferWr itePointer RXDO DATA 33 DYNAMIXEL Bp CTI T ROBOTIS C Language Example Dinamixel access with Am188ER CPU include lt stdio h gt include lt stdlib h gt include lt conio h gt include lt dos h gt include lt mem h gt define MCS80 include base h include lib188es c define RS485_DIRECTION_BIT 0x2000 define RS485 TXD SET PORT1 RS485 DIRECTION BIT define RS485 RXD RESET PORT1 RS485 DIRECTION BIT define BROADCASTING ID Oxfe m define MEMORY SPARE 10 Definition area define ADDRESS TORQUE ENABLE 20 define ADDRESS OPERATING MODE 19 define ADDRESS ID 3 define ADDRESS GOAL POSITION 26 define INST PING 0x01 define INST READ 0x02 define INST WRI
11. 3 Parameter1 Start Address of the Area to write Data Parameter2 1st Data to write Parameter3 2nd Data to write Parameter N 1 Nth Data to write Example 1 Set ID of connected Dynamixel as 1 Write 1 into the Address 3 of the Control Table The ID is transmitted using Broadcasting ID OxFE 18 DYNAMIXEL Bp STI T ROBOTIS Instruction Packet OXFF OXFF OXFE 0X04 0X03 0X03 0X01 OXF6 a eee RA ID LENGTH INSTRUCTION PARAMETERS CHECKSUM Because it was transmitted by Broadcast ID OXFE no return status packet 4 2 READ_DATA Function Read data from the Control Table of Dynamixel Length 0X04 Instruction 0702 Parameter1 Starting Address of Data to Read Parameter2 length of Data to Read Example 2 Read the internal temperature of the Dynamixel with ID 1 Read 1 byte from the Address Ox2B values of the Control Table Instruction Packet OXFF OXFF 0X01 0X04 0X02 OX2B 0X01 0XCC aM UR AR ID LENGTH INSTRUCTION PARAMETERS CHECKSUM The returned Status Packet will be as follows Status Packet OXFF OXFF 0X01 0X03 0X00 0X20 OXDB mS NAE ANS ID LENGTH 1 The value read is 0x20 The current Dynamixel s internal temperature is approximately 32 0X20 4 3 REG WRITE and ACTION 4 3 1 REG WRITE 19 DYNAMIXEL Bp STI T ROBOTIS Fun
12. 81 define _ON 0 define RxD8 RxD81 Hdefine OFF 1 Hardware Dependent Item Control Table Address define DEFAULT BAUD RATE 34 57600bps at 16MHz EEPROM AREA define RS485 TXD PORTE _BV PE2 485 DIRECTION 1 define MODEL NUMBER 1 0 define RS485 RXD PORTE amp BV PE2 PORT 485 DIRECTION 0 define P MODOEL NUMBER 1 define P VERSION 2 idefine PORT 485 DIRECTION PORTE P2 Bit2 of PortE is linked to ID 3 MAX485 direction pin ine BAUD RATE 4 def ine FINISH UCSROA 6 This bit is for checking TxD Buffer define P RETURN DELAY TIME 5 in CPU is empty or not define ANGLE LIMIT L 6 def ine TXD1 FINISH UCSRIA 6 define ANGLE LIMIT H 7 P_CCW ANGLE LIMIT 8 define SET TxDO FINISH sbi UCSROA 6 define P_CCW ANGLE LIMIT 9 RESET 1700 FINISH cbi UCSROA 6 SYSTEM DATA2 0 define CHECK TXDO FINISH bit is set UCSROA 6 define LIMIT TEMPERATURE 1 SET TxD1 FINISH sbi UCSRIA 6 define P DONN LIMIT VOLTAGE 12 define RESET TXD1 FINISH cbi UCSRIA 6 define UP LIMIT VOLTAGE 3 define CHECK TXD1 FINISH bit is set UCSRIA 6 def ine MAX TORQUE L 4 MAX TORQUE H 5 define INTERRUPT 0x01 define P RETURN LEVEL 6 define TX INTERRUPT 0x02 define ALARM LED 7 ine OVERFLOW INTERRUPT 0x01 ine P ALARM SHUTDOWN 8 define SERIAL PORTO 0 define P OPERATING MODE 9 define SERIAL PORTI 1 de
13. CK TXDO FINISH Wait until Shift register empty RS485_RXD return bPacketLength def ine RX WAIT TIMEOUT def ine TIMEOUT COUNT2 def ine RX TIMEOUT COUNTI Oxf000 3000L TIMEOUT COUNT2 10L read data from buffer 0 need a Parameter Total length of Return Packet RxPacket return Length of Return Packet byte RxPacket byte bRxPacketLength unsigned long ulCounter byte bCount bLength bChecksum byte bTimeout bTimeout 0 for bCount 0 bCount lt bRxPacketLength bCount ulCounter 0 while gbRxBufferReadPointer gbRxBufferWr itePointer if ulCounter gt TIMEOUT COUNT1 bTimeout 1 break if bTimeout break gbpRxBuffer bCount gbpRxInterruptBuffer gbRxBufferReadPointer bLength bCount bChecksum 0 if gbpTxBuffer 2 BROADCASTING ID if bTimeout amp amp bRxPacketLength 255 TxDString YrYn Error RxD Timeout CLEAR BUFFER if bLength gt 3 checking is available if gbpRxBuffer 0 Oxff gbpRxBuffer 1 Oxff TxDString CXrXn Error Wrong Header CLEAR BUFFER return 0 if gbpRxBuffer 2 gbpTxBuffer 2 TxDString YrYn Error TxID RxID CLEAR BUFFER return 0 if gbpRxBuffer 3 bLength 4 TxDString r n Error Length CLEA
14. DString 0 PrintBuffer gbpTxBuffer bTxPacketLength TxDString PrintBuffer gbpRxBuffer bRxPacketLength TxDString r n n Example 8 Go Ox3ff with Speed Ox3ff Any Key to Continue RxD80 gbpParameter 0 P GOAL POSITION Address of Firmware Version gbpParameter 1 Oxff Writing Data 8 GOAL POSITION L gbpParameter 2 0x03 Writing Data P GOAL POSITION H gbpParameter 3 Oxff Writing Data P GOAL SPEED L gbpParameter 4 0x03 Writing Data P GOAL SPEED bTxPacketLength TxPacket bID INST WRITE 5 bRxPacketLength RxPacket DEFAULT RETURN PACKET SIZE TxDString 0 PrintBuffer gbpTxBuffer bTxPacketLength TxDString CXrXn PrintBuffer gbpRxBuffer bRxPacketLength TxDStr ing r n n Example 9 Torque Off Any Key to Continue RxD8 0 gbpParameter 0 P TORQUE ENABLE Address of LED gbpParameter 1 0 Writing Data bTxPacketLength TxPacket INST WRITE 2 bRxPacketLength RxPacket DEFAULT RETURN PACKET SIZE TxDStr ing YrXn TxD PrintBuffer gbpTxBuffer bTxPacketLength TxDStr ing YrXn 0 PrintBuffer gbpRxBuffer bRxPacketLength TxDStr ing r n n End Push reset button for repeat while 1 31 DYNAMIXEL Bp About Register and value of bits vide 128 Data Sheet void PortInitialize void DDRA DDRB DDRC DDRD DDRE DDR
15. DX 116 TxDString r n n Dynamixel Driving Sample Program IISet ID to 3 bpParameter 0 ADDRESS ID bpParameter 1 3 bPacketLength TxPacket bpTxBuffer BROADCASTING 10 INST WRITE bpParameter 2 Length of Parameter bID 3 TxDString r n gt Dynamixel PrintBuffer bpTxBuffer bPacketLength bPacketLength RxPacket bpRxBuffer TxDString rn Dynamixel PrintBuffer bpRxBuffer bPacketLength IISet Motor Torque Enable bpParameter 0 ADDRESS TORQUE ENABLE bpParameter 1 7 1 bPacketLength TxPacket bpTxBuffer INST WRITE bpParameter 2 Length of Parameter TxDString rn gt Dynamixel PrintBuffer bpTxBuffer bPacketLength bPacketLength RxPacket bpRxBuffer TxDString rn Dynamixel PrintBuffer bpRxBuffer bPacketLength to Position 0x0100 lt gt 0x300 while 1 bpParameter 0 ADDRESS GOAL POSITION bpParameter 1 0x00 bpParameter 2 0x01 bPacketLength TxPacket bpTxBuffer bID INST WRITE bpParameter 3 Length of Parameter TxDString r n gt Dynamixel PrintBuffer bpTxBuffer bPacketLength bPacketLength RxPacket bpRxBuffer TxDString r n Dynamixel PrintBuffer bpRxBuffer bPacketLength MiliSec 1000 bpParameter 0 ADDRESS GOAL POSITION bpParameter 1 0x00 bpParameter 2 0x03 bPacketLength TxPacket bpTxBuffer bID INST WRITE bpParameter 3 Length of Parameter TxDString r n gt Dynam
16. ENT LOAD H 41 void TxDString byte bData define P PRESENT VOLTAGE 42 void TxD8Hex byte bSentData define P PRESENT TEMPERATURE 43 void TxD32Dec long ILong define REGISTERED INSTRUCTION 44 byte RxD81 void define P PAUSE TIME 45 void MiliSec word wDelayTime ine P MOVING 46 void PortInitialize void define P_LOCK 47 void Seriallnitialize byte bPort byte bBaudrate byte blnterrupt P PUNCH L 48 byte TxPacket byte bID byte bInstruction byte bParameterLength ine P PUNCH H 49 byte RxPacket byte bRxLength void PrintBuffer byte bpPrintBuffer byte bLength Instruction define INST_PING 0x01 Gloval Variable Number 30 DYNAMIXEL B volatile byte gbpRxInterruptBuffer 256 byte gbpParameter 128 byte gbRxBufferReadPointer byte gbpRxBuffer 128 byte gbpTxBuffer 128 volatile byte gbRxBufferWr itePointer main void byte bCount bID bTxPacketLength bRxPacketLength PortlnitializeQ Port In Out Direction Definition RS485_RXD Set RS485 Direction to Input State RS485 Initializing RxInterrupt Serial Initialize SERIAL_PORTO DEFAULT_BAUD_RATE RX_INTERRUPT RS232 Initializing None Interrupt Serial Initialize SERIAL DEFAULT_BAUD_RATE 0 RS485 RxBuffer Clear ing gbRxBufferReadPointer gbRxBufferWritePointer 0 56 0 Enable Interrupt Compiler Function TxD
17. F 0 input direction first PORTB PORTC PORTD PORTE PORTF PORTG 0x00 PortData initialize to 0 cbi SFIOR 2 All Port Pull Up ready Set all port to Set 5 LED port and RS485Direction port to output DDRB BIT LED DDRE e 15485 DIRECTION BIT LED MO BIT LED MI LED M2 BIT LED EO TurnOff LED LED MO OFF LED OFF LED M2 OFF LED EO OFF LED OFF send data to RS485 needs 3 parameter Length of parameters TxPacket return length of Return packet from Dynamixel ID of Dynamixel Instruction byte byte TxPacket byte byte bInstruction byte bParameterLength byte bCount bCheckSum bPacketLength gbpTxBuffer O Oxff gbpTxBuffer 1 Oxff gbpTxBuffer 2 bID gbpTxBuffer 3 Length Paramter Instruction Checksum gbpTxBuffer 4 blnstruction or bCount 0 bCount lt bParameterLength bCount bParameterLength 2 gbpTxBuffer bCount 5 gbpParameter bCount bCheckSum 0 bPacketLength bParameterLength 4 2 bCount 2 bCount lt bPacketLength 1 Oxff checksum bCount bCheckSum gbpTxBuffer bCount gbpTxBuffer bCount bCheckSum Writing Checksum with Bit Inversion RS485 bCount 0 bCount lt bPacketLength bCount sbi UCSROA 6 1700 FINISH TxD80 gbpTxBuffer bCount whi le CHE
18. Packet The Main Controller communicates with the Dynamixel by sending and receiving data packets There are two types of packets the Instruction Packet Main Controller to Dynamixel and the Status Packet Dynamixel to Main Controller N Instruction Packet Main Controller Status Packet Communication For the system connection below if the main controller sends an instruction packet with the ID set to N only the Dynamixel with this ID value will return its respective status packet and perform the required instruction Instruction Packet ID N Main 3 3 3 Controller Status Packet ID N Unique ID Communication problems will arise if multiple Dynamixel s have the same ID value This will cause multiple packets to be sent simultaneously resulting in packet collisions It is imperative that ID values are unique within each data network Protocol The Asynchronous Serial Communication word consists of 8 bits 1 Stop bit and no parity DYNAMIXEL Bp ROBOTIS 3 2 Instruction Packet The structure of the Instruction Packet is as follows Instruction Packet OXFF ID LENGTH INSTRUCTION PARAMETER1 PARAMETER NJ CHECK SUM The packet byte definitions are as follows OXFF Two OXFF bytes indicate the start of an incoming packet ID Unique ID of a Dynamixel The ID can range
19. R BUFFER return 0 or bCount 2 bCount bChecksum gbpRxBuf fer bCount if bChecksum Oxff bCount lt bLength TxDString Error Wrong CheckSum CLEAR BUFFER return 0 return bLength intBuffer print data in Hex code intBuffer needs two parameter gbpRxBuffer name of Pointer gbpTxBuffer id PrintBuffer byte bpPrintBuffer byte bLength byte bCount bCount 0 bCount lt bLength bCount TxD8Hex bpPr intBuffer bCount TxD8C TxDStr ing 7 LEN TxD8Hex bLength 1108 32 DYNAMIXEL B Print value of Baud Rate void PrintBaudrate void TxDStr ing r n RS232 TxD32Dec 16000000L 8L long UBRRIL 1L _TxDString BPS TxDString 5485 7 TxD32Dec 16000000L 8L long UBRROL 1L TxDString BPS Hardware Dependent tem define TXD1 READY bit is set UCSRIA 5 UCSR1A_Bit5 define TXD1 RESE define TXD1 DATA UDR1 define RXD1 READY bit is set UCSRIA 7 RXD1 RESE define RXD1 DATA UDR1 define TXDO READY bit is set UCSROA 5 define TXDO RESE define TXDO DATA UDRO ine RXDO READY bit is set UCSROA 7 define RXDO RESE define RXDO DATA UDRO Seriallnitialize set Serial Port to initial state Vide Megal28 Data sheet about Setting bit of register Seriallnitialize
20. String XrXn The Example of Dynamixel Evaluation with ATmega128 GCC AVR Dynamixel Communication Function Execution Step Step 1 Parameter Setting gbpParameter In case of no parameter instruction Ex INST PING this step is not needed Step 2 TxPacket ID INSTRUCTION LengthOfParameter Total TxPacket Length is returned Step 3 RxPacket ExpectedReturnPacketLength Real RxPacket Length is returned Step 4 PrintBuffer BufferStartPointer LengthForPr inting 1 TxDStr ing r n n Example 1 Scanning Dynamixels 079 Any Key to Continue RxD8 for bCount 0 bCount lt bCount bTxPacketLength TxPacket bCount INST PING 0 bRxPacketLength RxPacket 255 TxDString 0 PrintBuffer gbpTxBuffer bTxPacketLength TxDString 0 PrintBuffer gbpRxBuffer bRxPacketLength if bRxPacketLength DEFAULT RETURN PACKET SIZE TxDString Found ID TxD8Hex bCount bID bCount TxDString r n n Example 2 Read Firmware Version Any Key to Continue RxD80 gbpParameter 0 P VERSION Address of Firmware Version gbpParameter 1 1 Read Length bTxPacketLength TxPacket bID INST READ 2 RxPacketLength RxPacket DEFAULT RETURN PACKET _SIZE gbpParameter 1 TxDString TxD PrintBuffer gbpTxBuffer bTxPacketLength TxDString PrintB
21. TE 0x03 define INST SET SCHEDULE 0704 define INST DO SCHEDULE 0x05 define INST RESET 0x06 define DIGITAL MODE 0 Gloval variable number byte gbplnterruptRxBuffer 256 MEMORY SPARE 485 RxD Data Buffer byte gbRxBufferReadPointer gbRxBufferWritePointer Pointers for access the gbpInterruptRxBuffer void static interrupt far SerialOInterrupt void void PrintBuffer byte bpPrintBuffer byte bLength byte TxPacket byte bpTxBuffer byte byte blnstruction byte bpParameter byte bParameterLength Mai byte RxPacket byte bpRxBuffer ajor Function void main void byte bID bPacketLength byte bpTxBuffer 20 MEMORY byte bpRxBuffer 256 c MEMORY SPARE byte 256 MEMORY SPAREJ CLI Disable Interrupt Portlnitialize InitPort OUT PDATA1 0xe000 Set Out Port30 31 LED Port29 485Direction InitPort IN PDATA1 0x0004 Set In Port2 Push SW InitPort NORMAL USE 0x00c0 RS485 RXD IISet 485 Direction Select Port to 0 IIUartlnitialize P ndent Initializ outpw SPOBAUD 5 2MBPS 16MHz 16 5 SEU dene om 2 outpw SP1BAUD 17 57600 outpw SPOSTS 0 outpw SP1STS 0 Interruptinitialize 34 DYNAMIXEL Bp CTI T ROBOTIS SetInterrupt INUM_SERIALO Serial0Interrupt INT_ENABLEJINT_RX 7 Priority Memory Initialize gbRxBufferReadPointer gbRxBufferWritePointer 0 STI Interrupt Enable Example For Driving Dynamixel
22. Torque Enable Dynamixel FF FF 03 02 00 FA Dynamixel EF FF 03 05 03 14 00 01 DS Dvnamixell fF FF 03 02 00 FA gt 0 17 FF FF 03 05 03 14 00 03 07 FF FF 03 02 00 FA gt FF FF 03 05 03 1 DO Ol DS Dynamixel FF FF 03 02 00 FA gt 0 FF FF 03 05 03 14 00 03 07 Dyna ixell FF FF 03 02 00 FA Dvp mixell FF FF 03 05 03 1 00 0 09 lt 1 1 FF FF 03 02 00 n ES 4 e 0 00 17 RE 157600 8 N 1 SCHOU CAPS NUM fe OxFE is BROADCAST 10 so Dynamixel does not return status packet First 2 Instruction Packet 37 DYNAMIXEL Bp CTI T ROBOTIS Connector Company Name Molex Pin Number 4 Model Number Molex Part Number Old Part Number 22 03 5045 5267 04 50 37 5043 5264 04 Temperature range 40 C to 105 C Contact Insertion Force max 14 7N 3 30 Ib Contact Retention Force min 14 7N 3 30 Ib www molex com or www molex co jp for more detail information Female Connector Male Connector CIRCUIT 1 250 E NUI E S on me LAYOUT OOMPONENT SIDE 4 175 269 RECOMMENDED THICKNESS 88 Bi 490 193 a 190 575 yp ea ast 5 246 438 Dan 33 154 7 7 1 38 DYNAMIXEL Bp eI rm ROBOTIS Dimension
23. User s Manual 2005 11 16 209 Edition Closer to Real ROKOS Dynamixel DX 113 DX 116 DX 117 DYNAMIXEL Bp STI T ROBOTIS Contents 1 Summary 1 1 Overview and Characteristics of DX 113 116 and 117 Page 2 1 2 Main Specifications Page 3 2 Dynamixel Operation 2 1 Mechanical Assembly Page 4 2 2 Connector Assembly Page 4 2 3 Dynamixel Wiring Page 5 3 Communication Protocol 3 1 Communication Overview Page 8 3 2 Instruction Packet Page 9 3 3 Status Packet Page 9 3 4 Control Table Page 11 4 Instruction Set and Examples 4 1 WRITE DATA Page 18 4 2 READ DATA Page 19 4 3 REG WRITE and ACTION Page 19 4 4 PING Page 20 4 5 RESET Page 21 5 Examples Page 22 Appendix Page 28 DYNAMIXEL Bp STI T ROBOTIS 1 Dynamixel DX Series 1 1 Overview and Characteristics of the DX Series Dynamixel DX Series The Dynamixel robot actuator is a smart modular actuator that incorporates a gear reducer and a control circuitry with networking functionality all in a single package Despite its compact size it can produce large torque and is made with special materials to provide the necessary strength and structural resilience to withstand large external forces It also has the ability to detect and act upon internal conditions such as changes in internal temperature or supply voltage There are three models DX 113 DX 116 and DX 117 in the DX series of the Dynamixel robot actuator family and they have ma
24. W Load Load Direction 1 CW Load Address 0x2A Present Voltage The voltage applied to the Dynamixel The value is 10 times the actual voltage For example 10V is read as 100 0x64 Address 0x2B Present Temperature Current internal Dynamixel temperature Degrees Celsius Address 0x2C Registered Instruction Set to 1 when a REG WRITE instruction is made After an Action instruction and an action it is reset to 0 Address 0x2E Moving Set to 1 when the Dynamixel moves by its own power Address Ox2F Lock If set to 1 only Address 0x18 Address 0x23 can be written to Other areas are not permitted Once locked it can only be unlocked by powering down Address 0x30 0x31 Punch Minimum current being supplied to the motor during an action The minimum value is 0x20 and the maximum value as Ox3ff 16 DYNAMIXEL Range DX Series IROBOTIS Each Register has an operative range Write instructions made outside of these ranges will return an error The following table summarises the data range for each register 16 bit data registers are indicated as L and H two bytes Each byte of a two byte register can be written to independently m oxo p 2049 4004 50x05 ReumDeayTme o exo cw argetimi 2 o 1023043 cow Angle Lime 2 o 1023030 O Highest Limit Temperature 1 9 159099 F2 0x00 tre Lowest Limit Vaag
25. ction Length Instruction Parameter1 Parameter2 Parameter3 Parameter N 1 4 3 2 ACTION Function Length Instruction Parameter Broadcasting 4 4 PING Function Length Instruction Parameter REG WRITE instruction is similar to the WRITE DATA instruction but the execution timing is different When the Instruction Packet is received the values are saved into the Buffer and the Write instruction is under a standby status The Registered Instruction register Address Ox2C is set to 1 After an Action Instruction Packet is received the registered Write instruction is executed N 3 The number of Write Data bytes is N 0X04 Start Address for Write Data 1st Data to Write 2nd Data to Write N 1 Nth Data to Write Execute the WRITE instruction written by REG_WRITE 0x02 0X05 NONE The ACTION instruction is useful when multiple Dynamixels needs to move simultaneously When controlling multiple units slight time delays occur between the 1st unit to receive an instruction and the last one The Dynamixel approach fixes this problem through the use of the ACTION instruction When sending ACTION instructions to move more than two Dynamixel units the Broadcast ID OXFE should be utilised Used to request a specific Dynamixel status packet or to check the existence of a Dynamixel with a particular ID 0X02 0x01 NONE 20 DYNAMIXEL Bp STI T ROBOTIS Example 3 To obtain the status packet of a Dynamixel w
26. dition provided in the above example can be shown in the graph below CW Goal Position CCW CW n M Angle Position Output Torque A CCW Compliance Slope AddressOx1D 0x40 Approximately 18 8 CCW Compliance Margin AddressOx1B 0x01 Approximately 0 29 25 DYNAMIXEL Bp STI T ROBOTIS CW Compliance Margin AddressOx01A 0x01 Approximately 0 29 D CW Compliance Slope AddressOx1C 0x40 Approximately 18 8 Instruction Packet Instruction WRITE_DATA Address 0x1A DATA 0x01 0x01 0x40 0x40 Communication gt Dynamixel FF FF 00 07 03 1A 01 01 40 40 59 LEN 011 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR The effect of a Compliance Slope changes at the boundary of 2n n is positive number that is the effect of the values of Compliance between Ox11 and 0x20 are the same Example 18 Position Dynamixel with ID 0 at Position 180 after moving it at the speed of 35RPM Set Address Ox1E Goal Position 0x200 Address Ox20 Moving Speed 0x200 Instruction Packet Instruction WRITE DATA Address Ox1E DATA 0x00 0x02 0x00 0x02 Communication gt Dynamixel FF FF 00 07 03 1E 00 02 00 02 D3 LEN 011 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR Example 19 Set the position of a Dynamixel ID 0 to an angular Position of another Dynamixel ID 1 to an angular Position of 300 Make
27. e Dynamixel with ID 0 to 0x40 Instruction Packet Instruction WRITE DATA Address 0x30 DATA 0x40 0x00 Communication gt Dynamixel FF FF 00 05 03 30 40 00 87 LEN 009 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR 27 DYNAMIXEL Bp STI T ROBOTIS Appendix RS 485 RS 485 is a protocol used for serial communication which operates by forming a bus with multiple clients connected to a single line Thus transmission and reception cannot occur at the same time and while one client is transmitting all the other clients need to be in input mode The Main Controller that controllers the Dynamixel actuators sets the RS485 communication direction to be input mode and only when it is transmitting an Instruction Packet it changes the direction to be output mode RS485 Direction Output Duration Instruction Packet Status Packet Return Delay Time Return Delay Time The time it takes for the Dynamixel actuator to return the Status Packet after receiving an Instruction Packet The Default Value is 160 uSec and can be changed via the Control Table at Address 5 The Main Controller needs to change the RS485 communication direction during the Return Delay Tim after sending an instruction packet 485 Direction For RS 485 the timing to change the direction to receiving mode right after the ending of the transmission is important The bit definitions within the register that indicates UART STATUS are
28. eterLength bCount bpTxBuffer bCount 5 bpParameter bCount bCheckSum 0 bPacketLength bParameterLength 4 2 for bCount 2 bCount lt bPacketLength 1 bCount except Oxff checksum bCheckSum bpTxBuffer bCount bpTxBuffer bCount bCheckSum Writing Checksum with Bit Inversion Should wait until last data bit transmission is completed Note Shift register empty is differ from Tx TxD80 bpTxBuffer bCount Ready Tx Ready just means you can load the RS485 TXD Change 485 Direction to Transmission for bCount 0 bCount lt bPacketLength bCount data to CPU UART TxD Register There can be while ITXD FINISHO Wait until TXD Shift register empty several Tx Buffering registers as what kind of RS485 RXD E return bPacketLength void PrintBuffer byte bpPrintBuffer byte bLength byte bCount for bCount 0 bCount lt bLength bCount 36 DYNAMIXEL eI rm ROBOTIS TxD8Hex bpPrintBuffer bCount TxD8 Result lol DEE EE ASM TELH 0 CPU SerialPort SPOI Reset by Switch Boot System Mode Robot S Co Ltd http ews robotis com 251 951 el gt go EXE Jump to 0010 0700 Dynamixel Driving Saaple Program Dvnamixell FF FF FE o4 03 03 03 F4 Set ID to 3 Dvnamixel gt FF 03 04 03 14 0 Motor
29. fine DONN CALIBRATION L 20 DONN CALIBRATION H 21 define LED ON PORTE 3 PORTE Bit3 define UP CALIBRATION L 22 define LED ON PORTE 4 PORTE Bit4 define P UP CALIBRATION H 23 define LED M2 ON PORTE PORTE Bit6 def ine LED ON cbi PORTE 7 Bit7 define TORQUE ENABLE 24 def ine LED ON cbi 0 BitO define LED 25 define P COMPLIANCE MARGIN 26 def ine LED MO OFF sbi PORTE 3 PORTE Bit3 define P COMPLIANCE MARGIN 27 def ine LED M1 OFF sbi PORTE 4 PORTE Bit4 define COMPLIANCE SLOPE 28 def ine LED M2 OFF sbi PORTE 6 PORTE Bit6 define P_CCW COMPLIANCE SLOPE 29 def ine LED EO OFF sbi PORTE 7 PORTE Bit7 define P GOAL POSITION L 30 def ine LED OFF sbi PORTB 0 PORTB BitO define P GOAL POSITION 31 define GOAL SPEED L 32 def ine LED MO 0x08 Port E define GOAL SPEED H 33 define LED 0x10 Port E define P TORQUE LIMIT L 34 define LED M2 0x40 Port E define P TORQUE LIMIT 35 define LED EO 0x80 Port E define P PRESENT POSITION L 36 LED 0x01 Port B define P PRESENT POSITION H 37 define P PRESENT SPEED L 38 define RS485 DIRECTION 0x04 Port E define PRESENT SPEED 39 void TxD81 byte bTxdData ine P PRESENT LOAD L 40 void TxD80 byte bTxdData define P PRES
30. from 0X00 to OXFD 254 IDs are available Broadcasting ID ID ID OXFE is the Broadcast ID which is assigned to all of the connected Dynamixel s Status packets will not be returned with a broadcasting ID LENGTH The length of the Status Packet The value is Parameter number N 2 INSTRUCTION The instruction for the Dynamixel to perform PARAMETERO N Used if there is additional information to be sent other than the Instruction CHECK SUM The calculation method for the Check Sum is as follows Check Sum Length Instruction Parameter1 Parameter N If the calculated value is bigger than 255 the lower byte becomes the checksum represents the Not or complement operation 3 3 Status Packet The Status Packet is the response packet from the Dynamixel to the Main Controller after receiving an instruction packet The structure of Status Packet is as follows ID LENGTH ERROR 1 PARAMETER2 PARAMETER CHECK SUM The meaning of each byte within the packet is as follows DYNAMIXEL Bp STI T ROBOTIS OXFF Two OXFF bytes indicate the start of a packet ID ID of the Dynamixel which is returning the packet LENGTH The length of the Status Packet The value is Parameter number N 2 ERROR Dynamixel communication error flags The meanin
31. g of each bit is as follows Een s Set to 1 if an undefined instruction is given without the Bit6 Instruction Error reg write instruction Overload Error Set to 1 if the specified torque can t control the load Set to 1 if the checksum of the intruction packet is incorrect Bit 3 Range Error Set to 1 if the instruction is out of the usage range Overheating Set as 1 if the internal temperature of Dynamixel is out of Bit 2 Error the operative range as set in the control table Set as 1 if the goal position is set outside of the range between CW Angle Limit and CCW Angle Limit Input Voltage Set to 1 if the voltage is out of the operative range set in Bit 0 Error the control table Angle Limit Error Used when additional information is required CHECK SUM SUM Calculation method of Check Sum is as follows Check Sum Length Instruction Parameter1 Parameter N If the calculated value is bigger than 255 the lower byte becomes the checksum represents the Not or complement operation 10 DYNAMIXEL 3 4 Control Table RAM Area DX Series IROBOTIS Address Access 0 0X00 T 0X01 2 0X02 3 0X0 Initial Value 116 0x74 0 0x00 1 0x01 34 0x22 250 0xFA 0 0x00 0 0x00 255 0xFF 3 0x03 0 0x00 85 0x55 60 0X3C 190 0xBE 255 0XFF 3 0x03 2 0x02 4 0x04 4 0x04 0 0x00 L H PRR
32. h TxDString PrintBuffer gbpRxBuffer bRxPacketLength if bRxPacketLength DEFAULT RETURN PACKET SIZE gbpParameter 1 TxDStr ing CXrYn or bCount 0 bCount lt 49 bCount 1108 TxD8Hex bCount TxDStr ing C1 TxD8Hex gbpRxBuffer bCount 5 TxD8 TxDStr ing r n n Example 6 Go 0x200 with Speed 0x100 Any Key to Continue RxD8 gbpParameter O P GOAL POSITION Address of Firmware Version gbpParameter 1 0x00 Writing Data 8 GOAL POSITION L gbpParameter 2 0x02 Writing Data P GOAL POSITION H gbpParameter 3 0x00 Writing Data P GOAL SPEED L gbpParameter 4 0x01 Writing Data P GOAL SPEED H bTxPacketLength TxPacket bID INST WRITE 5 bRxPacketLength RxPacket DEFAULT RETURN PACKET SIZE TxDString 0 PrintBuffer gbpTxBuffer bTxPacketLength TxDString PrintBuffer gbpRxBuffer bRxPacketLength TxDStr ing r n n Example 7 Go 0100 with Speed 0x40 Any Key to Continue RxD80 gbpParameter O P GOAL POSITION Address of Firmware Version gbpParameter 1 0x00 Writing Data P GOAL POSITION L gbpParameter 2 0x00 Writing Data P GOAL POSITION H gbpParameter 3 0x40 Writing Data P GOAL SPEED L gbpParameter 4 0x00 Writing Data P GOAL SPEED H bTxPacketLength TxPacket bID INST WRITE 5 bRxPacketLength RxPacket DEFAULT RETURN PACKET SIZE Tx
33. in Link to conn ector CPU RxD CPU TxD Link to CPU UART RxD TxD DIRECTION485 Link to CPU Output Port 485 Direction Select ink Application Example for RS485 L DYNAMIXEL eI T ROBOTIS The direction of data signals on the TTL level TxD and RxD depends on the DIRECTION485 level as the following When the DIRECTIONA85 level is High the TxD signal is outputted as D D When the DIRECTIONA85 level is Low the D D signal is inputted to RxD RS485 The communication protocol used by the Dynamixel actuator RS485 IEEE485 uses the multi drop method of connecting multiple terminals on a single node Thus a protocol that does not allow multiple transmissions at the same time should be maintained on a RS485 network Main Controller RS485 Multi Drop Link Note Please ensure that the pin assignments are correct when connecting the Dynamixel actuators Check the current consumption after the wiring is completed The current consumption of a single Dynamixel actuator unit in standby mode should be no larger than 50mA Connection Status Verification When power is applied to the Dynamixel actuator the LED blinks twice to confirm its connection Inspection If the above operation was not successful check the connector pin assignment and the voltage current limit of the power supply DYNAMIXEL eI rm ROBOTIS 3 Communication Protocol 3 1 Communication Overview
34. ion lt CCW Angle Limit An Angle Limit Error will occur if this relationship is not satisfied Address 0x0B the Highest Limit Temperature The upper limit of the Dynamixel s operative temperature If the Dynamixel s internal temperature is higher than this value an Over Heating Error Bit Bit 2 of the Status Packet will be set An alarm will be set in Address 17 18 The values are in Degrees Celsius Address 0x0C 0x0D the Lowest Highest Limit Voltage Setting the operative upper and lower limits of the Dynamixel s voltages If the present voltage Address42 is out of the specified range a Voltage Range Error bit will be set in the Status Packet and an alarm executed will be set in Address s 17 18 The values are 10 times the actual voltages For example if the Address 12 value is 80 then the lower voltage limit is set to 8V Address 0x0E 0x0F 0x22 0x23 Max Torque The max torque output for the Dynamixel When it is set to 0 the Dynamixel enters a Torque Free Run condition The Max Torque Torque Limit is assigned to EEPROM Address OX0E 0x0F and RAM Address 0x22 0x23 and a power on condition will copy EEPROM values to RAM The torque of a Dynamixel is limited by Address0x22 0x23 of RAM Address 0X10 Status Return Level To determine whether the Dynamixel will return the Status Packet after the transmission of an Instruction Packet Address16 Return of Status Packet Em mi Do net respond to any instruction
35. iping 3 Forming a 5 Assembling 2 Inserting 6 Complete 4 Formed Wire DYNAMIXEL eI rm ROBOTIS 2 3 Dynamixel Wiring Pin Assignment The connector pin assignments are as the following The two connectors on the Dynamixel actuator are internally connected to each other Pin 1 GND Pin 2 12V 18V Pin 3 D RS485 Signal Pin 4 D RS485 Signal Wire Link Connect the pins to pins that have the same number as shown below Main Controller Main Controller To operate the Dynamixel actuators the main controller must support RS485 You can design and build your own controller but the use of the CM 2 Dynamixel controller board is recommended PC LINK APC can be used to control the Dynamixel actuator via the CM 2 controller RS485 Level Dynamixels DYNAMIXEL eI rm ROBOTIS Stand Alone The CM 2 board can be directly mounted on a robot that is built with Dynamixel actuators CM 2 Board on Robot For usage details please refer to the CM 2 manual Connection to UART To control the Dynamixel actuators the main controller needs to convert its UART signals from TTL level to RS485 level The recommended circuit diagram for this is shown below lt 485 Driving Chip o 1 2 RE DIRECTION485 D 104 cam CPU TXD 4 ip MAX485 D D 485 Link P
36. ith ID 1 Instruction Packet OXFF OXFF 0X01 0X02 0X01 OXFB fou SN ID LENGTH INSTRUCTION CHECKSUM The returned Status Packet is as follow Status Packet OXFF OXFF 0X01 0X02 0X00 OXFC ID LENGTH ERROR CHECKSUM 4 5 RESET Function Restore the condition of the Control Table of the Dynamixel back to the Factory Default values Length 0X02 Instruction 0X06 Parameter NONE Example 4 Reset Dynamixe with ID 0 Instruction Packet OXFF OXFF 0X00 0X02 0X06 OXF 7 NE SE ID LENGTH INSTRUCTION CHECKSUM The returned Status Packet is as follows Status Packet OXFF OXFF 0X00 0X02 0X00 OXFD a ID LENGTH Please note that after a RESET instruction the ID of the Dynamixel is changed to 1 21 DYNAMIXEL Bp STI T ROBOTIS 5 Example Used to explain through example with the assumption that the Dynamixel has been Reset ID 1 Baudrate 57142BPS Example 6 Read the Model Number and Firmware Version of Dynamixel with ID 1 Instruction Packet Instruction READ_DATA Address 0x00 Length 0x03 Communication gt Dynamixel FF FF 01 04 02 00 03 F5 LEN 008 lt Dynamixel FF FF 01 05 00 74 00 08 7D LEN 009 Status Packet Result Model Number 116 0x74 Firmware Version 0x08 Example 7 Change ID number
37. ixel PrintBuffer bpTxBuffer bPacketLength bPacketLength RxPacket bpRxBuffer TxDString r n Dynamixel PrintBuffer bpRxBuffer bPacketLength MiliSec 1000 IIwhile 1 void static interrupt far SerialOInterrupt void Serial RxD Interrupt routine STI Enable Interrupt gbpInterruptRxBuffer gbRxBufferWritePointer 0 Reading Arrival Data outpw EOI 0x14 End of Interrupt byte RxPacket byte bpRxBuffer 35 DYNAMIXEL eI rm ROBOTIS define RX_TIMEOUT_COUNT2 100001 10mSec define RX_TIMEOUT_COUNT1 TIMEOUT COUNT2 10L 1Sec unsigned long ulCounter byte bCount ulCounter 0 while gbRxBufferReadPointer gbRxBufferWritePointer if ulCounter gt RX_TIMEOUT_COUNT1 return 0 bCount 0 for bCount 0 bCount lt 254 bCount Maximum Data Length Limit 255 ulCounter 7 0 while gbRxBufferReadPointer gbRxBufferWritePointer if ulCounter gt COUNT2 return bCount bpRxBuffer bCount gbpInterruptRxBuffer gbRxBufferReadPointer return bCount byte TxPacket byte bpTxBuffer byte byte blnstruction byte bpParameter byte bParameterLength byte bCount bCheckSum bPacketLength bpTxBuffer 0 Oxff bpTxBuffer 1 Oxff bpTxBuffer 2 bID bpTxBuffer 3 bParameterLength 2 Length Paramter Instruction Checksum bpTxBuffer 4 binstruction for bCount 0 bCount bParam
38. namixel RAM and EEPROM The data values for the RAM Area will be set to the default initial values on power on The data values for the EEPROM Area are non volatile and will be available next power on Initial Value The Initial Value column of the control table shows the Factory Default Values for the case of EEPROM Area Data For the RAM Area Data the initial value column gives the power on data values Please note the following meanings for data assigned to each address in the control table Address 0x00 0x01 Model Number In the case of the DX 116 the value is 0X0074 116 Address 0x02 Firmware Version Address 0x03 ID Unique ID number to identify the Dynamixel Different ID s are required to be assigned to linked Dynamixels Address 0x04 Baud Rate Determines the Communication Speed The Calculation method is Speed BPS 2000000 Address4 1 Data Value as per Major Baud Rate 2000000 2000000 0 000 Note A maximum Baud Rate error of 3 is within the UART communication tolerance 12 DYNAMIXEL Bp STI T ROBOTIS Address 0x05 Return Delay Time The time taken after sending the Instruction Packet to receive the requested Status Packet The delay time is given by 2uSec Address5 value Address 0x06 0x07 0x08 0x09 Operating Angle Limit Set the operating angle to restrict the Dynamixel s angular range The Goal Position needs to be within the range of CW Angle Limit lt Goal Posit
39. ny advantages over similar products Precision Control Position and speed can be controlled with a resolution of 1024 steps Compliance Driving The degree of compliance can be adjusted and specified in controlling position Feedback Feedback for angular position angular velocity and load torque are available Alarm System The Dynamixel series robot actuator can alert the user when parameters deviate from user defined ranges e g internal temperature torque voltage etc and can also appropriately handle the problems by itself Communication Wiring is easy with daisy chain connection and it support communication speeds up to 1M BPS High performance Motors Models DX 116 and DX 117 use the RE MAX Series Coreless DC Motors which are the top of the line Swiss Maxon motors allowing them to produce large output torques and high accelerations Distributed Control The actuation schedule can be set with a single command packet thus enabling the main processor to control many Dynamixel units even with very few resources Engineering Plastic The main body of the unit is made with high quality engineering plastic which enables it to handle high torque loads DYNAMIXEL Bp ROBOTIS Metal Gear Axis Bearing Status LED All gears are made with metal to ensure durability A bearing is used at the final axis to ensure no efficiency degradation with high external loads on the output shaft The LED can indicate the erro
40. r status to the user 1 2 Main Specifications 66 66 58 Weight g Gear Reduction Ratio 142 5 192 6 192 6 Input Voltage 12 16 12 16 12 Final Max Holding Torque kgf cm 21 38 28 50 28 89 38 52 10 20 Sec 60degree 0 127 0 095 0 172 0 129 0 150 Resolution 0 35 Operating Angle 300 Voltage DX116 117 12V 16V Recommended voltage 14 4V DX113 12V Max Current 1200mA Operating Temp 5 C 85C Command Signal Protocol Type Link Physical ID Communication Speed Feedback Material Motor Digital Packet Half duplex Asynchronous Serial Communication 8bit 1stop No Parity RS 485 Multi Drop daisy chain type Connector 254 ID 0 253 7343bps 1 Mbps Position Temperature Load Input Voltage etc Full Metal Gear Engineering Plastic Body Swiss MAXON Motor DX 116 DX 117 DX 113 uses a cored motor DYNAMIXEL eI rm ROBOTIS 2 Dynamixel Operation 2 1 Mechanical Assembly Follow the figure below for the mechanical assembly of the Dynamixel actuator Screw for Horn Screw for mount 8EA The 8 sets of screws and nuts are only used for attaching the Dynamixel actuator to other parts 2 2 Connector Assembly Assemble the connectors as shown below Attach the wires to the terminals using the correct crimping tool If you do not have access to a crimping tool solder the terminals to the wires to ensure that they do not become loose during operation 1 Str
41. s 1 590x32 2500s isoXoD the Highest Limit ottage 1 50002 2500s vatge z o soom Satus Remtes o 2 aame 9 ex Alarm Shutdown o zom meewe L r Torque Enable 1 w rT T _ 26 0x1A CW Compliance Margin 1 0 zoe 27 0 COW Compliance Margin 1 0 254 0 2000 CW Compliance Sope 1 1 2540 2019 COW Compliance Slope 1 1 2540 S0 0x1E Goal Positon 2 9 1023650 320x20 Moving 2 o 102003 aoa Teweumt 2 0 1020030 4020 Regstredmsudon o ick rT r T EE Pun 9 1023000 Control Table Data Range and Length for Writing 17 DYNAMIXEL Bp STI T ROBOTIS 4 Instruction Set and Examples The following Instructions are available Number of dk PING No action Used to obtain a Dynamixel Status 0x01 Packet READ DATA Read the values in the Control table WRITE DATA Write the values to the Control Table REG WRITE Similar to WRITE DATA but stay in standby 0x04 mode until write upon the action instruction ACTION Start the action registered by REG WRITE Change the values of the Dynamixel in the 0x06 control table back to the Factory Default Values 4 1 WRITE DATA Function Write data into the control table of the Dynamixel Length N 3 Writing Data is N Instruction 0X0
42. t NO ERROR The Status Packet will not be returned for the next instruction Example 15 If temperature values are higher than those defined operative temperatures set the alarm to make the Dynamixel blink and then shut down the Dynamixel Torque off Overheating Error is Bit 2 therefore set the alarm value to 0x04 Instruction Packet Instruction WRITE DATA Address 0x11 DATA 0x04 0x04 Communication gt Dynamixel FF FF 00 05 03 11 04 04 DE LEN 009 lt Dynamixell FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR 24 DYNAMIXEL Bp CTI T ROBOTIS Example 16 Turn on the LED of the Dynamixel with ID 0 and enable the torque Instruction Packet Instruction WRITE DATA Address 0x18 DATA 0x01 0x01 Communication gt Dynamixel FF FF 00 05 03 18 01 01 DD LEN 009 lt Dynamixel FF FF 00 02 00 FD LEN 006 Status Packet Result NO ERROR Physical confirmation of an enabled torque can be obtained by attempting to rotate the motor with your hand Example 17 Set the Dynamixel with ID 0 to have a Compliance Margin 1 and Compliance Slope 0x40 Compliance The following graph shows the Angle Error and Torque Output CW Goal Position CCW CW X Angle Error CCW If the position is slightly deviated from the goal position the motor will generate a high torque to try to adjust its position to that of the goal position The true control method is different due to the inertia The con
43. to 1 Torque Enabled Condition Address 0x19 LED LED is on when set to 1 and LED is off if set to 0 Address 0x1A 0x1D Compliance Margin and Slope The Dynamixel controls Compliance by setting the Margin and Slope If used well Compliance will absorb the shocks The following graph demonstrates the use of Compliance values length of A B C amp D relative to Position Error and applied torque CW Goal Position CC CW X axis Position Error CCW Y axis Output Torque A B D CCW Compliance Slope Address0x1D CCW Compliance Margin Address0x1B CW Compliance Margin Address0x1A D CW Compliance Slope Address0x1C E Punch Address0x30 31 Address 0X1E 0x1F Goal Position Requested Angular Position for the Dynamixel to move to If this is set to Ox3ff then the goal position will be 300 150 Goal Position Ox1ff 300 300 360 0 Goal Position 0x3ff Invalid Angle Goal Position 0 15 DYNAMIXEL Bp STI T ROBOTIS Address 0x20 0x21 Moving Speed The angular speed to move to the Goal Position If set to the maximum values of Ox3ff it moves at 7ORPM Address 0x24 0x25 Present Position Current position of the Dynamixel Address 0x26 0x27 Present Speed Current Speed of the Dynamixel Address 0x28 0x29 Present Load Load size on the Dynamixel in action Bit 10 is the direction of the load 15 10 4 3 2 150 lVaue Load Direction Load Value Load Direction 0 CC
44. uffer gbpRxBuffer bRxPacketLength if bRxPacketLength DEFAULT RETURN PACKET SIZE gbpParameter 11 TxDStr ing r n Return Error 2 TxD8Hex gbpRxBuf fer 4 TxDString Firmware Version TxD8Hex gbpRxBuffer 5 TxDString XrYnYn Example 3 LED ON Any Key to Continue RxD8 0 gbpParameter 0 P LED Address of LED gbpParameter 1 1 Writing Data bTxPacketLength TxPacket bID INST WRITE 2 bRxPacketLength RxPacket DEFAULT RETURN PACKET SIZE TxDStr TxD PrintBuffer gbpTxBuffer bTxPacketLength TxDString PrintBuffer gbpRxBuffer bRxPacketLength TxDString CXrXnYn Example 4 LED OFF Any Key to Continue RxD8 gbpParameter 0 LED Address of LED gbpParameter 1 0 Writing Data bTxPacketLength TxPacket bID INST WRITE 2 bRxPacketLength RxPacket DEFAULT RETURN PACKET SIZE TxDString CXrXn 0 PrintBuffer gbpTxBuffer bTxPacketLength TxDString CXrXn PrintBuffer gbpRxBuffer bRxPacketLength TxDString r n n Example 5 Read Control Table Any Key to Continue RxD80 gbpParameter 0 0 Reading Address gbpParameter 1 49 Read Length bTxPacketLength TxPacket bID INST READ 2 bRxPacketLength RxPacket DEFAULT RETURN PACKET _SIZE gbpParameter 1 TxDString 0 PrintBuffer gbpTxBuffer bTxPacketLengt
Download Pdf Manuals
Related Search
Related Contents
Tripp Lite PowerVerter Plus DC-to-AC Inverter User's Manual antonio_dg_dr_rcla - Repositório Institucional UNESP Counsellors` Online Services User Manual 2015–2016 Download, 3.57 MB Notification d`information de securite sanitaire Blue Wave Boats 220 V-Bay LC User's Manual CERTITEST® Model 8160 Automated Filter Tester Instruction Samsung AS09PBGE manual de utilizador Copyright © All rights reserved.
Failed to retrieve file