The Robots We currently use ActiveMedia's Pioneer II DX8 robots. We mounted a SICK laser range finder, a stayton board with USB-to-serial and WaveLAN adapters plus some VICOR current converter on the robot. ![]() The stayton board is mounted in the blue box behind the laser range finder. This plastic lunch box is a perfect, light and cheap (2.50 Euros at OBI, Germany) chassis for the stayton boards. ![]() USB-Serial I used USB-Serial adapter to connect robot and laser range finder to the stayton board. At first I used the IOGear GUC232A with Bens driver. But when using more the one adapter the order of the assigned ports is more or less random. So I switched to Keyspan USA-49WLC (a 4-port adapter). I compiled the corresponding driver with the corss-compiler for my stayton board. If you are using the Linux kernel 2.4.19 you can use my compiled usb-serial-modules. Extract the archive to /lib/modules/2.4.19-rmk2-pxa2/kernel/drivers/usb/serial/ (and load the module(s) with modprobe keyspan). Perhaps you need to create a deive with mknod /dev/usb/ttyUSB0 c 188 0; mknod /dev/usb/ttyUSB1 c 188 1; ...) The Robot Control System The running control software is the BEE-Software as well as CARMEN. I patched the TCX-library (for BEE) and the IPC-library (for CARMEN) responsible for the communication between the modules (the IPC-patch has been integrated in the repository at the 12.Jun, 2003) to support the stayton boards. Now software running the stayton boards can communicate with other BEE/CARMEN-modules. A patched version of the TCX-Communication system can be found in here. Just override your old tcx-directory within bee. The new server works on stayton boards as well as with i386 architectures. The Double-Problem The problem was the double representation of the stayton boards. Ints, longs and floats are presented like on a i386 processor. But the first and the last 32bits of a double are swapped. E.g. the double 0x01234567 (hexadecimal) on a i386 would be represented as 0x045670123 on a stayton board. So all doubles to be send over the network or received from another module have to be swapped. But now it works (see the patched IPC version in CARMEN)! The swapping can be done with a function like this: double stayton_swap_double_high_low(double d) { double r = 0; ((unsigned int*) &r)[0] = ((unsigned int*) &d)[1]; ((unsigned int*) &r)[1] = ((unsigned int*) &d)[0]; return r; } Running the Control Software To control a Pioneer robot with BEE or CARMEN and a stayton board you have to start the "pioneer"-module as well as the "laser"-module on the stayton board. The stayton board is connected with a PC via wireless network. The PC runs the other necessary BEE or CARMEN-modules like "tcxServer" or "central", "localize", etc. Compiling Software To compile "pioneer" and "laser" for the stayton boards I used the arm-linux-cross-compiler. You have to adapt the global Makefile by replacing gcc, g++, etc. by arm-linux-gcc, etc. If using CARMEN, both modules can be compiled directly you (perhaps) only have to disable the "pioneer-test" program in the Makefile delivered with the "pioneer"-module. If using BEE, I suggest to add a -Di386 to the Compiler-Flags and uncomment lines causing an error during the compilation process. The cross-compiler I used can be found on Ben page (arm-linux-cross-compiler). On his pages you find additional informations, disk images, etc. for the stayton board! Video A small (divx5) video of the first stayton-board controlled run can be found here. Some useful links: |