LCDproc install for LCDncid

LCDproc

Last Edit: May 8, 2015


All examples below assume LCDproc version 0.5.7.

Index

Configure Raspbian
Install LCDproc
Make and install LCDproc from source
LCDproc configuration file
Using an Adafruit LCD Pi Plate
Using a HD44780 compatible LCD wired as 4-bit parallel
Test

Configure Raspbian

sudo raspi-config

Install LCDproc

sudo apt-get install lcdproc

LCDd -h

Example:

LCDd - LCDproc Server Daemon, 0.5.7

Copyright (c) 1998-2014 Selene Scriven, William Ferrell, and misc. contributors. This program is released under the terms of the GNU General Public License.

....

sudo apt-get purge lcdproc

and then continue to "Make and install LCDproc from source."

Make and install LCDproc from source

sudo apt-get install libusb-dev libncurses-dev libxosd-dev

wget http://sourceforge.net/projects/lcdproc/files/lcdproc/0.5.7/lcdproc-0.5.7.tar.gz

tar xzf lcdproc-0.5.7.tar.gz

cd lcdproc-0.5.7

sudo apt-get install cvs autoconf automake

         cvs -z3 \
         -d:pserver:anonymous@lcdproc.cvs.sourceforge.net:/cvsroot/lcdproc \
         checkout -P lcdproc

cd lcdproc

sh ./autogen.sh

Either type the following all on one line without the \, or copy and paste the two lines together:

      ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
      --enable-drivers=curses,hd44780,picolcd,xosd

and then type:

         make

sudo invoke-rc.d LCDd stop

server/LCDd -f -c LCDd.conf

You should see a curses emulation window inside a terminal window:

LCDproc Server

If you do, terminate LCDd with <CTRL><C>.

change line: DriverPath=server/drivers/

to be      : DriverPath=/usr/lib/lcdproc/

sudo make install

sudo cp scripts/init-LCDd.debian /etc/init.d/LCDd
sudo cp scripts/init-lcdproc.debian /etc/init.d/lcdproc sudo chmod +x /etc/init.d/LCDd /etc/init.d/lcdproc

LCDproc configuration file

sudo cp /usr/share/doc/lcdncid/LCDd-piplate-rpi.conf /etc/LCDd.conf

sudo cp /usr/share/doc/lcdncid/LCDd-4bit-rpi.conf /etc/LCDd.conf

sudo invoke-rc.d LCDd restart

sudo invoke-rc.d LCDd restart

sudo update-rc.d LCDd defaults

Using an Adafruit LCD Pi Plate

adafruit-piplate

sudo raspi-config

  • When prompted with, Would you like the ARM I2C interface to be enabled?, choose YES.

  • When prompted with, Would you like the I2C kernel module to be loaded by default? it is very important that you choose NO; you'll be enabling the kernel modules manually below.

  • If you do not see i2c-dev, add it by typing:

            sudo sh -c "echo 'i2c-dev' >> /etc/modules"
  • If you do not see i2c-bcm2708, add it by typing:

            sudo sh -c "echo 'i2c-bcm2708' >> /etc/modules"

sudo apt-get install python-smbus
sudo apt-get install i2c-tools

Using a HD44780 compatible LCD wired as 4-bit parallel

hd44780 prototype

            Signal    LCD_Pin    RaspberryPi_Pin  
            GND        1         P1-06
            +5V        2         P1-02
            Contrast   3         P1-06  see Notes 1, 3 below
            RS         4         P1-26
            RW         5         P1-06
            E          6         P1-24

            Data 4    11         P1-22
            Data 5    12         P1-18
            Data 6    13         P1-16
            Data 7    14         P1-12
            BL        15                see Notes 2, 3 below
            GND       16         P1-06

Note 1:

Pin mapping as shown will provide maximum contrast.

For adjustable contrast, LCD pin 3 can be connected to the wiper of a 10K pot. The other legs are connected to +5V and GND.

Note 2:

Connect to +5V through a 10-600 ohm resistor for desired brightness.

Note 3:

The LCDproc HD44780 default pin mapping table differs slightly from the recommended pin mapping:

  • Contrast (pin 3) is not in the LCDproc default pin mapping table; recommended pin mapping has it connected to GND.
  • BL (pin 15) is connected to P1-11 in the LCDproc default pin mapping table; recommended pin mapping has it connected to +5V through a resistor.

Test

sudo LCDd -f

LCDproc Server

Terminate LCDd with <CTRL><C>.

sudo invoke-rc.d LCDd start

sudo update-rc.d LCDd defaults

sudo update-rc.d lcdncid defaults

man LCDd
man invoke-rc.d
man update-rc.d