Omni Directional Wheels
This is the page for Tad Goff's E5 final project, Omni-Directional Wheels
My goal was to build a device that moves omni-directionally using holonomic or 'omni' wheels. There will be four wheels arranged around the chassis such that there are two opposing sets. The device will be controlled by an analog thumbstick from a Playstation 2 controller, and will be programmed in MatLab. The final product is a “robot” that moves omni-directionally.
Segway's new RMP
I saw this image of Segway's new RMP (Robotic Mobility Platform) online and I though that it looked cool. I began to research these wheels and their feasibility as a final project. The programming and building of such an RMP, on a much smaller scale seemed within my ability if I could get the wheels. As it turned out I could not get the mecanum wheels but it did start me thinking about methods for omni-directional motion.
These mecanum wheels use rollers on a 45° angle around the circumference to allow lateral motion. When all the wheels spin forwards, the lateral forces created by the angle of the rollers cancel and the device moves forward normally. When the wheels spin in different directions, the forwards and backwards forces cancel and the device moves laterally, diagonally or spins.
Because I could not buy any reasonably sized mecanum wheels I chose to use holonomic wheels instead. Holonomic wheels (also known as omni wheels)have rollers perpendicular to the direction of rotation. This allows them to roll normally and slide laterally. By positioning them so they are not parallel they can move omni-directionally. My design uses two sets of wheels perpendicular to each other, but any no-parallel arrangement will work.
My design consists of two sets of wheels perpendicular to each other driven by servo motors. For control I took a Playstation 2 controller apart and used the thumbstick in stead of the two potentiometers in the "pot boxes" we used to control the arm. The script is very simple. It scales the potentiometer values from the thumbstick to add to the pulse widths for the motors.
For the power to drive my device I used continuous rotation servo motors. These are controlled just like normal servo motors, by changing the width of the pulses sent to them. Every motor has a center pulsewidth value where the motor won't move at all. Pulsewidths longer than this value will cause the motor to move clockwise, getting faster as the pulse widths are farther from the center, while shorter pulses will cause the motor to spin counter-clockwise.
I needed a way to continuously input data into MatLab, so I decided to use potentiometers, similar to the "pot boxes" we used in the second MatLab lab. I decided to not use the pot boxes again because the two knob design makes for an awkward etch-a-sketch like controller. Instead I used an analog joystick from a Playstation 2 controller. In general, the analog stick in a video game controller is just a set of two potentiometers perpendicular to each other. these two videos (from howstuffworks.com) show how joysticks work by using variable resistors (potentiometers) to send a signal to a computer.
- All the motors are slightly different
- There was not good way to attach the wheels and motor
- I didn’t know how I could input data into MatLab continuously
- I remembered that we did this with potentiometers
- Eventually I discovered that I could use an analog stick in stead of two knobs
- This actually lead to a very simple script
s=instrfind; %Find any serial links (we can have only 1) delete(s); %... and delete. s=serial('COM1','Baudrate',115200,'Terminator','CR');%Create a new serial communications link fopen(s); %Open it.
loopTm=5; %Amount of time the program will run startTm=clock(); %store the starting time while etime(clock(),startTm)<loopTm,
fprintf(s,'VC'); %Inquire from connection "C"(left/right on analog stick) LfRt=fread(s,1); %Read left/right value. fprintf(s,'VD'); %Inquire from connection "D"(up/down on analog stick) UpDn=fread(s,1); %Read up/Down value. LfRt= LfRt/255*80-40; %Scale values from the thumbstick to change pulsewidths UpDn= UpDn/255*80-40;
%an array of pulsewidths (1 per wheel). %By adding the UpDn and LfRt variables the speed is changed. wheels=[1517+UpDn 1545-UpDn 1523-LfRt 1487+LfRt]; %create string to send to the device cmd=['#0P' num2str(wheels(1)) '#1P' num2str(wheels(2)) '#2P' num2str(wheels(3)) '#3P' num2str(wheels(4)) 'T' num2str(T)]; %...and send it. fprintf(s,cmd); end %The loop ends here.
fprintf(s,'#0P0#1P0#2P0#3P0T0'); %stop all the motors.