Centennial-FTC-Robotics / Virus2019-2020

The 2019-2020 repository for the FTC Team VIRUS 9866!
https://chsftcrobotics.weebly.com
3 stars 2 forks source link

Only update motor powers once a threshold is passed #24

Closed OriginalAndCreativeName closed 4 years ago

OriginalAndCreativeName commented 4 years ago

When we run a PID loop to run to position, the motor powers change every loop.

Sometimes these changes are negligible, and so it can be beneficial to only update the motor powers once they have changed from their previous value by a significant amount (ex .02)

This would speed up loop speeds and improve our control, especially near the end of the movement, where the motor speed changes are very small.

keertikbacon commented 4 years ago

I added it in, and looks like there weren't any issues when calling goToPosition