This is a demonstration program which draws a keypad on the LCD and uses the touch screen to allow an operator to key-in an access code. Two possible codes are allowed to grant to different levels of access. Additionally the push button is used to allow an operator to send Moorse Code pulses in to the device which is checked against two characters to determine if there was a match, and if so, access is granted.
Dependencies: LCD_DISCO_F429ZI mbed TS_DISCO_F429ZI mbed-os BSP_DISCO_F429ZI
Also draws a mushroom on the screen and animates it.
Diff: SecurityUnlockDemo-Main.h
- Revision:
- 1:316582aec4fb
- Parent:
- 0:04d4cc695e56
diff -r 04d4cc695e56 -r 316582aec4fb SecurityUnlockDemo-Main.h --- a/SecurityUnlockDemo-Main.h Sat Jun 01 05:32:16 2019 +0000 +++ b/SecurityUnlockDemo-Main.h Sat Jun 01 20:43:11 2019 +0000 @@ -2,23 +2,28 @@ // ---------------------------------------------------------------------- // SecurityUnlockDemo-Main.h // -// Fredric L. Rice, May 2019 +// Fredric L. Rice, June 2019 // // ---------------------------------------------------------------------- #ifndef _SECURITYUNLOCKDEMOMAIN_H_ #define _SECURITYUNLOCKDEMOMAIN_H_ 1 - // We define the format of the keypad data structure which the - // module will use to describe the placement of each key - typedef struct KeypadLocation - { - uint16_t u16_screenXLocation; - uint16_t u16_screenYLocation; - uint16_t u16_keyHeight; - uint16_t u16_keyWidth; - uint8_t u8_keyASCIICharacter; - } KeypadLocation_t; +// ---------------------------------------------------------------------- +// Defined constants that we might use here +// +// ---------------------------------------------------------------------- + +// For some purposes we may want to know the dimentions of the screen +#define LCD_WIDTH 240 +#define LCD_HEIGHT 320 + +// ---------------------------------------------------------------------- +// Function prototypes that we will export +// +// ---------------------------------------------------------------------- + +extern void MainGrantAccess(uint8_t u8_thisAccessLevel); #endif