In the second version of the keypad library, an effort has been made to generate compile-time errors for common mistakes and to eliminate possibly ambiguous compilation. Failure to include these directives will cause compile-time errors, run-time errors, or both. However, several preprocessor directives must be invoked before including the keypad header file (keypad.h). The keypad library has been designed to be versatile, requiring very little user intervention to operate as intended. The keypad library automatically advances the cursor as each letter is typed. Specifies the starting location for typed characters. void keypad_gotoxy(unsigned char x, unsigned char y).There are three display modes: KEYPAD_NODISPLAY, KEYPAD_MASKDISPLAY (display an asterisk ('*') for each typed character), and KEYPAD_ECHODISPLAY (display characters as typed). Specifies how the keypad library handles displaying key presses. void keypad_set_display(unsigned char display).Call this function as soon as keystring has been processed and another keystring required.Įxtended user interface for operating the display: Once the keystring has been terminated, the keypad state machine enters a done state so no additional key presses can be read until the keystring has been processed and the keypad released. This function reads key presses, constructs the "keystring", and signals its completion/termination using "keystring_ready". Responsible for running the keypad state machine. Specifies which keypad buttons (based upon their keysymbol) to ignore. void keypad_ignore_keysymbol(unsigned char keysymbol).A terminator must be defined for the telephone and hexadecimal keypads unless using the keypad as a keyboard (see below). Replaces a character in the key symbol table with '\0' (NULL). void keypad_define_terminator(unsigned char keysymbol).Replaces a character in the key symbol table with a new user specified character. void keypad_map_keysymbol(unsigned char old_keysymbol, unsigned char new_keysymbol).
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |