exitVelocityMap.put(25.0, 25.0* 3.2);
// currently regresses to y = 1.34959x + 9.79618
- shooterVelocityMap.put(0.0, 9.55);
- shooterVelocityMap.put(1.00, 11.5);
- shooterVelocityMap.put(2.00, 12.3);
- shooterVelocityMap.put(3.00, 14.0);
- shooterVelocityMap.put(4.00, 15.5);
- shooterVelocityMap.put(5.00, 17.0);
- shooterVelocityMap.put(5.60, 18.0);
- shooterVelocityMap.put(25.0, 43.44);
+ shooterVelocityMap.put(0.0, 9.55 * 1.05);
+ shooterVelocityMap.put(1.00, 11.5 * 1.05);
+ shooterVelocityMap.put(2.00, 12.3 * 1.1);
+ shooterVelocityMap.put(3.00, 14.0 * 1.075);
+ shooterVelocityMap.put(4.00, 15.5 * 1.075);
+ shooterVelocityMap.put(5.00, 17.0 * 1.05);
+ shooterVelocityMap.put(5.60, 18.0 * 1.05);
+ shooterVelocityMap.put(25.0, 43.44 * 1.05);
- newHoodMap.put(1.00, 78.0);
- newHoodMap.put(1.49, 72.0);
- newHoodMap.put(2.09, 70.0);
- newHoodMap.put(2.95, 68.0);
- newHoodMap.put(5.05, 60.0);
- newHoodMap.put(5.79, 59.0);
- newHoodMap.put(4.07, 65.0);
newHoodMap.put(0.0, 75.9);
+ newHoodMap.put(1.00, 78.0);
+ newHoodMap.put(1.49, 72.0 - 2.0 - 1.0);
+ newHoodMap.put(2.09, 70.0 - 4.0 - 2.0);
+ newHoodMap.put(2.95, 68.0 - 4.0 - 2.0);
+ newHoodMap.put(4.07, 65.0 - 3.0 - 2.0);
+ newHoodMap.put(5.05, 60.0 - 1.0 - 1.0);
+ newHoodMap.put(5.79, 59.0 - 2.0);
newHoodMap.put(27.99, 0.0);
-
}
}
private final ShooterIOInputsAutoLogged inputs = new ShooterIOInputsAutoLogged();
-
- LoggedNetworkNumber powerModifier = new LoggedNetworkNumber("OPERATOR: Shooter Power Modifier", 1.05);
+ double powerModifier = 1.00;
public Shooter() {
updateInputs();
// Convert to RPS
- double targetVelocityRPS = Units.radiansToRotations(shooterTargetSpeed / (ShooterConstants.SHOOTER_LAUNCH_DIAMETER/2)) * powerModifier.get();
+ double targetVelocityRPS = Units.radiansToRotations(shooterTargetSpeed / (ShooterConstants.SHOOTER_LAUNCH_DIAMETER/2)) * powerModifier;
if (!Constants.DISABLE_SMART_DASHBOARD) {
SmartDashboard.putNumber("Target Velocity RPS", targetVelocityRPS);
SmartDashboard.putBoolean("Shooter At Speed", atTargetSpeed());
SmartDashboard.putBoolean("Shooter Running", shooterTargetSpeed > 0);
}
-
+ powerModifier = SmartDashboard.getNumber("OPERATOR: Shooter Power Modifier", powerModifier);
+ SmartDashboard.putNumber("OPERATOR: Shooter Power Modifier", powerModifier);
+
// keep this
SmartDashboard.putString("WON AUTO?", (HubActive.wonAuto()) ? "WON" : "LOST");
}
}
public void bumpUpShooterModifier() {
- powerModifier.set(powerModifier.get() + 0.025);
+ powerModifier += 0.025;
}
public void bumpDownShooterModifier() {
- powerModifier.set(powerModifier.get() - 0.025);
+ powerModifier -= 0.025;
}
/**