View Single Post
  #2   Spotlight this post!  
Unread 22-05-2015, 21:52
SoftwareBug2.0's Avatar
SoftwareBug2.0 SoftwareBug2.0 is offline
Registered User
AKA: Eric
FRC #1425 (Error Code Xero)
Team Role: Mentor
 
Join Date: Aug 2004
Rookie Year: 2004
Location: Tigard, Oregon
Posts: 486
SoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant future
Re: Swerve path and motor trajectory generator?

Quote:
Originally Posted by emileh3467 View Post
I think you could benefit greatly from Ether's swerve kinematics and programming documents. Look for the excel spreadsheet. All you need to give is a Joystick Y(up/down), X(left/right strafe), Z (Rotation) and Gyro Angle and it visualizes the angle and speed of 4 swerve wheels.

There is also a paper on how to write these algorithms into the programming language of your choice.

Hope this helps.
I think what he's looking for is something that will generate a sequence of angles and powers to do over time not just a single setting to choose. Interestingly, I have written such a thing for some restricted cases but was more of an exploratory exercise and didn't actually make it onto a robot.

To illustrate the difference between these two things, suppose what you want to do is go left. Ether's spreadsheet will tell you to turn all the wheels should face left and the power should be 100%. If you want to actually make trajectories what you would have is the sequence of "first turn wheels so they face left, second then turn power on for 1 ft.". Incidentally, this is not the fastest way to get to a given x,y coordinate unless you're already facing that direction.