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

Added older auto sequences

This commit is contained in:
Adam Long 2015-03-19 12:52:16 +00:00
parent c47be842ae
commit 5193cbb59a
3 changed files with 16 additions and 2 deletions

View File

@ -7,7 +7,7 @@ AutoDrive::AutoDrive(double duration, double xtmp, double ytmp, double ztmp, boo
x=xtmp; x=xtmp;
y=ytmp; y=ytmp;
z=ztmp; z=ztmp;
gyro=false; gyro=useGyro;
} }
void AutoDrive::Initialize(){ void AutoDrive::Initialize(){
DentRobot::drivetrain->ResetGyro(); DentRobot::drivetrain->ResetGyro();

View File

@ -74,6 +74,20 @@ Autonomous::Autonomous(int seq){
// Same as auto 4 with (Three|Two) totes checked, collect bin, drive to Auto Zone (TM), release totes // Same as auto 4 with (Three|Two) totes checked, collect bin, drive to Auto Zone (TM), release totes
//TODO: Implement this //TODO: Implement this
break; break;
case 8:
//Use rear elevator to move tote
AddSequential(new BinRaise(1));
AddSequential(new Turn(2.1));
AddSequential(new AutoDrive(SmartDashboard::GetNumber("Auto Zone Distance"),0.0,0.75));
AddSequential(new Turn(2.1));
break;
case 9:
//Use rear elevator to move tote
AddSequential(new BinLower(1.5));
AddSequential(new Turn(2.1));
AddSequential(new AutoDrive(SmartDashboard::GetNumber("Auto Zone Distance"),0.0,-0.75));
AddSequential(new Turn(2.1));
break;
default: default:
printf("Invalid seq: %d\n", seq); printf("Invalid seq: %d\n", seq);
break; break;

View File

@ -13,7 +13,7 @@ void RollIn::Execute(){
//}else{ //}else{
// DentRobot::collector->MoveRollers(cvt*1.5); // DentRobot::collector->MoveRollers(cvt*1.5);
//} //}
DentRobot::collector->MoveRollers(DentRobot::oi->GetLeftThrottle() * 0.8); DentRobot::collector->MoveRollers(DentRobot::oi->GetLeftThrottle() * 1.0);
} }
bool RollIn::IsFinished(){ bool RollIn::IsFinished(){
return IsTimedOut(); return IsTimedOut();