subsystem limelight
This commit is contained in:
		| @@ -9,8 +9,6 @@ import edu.wpi.first.networktables.NetworkTable; | ||||
| import edu.wpi.first.networktables.NetworkTableEntry; | ||||
| import edu.wpi.first.networktables.NetworkTableInstance; | ||||
| import edu.wpi.first.wpilibj2.command.SubsystemBase; | ||||
| import frc.robot.LimelightHelpers; | ||||
|  | ||||
|  | ||||
|  | ||||
| public class Limelight extends SubsystemBase { | ||||
| @@ -22,10 +20,11 @@ public class Limelight extends SubsystemBase { | ||||
|   NetworkTableEntry pipeline = table.getEntry("pipeline"); | ||||
|   NetworkTableEntry tv = table.getEntry("tv"); | ||||
|   NetworkTableEntry camMode = table.getEntry("camMode"); | ||||
|   NetworkTableEntry tid = table.getEntry("tid"); | ||||
|  | ||||
|   | ||||
|      /** Creates a new Limelight. */ | ||||
|   public Limelight() { | ||||
|  | ||||
|   } | ||||
|    | ||||
|   public double getx(){ | ||||
| @@ -40,11 +39,14 @@ public class Limelight extends SubsystemBase { | ||||
|   public boolean getv(){ | ||||
|     return tv.getBoolean(false); | ||||
|   } | ||||
|   public double getpipeline(){ | ||||
|     return pipeline.getDouble(0); | ||||
|   public void setpipeline(){ | ||||
|      pipeline.setNumber(0); | ||||
|   } | ||||
|   public double getcamMode(){ | ||||
|     return camMode.getDouble(0); | ||||
|   public void setcamMode(){ | ||||
|     camMode.setNumber(0); | ||||
|   } | ||||
|   public double getTid(){ | ||||
|     return tid.getDouble(0); | ||||
|   } | ||||
|  | ||||
|   @Override | ||||
|   | ||||
		Reference in New Issue
	
	Block a user