From 5bbbf1717ee34b69daab68e87ccaaef1e0549d43 Mon Sep 17 00:00:00 2001 From: Aidan Ferguson Date: Mon, 15 Feb 2016 15:14:20 -0500 Subject: [PATCH] Finished shooter switch. --- Robot2016/src/Shooter.h | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/Robot2016/src/Shooter.h b/Robot2016/src/Shooter.h index aeeab87..a8469b7 100644 --- a/Robot2016/src/Shooter.h +++ b/Robot2016/src/Shooter.h @@ -96,9 +96,9 @@ public: case READY: { state = SPINNINGUP; - launch_spinny->Set(-1); - launcher->Set(PICKUP_POWER); - pickup->Set(PICKUP_POWER); + launch_spinny->Set(0); + launcher->Set(LAUNCH_POWER); + pickup->Set(LAUNCH_POWER); shotClock.Reset(); shotClock.Start(); break; @@ -118,7 +118,7 @@ public: } case LAUNCH: { - launch_spinny->Set(1); + launch_spinny->Set(LAUNCH_POWER); state = LAUNCHING; break; } @@ -131,6 +131,19 @@ public: } break; } + case RESETTING: + { + launch_spinny->Set(0); + launcher->Set(0); + pickup->Set(0); + state = READY; + break; + } + case ON_FIRE: + { + std::cout << "Something is wrong with the launch sequence.\n"; + break; + } } }