Created
July 23, 2019 10:28
-
-
Save ThaiEasyElec/9fb9460ee5bafced5f3836ca074b9850 to your computer and use it in GitHub Desktop.
Home Alarm System
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void checkPassword(){ // Function check the password | |
if (password.evaluate()){ | |
//Add code to run if it works | |
while(1){ | |
//Serial.println("Success"); | |
fl = 1; | |
digitalWrite(status_lock, LOW); | |
digitalWrite(status_unlock, HIGH); | |
lcd.setCursor(0, 3); | |
lcd.print(" ** Home Unlock ** "); | |
keypad.getKey(); | |
Alarm_off(); | |
password.reset(); | |
} | |
}else{ | |
Serial.println("Wrong"); | |
//add code to run if it did not work | |
lcd.setCursor(0, 3); | |
lcd.print("**Password Wrong **"); | |
delay(1000); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment