Migrating from LCD4Linux to LCDproc

Help
2012-06-20
2013-03-31
  • Missionierer
    Missionierer
    2012-06-20

    Hi!

    I have a Lanner FW-7565 with a LCM-162 display (driver: HD44780) running with Debian Squeezy on it. Because of the tiny display (20x2) I could with LCD4Linux only get two lines of information (for example: CPU + ETH0 usage) on the display. Therefore I wanted to migrate to LCDproc to get more information (key up/down for CPU, MEM, ETH0,… usage) on the display.

    The problem is that my LCDproc output on the display is blinking and doesn´t show my “hello world”.  Can you help me debug my config files? Here is the config:

    Running LCD4Linux config:

    Display LCM-162a {
        Driver 'HD44780'
        Model 'LCM-162'
        #Bus 'parport'
        Port '/dev/parport0'
        Size '20x2'
        UseBusy 0
        asc255bug 0
        Icons 0
        SingleKeyPress 1
        #Icons 0
        Contrast 95
        Backlight 50
    }
    

    Here is my LCDd.conf

    [server]
    Driver=hd44780
    Bind=127.0.0.1
    Port=13666
    ReportLevel=5
    #ReportToSyslog=yes
    WaitTime=5
    User=nobody
    #User=root
    #ServerScreen=no
    Foreground=no
    DriverPath=/usr/lib/lcdproc/
    Hello="Hello World!"
    GoodBye="Thanks for using"
    GoodBye="LCDproc!"
    ToggleRotateKey=Enter
    PrevScreenKey=Left
    NextScreenKey=Right
    ## Hitachi HD44780 driver ##
    [hd44780]
    ConnectionType=8bit
    Port=0x378
    Device=/dev/parport0
    #Speed=0
    Keypad=yes
    Contrast=0
    Backlight=yes
    OutputPort=no
    #Lastline=true
    Size=20x2
    #vspan=2,2
    #ExtendedMode=yes
    Charmap=hd44780_default
    #DelayMult=2
    #KeepAliveDisplay=0
    #RefreshDisplay=5
    DelayBus=true
    # For example to give directly connected key 4 the string "Enter", use:
    #   KeyDirect_4=Enter
    # For matrix keys use the X and Y coordinates of the key:
    #   KeyMatrix_1_3=Enter
    KeyMatrix_4_1=Enter
    KeyMatrix_4_2=Up
    KeyMatrix_4_3=Down
    KeyMatrix_4_4=Escape
    

    Here is my log:

    # LCDd  -f
    LCDd version 0.5.2 starting
    Built on Jan 13 2009, protocol version 0.3, API version 0.5
    Using Configuration File: /etc/LCDd.conf
    Set report level to 5, output to stderr
    LCDd 0.5.2, LCDproc Protocol 0.3
    Part of the LCDproc suite
    Copyright (C) 1998-2007 William Ferrell, Scott Scriven
                            and many other contributors
    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
    as published by the Free Software Foundation; either version 2
    of the License, or (at your option) any later version.
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software Foundation,
    Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
    Server running in foreground
    Listening for queries on 127.0.0.1:13666
    screenlist_init()
    driver_load(name="hd44780", filename="/usr/lib/lcdproc/hd44780.so")
    HD44780: Matrix key 3 0: "Enter"
    HD44780: Matrix key 3 1: "Up"
    HD44780: Matrix key 3 2: "Down"
    HD44780: Matrix key 3 3: "Escape"
    hd44780: Using hd44780_default charmap
    Key "Escape" is now reserved in exclusive mode by client [-1]
    Key "Enter" is now reserved in shared mode by client [-1]
    Key "Up" is now reserved in shared mode by client [-1]
    Key "Down" is now reserved in shared mode by client [-1]
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_switch: switched to screen [_server_screen]
    screenlist_process()
    screenlist_process()
    screenlist_process()
    screenlist_process()
    screenlist_process()
    screenlist_process()
    screenlist_process()
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    screenlist_process()
    screenlist_switch(s=[_server_screen])
    ^CServer shutting down on SIGINT
    Key "Escape" was reserved in exclusive mode by client [-1] and is now released
    Key "Enter" was reserved in shared mode by client [-1] and is now released
    Key "Up" was reserved in shared mode by client [-1] and is now released
    Key "Down" was reserved in shared mode by client [-1] and is now released
    screenlist_shutdown()
    Exiting.
    
     
  • Missionierer
    Missionierer
    2012-06-21

    Has someone any clue where the problem in the config is?

    The first row of lines are all black and the second row doesen´t show anything.

     
  • Markus Dolze
    Markus Dolze
    2012-06-22

    The LCM-162 uses a wiring that is different from those used by the '8bit' or 'winamp' wirings.

    You have two options:

    1. Follow the steps from http://www.tecnowledge.net/2009/06/getting-lcdproc-to-work-with-an-lcm-162-freebsd/ at add a new sub-driver for it. Note that this is not an official driver and is unsupported by ourselves.

    2. Go into hd44780-ext8bit.c and replace these lines:

    #define RS  STRB
    #define RW  LF
    #define EN1 INIT
    

    with these ones:

    #define RS  SEL
    #define RW  INIT
    #define EN1 LF
    

    Using option 2) the keypad may need more fiddling with the reported key presses.

     
  • Missionierer
    Missionierer
    2012-06-25

    Fine Thnx, i will try it!