|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools |
Rating:
|
Display Modes |
|
#1
|
|||
|
|||
|
Mecanum wheel twist issues.
This year we are working with a mecanum drive system. We have everything working peachy but the twist. When we twist the joystick, the robot moves in a completely random pattern. Forward, backward, and strafe are all fine.
To handle the operations we are using the Cartesian mecanum drive. For the twist we tried using Code:
stick.GetTwist() Code:
stick.GetZ() Do you guys have any idea what the problem may be? At this point, we think it may be a mechanical issue. |
|
#2
|
||||
|
||||
|
Re: Mecanum wheel twist issues.
Quote:
Then put the bot on blocks (all 4 wheels off the floor) and give it a twist (rotate) command, tell us what direction each of the wheels is spinning. What model joystick are you using? |
|
#3
|
|||
|
|||
|
Re: Mecanum wheel twist issues.
Here is a picture of the underside of the bot:
Please excuse the sub par wiring job. We're still working on cleaning that up. When twisting the joystick to the left, the front and back wheels turn away from each other. The front go forward and the back go backward. When twisting the joystick right, that is reversed, with the front going back and the back going forward. As for the joystick, we are using a Logitech extreme 3D pro. |
|
#4
|
||||
|
||||
|
Re: Mecanum wheel twist issues.
All four wheels appear to be mounted in the correct configuration.
Quote:
To rotate clockwise, the left wheels should be going forward and the right wheels backward. Vice-versa for turning counter-clockwise. |
|
#5
|
|||
|
|||
|
Re: Mecanum wheel twist issues.
So could this possibly be an issue with the ports the motor controllers are plugged into?
|
|
#6
|
||||
|
||||
|
Re: Mecanum wheel twist issues.
A sample code maybe helpful.
|
|
#7
|
||||
|
||||
|
Re: Mecanum wheel twist issues.
Quote:
|
|
#8
|
|||
|
|||
|
Re: Mecanum wheel twist issues.
Right now the only portion of code that has anything to do with the driving looks like this:
Code:
myRobot.MecanumDrive_Cartesian(stick.GetX(), stick.GetY(), stick.GetZ()); The ports are initialized as so: Code:
myRobot(1,2,3,4), stick(1) Front left motor- Port 1 Front right motor- Port 2 Back left motor- Port 3 Back right motor- Port 4 EDIT: I forgot as a side note, the MecanumDrive_Cartesian calls for input from a gyro at the end. That has not been included yet as we are working on getting our gyro mounted and working now. Last edited by zackd97 : 15-02-2014 at 18:19. |
|
#9
|
|||||
|
|||||
|
Re: Mecanum wheel twist issues.
The RobotDrive constructor takes four motors in the order frontLeft, rearLeft, frontRight, rearRight. It looks like you have ports 2 and 3 swapped.
|
|
#10
|
|||
|
|||
|
Re: Mecanum wheel twist issues.
This was the solution. Thank you!
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|