Hi, this is our first time using Pathplanner ( swerve is configured with YAGSL). We had created a basic path moving straight forward. But when it does move this is what happens
Below shown is the path we used
So after more testing
We have a few more observations
When the swerve is kept on a trolley. The wheels appear to move perfectly straight and even the path planner recognises the path being completed accurately.However when we kept the swerve on the floor its slowly starts spiralling out of control (edited)
i dont understand what you mean by wheels in the same direction, however during teleop the code works perfectly with angular velocity control (not direct angle control haven’t tested too)
I said “correct” direction not “same”. The difference is very important here. This sounds like when your wheels are running with positive dutycycle they cause the robot to turn CW, which is an easy fix.
it seems to spiral out of the control which could be beause it is trying to correct angular error and the correction is in the direction of the error, so this could be the problem.
You have to test the 8 steps. You could do this by running with pathplanner but that is more tedious. I recommend using this drive function to test the eight steps.
This sounds like the glue/loctite holding your magnets in place is slipping, please check and redo them according to the module assembly documentation. This will cause an issue during any match you play and maybe even your autonomous.
Also @nstrike, how do we flip the gyro for the opposite alliance? Since for blue Alliance, the robot moves correctly. But when we set it as ed alliance, the robot follows the path correctly but after reaching the end it makes a 180-degree turn.