2
0
mirror of https://github.com/team2059/Dent synced 2024-12-18 20:52:29 -05:00

Tuning autonomous

This commit is contained in:
Adam Long 2015-02-26 12:45:35 +00:00
parent 57ef72d403
commit c3e5b0cc5b
4 changed files with 9 additions and 4 deletions

View File

@ -34,12 +34,17 @@ Autonomous::Autonomous(int seq){
printf("Done");
AddSequential(new AutoDrive(SmartDashboard::GetNumber("Auto Tote Distance"), -0.75));
AddSequential(new CollectTote());
AddSequential(new Raise());
AddSequential(new AutoDrive(SmartDashboard::GetNumber("Auto Tote Distance"), -0.75));
AddSequential(new CollectTote());
AddSequential(new Lower());
AddSequential(new Raise());
printf("Three totes?: %d\n",SmartDashboard::GetBoolean("Three totes"));
if(SmartDashboard::GetBoolean("Three totes")){
AddSequential(new AutoDrive(SmartDashboard::GetNumber("Auto Tote Distance"), -0.75));
AddSequential(new CollectTote());
AddSequential(new Lower());
AddSequential(new Raise());
}
AddSequential(new Turn(90));
AddSequential(new AutoDrive(SmartDashboard::GetNumber("Auto Zone Distance"), -0.75));

View File

@ -4,7 +4,7 @@
Lower::Lower() : Command("Lower"){
}
void Lower::Initialize(){
SetTimeout(2.5);
SetTimeout(3.0);
}
void Lower::Execute(){
DentRobot::elevator->Run(-1.0);

View File

@ -4,7 +4,7 @@
Raise::Raise() : Command("Raise"){
}
void Raise::Initialize(){
SetTimeout(3.0);
SetTimeout(3.5);
}
void Raise::Execute(){
DentRobot::elevator->Run(1.0);

View File

@ -20,8 +20,8 @@
#define BINELEVATOR_TOP_DIO 8
#define BINELEVATOR_ENCODERA 10
#define BINELEVATOR_ENCODERB 11
#define BINELEVATOR_SOLDENOID_ONE 1
#define BINELEVATOR_SOLDENOID_TWO 2
#define BINELEVATOR_SOLDENOID_ONE 6
#define BINELEVATOR_SOLDENOID_TWO 7
// Drivetrain
#define DRIVE_FRONT_LEFT_CAN 2