3rd year group project. Electronic and Electrical Engineering. Heriot-Watt University. This is the code for the mbed for the Automatic Little Object Organiser (ALOO).

Dependencies:   MCP23017 TCS3472_I2C WattBob_TextLCD mbed

Revision:
23:db91aaa43a9e
Parent:
22:993821a4c396
Child:
24:02c61793f90b
--- a/globals.cpp	Thu Nov 26 15:47:17 2015 +0000
+++ b/globals.cpp	Sat Nov 28 23:28:22 2015 +0000
@@ -16,6 +16,7 @@
 
 bool connectedToPC = false;
 bool runServoTest = false;
+bool runBreakBeamTest = false;
 PCModes currentMode = None;
 Controls currentState = Pause;
 
@@ -191,3 +192,13 @@
     wait(0.1);
     pc.printf("DEBUG: Setting port parity to: %i.\n", parity);
 }
+
+void testBreakBeams(Controls state){
+	if (state == Start){
+		pc.printf("INFO: Running break beam test.\n");
+		runBreakBeamTest = true;
+	}else if (state == Pause){
+		pc.printf("INFO: Exiting break beam test.\n");
+		runBreakBeamTest = false;
+	}
+}