![]() |
Autonomous drive scripting
5 Attachment(s)
I built some VIs to record inputs going to motor controllers to an array then write that array to a TDMS file. Then I read the file, index the array, and write the elements to the motor controller. I'm wondering if there are ways to ensure the robot drives as close a path as possible to the on the driver recorded. I already added a function to smooth out the joystick inputs and the "voltage corrected tank drive" algorithm from the team 358 LV document. I'm wondering if there are any other ways to help make sure the path is consistent. I also want to know if the TDMS functions are being used correctly and if I can do anything to optimize it.
All relevant VIs/sub VIs are uploaded as snippets. |
Re: Autonomous drive scripting
If you want the robot to consistently drive the same path (or in this case a trajectory because it's time indexed) you need to use some sensors.
I really recommend to view this thread: https://www.chiefdelphi.com/forums/s....php?p=1474091 In your case you already have a trajectory so you don't need to generate it, and you can use sensors to follow it. This year my team created our autonomous by recording what the drivers did and some sensors. We used for each of our arms feedforward + PID and for the drivetrain we recorded its position and angle and use non linear control to follow the trajectory. We also constrained the jerk, acceleration, and velocity while recording so it will be motion profiled. |
| All times are GMT -5. The time now is 20:44. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi