Robotics day 16- Keypad safe
- sreeramchittayil
- Jan 20, 2023
- 1 min read
What is a safe? A safe is a password-protected system that only opens if the correct password or digits are typed in. If not, the screen will read "Wrong password, please try again." This is exactly what I have done in this lesson. I wrote a code where the correct password is a specific set of digits (which were 1, 2, and 3). If the correct password is clicked on the keypad, the four LED lights will turn on, but if the wrong password is clicked, the monitor will say "Please try again." My plans for the next lesson are to add a buzzer and write a code where if the wrong code is pressed three times, the buzzer will start to ring. This will be an effective way to improve the game and make it more realistic.
The code for the safe:

Comments