diff --git a/LCDd.conf b/LCDd.conf index 6be421c..87652c1 100644 --- a/LCDd.conf +++ b/LCDd.conf @@ -643,14 +643,15 @@ Speed=19200 # Set the display type [default: lcd; legal: lcd, lkd, vfd, vkd] Type=lkd -# The following table translate from MtxOrb Key to Logical Key. -# See [menu] section for an explanation of the key mappings -LeftKey=A -RightKey=B -EnterKey=C -UpKey=D -DownKey=E -EscapeKey=F +# The following table translates from MtxOrb key letters to logical key namess. +# By default no keys are mapped, meaning the keypad is not used at all. +#KeyMap_A=Left +#KeyMap_B=Right +#KeyMap_C=Up +#KeyMap_D=Down +#KeyMap_E=Enter +#KeyMap_F=Escape +# See the [menu] section for an explanation of the key mappings # You can find out which key of your display sends which # character by setting keypad_test_mode to yes and running diff --git a/docs/lcdproc-user/drivers/mtxorb.docbook b/docs/lcdproc-user/drivers/mtxorb.docbook index 302cb37..beade4c 100644 --- a/docs/lcdproc-user/drivers/mtxorb.docbook +++ b/docs/lcdproc-user/drivers/mtxorb.docbook @@ -1,5 +1,5 @@ -The Matrix Orbital Driver (MtxOrb) +The MtxOrb Driver This section covers the installation process for the Matrix Orbital LCD @@ -209,6 +209,8 @@ + + @@ -328,6 +331,43 @@ Slightly modified in order to include it in this document March 2002, Rene Wagne + + + KeyMap_LETTER= + KEY + + + + Matrix Orbital displays support keypads with up to 25 keys, which return + one of the letters A - Y for each + pressed key. + + + These settings allow to map the letter LETTER, + that is generated by the display when a key is pressed, to be mapped to + a key name KEY that LCDd + can understand (see + for more information). + + + There is no default key mapping; if no keys are mapped in the + LCDd.conf config file, the display is treated + as if it had no keys attached. + + + + KeyMap_A=Left + KeyMap_B=Right + KeyMap_C=Up + KeyMap_D=Down + KeyMap_E=Enter + KeyMap_F=Escape + + + + + + diff --git a/server/drivers/MtxOrb.c b/server/drivers/MtxOrb.c index dce7ff5..854e46c 100644 --- a/server/drivers/MtxOrb.c +++ b/server/drivers/MtxOrb.c @@ -57,9 +57,10 @@ #include "report.h" -// Uncomment to test new key mapping code -//#define MTXORB_NEW_KEYMAP -// Also don't forget to define key mappings in LCDd.conf: KeyMap_A=Enter, ... +// Use the new key mapping code +#define MTXORB_NEW_KEYMAP +// Don't forget to define key mappings in LCDd.conf: KeyMap_A=Enter, ... +// otherwise you will not get your keypad working. #ifdef MTXORB_NEW_KEYMAP /* MO displays allow 25 keys that map by default to 'A' - 'Y' */