|
Re: Strafe using Joystick Buttons
Assuming you are using two KOP joysticks:
If your drivers like tank drive, we implemented tank-like solution for our crab-drive last year. Basically, we used both Y-axis as a Tank Drive, then used the average X axis to determine the translation angle. When translating at more than 45 degrees, it would turn the front/back pairs into tank drive (instead of the right/left pairs). It worked really well, since our drivers had been trained on tank drive and liked it very much. To implement this, you would use Mecanum-Polar with the Direction as the average of the X-axis multiplied by 90 (to turn the -1/1 into -90/90), Magnitide as the average of the Y-axis, and the Rotation as the difference in X-axis over two.
I would recommend against the "wheelie-bob" since it is not designed to be set while driving, and would be hard for your driver to adjust on-the-fly. Also, you should be aware that it has a range of 0 to 1, not -1,1.
Another thing you could do, you could use the atan2 of left js for a translation angle and the right stick as an arcade drive, that seemed to work well for us in testing. To implement this in LabVIEW, you could use Mecanum-Polar with the Magnaitude being the Y-axis of the right stick, Rotation being the X axis of the right stick, and Direction being atan2 (in degrees) of the left stick.
It all depends on what your driver wants..
@patrick - It is not the language but your understanding of the language that makes things easy or hard. Some people prefer LabVIEW and find things very easy to use, others like C++ or Java.
__________________
Kettering University - Computer Engineering
Kettering Motorsports
Williams International - Commercial Engines - Controls and Accessories
FRC 33 - The Killer Bees - 2009-2012 Student, 2013-2014 Advisor
VEX IQ 3333 - The Bumble Bees - 2014+ Mentor
"Sometimes, the elegant implementation is a function. Not a method. Not a class. Not a framework. Just a function." ~ John Carmack
|