This project is my final project for ME 461 at the University of Illinois Urbana-Champaign. ME 461 is Computer Controls of Mechanical Systems, and is taught by professor Dan Block. This code builds off of something put together by Yorihisa Yamamoto at Mathworks that outlines the equations needed to balance a two-wheeled robot.
In order to balance, information is taken from both the gyroscope and the accelerometer from the IMU. It is then processed through a number of equations along with the wheel position to tell the motors which way to move.
The added wrinkle with this code is that it includes an additional segment that helps the robot move back if it hits a wall head on. There are two microswitches on the front of the robot that, when pressed, will signal to the robot to move backward before rebalancing itself. If the Segbot has been given the command to move forward before it hits the wall, once it has moved back, it will need to be given that command again in order to keep moving.
For more information about the kit, you can contact Professor Block at d-block@illinois.edu
Comments
Please log in or sign up to comment.