/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { // instantiate the command used for the autonomous period autonomousCommand = new ExampleCommand(); frontLeft = new Victor(1); // Creating Victor motors frontRight = new Victor(2); rearLeft = new Victor(3); rearRight = new Victor(4); myDrive = new RobotDrive(frontLeft, frontRight); // myDrive = new RobotDrive(frontLeft,frontRight,rearLeft,rearRight); driveStick = new Joystick(1); gyro = new Gyro(1); // Initialize all subsystems CommandBase.init(); }
public void robotInit() { // instantiate the command used for the autonomous period //autonomousCommand = new ExampleCommand(); // Initialize all subsystems CommandBase.init(); table = NetworkTable.getTable("CRIO"); table.putBoolean("bool", true); table.putNumber("double", 3.1415927); table.putString("sring", "a string"); LogDebugger.log("robot init!!!"); // LiveWindow.addActuator("compressor", "alt relay", RobotMap.testCompRelay); // LiveWindow.addActuator("compressor", "act compressor", RobotMap.airCompressor); // LiveWindow.addSensor("compressor", "sensor compressor", RobotMap.airCompressor); }
/** * */ public void robotInit() { // instantiate the command used for the autonomous period DriveTrain = new DriveTrain(); launchercontroller = new Launcher(); rollerSubsystem = new Roller(); display = DriverStationLCD.getInstance(); compressor = new Compressor(RobotMap.PressureSwitchDigitalInput, RobotMap.CompressorRelay); compressor.start(); DriveTrain.shiftHighGear(); OI.initialize(); autonomousCommand = new Autonomous(); arduino = new ArduinoConnection(); arduino.setPattern("4"); pattern = 0; driverStation = DriverStation.getInstance(); alliance = driverStation.getAlliance().value; digital1 = driverStation.getDigitalIn(1); digital2 = driverStation.getDigitalIn(2); digital3 = driverStation.getDigitalIn(3); // Initialize all subsystems. // Subsystems: a self-contained system within a larger system. CommandBase.init(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { // instantiate the command used for the autonomous period autonomousCommand = new ExampleCommand(); RobotParts.compressor.start(); RobotParts.drive.setSafetyEnabled(false); // Initialize all subsystems CommandBase.init(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { SmartDashboard.putData("Tank Drive", new SetStation(1)); SmartDashboard.putData("Arcade Drive", new SetStation(2)); SmartDashboard.putData("XBox Controller Tank", new SetStation(3)); SmartDashboard.putData("XBox Controller Arcade", new SetStation(4)); /** * Adds buttons to SmartDAshboard */ // instantiate the command used for the autonomous period autonomousCommand = new AutonomousCommand(); prefs = Preferences.getInstance(); prefs.putDouble("Deadband",0.1); prefs.putDouble("ArmDeadband", 0.1); prefs.putDouble("LeftPolarity", -1); prefs.putDouble("RightPolarity", -1); prefs.putDouble("Scaler", 1); prefs.putDouble("HueLow", 80); prefs.putDouble("HueHigh", 200); prefs.putDouble("SaturationLow",100); prefs.putDouble("SaturationHigh",300); prefs.putDouble("BrightnessLow",200); prefs.putDouble("BrightnessHigh", 240); SmartDashboard.putData(Scheduler.getInstance()); /** * Adds variables to the Preferences Table in SmartDashboard, */ // Initialize all subsystems CommandBase.init(); System.out.println("--------------------2713-----------------------"); System.out.println("*Awsome-sauce code produced by Fid inc. *"); System.out.println("*WARNING: might not possibly work *"); System.out.println("-----------------TEST-ROBOT--------------------"); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { // instantiate the command used for the autonomous period autonomousCommand = new ExampleCommand(); // Initialize all subsystems CommandBase.init(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { teleopDriveCommand = new DriveWithJoystick(); // Initialize all subsystems CommandBase.init(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { // instantiate the command used for the autonomous period autonomousCommand = new AutoMode(); // Initialize all subsystems CommandBase.init(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { // instantiate the command used for the autonomous period //autonomousCommand = new Autonomous(); // Initialize all subsystems CommandBase.init(); SmartDashboard.putData(Scheduler.getInstance()); delay = new Delay(1); gyroOff = CommandBase.gyro.getAngle()/Timer.getFPGATimestamp(); }
public void teleopInit() { // This makes sure that the autonomous stops running when // teleop starts running. If you want the autonomous to // continue until interrupted by another command, remove // this line or comment it out. //autonomousCommand.cancel(); delay = new Delay(1); gyroOff = CommandBase.gyro.getAngle()/Timer.getFPGATimestamp(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { getWatchdog().setEnabled(true); RobotMap.init(); CommandBase.init(); drivetrain = CommandBase.drivetrain; SmartDashboard.putBoolean("motorKilled", false); }
public void robotInit() { autonomousCommand = new Autonomous1(); autoChooser = new SendableChooser(); autoChooser.addDefault("Autonomous 1", new Autonomous1()); SmartDashboard.putData("Autonomous Chooser", autoChooser); CommandBase.init(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { // instantiate the command used for the autonomous period // autonomousCommand = new ExampleCommand(); // Initialize all subsystems CommandBase.init(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { // Initialize the CommandBase so that everything is ready to run CommandBase.init(); // instantiate the command used for the autonomous period // Set it so that it runs the SodaDelivery command automatically during // the automous period. autonomousCommand = new SodaDelivery(); }
/** * This function is run when the robot is first started up and should be * used for any initialization code. */ public void robotInit() { // instantiate the command used for the autonomous period autonomousCommand = new ExampleCommand(); driveCommand = new Drive(); shootCommand = new RunShooter(); eccentricCommand = new EccentricWheel(); potCommand = new Potentiometer(); // Initialize all subsystems CommandBase.init(); }
public void updateStatus() { CommandBase.driveTrain.updateStatus(); }
public void pidWrite(double d) { CommandBase.drivetrain.setRightDrive(d); System.out.println("Right Drive Speed: "+d); }
public void changeGears() { lowGear = !lowGear; CommandBase.drivetrain.changeGears(lowGear); System.out.println("Gears Changed"); }
public void pidWrite(double d) { CommandBase.drivetrain.setLeftDrive(d); System.out.println("Left Drive Speed: "+d); }
public void updatestatus(){ CommandBase.driveTrain.updateStatus(); }
public void updateStatus(){ CommandBase.theScooperCollector.updateStatus(); CommandBase.theAccelerometer.updateStatus(); CommandBase.thePizzaBoxTilt.updateStatus(); }