diff --git a/routines/common.h b/routines/common.h index 34b7687..2ccbfd1 100644 --- a/routines/common.h +++ b/routines/common.h @@ -3,12 +3,23 @@ #include "dev/linesensors.h" #include "robot.h" -typedef bool (*EGG_CALLBACK)(EggSensor::Reading& reading); struct negate { LineSensors::Reading::State s; }; void waitForLine(Robot& r, LineSensors::Reading::State s); void waitForLine(Robot& r, negate n); + void goToConveyor(Robot& r, bool east = true); + +typedef bool (*EGG_CALLBACK)(EggSensor::Reading& reading); + +/** Drives along the conveyor collecting eggs +\htmlonly +
+ +
+\endhtmlonly +*/ void conveyorCollect(Robot& r, EGG_CALLBACK shouldCollect); + void checkpoint(Robot& r, std::string id); void dropEggs(Robot& r, int n = 1);