Sync'd the latest changes from 2025 season.

Moved all auto tasks from autotasks to tasks.
Added new Dashboard class.
Added solvePnP support to vision.
Added updateStatus to vision.
Added updateStatus too FtcAuto, FtcTeleOp.
Removed updateStatus from Robot.java.
Added asymetric motion profile support to PurePursuit.
Added updateStatus to RobotBase.
Added solvePnp support for vision.
Updated trclib, ftclib.
Added acme FtcDashboard support.
Added support to tune using acme FtcDashboard.
Added maxDeceleration support in SpeedTest.
This commit is contained in:
Titan Robotics Club
2025-04-25 20:43:46 -07:00
parent e77f40297a
commit 0869026b76
12 changed files with 568 additions and 596 deletions

View File

@ -32,7 +32,7 @@ import ftclib.sensor.FtcRobotBattery;
import teamcode.subsystems.LEDIndicator;
import teamcode.subsystems.RobotBase;
import teamcode.subsystems.RumbleIndicator;
import teamcode.subsystems.Vision;
import teamcode.vision.Vision;
import trclib.motor.TrcMotor;
import trclib.motor.TrcServo;
import trclib.pathdrive.TrcPose2D;
@ -56,6 +56,7 @@ public class Robot
private static TrcPose2D endOfAutoRobotPose = null;
private static double nextStatusUpdateTime = 0.0;
// Robot Drive.
public RobotBase robotBase;
public FtcRobotDrive.RobotInfo robotInfo;
public FtcRobotDrive robotDrive;
// Vision subsystems.
@ -83,7 +84,7 @@ public class Robot
nextStatusUpdateTime = TrcTimer.getCurrentTime();
speak("Init starting");
// Create and initialize Robot Base.
RobotBase robotBase = new RobotBase();
robotBase = new RobotBase();
robotInfo = robotBase.getRobotInfo();
robotDrive = robotBase.getRobotDrive();
// Create and initialize vision subsystems.
@ -271,31 +272,6 @@ public class Robot
}
} //stopMode
/**
* This method update all subsystem status on the dashboard.
*
* @param startLineNum specifies the first Dashboard line for printing status.
*/
public void updateStatus(int startLineNum)
{
double currTime = TrcTimer.getCurrentTime();
if (currTime > nextStatusUpdateTime)
{
int lineNum = startLineNum;
nextStatusUpdateTime = currTime + RobotParams.Robot.DASHBOARD_UPDATE_INTERVAL;
if (robotDrive != null)
{
dashboard.displayPrintf(lineNum++, "DriveBase: Pose=%s", robotDrive.driveBase.getFieldPosition());
}
//
// Display other subsystem status here.
//
if (RobotParams.Preferences.showSubsystems)
{
}
}
} //updateStatus
/**
* This method is called to cancel all pending operations and release the ownership of all subsystems.
*/