Skip to content

Commit

Permalink
Pneumatics
Browse files Browse the repository at this point in the history
  • Loading branch information
EldraziSquirrel committed Feb 20, 2024
1 parent 008251c commit 71b4e94
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/main/java/frc/robot/subsystems/ClimbSubsystem.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
import com.revrobotics.ControlType;
import com.revrobotics.SparkPIDController;
import edu.wpi.first.networktables.NetworkTableInstance;
import edu.wpi.first.wpilibj.PneumaticsModuleType;
import edu.wpi.first.wpilibj.Solenoid;
import edu.wpi.first.wpilibj2.command.SubsystemBase;
import frc.robot.Robot;
import frc.robot.StateControllerSub;
Expand Down Expand Up @@ -57,7 +59,9 @@ public ClimbSubsystem(StateControllerSub stateControllerSub) {
climbFollower.burnFlash();
}

private final Solenoid m_solenoid = new Solenoid(PneumaticsModuleType.REVPH, 0);

static final double maxClawDistanceMeters = 0.50;//TODO: find this
double setpointMeters = 0.0;//bottom
double simMeters = 0.0;

Expand Down Expand Up @@ -94,10 +98,10 @@ public double getClawPosition(){
}

void extendPneumatic(){
//TODO: make arm go to stowed position
m_solenoid.set(true);
}
void retractPneumatic(){
//TODO: make arm go to ready position
m_solenoid.set( false);
}

void extendClaw(){
Expand Down

0 comments on commit 71b4e94

Please sign in to comment.