Open AshwinS27 opened 4 years ago
Note: Make sure you know the difference and make your commands differentiate between TurnNDegreesAbsolute
(ie: if I say 90, will always point west/east, regardless of where you started) and TurnNDegreesRelative
(will turn relative to the robot's current heading).
Additionally, please ensure that you leave a comment (ideally a javadoc for the parameter in the constructor) saying which way is positive (clockwise or counterclockwise)
Look into the possibility of using motion magic for closed loop control on the turning.
Essentially both turn functions can be reduced down to one base method. TurnNDegreesRelative which uses Motion Magic
The TurnNDegrees absolute just has an additional calculation to figure out how far to turn to get to the final setpoint from where it is.
I think this might work better than closed Loop control on turn X degrees absolute with a PID controller.
Watch out for the Angles! As I recall some methods had "North at Zero and then went + and - 180 degrees. Others had north at 0 and 360 and increased 360 in a clockwise pattern.
On Sat, Jan 18, 2020 at 11:02 AM Richard Wardin notifications@github.com wrote:
Note: Make sure you know the difference and make your commands differentiate between TurnNDegreesAbsolute (ie: if I say 90, will always point west/east, regardless of where you started) and TurnNDegreesRelative (will turn relative to the robot's current heading).
Additionally, please ensure that you leave a comment (ideally a javadoc for the parameter in the constructor) saying which way is positive (clockwise or counterclockwise)
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/The-Charge/Recharge2020/issues/16?email_source=notifications&email_token=ABQRZA5UTAZQZTH5HKA54M3Q6MRXXA5CNFSM4KITVZW2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJ3TQQ#issuecomment-575912386, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABQRZA6WQX66Z6ZS22I776DQ6MRXXANCNFSM4KITVZWQ .
Also, I do have a Pigeon IMU from CTRE if you want to give it a try.
On Sun, Jan 19, 2020 at 4:24 AM Sandy Currie abcurrie@gmail.com wrote:
Look into the possibility of using motion magic for closed loop control on the turning.
Essentially both turn functions can be reduced down to one base method. TurnNDegreesRelative which uses Motion Magic
The TurnNDegrees absolute just has an additional calculation to figure out how far to turn to get to the final setpoint from where it is.
I think this might work better than closed Loop control on turn X degrees absolute with a PID controller.
Watch out for the Angles! As I recall some methods had "North at Zero and then went + and - 180 degrees. Others had north at 0 and 360 and increased 360 in a clockwise pattern.
On Sat, Jan 18, 2020 at 11:02 AM Richard Wardin notifications@github.com wrote:
Note: Make sure you know the difference and make your commands differentiate between TurnNDegreesAbsolute (ie: if I say 90, will always point west/east, regardless of where you started) and TurnNDegreesRelative (will turn relative to the robot's current heading).
Additionally, please ensure that you leave a comment (ideally a javadoc for the parameter in the constructor) saying which way is positive (clockwise or counterclockwise)
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/The-Charge/Recharge2020/issues/16?email_source=notifications&email_token=ABQRZA5UTAZQZTH5HKA54M3Q6MRXXA5CNFSM4KITVZW2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJ3TQQ#issuecomment-575912386, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABQRZA6WQX66Z6ZS22I776DQ6MRXXANCNFSM4KITVZWQ .
Command crucial for AUTON. Look at 2017 and 2018 Code