|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#16
|
||||
|
||||
|
Re: Mecanum steering
I forgot to answer your other questions!
Quote:
Quote:
Last edited by carrillo694 : 06-03-2013 at 15:33. Reason: wording. |
|
#17
|
||||
|
||||
|
Re: Mecanum steering
Quote:
Quote:
The WPILib RoboDrive methods have an input for gyro angle. Code:
/**
* Drive method for Mecanum wheeled robots.
*
* A method for driving with Mecanum wheeled robots. There are 4 wheels
* on the robot, arranged so that the front and back wheels are toed in 45 degrees.
* When looking at the wheels from the top, the roller axles should form an X across the robot.
*
* This is designed to be directly driven by joystick axes.
*
* @param x The speed that the robot should drive in the X direction. [-1.0..1.0]
* @param y The speed that the robot should drive in the Y direction.
* This input is inverted to match the forward == -1.0 that joysticks produce. [-1.0..1.0]
* @param rotation The rate of rotation for the robot that is completely independent of
* the translation. [-1.0..1.0]
* @param gyroAngle The current angle reading from the gyro. Use this to implement field-oriented controls.
*/
public void mecanumDrive_Cartesian(double x, double y, double rotation, double gyroAngle)
|
|
#18
|
||||
|
||||
|
Re: Mecanum steering
Quote:
To anyone, how does the gyro temp feedback work in the code? (I don't usually get into the programming so you should talk to me like I'm 6) I'm poking through the java API and didn't notice temp anywhere in the gyro class. Since the temp is obviously going to a different channel than the gyro, it seems i would need to also set temp up as a separate sensor, but that too i didn't see in the sensorbase class. ?? Also to add 2 cents on the general mecanum talk: We've used mecanum since 2011 and never seen the "forward command equals horrible spin result" described all the time on CD. This is without gyro or encoder feedback. We have never been accused of having really fantastically designed and constructed drivetrains and have never given much (or any) time to weight distribution. This year a test drivebase was made which exhibited something kinda like the "forward command equals spin", but it was very minor and the driver was able to compensate for it without much trouble. Just looking at it everyone figured the problem was the fact that the electronics board thrown on top had the battery cantilevered outside of the frame. At this point the battery had to be 25-50% of the total weight. THEN it was discovered that the 8020 frame was assembled incorrectly causing the frame to be warped. The combination of the 2 had one wheel taking almost none of weight. And still the driving behavior was not that bad. This leads me to the hypothesis that "forward command equals horrible spin result" behavior reported frequently is almost always caused by incorrect use or poor functionality of the gyro...Last edited by lcoreyl : 16-03-2013 at 20:19. Reason: forgot one thing |
|
#19
|
||||
|
||||
|
Re: Mecanum steering
No, no additional information. Our driver is nails without it, and we don't need it for autonomous, so it's something we plan on investigating further in the off season.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|