
Safe of the God's was a group project. For the project we were given the task to create an electronic safe with an embedded system.
Dependencies: mbed Servo PinDetect
src/lock.h@4:628468ce3e86, 2018-12-29 (annotated)
- Committer:
- monwonga3
- Date:
- Sat Dec 29 07:04:53 2018 +0000
- Revision:
- 4:628468ce3e86
- Parent:
- lock.h@2:04bbd14722bd
Safe of the Gods
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
monwonga3 | 4:628468ce3e86 | 1 | /* |
monwonga3 | 4:628468ce3e86 | 2 | * Authors: Group 4 Adam Elghor, Brian Kaplan, Sayak Chatterjee, Moraa Onwonga |
monwonga3 | 4:628468ce3e86 | 3 | * Purpose: Controls the LOCK state of the machine |
monwonga3 | 4:628468ce3e86 | 4 | * Language: C++ |
monwonga3 | 4:628468ce3e86 | 5 | */ |
Sayak97 | 1:2c365f6da61d | 6 | |
monwonga3 | 4:628468ce3e86 | 7 | /* |
monwonga3 | 4:628468ce3e86 | 8 | * Function: lock |
monwonga3 | 4:628468ce3e86 | 9 | * -------------------- |
monwonga3 | 4:628468ce3e86 | 10 | * Locks safe |
monwonga3 | 4:628468ce3e86 | 11 | * |
monwonga3 | 4:628468ce3e86 | 12 | * returns: the next state in the state machine |
monwonga3 | 4:628468ce3e86 | 13 | * Open: After it has been locked |
monwonga3 | 4:628468ce3e86 | 14 | * |
monwonga3 | 4:628468ce3e86 | 15 | */ |
monwonga3 | 4:628468ce3e86 | 16 | enum states lock(); |
monwonga3 | 4:628468ce3e86 | 17 | |
monwonga3 | 4:628468ce3e86 | 18 | /* |
monwonga3 | 4:628468ce3e86 | 19 | * Function: authenticateLock |
monwonga3 | 4:628468ce3e86 | 20 | * ---------------------------- |
monwonga3 | 4:628468ce3e86 | 21 | * Checks whether a cup was found through the sonar sensor |
monwonga3 | 4:628468ce3e86 | 22 | * |
monwonga3 | 4:628468ce3e86 | 23 | * returns: true if cup found else false |
monwonga3 | 4:628468ce3e86 | 24 | */ |
monwonga3 | 4:628468ce3e86 | 25 | bool authenticateLock(); |
monwonga3 | 4:628468ce3e86 | 26 |