Re: Help with configuration needed for menu using PicoLCD driver

Martin T Jones <[email protected]> Tue, 21 Feb 2012 16:02:04 +0000
Newsgroups gmane.comp.sysutils.lcdproc
Message-ID <[email protected]>
On 20/02/12 22:59, Kaya Saman wrote:
>
>> Try changing the debug reporting level from RPT_DEBUG to RPT_NOTICE 
>> in function picoLCD_get_key in file server/drivers/picolcd.c and 
>> rebuilding with debug enabled.
>> ./configure --enable-drivers=picolcd  --enable-debug  --enable-lcdproc-menus
>> make
>> Then run the server with debug reporting and see what is reported 
>> when you press a key.
>> ./server/LCDd -fr3 -c ./LCDd.conf
>> The key definitions from my configuration file are as below, much as 
>> Markus suggested.
>> # The "...Key=" lines define what the server does with keypresses that
>> # don't go to any client. The ToggleRotateKey stops rotation of screens, while
>> # the PrevScreenKey and NextScreenKey go back / forward one screen (even if
>> # rotation is disabled.
>> # Assign the key string returned by the driver to the ...Key setting. These
>> # are the defaults:
>> ToggleRotateKey=Enter
>> PrevScreenKey=Left
>> NextScreenKey=Right
>> ScrollUpKey=Up
>> ScrollDownKey=Down
>>
>> ## The menu section. The menu is an internal LCDproc client. ##
>> [menu]
>> # You can configure what keys the menu should use. Note that the MenuKey
>> # will be reserved exclusively, the others work in shared mode.
>>
>> # Up to six keys are supported. The MenuKey (to enter and exit the menu), the
>> # EnterKey (to select values) and at least one movement keys are required.
>> # These are the default key assignments:
>> #MenuKey=Escape
>> MenuKey=F5
>> EnterKey=Enter
>> UpKey=Up
>> DownKey=Down
>> LeftKey=Left
>> RightKey=Right
>> Regards,
>>
>> Martin
>>
>
> Many thanks for the response and sorry for such a looooong delay!!! 
> Things got kinda hectic for a while.
>
>
> I have actually got the F1 key to start the menu so that's not an 
> issue :-)
>
>
> I was just wondering however, if I wanted to use the +/- keys what 
> would they be called as I'm guessing the **Enter** key is the **OK** 
> key in the center of the keypad?
>
>
> So also quick question, how to re-enable rotation?
>
>
> If I press **Enter** the rotation stops then how to do the reverse?
>
>
> Thanks,
>
>
> Kaya

The key strings are defined in server/drivers/picolcd.c the mapping 
should be obvious.

         .keymap       = { NULL,  "Plus", "Minus", "F1", "F2", "F3", "F4", "F5",

                   "Left", "Right", "Up", "Down", "Enter" },

The ToggleRotateKey stops and /starts/ rotation of screens so you just 
press Enter (OK) again, the clue is in the name, perhaps the comment 
above needs ammending.

Martin

_______________________________________________
LCDproc mailing list
[email protected]
http://lists.omnipotent.net/mailman/listinfo/lcdproc