Keypad – Matrix Orbital LK402-25 User Manual
Page 30

30
6. Keypad
6.1. Auto Transmit
Key Presses On
Dec
Hex
ASCII
254 65
FE 41
■ A
Key presses are automatically sent to the host when received by the display. Default is Auto Transmit on.
6.2. Auto Transmit
Key Presses Off
Dec
Hex
ASCII
254 79
FE 4F
■ O
Key presses are held in the 10 key buffer to be polled by the host using the Poll Key Press command. Use this
mode for I2C transactions. Default is Auto Transmit on.
6.3. Poll Key
Press
Dec
Hex
ASCII
254 38
FE 26
■ &
Reads the last unread key press from the 10 key display buffer. If another key is stored in the buffer the MSB will
be 1, the MSB will be 0 when the last key press is read. If there are no stored key presses a value of 0 will be
returned. Auto transmit key presses must be turned off for this command to be successful.
Response
1 byte, value of key pressed (MSB determines additional keys to be read)
6.4. Clear Key
Buffer
Dec
Hex
ASCII
254 69
FE 45
■ E
Clears all key presses from the key buffer.
6.5. Set Debounce
Time
Dec
Hex
ASCII
254 85
FE 55
■ U
Time
Time
Time
Sets the time between a key press and a key read by the display. Most switches will bounce when pressed; the
debounce time allows the switch to settle for an accurate read. Default is 8 representing a debounce time of
approximately 52ms.
Time
1 byte, debounce increment (debounce time =
Time
* 6.554ms)