March 4, 2023, 8:06pm
Our robot keeps drifting to one side whenever we try to move straight. We know that this problem is not a mechanical issue however we can’t find anything wrong with the code that would lead to this.
This screenshot is from the log file from the driver station.
Here is a link to our code
March 4, 2023, 8:52pm
Please post photos of your chassis. How did your team determine that it is not a mechanical issue? What tests have been done?
March 4, 2023, 9:08pm
Here’s what’s been done so far:
checked friction on both sides via hand
disabled and * kicked * the bot travels straight
disassembled and verified the same gear ratio on both sides
checked and corrected an initial wire issue
We did find that one motor is drawing more than the others and are trying to trouble shoot that one atm
March 4, 2023, 9:15pm
Are you using the KOP chassis? If you are, check that all the pinion gears on the 4 motors are the same. We had a similar problem many years ago and struggled with it all season. After the season ended, we found out it was possible for a pinion with fewer teeth to fit. We had re-used motors from previous years.
March 4, 2023, 9:38pm
all pinion gears are 14 teeth
March 4, 2023, 9:58pm
How much is the drivetrain drifting by? How much more current is the anomalous motor pulling?
March 4, 2023, 10:13pm
If someone check the code, please. The code was updated with restore Factory Defaults for the Spark Max motor controllers. It is updated through the GitHub link.
Definitely this. We need a more quantitative description of what’s going on