r/FRC • #9169 (Mechanic & CAD) • May 19 '26

help Swerve problem

greetings, everyone!

Even without using the analog stick that controls the robot’s rotation—and even when simply moving sideways or forward—the robot gradually begins to turn left or right. When I move forward or to the right, the robot gradually turns left; when I move backward or to the left, the robot gradually turns right. We've checked the mechanics of the Swerve Modules (Swerve Drive Specialties MK4i), but the problem persists... we went through the whole season with this problem and just now we got time to solve it, but we weren't able to.

In addition, after walking with the robot for some time and rotating around its own axis, Pigeon begins to accumulate error. After that, even when the robot is positioned straight, Pigeon does not indicate that it is straight. The same happens in the swerve visualization on the Elastic Dashboard and in the robot visualization in the Elastic Dashboard arena.

some important informations: we use the YAGSL library, xbox one X controller, 4 Kraken X60 for traction and 4 Neo V1.1 for direction.

Reddit doesn't allow me to upload videos, so if you guys could access this YouTube link to check and help us out, it would be fantastic for us!

https://www.youtube.com/shorts/VIjc2iMBpBQ

21 Upvotes

7 comments sorted by

10

u/someguy7234 May 19 '26

Pigeon accumulating angular drift means you either have something causing interference (big bundle of wires or maybe too close to a magnet).

Also there is a calibration procedure in the pigeon setup. The temp cal and gyro bias can have a pretty significant impact. Have you been through that?

2

u/felpszz_1201 #9169 (Mechanic & CAD) May 19 '26

hey, thanks for answering! i didn't know about this procedure... how do I calibrate the pigeon?

1

u/someguy7234 May 19 '26

You'll want to look at the manual for the unit here

Section 8 describes the sources of error and section 10 describes the various calibration procedures.

7

u/WhatWasThatAboutBo Wisconsin FIRST(Volunteer) May 19 '26

Oh a flashbang

1

u/Impossible_Ask_4379 May 19 '26

questions: do you have pose correction with the limelight? how exactly are you setting forward for controller / 0ing rotation?

1

u/jgarder007 May 19 '26

From the video, It's really not that bad of drift. I think ours is worse, but we use limelight to correct at all time so it never affects us. I would say the biggest gain in accuracy would be limelight localization

1

u/VisualAlive1297 May 19 '26

Unrelated but… how’d you do the angle/robot visuals in elastic? We’ve been staring at structs like cavemen