2015-01-16 19:29:55 -05:00
|
|
|
#include "Elevator.h"
|
|
|
|
#include "../RobotMap.h"
|
2015-01-17 12:21:16 -05:00
|
|
|
//Elevator::Elevator() : PIDSubsystem("Elevator", kP_real, kI_real, 0.0){
|
|
|
|
Elevator::Elevator() : Subsystem("Elevator"){
|
2015-01-16 20:46:58 -05:00
|
|
|
pot=new AnalogPotentiometer(0);
|
|
|
|
leftMotor=new Talon(1);
|
|
|
|
rightMotor=new Talon(0);
|
2015-01-17 12:21:16 -05:00
|
|
|
//SetAbsoluteTolerance(0.004);
|
2015-01-16 19:29:55 -05:00
|
|
|
}
|
2015-01-17 12:21:16 -05:00
|
|
|
void Elevator::InitDefaultCommand(){
|
2015-01-16 19:29:55 -05:00
|
|
|
}
|
2015-01-16 20:46:58 -05:00
|
|
|
float Elevator::GetPotValue(){
|
|
|
|
return pot->Get();
|
|
|
|
}
|
|
|
|
void Elevator::Run(double power){
|
|
|
|
leftMotor->Set(power);
|
|
|
|
rightMotor->Set(power);
|
|
|
|
}
|