src/main/cpp/subsystems/Subsystem1.cpp
// END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=INCLUDES

END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=INCLUDES
END AUTOGENERATED CODE SOURCE = ROBOTBUILDER ID = INCLUDES
Subsystem1::Subsystem1(){
SetName("Subsystem1");
 AddChild("Speed Controller 1", &m_speedController1);
 AddChild("AnalogGyro 1", &m_analogGyro1);
 m_analogGyro1.SetSensitivity(0.007);
 AddChild("AnalogAccelerometer 1", &m_analogAccelerometer1);
 m_analogAccelerometer1.SetSensitivity(0.0); m_analogAccelerometer1.SetZero(2.5);
 AddChild("Quadrature Encoder 1", &m_quadratureEncoder1);
 m_quadratureEncoder1.SetDistancePerPulse(1.0);
    m_quadratureEncoder1.SetPIDSourceType(frc::PIDSourceType::kRate);
 AddChild("Indexed Encoder 1", &m_indexedEncoder1);
 m_indexedEncoder1.SetDistancePerPulse(1.0);
    m_indexedEncoder1.SetPIDSourceType(frc::PIDSourceType::kRate);
    m_indexedEncoder1.SetIndexSource((unsigned int)4, frc::Encoder::IndexingType::kResetOnRisingEdge);
 AddChild("Analog Potentiometer 1", &m_analogPotentiometer1);
 AddChild("Analog Input 1", &m_analogInput1);
 AddChild("Limit Switch 1", &m_limitSwitch1);
 AddChild("Digital Input 1", &m_digitalInput1);
 AddChild("Ultrasonic 1", &m_ultrasonic1);
 AddChild("PowerDistributionPanel 1", &m_powerDistributionPanel1);
 AddChild("Nidec Brushless 1", &m_nidecBrushless1);
 AddChild("Servo 1", &m_servo1);
 AddChild("Digital Output 1", &m_digitalOutput1);
 AddChild("Spike 1", &m_spike1);
 AddChild("Analog Output 1", &m_analogOutput1);
 AddChild("Compressor 1", &m_compressor1);
 AddChild("Solenoid 1", &m_solenoid1);
 AddChild("Relay Solenoid 1", &m_relaySolenoid1);
 AddChild("Double Solenoid 1", &m_doubleSolenoid1);
 AddChild("Speed Controller 4", &m_speedController4);
 AddChild("Speed Controller 5", &m_speedController5);
 AddChild("Differential Drive 1", &m_differentialDrive1);
 m_differentialDrive1.SetSafetyEnabled(true);
        m_differentialDrive1.SetExpiration(0.1);
        m_differentialDrive1.SetMaxOutput(1.0);
 AddChild("Analog Potentiometer 2", &m_analogPotentiometer2);
 AddChild("Speed Controller 2", &m_speedController2);
 AddChild("PID Controller 1", &m_pIDController1);
         m_pIDController1.EnableContinuousInput(0.0, 5.0);
 m_pIDController1.SetTolerance(0.2); 
    frc::SmartDashboard::PutData("PID Controller 1", &m_pIDController1);
}
Subsystem1 :: Subsystem1 ( ) { SetName ( " " ) ; AddChild ( " " , & m_speedController1 ) ; AddChild ( " " , & m_analogGyro1 ) ; m_analogGyro1 . SetSensitivity ( 0.007 ) ; AddChild ( " " , & m_analogAccelerometer1 ) ; m_analogAccelerometer1 . SetSensitivity ( 0.0 ) ; m_analogAccelerometer1 . SetZero ( 2.5 ) ; AddChild ( " " , & m_quadratureEncoder1 ) ; m_quadratureEncoder1 . SetDistancePerPulse ( 1.0 ) ; m_quadratureEncoder1 . SetPIDSourceType ( frc :: PIDSourceType :: kRate ) ; AddChild ( " " , & m_indexedEncoder1 ) ; m_indexedEncoder1 . SetDistancePerPulse ( 1.0 ) ; m_indexedEncoder1 . SetPIDSourceType ( frc :: PIDSourceType :: kRate ) ; m_indexedEncoder1 . SetIndexSource ( ( unsigned int ) 4 , frc :: Encoder :: IndexingType :: kResetOnRisingEdge ) ; AddChild ( " " , & m_analogPotentiometer1 ) ; AddChild ( " " , & m_analogInput1 ) ; AddChild ( " " , & m_limitSwitch1 ) ; AddChild ( " " , & m_digitalInput1 ) ; AddChild ( " " , & m_ultrasonic1 ) ; AddChild ( " " , & m_powerDistributionPanel1 ) ; AddChild ( " " , & m_nidecBrushless1 ) ; AddChild ( " " , & m_servo1 ) ; AddChild ( " " , & m_digitalOutput1 ) ; AddChild ( " " , & m_spike1 ) ; AddChild ( " " , & m_analogOutput1 ) ; AddChild ( " " , & m_compressor1 ) ; AddChild ( " " , & m_solenoid1 ) ; AddChild ( " " , & m_relaySolenoid1 ) ; AddChild ( " " , & m_doubleSolenoid1 ) ; AddChild ( " " , & m_speedController4 ) ; AddChild ( " " , & m_speedController5 ) ; AddChild ( " " , & m_differentialDrive1 ) ; m_differentialDrive1 . SetSafetyEnabled ( true ) ; m_differentialDrive1 . SetExpiration ( 0.1 ) ; m_differentialDrive1 . SetMaxOutput ( 1.0 ) ; AddChild ( " " , & m_analogPotentiometer2 ) ; AddChild ( " " , & m_speedController2 ) ; AddChild ( " " , & m_pIDController1 ) ; m_pIDController1 . EnableContinuousInput ( 0.0 , 5.0 ) ; m_pIDController1 . SetTolerance ( 0.2 ) ; frc :: SmartDashboard :: PutData ( " " , & m_pIDController1 ) ; }
END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=INCLUDES
END AUTOGENERATED CODE SOURCE = ROBOTBUILDER ID = INCLUDES
// BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=DECLARATIONS
 // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=DECLARATIONS
