Trung Nguyen
/
FINAL_PROJECT_4180
asdasdasd
Fork of FINAL_PROJECT_4180 by
Diff: lib.h
- Revision:
- 10:c3556e27e576
- Parent:
- 9:48e93bcd1d5c
- Child:
- 11:1d7021c0739d
--- a/lib.h Mon Apr 25 01:39:32 2016 +0000 +++ b/lib.h Mon Apr 25 01:57:10 2016 +0000 @@ -2,6 +2,11 @@ #include "FPScanner.h" #include "uLCD_4DGL.h" +typedef struct{ + int user_id; + int hash; +} HASH_RECORD; + int hashcode(const char *data, int size); void read_mag_card(Serial *device, char *dest, int *size); bool fp_enroll(FPScanner *fp); @@ -13,4 +18,6 @@ void buzzer(PwmOut *speaker, int seconds); void failure_display(uLCD_4DGL *lcd, char *text); void success_display(uLCD_4DGL *lcd, char *text); -int id_to_int(char *user_id, int size); \ No newline at end of file +int id_to_int(char *user_id, int size); +void add_to_table(HASH_RECORD *table, int ind, int user_id, int hash); +bool contain_hash(HASH_RECORD *table, int table_size, int user_id, int hash); \ No newline at end of file