Code Update 4

Tags: journal and think
Personhours: 36
Code Update 4 By Elm, Nirjha, and Alyssa

After LM2, the SCORPIUS code was fully revamped to improve structure and performance. However, due to limited time before LM3, we weren’t able to fine-tune our auton and driver controls, so we couldn’t use our code to its full potential.

One of the main challenges during LM3 was that the third ball consistently undershot. To address this, we developed an equation to calculate the necessary launch speed from different field positions and fine-tuned our PID velocity to work with the momentum batteries added by build. Using distance measurements from the Limelight, we plotted the required flywheel speeds and applied multiple regressions. A quartic regression provided the best fit, with the highest R² value, enabling accurate launch predictions across different distances.

We also transitioned to using Superstar, by adding specific servo values that the star moves to between subsequent shots during the shooting sequence. Additionally, we implemented Roadrunner to track the robot’s trajectory and position through a virtual field map defining exact robot poses using waypoints (coordinates holding x, y and theta value for heading; middle of the field is origin). During auton, the robot executes missions which are reusable, goal-focused tasks that coordinate drivetrain motion and robot actions. This allows smooth movement between objectives without unnecessary stops.

We have developed two autons: one that scores from the launching zone near the audience and another from the launching zone near the goal, allowing for flexibility depending on match setup and how our teammates operate. Our auton can reliably score 6–9 artifacts.

One issue we have realized was that our limelight was struggling to identify the goals due to the fact that we tuned it in an environment with bright lighting. We also noticed that most balls were overshooting. These are both largely due to misalignment with the goal and limelight detection, and we plan to fix these issues before our next competition.

Date | February 8, 2026