Skittles Dispenser by Benjamin Kim and Alex Zdanov

Dependencies:   4DGL-uLCD-SE HC_SR04_Ultrasonic_Library LSM9DS1_Library_cal Servo mbed

Revision:
3:2087575bfd0e
Parent:
2:c61e6541a2b4
Child:
4:8952303a18be
diff -r c61e6541a2b4 -r 2087575bfd0e main.cpp
--- a/main.cpp	Tue Mar 14 21:30:21 2017 +0000
+++ b/main.cpp	Tue Mar 14 21:54:45 2017 +0000
@@ -105,7 +105,6 @@
 
     uLCD.printf("Enter code for \n candy\n");
 
-    myservo.write(1);
     while(1) {
         /*//Checking if someone is skaing the machine
         while(!IMU.gyroAvailable())
@@ -141,9 +140,9 @@
         if(correct == 2) { // They inputted the correct password
             uLCD.cls();
             uLCD.printf("Correct Password! \n\n\n Dispensing Candy!");
-            //myservo = 0.5;
-            wait(3);
-            //myservo = 0;
+            myservo = 1;
+            wait(1.3333);
+            myservo = 0.5;
             uLCD.cls();
             uLCD.printf("Enjoy!");
             wait(2.0);