1
This commit is contained in:
@@ -78,18 +78,9 @@ public final class Constants {
|
|||||||
public static final String LIMELIGHT_NAME_Shooter = "limelight-shooter";
|
public static final String LIMELIGHT_NAME_Shooter = "limelight-shooter";
|
||||||
public static final String LIMELIGHT_NAME_Intaker = "limelight-intaker";
|
public static final String LIMELIGHT_NAME_Intaker = "limelight-intaker";
|
||||||
public static final Boolean UsingMetaTag2 = true;
|
public static final Boolean UsingMetaTag2 = true;
|
||||||
<<<<<<< HEAD
|
|
||||||
public static final int Pipeline = 1;
|
|
||||||
public static final double TXDeadHand = 0.5;
|
|
||||||
public static final double TZDeadHand = 0.5;
|
|
||||||
public static final double AutoClimbAlignSpeed = 0.1;
|
|
||||||
public static final double AutoClimbAlignTolerance = 0.1;
|
|
||||||
public static final double AutoClimbmaxAngularVelocity = 0.1;
|
|
||||||
=======
|
|
||||||
public static final double AutoClimbAlignSpeed = 0.5;//等查资料
|
public static final double AutoClimbAlignSpeed = 0.5;//等查资料
|
||||||
public static final double AutoClimbAlignTolerance = 0.1;//?
|
public static final double AutoClimbAlignTolerance = 0.1;//?
|
||||||
public static final double AutoClimbmaxAngularVelocity = 0.5;//等查资料
|
public static final double AutoClimbmaxAngularVelocity = 0.5;//等查资料
|
||||||
>>>>>>> a8acbce9dc302adc52e28e6f8c205677f50ea20e
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public class Field {
|
public class Field {
|
||||||
|
|||||||
@@ -144,11 +144,6 @@ public class RobotContainer {
|
|||||||
controllerlower.a()
|
controllerlower.a()
|
||||||
.onTrue(robotStatusManager.setStatusCommand(RobotStatus.Climbing))
|
.onTrue(robotStatusManager.setStatusCommand(RobotStatus.Climbing))
|
||||||
.onFalse(robotStatusManager.setStatusCommand(RobotStatus.AllTelop));
|
.onFalse(robotStatusManager.setStatusCommand(RobotStatus.AllTelop));
|
||||||
<<<<<<< HEAD
|
|
||||||
=======
|
|
||||||
|
|
||||||
|
|
||||||
>>>>>>> a8acbce9dc302adc52e28e6f8c205677f50ea20e
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void configueShooter(){
|
private void configueShooter(){
|
||||||
|
|||||||
@@ -76,9 +76,9 @@ public class ShooterControls {
|
|||||||
flywheelSpeed = 0;
|
flywheelSpeed = 0;
|
||||||
conveyorSpeed = 0;
|
conveyorSpeed = 0;
|
||||||
}
|
}
|
||||||
if(shooterSubsystem.flywheelMotorLeft.getVelocity().getValueAsDouble()<flywheelSpeed*0.9){
|
// if(shooterSubsystem.flywheelMotorLeft.getVelocity().getValueAsDouble()<flywheelSpeed*0.7){
|
||||||
conveyorSpeed = 0;
|
// conveyorSpeed = 0;
|
||||||
}
|
// }
|
||||||
shooterControlTable.getEntry("flywheelTargetSpeed").setDouble(flywheelSpeed);
|
shooterControlTable.getEntry("flywheelTargetSpeed").setDouble(flywheelSpeed);
|
||||||
shooterControlTable.getEntry("conveyerTargetSpeed").setDouble(conveyorSpeed);
|
shooterControlTable.getEntry("conveyerTargetSpeed").setDouble(conveyorSpeed);
|
||||||
shooterControlTable.getEntry("backboardTargetPosition").setDouble(backboardPosition);
|
shooterControlTable.getEntry("backboardTargetPosition").setDouble(backboardPosition);
|
||||||
|
|||||||
@@ -131,14 +131,6 @@ public class CommandSwerveDrivetrain extends TunerSwerveDrivetrain implements Su
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
=======
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
>>>>>>> a8acbce9dc302adc52e28e6f8c205677f50ea20e
|
|
||||||
private static final double kMaxVisionJumpMeters = 1.0;
|
private static final double kMaxVisionJumpMeters = 1.0;
|
||||||
private static final double kMaxOmegaDegPerSec = 360.0;
|
private static final double kMaxOmegaDegPerSec = 360.0;
|
||||||
|
|
||||||
@@ -282,10 +274,6 @@ public class CommandSwerveDrivetrain extends TunerSwerveDrivetrain implements Su
|
|||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
<<<<<<< HEAD
|
|
||||||
=======
|
|
||||||
|
|
||||||
>>>>>>> a8acbce9dc302adc52e28e6f8c205677f50ea20e
|
|
||||||
public String driveToAprilTag(){
|
public String driveToAprilTag(){
|
||||||
//Rotation2d targetHeading = getPose().getRotation();
|
//Rotation2d targetHeading = getPose().getRotation();
|
||||||
if(!LimelightSupplier.isTargetVisible() ){
|
if(!LimelightSupplier.isTargetVisible() ){
|
||||||
@@ -296,18 +284,12 @@ public class CommandSwerveDrivetrain extends TunerSwerveDrivetrain implements Su
|
|||||||
for(int id : new int[]{16,32}){
|
for(int id : new int[]{16,32}){
|
||||||
if(id == trueId){
|
if(id == trueId){
|
||||||
ifRightTag = true;
|
ifRightTag = true;
|
||||||
<<<<<<< HEAD
|
|
||||||
System.out.println("Target get.");
|
System.out.println("Target get.");
|
||||||
=======
|
|
||||||
>>>>>>> a8acbce9dc302adc52e28e6f8c205677f50ea20e
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(!ifRightTag){
|
if(!ifRightTag){
|
||||||
<<<<<<< HEAD
|
|
||||||
System.out.println("No Target.");
|
System.out.println("No Target.");
|
||||||
=======
|
|
||||||
>>>>>>> a8acbce9dc302adc52e28e6f8c205677f50ea20e
|
|
||||||
return "No Target";
|
return "No Target";
|
||||||
}
|
}
|
||||||
double tx = LimelightSupplier.getTX() ;
|
double tx = LimelightSupplier.getTX() ;
|
||||||
|
|||||||
@@ -84,20 +84,7 @@ public class LimelightSupplier extends SubsystemBase {
|
|||||||
SmartDashboard.putString("LimelightPipeType", LimelightHelpers.getCurrentPipelineType(Constants.Limelight.LIMELIGHT_NAME_Intaker));
|
SmartDashboard.putString("LimelightPipeType", LimelightHelpers.getCurrentPipelineType(Constants.Limelight.LIMELIGHT_NAME_Intaker));
|
||||||
if (isTargetVisible()){
|
if (isTargetVisible()){
|
||||||
SmartDashboard.putString("LimelightTargetVisible", "YES");
|
SmartDashboard.putString("LimelightTargetVisible", "YES");
|
||||||
<<<<<<< HEAD
|
|
||||||
// SmartDashboard.putNumber("LimelightTX", getTX());
|
|
||||||
// SmartDashboard.putNumber("LimelightTY", getTY());
|
|
||||||
SmartDashboard.putNumber("LimelightTA", getTA());
|
SmartDashboard.putNumber("LimelightTA", getTA());
|
||||||
// double[] targetPose = getTargetPose();
|
|
||||||
// String s = "";
|
|
||||||
// for(double x : targetPose){
|
|
||||||
// s += Double.toString(x);
|
|
||||||
// s += " ";
|
|
||||||
// }
|
|
||||||
// SmartDashboard.putString("LimeLightTP", s);
|
|
||||||
=======
|
|
||||||
SmartDashboard.putNumber("LimelightTA", getTA());
|
|
||||||
>>>>>>> a8acbce9dc302adc52e28e6f8c205677f50ea20e
|
|
||||||
SmartDashboard.putNumber("TargetRY", getTargetRotationY());
|
SmartDashboard.putNumber("TargetRY", getTargetRotationY());
|
||||||
SmartDashboard.putNumber("TargetTX", getTX());
|
SmartDashboard.putNumber("TargetTX", getTX());
|
||||||
SmartDashboard.putNumber("TargetTZ", getTargetTZ());
|
SmartDashboard.putNumber("TargetTZ", getTargetTZ());
|
||||||
|
|||||||
Reference in New Issue
Block a user