![]() |
Best way to control the mechanum wheels
So I've heard that it's easier to control the robot with four mechunum wheels with an x-box controller. Is this true? If it is true how do you program that, because I'm our teams programmer?
|
Re: Best way to control the mechanum wheels
First, before touching any code, write down everything on paper. Now I personally have no experience with mechanum drive, but I do have lots of experiences when the robot goes haywire because I used the wrong operation or something silly like that. Always double check before hitting "run".
I would say if the X axis (or what ever you are trying to control the strafing with) is past a certain point then switch to "strafing" mode. Then make the wheels rotate based on the x axis. Its quiet simple IMHO. I assume you would have the same code for the regular 4, 6, 8 wheel drive then tag on the strafing. |
Re: Best way to control the mechanum wheels
slow down there i forgot to say this our first year with mecanum wheels should we just stick to the basics with the joysticks?
|
Re: Best way to control the mechanum wheels
You should use a joystick with a twist axis. Forward and back make the robot go forward and back, side to side makes it strafe, and twisting the joystick turns the robot. I have no idea about the programming though, I do mechanical/CAD.
|
Re: Best way to control the mechanum wheels
Quote:
|
Re: Best way to control the mechanum wheels
Quote:
PS: for all I know, what you said was 100% correct and if so, I apologize. |
Re: Best way to control the mechanum wheels
Quote:
Stick to the joysticks. There's prewritten code around somewhere; you would of course have to find it in your favorite language and tweak it for your robot. I don't recommend doing mecanum in the six weeks if you haven't done it before; if you do it that way, KISS is a MUST. Start with stuff that's already out there. David, you're close to right about the method, except that you forgot one thing: 4 independent motors vs 2 pairs of 2 motors. 2 pairs of 2 motors, you can Y-cable. 4 independent, it's a lot harder to Y-cable for some reason. Also use caution: Should you go to fallback (mecanum goes to 4WD rather easily), make sure you comment out the strafing--Alan Anderson of FRC45 found that out the hard way. You could also do a complete directional program. That might be a bit harder. |
Re: Best way to control the mechanum wheels
My team really wants to do mecanum wheels... Anyone got any sample code for two joysticks+mecanum wheels?
|
Re: Best way to control the mechanum wheels
This is my 2nd year programming and last year we had a basic 4 wheel drive. For this year the team has chosen to go with mecanum. I'm using labview. It would be awesome if someone could teach me the programming behind mecanum drive.
|
Re: Best way to control the mechanum wheels
Im using c++ anyone got any good libraries?
|
Re: Best way to control the mechanum wheels
Which develpment environment are you planning to use?
If its LabView, the VIs are all supplied. You'll have to do some problem solving to convert the joystick's output (or any other kind of steering device) to the inputs that the mechanum VI requires. I can vouch for the LabView VI. We used it last year, it works great. And we've done mechanum wheels 3 of the last 5 years. Like anything else, there are tradeoffs to consider. Keith Hall Mentor FRC 2171, FLL 1528 |
Re: Best way to control the mechanum wheels
Quote:
|
Re: Best way to control the mechanum wheels
Last year we used mecanum to great success, using two joysticks. One joystick controlled movement direction, and the other controlled rotation -- exactly like a 1st person shooter played on Xbox.
While it wasn't an Xbox controller, our driver could think of it as one, and he had an intuitive knack for it very quickly. |
Re: Best way to control the mechanum wheels
So it's not hard to do it in c++?
|
Re: Best way to control the mechanum wheels
Quote:
|
| All times are GMT -5. The time now is 13:09. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi