Wiimote Controlled Traxster Robot
Wiimote Bluetooth Control
The included program uses Peter Barrett's BlueUSB library in order to control a Traxster Robot using a Wii Remote. A Bluetooth dongle using a CSR chip is necessary for the library to work. To pair the Wiimote to the dongle, press the 1 and 2 buttons simultaneously and reset the mbed. LED1 on the Wiimote will remain lit after the pairing is complete. The information sent over the Bluetooth connection is parsed by the mbed program into motor values to send over a serial connection to the Traxster Robot. Features include forward and reverse control using the 1 and 2 buttons, turning using the D-pad and accelerometer, speed control using the accelerometer, and front-end collision detection using an IR sensor. Detailed information about Wiimote status reporting can be found at http://wiibrew.org/wiki/Wiimote
Code to control a Traxster robot using a Wimote and Android app
The RoboticsConnection Traxster Robot is a simple chassis holding 2 DC geared motors with rotary encoders. Driving the robot is the Serializer 3.0 board, which contains a PIC18 microcontroller that manages the motor control.
Serial commands (such as "mogo 1:50" or "stop") are sent from the mbed using a standard Serial connection with TTL voltage levels. The Serializer then uses these commands in conjunction with PID control and the motors' encoder feedback to drive the motor H-bridges. This way, the mbed's software can focus on Bluetooth input and offload the details of driving the robot.
Additionally, the Serializer provides a 5V output (regulated from the battery) which is used to power the mbed and other devices on the top breadboard, eliminating the need for a separate power supply.
More information on the Serializer can be found on its datasheet here.
An analog IR distance sensor was attached to the front of the robot and connected to one of the mbed's AnalogIn pins, allowing for simple collision detection to stop the robot before running into a wall or other obstacle.
There is also an Android application component to the included example program. Using the BlueSMiRF Gold RN-42 module, accelerometer data can be sent to the mbed via an Android application over what is essentially a Bluetooth serial connection. To activate this mode, pair your Android phone to the BlueSMiRF, toggle switch 4, and reset the mbed. You cannot control the robot using both modes simultaneously and must reset the mbed to swap between them.
Please log in to post comments.