kh

Dependencies:   mbed PinDetect Servo

Revision:
1:2c365f6da61d
Parent:
0:28e05e1a3d1e
Child:
2:04bbd14722bd
--- a/lock.cpp	Sat Nov 10 19:30:54 2018 +0000
+++ b/lock.cpp	Sat Nov 10 20:08:46 2018 +0000
@@ -4,6 +4,7 @@
 * Language: C
 */
 #include "lock.h"
+#include "authentication.h"
 #include "actuators.h"
 #include "powerManagement.h"
 #include "parameters.h"
@@ -18,12 +19,12 @@
 *
 */
 enum states lock() {
-	if(authenticate()) {
+	if(authenticateLock()) {
 		openSafe();
 		wait(5000);
 		return OPEN;
 	} else {
-		return LOCK:
+		return LOCK;
 	}
 }
 
@@ -34,6 +35,6 @@
 *
 *  returns: true if cup found else false
 */
-bool authenticate() {
+bool authenticateLock() {
     return CorrectEntrySequenceAttempt();
 }