6. Bioloid CM-5 控制器電路
Direction_Port 可以控制 TXD, RXD 的方向
Direction_Port is high: the TxD is output as data.
Direction_Port is Low: the data is input as RxD.
7. KRS Serial USB Adapter 電路
採用機器人控制板半雙工的設計
TxD 及 RxD 短路,在輸出資料時同時會收到訊號
在 WinXP 或是 Linux 下傳輸 data 時,如果發生
context switch 不會有 data loss 的情形
8. 常見的 Serial USB Adapter 電
路
大多數機器人玩家的作法
用硬體 (DTxEN) 控制 RxD, TxD 的 enable 與
disable
9. RB-100 Comport 簡介
RB-100 comport location
COM 1 ~ 4 的傳輸速度最高 115200 bps.
COM 4
(TTL, Half-duplex)
COM 3
(TTL, Full-duplex)
COM 2
(RS-485)
COM 1
(RS-232)
Power
10. COM 2 / RS-485
Pin # Signal
Name
Line
Color
1 GND Black
2 Vxx Red
3 RS485+ Other
4 RS485- Other
1 2 3 4
1 2 3 4
22. COM 3 / AX-12 轉接線製
作
Connect AX-12 to RoBoard's COM 3
23. COM 4 / Half Duplex TTL
Pin # Signal
Name
Line
Color
1 GND Other
2 Vxx Red
3 TXRX4 Black
3 2 1
3 2 1
24. COM 4 / Half Duplex TTL
For older models:
DM118A/DM118B/DM118C
COM4 is an usual industrial
half-duplex port whose data-
transfer direction is controlled
by RTS signal of COM4.
RTS enabled: transfer data
RTS disabled: receive data
25. COM 4 / Half Duplex TTL
For the newest model:
DM118D
COM4 is equivalent to a full-
duplex port of TXD/RXD
shorted.
It is the configuration most
compatible to common serial
servos, such as Bioloid AX-12
and KONDO KRS-2552HV.
26. COM 4 / AX-12 轉接線製
作
Preparation
1×3 2.54mm pitch pin headerRoBoard COM3 line
27. COM 4 / AX-12 轉接線製
作
Solder the COM 4 line and the pin header together
Vxx
Data
GND
29. COM 4 / AX-12 轉接線製
作
Connect AX-12 to RoBoard's COM 4
30. RB-110 Comport 簡介
RB-110 comport location
COM 1 ~ 4 的傳輸速度最高可達 750K bps.
COM 5 & 6 的傳輸速度最高可達 12M bps.
COM 1
(RS-232)
COM 5
(TTL, Full-duplex,
FTDI Hi-Speed)
COM 4
(TTL, Full-duplex)
COM 3
(TTL, Full-duplex)
COM 2
(RS-485)
System Power
Servo Power
COM 6
(TTL, general function,
FTDI Hi-Speed)
31. COM 2 / RS-485
Pin # Signal
Name
Line
Color
1 GND Black
2 Vxx Red
3 RS-485+ Other
4 RS-485- Other
4
3
2
1
4
3
2
1
40. COM 5 / Full Duplex TTL / FTDI
Hi-Speed
Pin # Signal
Name
Pin # Signal
Name
Pin # Signal
Name
Pin # Signal
Name
1 GND 2 Vxx 3 TXD5 4 RXD5
1 2 3 4 1 2 3 4
Note: You can also use COM 5 as Half-Duplex TTL (same as COM 3/4)
64. USB2Dynamixel
Dynamixel SDK 是由 ROBOTIS 所發布的開放源碼
,可透過 USB2Dynamixel 由 PC 端 USB 連接至
Servos 。
USB2Dynamixel 可將 PC 端 USB 訊號轉成
TTL 、 RS485 以及 RS232 。
65. Dynamixel SDK for RoBoard
Dynamixel SDK for RoBoard 則是將 Dynamixel
SDK 移植到 RoBoard 的 Serial Port 上,讓使
用者可直接透過 RoBoard 的 Serial Port 連接
Dynami-xel servos ,省掉中間的轉接器。
79. Include Header files
……
#include "dynamixel.h"
#include "roboard_dll.h“
……
int main()
{
roboio_SetRBVer(…);
……
// use API of Dynamixel SDK here
……
}
RB_100 or RB_110
80. 基本函式使用介紹
dxl_initialize()
開 對應的啟 COM Port 並進行初始化設定,執行成功回傳
1 ,失敗則回傳 0 。
使用範例:
int main() {
roboio_SetRBVer(…);
if( dxl_initialize() )
printf( "Succeed to open COM Port !n" );
else
printf( "Failed to open COM Port !n" );
……
}