// RobotBuilder Version: 2.0
//
// This file was generated by RobotBuilder. It contains sections of
// code that are automatically generated and assigned by robotbuilder.
// These sections will be updated in the future when you export to
// Java from RobotBuilder. Do not put any code or make any change in
// the blocks indicating autogenerated code or it will be lost on an
// update. Deleting the comments indicating the section will prevent
// it from being updated in the future.


package org.usfirst.frc620.Warbot2017;

// BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=IMPORTS
import edu.wpi.first.wpilibj.AnalogPotentiometer;
import edu.wpi.first.wpilibj.DigitalInput;
import edu.wpi.first.wpilibj.PowerDistributionPanel;
import edu.wpi.first.wpilibj.Relay;
import edu.wpi.first.wpilibj.Relay.Value;
import edu.wpi.first.wpilibj.RobotDrive;
import edu.wpi.first.wpilibj.Spark;
import edu.wpi.first.wpilibj.SpeedController;
import edu.wpi.first.wpilibj.RobotDrive.MotorType;
// END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=IMPORTS
import edu.wpi.first.wpilibj.livewindow.LiveWindow;
import edu.wpi.first.wpilibj.smartdashboard.SmartDashboard;

/**
 * The RobotMap is a mapping from the ports sensors and actuators are wired into
 * to a variable name. This provides flexibility changing wiring, makes checking
 * the wiring easier and significantly reduces the number of magic numbers
 * floating around.
 */
public class RobotMap {
    // BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=DECLARATIONS
    public static SpeedController driveTrainfrontRight;
    public static SpeedController driveTrainbackRight;
    public static SpeedController driveTrainfrontLeft;
    public static SpeedController driveTrainbackLeft;
    public static RobotDrive driveTrainRobotDrive;
    public static PowerDistributionPanel driveTrainpdp;
    public static SpeedController climberclimbMotor;
    public static SpeedController gearArmarmMotor;
    public static AnalogPotentiometer gearArmpot;
    public static SpeedController ballMechballMotor;
    public static Relay visionlightSpike;
    /**4*/
    public static DigitalInput climberContactLimit;
    /**2*/
    public static DigitalInput climberDownLimit;
    /**3*/
    public static DigitalInput climberUpLimit;
    /**1*/
    public static DigitalInput ballDownLimit;
    /**5*/
    public static DigitalInput ballUpLimit;

    // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=DECLARATIONS

    public static void init() {
    	climberContactLimit= new DigitalInput(4);
    	climberDownLimit = new DigitalInput(2);
    	climberUpLimit = new DigitalInput(3);
//    	ballDownLimit = new DigitalInput(1);
//    	ballUpLimit = new DigitalInput(5);
        // BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS
        driveTrainfrontRight = new Spark(3);//3
        LiveWindow.addActuator("DriveTrain", "frontRight", (Spark) driveTrainfrontRight);
        
        driveTrainbackRight = new Spark(1);//1
        LiveWindow.addActuator("DriveTrain", "backRight", (Spark) driveTrainbackRight);
        
        driveTrainfrontLeft = new Spark(2);//2
        LiveWindow.addActuator("DriveTrain", "frontLeft", (Spark) driveTrainfrontLeft);
        
        driveTrainbackLeft = new Spark(0);//0
        LiveWindow.addActuator("DriveTrain", "backLeft", (Spark) driveTrainbackLeft);
        
        driveTrainRobotDrive = new RobotDrive(driveTrainfrontRight, driveTrainbackRight,
              driveTrainfrontLeft, driveTrainbackLeft);
        
        driveTrainRobotDrive.setSafetyEnabled(true);
        driveTrainRobotDrive.setExpiration(0.1);
        driveTrainRobotDrive.setSensitivity(0.5);
        driveTrainRobotDrive.setMaxOutput(1.0);

        driveTrainpdp = new PowerDistributionPanel(0);
        LiveWindow.addSensor("DriveTrain", "pdp", driveTrainpdp);
        
        climberclimbMotor = new Spark(5);//5
        LiveWindow.addActuator("Climber", "climbMotor", (Spark) climberclimbMotor);
        
        gearArmarmMotor = new Spark(6);//6
        LiveWindow.addActuator("GearArm", "armMotor", (Spark) gearArmarmMotor);
        
        gearArmpot = new AnalogPotentiometer(0, 1.0, 0.0);
        LiveWindow.addSensor("GearArm", "pot", gearArmpot);
        
        ballMechballMotor = new Spark(4);//4
        LiveWindow.addActuator("BallMech", "ballMotor", (Spark) ballMechballMotor);
        
        visionlightSpike = new Relay(0);
        visionlightSpike.set(Relay.Value.kOff);
        LiveWindow.addActuator("Vision", "lightSpike", visionlightSpike);
        

		driveTrainRobotDrive.setInvertedMotor(MotorType.kRearRight, true);
		//driveTrainRobotDrive.setInvertedMotor(MotorType.kFrontLeft, true);//If Test Bot
		driveTrainRobotDrive.setInvertedMotor(MotorType.kFrontRight, true);//If Final Bot
        // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS
    }
}

@@ -845,17 +845,52 @@
 otDrive;
-%0D
+%0Aimport edu.wpi.first.wpilibj.Servo;
 %0Aimport 
@@ -1816,16 +1816,51 @@
 tDrive;%0A
+    public static Servo ropeServo;%0A
     publ
@@ -4617,16 +4617,50 @@
         
+%0A        ropeServo = new Servo(7);
 %0A%0A%09%09driv

Update Robot MAp