The HD44780 Driver

The HD44780 has become the de-facto standard of alphanumeric character displays. Although the original Hitachi HD44780 is long out of production, its command set has survived in a variety of (fully or nearly) compatible LCD, VFD and even OLED displays sold by a broad range of manufacturers all over the world. To name only a few: KS0066, KS0070, KS0076, LC7985, NT3881, SED1278, ST7066 ...

The command set of these displays, which sometimes are advertised as being "industry standards compatible", is thus the workhorse of controllers for displays ranging from 8x1 to 20x4 or 40x2 characters. There are even displays with larger dimensions sporting two controllers, one for each half of the display.

The HD44780 driver supports various ways of connecting HD44780 devices to your system. Each of these different ways is called a connection type of the driver.

Depending on the connection type and the display connected, the driver supports various special features.

The following table lists the available connection types, sorted by the kind of connection (parallel port, serial port, USB, I2C, SPI or others).

Table 5.1. HD44780: Connection Types

ConnectionTypeWiring / Display Type
Parallel port connection types:
4bit4-bit wiring. This is the default.
8bit8-bit wiring ("lcdtime" style)
winamp8-bit wiring ("winamp" style)
lcm1628-bit wiring ("lcm162" style)
serialLptSerial LPT wiring
Serial (RS-232) connection types:
picanlcdPIC-an-LCD serial device "picanlcd"
lcdserializerLCD serializer "lcdserializer"
los-panelLCD on Serial panel device "los-panel" (http://mlf.home.xs4all.nl/los/)
vdr-lcdVDR LCD serial device "vdr-lcd"
vdr-wakeupVDR-Wakeup module "vdr-wakeup"
ezioEZIO-100 and EZIO-300 by Portwell
USB connection types:
pertelianPertelian X2040 LCD display (http://pertelian.com/joomla/index.php?option=com_content&task=view&id=43&Itemid=48)
lis2LIS2 from VLSystem (http://www.vlsys.co.kr)
mplayMPlay Blast from VLSystem (http://www.vlsys.co.kr)
usblcdUSBLCD adapter from Adams IT Services (http://www.usblcd.de/)
bwctusbBWCT USB device "bwctusb" (http://www.bwct.de/lcd.html)
lcd2usbTill Harbaum's LCD2USB (http://www.harbaum.org/till/lcd2usb/)
usbtinyDick Streefland's USBtiny (http://www.xs4all.nl/~dicks/avr/usbtiny/)
uss720Belkin USS-720 USB-to-IEEE 1284 Bridge (Belkin F5U002)
USB-4-allThe USB-4-all controller board from Sprut (http://www.sprut.de/electronic/pic/projekte/usb4all/usb4all.htm)
ftdi Display connected to a FTDI RS2232 (dual channel) or FTDI RS232 (single channel) USB chip
I2C connection types:
i2cLCD driven by PCF8574(A)/PCA9554(A) connected via I2C
piplateAdafruit RGB Positive 16x2 LCD+Keypad for Raspberry Pi
SPI (Serial Peripheral Interface):
spiDisplay using a KS0073 or similar in serial mode accessed via Linux SPI device
pifacecadPiFace Control and Display for Raspberry Pi
Other connection types:
ethlcdDisplay connected via TCP to PoE powered ethlcd device (http://manio.skyboo.net/ethlcd/)
raspberrypiLCD connected to the GPIO header of a Raspberry Pi
gpioLCD connected to GPIO lines (linux sysfs interface)


Tip

If you suspect the table above to be outdated, you might want to have a look at server/drivers/hd44780-drivers.h in LCDproc's source directory which contains the actual translation code.

Connections

Common connections for all connection types

No matter what connection type you choose, you will always need some connections. They are explained here.

Power

All variants use the same method of obtaining power. i.e., for each LCD:

Table 5.2. HD44780: Power Connections

LCDSignal
namepin
VEE1GND (connect to any of pins 18 - 25 of you parallel port)
VCC2+5V
VLC3(contrast adjustment)

Warning

Always double check your power connection, your display will probably not survive a reversely connected supply !

There are several ways to get 5V:

  • Connect to a 5V line intended for disk drives (the red wire is 5V, black is GND).

  • Get it from the VCC and GND pins of an USB connector. For the USB connection types this is done automatically, as the circuits used there automatically power the LCD.

  • Get it from a joystick port (pin 1 and 9 are 5V, 4, 5 and 12 are GND). It seems that some soundcards can use these lines for communication, so if you want to use this first check whether it really gives a 'clean' 5V.

  • If you don't have a backlight, you can sometimes get the needed mA's from the LPT port itself. Connect a few diodes from the data pins to a capacitor and you have the 5V. If it's strong enough is another question...

  • Get it from the keyboard connector. I do not recommend to use this with a backlight, as the keyboard connector is often protected with a fuse of 100mA or 200mA.

Figure 5.1. HD44780: Connecting the contrast adjusting pin (VLC)



     (variable resistor)
        .------.
 Vcc ---|  10k |--- GND
        `---^--'
           /|\
            |
           Vlc



Keypad

You can connect a keypad with most connection types. The maximum supported number of keys differs per type. There are several ways to connect the keys to the input pins.

Direct Keys

If you connect a key like sketched below, then you can only connect one key per input pin. It is a simple solution if you need only few keys.

Figure 5.2. HD44780: Direct Keys



      O 5V
      |
      |
      -
     | | 10k
     | |
      -
      |
      +-----------o input  (X)
      |
      |
      o
       \
      o
      |
      |
     === GND



By default, the following keystrokes are generated by the different keys:

Table 5.3. HD44780: Direct Key Mapping

key indexmapped string
X1A
X2B
X3C
X4D
X5E


You can change the mapping using the KeyDirect_NUM configuration option, where NUM is the subscript to the X in the table above.

Matrix Keys

Using a matrix, we can connect much more keys. To simplify the drawing here, we replace all switches with an @ symbol:

Figure 5.3. HD44780: Single Matrix Key



             X line
                |
                |
  Y line ---+---------
            |   |                    |
            o   |               =  --@--
             \  |                    |
            o   |
            |   |
            +---+
                |
                |



We connect the matrix of keys like this:

Figure 5.4. HD44780: Complete Key Matrix



Y1 o---|<---@--@--@
            |  |  |
Y2 o---|<---@--@--@
            |  |  |
Y3 o---|<---@--@--@
            |  |  |
Y4 o---|<---@--@--@            O 5V
            |  |  |            |
    diodes  |  |  |     ___    |
    1N4148  +----------|___|---+
            |  |  |     ___    |
            |  +-------|___|---+
            |  |  |     ___    |
            |  |  +----|___|---+     resistors 22k
            |  |  |
            o  o  o
            X1 X2 X3



As you can see, you need 1 resistor per X line, and 1 diode per Y line. By default, lcdproc will presume that you have a keypad with a layout like a telephone connected, with X and Y lines connected as show. To be more precise, it assumes this mapping:

Table 5.4. HD44780: Matrix Keypad Layout

 X1X2X3X4X5
Y1123AE
Y2456BF
Y3789CG
Y4*0#DH

This mapping can be changed using the KeyMatrix_X_Y configuration option, where X and Y are the subscripts to the respective axes above.

If you only need e.g. 10 keys, leave the rest away. You should modify and recompile the driver to get an other keypad layout.

You can buy arrays of keys that are connected like this in the electronics shop. They usually call it a matrix keypad. To hook it to lcdproc, you would only need to add the resistors and diodes.

If you want to use just one return line, for example with the serialLpt wiring, it looks (completely drawn) like this:

Figure 5.5. HD44780: One Return Line



                  O 5V
                  |
                 .-.
                 | | 4k7 or 22k
     diodes      | |
     1N4148      '-'
            ___   |
Y1 o---|<---o o---+
            ___   |
Y2 o---|<---o o---+
            ___   |
Y3 o---|<---o o---+
            ___   |
Y4 o---|<---o o---+----o return line



Tip

If the driver generates keypresses without that you actually press a key, it might be that the unconnected input lines are picking up electromagnetic waves from the air. In that case connect the unconnected input lines (pin 10, 11, 12, 13 and 15 of the LPT) to VCC = 5V.

Backlight

A small extension allows you to switch the backlight of the display on and off. At the moment only the 4bit and winamp connection types support this. The extension uses one output pin, you cannot use that pin for other functions anymore. The wiring looks like this:

Figure 5.6. HD44780: Backlight Wiring



                                             O 5V
                                      ___    |
                                 +---|___|---+
LPT Sub-D connector              |   4k7     |
                                 |           |e
                          ___    |       b |/
     BL pin o------------|___|---+---------|
                          1k               |\
                                       BC327 |c
                                             |        LCD connector
                                             |
                                             +--------o 15 backlight

                                             +--------o 16 GND backlight
                                             |
                                            === GND

Note: 4k7 means 4,7 kOhm.
The BC327 transistor has the following connections:

     _____
    |     |
    |BC327|
    |_____|
     | | |
     | | |
     | | |
     c b e



Caution

Sometimes the backlight connections are not on the 'main' connector, but on the side. If that is the case, there is usually NO RESISTOR present to limit the current through the LEDs. Therefore you should then add a resistor after the transistor of about 10 ohm (see display documentation).

Tip

If you want the backlight to light a bit while it is "switched off", you can add a resistor bypassing the transistor from e to c, with a value of, say 47ohm or 22ohm. (My 4x20 has an internal resistor of 6ohm, so with 47 ohm extra it lights at only 1/9th. I like this. Joris.)

4bit

This wiring is originally based on "lcdtext" (by Matthias Prinke).

Table 5.5. HD44780: 4bit Pinouts (1)

printer port<->LCD
namepinnamepin
  GNDVEE1
  +5VVCC2
  (contrast adjustment)VLC3
D46 RS4
  GNDRW5
D68 EN6
D02 D411
D13 D512
D24 D613
D35 D714

Note

The RW (pin 5) line of the display decides whether the display receives data from the LPT port, or whether it sends data to the LPT port: if grounded it receives, if High or connected to nothing at all it "sends" (i.e., will not work as intended). So, if you are not sure that you need it otherwise, then connect it to GND. This certainly applies if you have only one display.

Theoretically this wiring sends the data over twice as slow as the winamp or ext8bit wirings, because it only sends 4 bits at a time.

The 4bit connection type supports more than one display connected to the same parallel port. If you want to connect more than one display, then wire the all the displays to the parallel port according to the scheme above with the exception of the EN (pin 6) line of the LCDs.

For the second and further displays, you can find the wiring for the EN (pin 6) line in the table below.

Table 5.6. HD44780: 4bit Pinouts (2)

printer port<->LCD
namepinnamepin
D79 EN26 of 2nd display
D57 EN36 of 3rd display
STR1 EN46 of 4th display
LF14 EN56 of 5th display
INIT16 EN66 of 6th display
SEL17 EN76 of 7th display

The optional keypad can be connected as follows:

Table 5.7. HD44780: 4bit Keypad Pinouts

printer port<->keypadremarks
namepinpin
D02 Y1 
D13 Y2 
D24 Y3 
D35 Y4 
D46 Y5 
D57 Y6Only if not used for backlight or 3rd controller.
nSTRB1 Y7Only if not used for additional controllers.
nLF14 Y8
INIT16 Y9
nSEL17 Y10
nACK10 X1 
BUSY11 X2 
PAPEREND12 X3 
SELIN13 X4 
nFAULT15 X5 

The optional backlight wiring should be connected to D5, pin 7.

8bit "Winamp"

This type of connection should work with winamp.

Table 5.8. HD44780: "Winamp" wiring

printer port<->LCD
namepinnamepin
D02 D07
D13 D18
D24 D29
D35 D310
D46 D411
D57 D512
D68 D613
D79 D714
nSTRB1 EN6
nLF14 RW5 (EN3 6 - LCD 3) (optional (*) )
INIT16 RS4
nSEL17 EN2(6 - LCD 2) (optional)

(*) on the RW line of the display: this line decides whether the display receives data from the LPT port, or whether it sends data to the LPT port: if grounded it receives, if High or connected to nothing at all it "sends" (i.e., will not work as intended). So, if you are not sure that you need it otherwise, then connect it to GND. This certainly applies if you have only one display.

If you want the display to work with the Winamp plugin, wire nLF (pin 14) to RW of your LCD. You can then use the plugin in bidirectional mode (which is much faster). With 3 connected LCDs this is not possible. Note from Benjamin: I haven't tried using winamp while having the third LCD connected to this line.

The optional keypad can be connected as follows:

Table 5.9. HD44780: "Winamp" wiring - Keypad

printer port<->keypad
namepinpin
D02 Y1
D13 Y2
D24 Y3
D35 Y4
D46 Y5
D57 Y6
D68 Y7
D79 Y8
nACK10 X1
BUSY11 X2
PAPEREND12 X3
SELIN13 X4
nFAULT15 X5

The optional backlight wiring should be connected to nSEL, pin 17.

8bit "lcdtime"

This is originally based on "lcdtime" (by Benjamin Tse ) and allows you to combine the LCD with a LED bargraph. The LCD is driven by LCDproc and the LEDs by another program such as portato. Further details can be obtained from:

http://www.ibiblio.org/pub/linux/system/status/lcdtime-0.2.tar.gz
http://www.ibiblio.org/pub/linux/system/status/meter-0.2.tar.gz
http://www.ibiblio.org/pub/linux/system/status/portato-1.2.tar.gz

The LCD connections are:

Table 5.10. HD44780: "lcdtime" wiring

printer port<->LCD
namepinnamepin
D02 D07
D13 D18
D24 D29
D35 D310
D46 D411
D57 D512
D68 D613
D79 D714
nSEL17 - 
nSTRB1 RS4
nLF14 RW5 (optional - pull LCD RW low (*)
INIT16 EN6

(*) on the RW line of the display: this line decides whether the display receives data from the LPT port, or whether it sends data to the LPT port: if grounded it receives, if High or connected to nothing at all it "sends" (i.e., will not work as intended). So, if you are not sure that you need it otherwise, then connect it to GND.

See the lcdtime tar-ball (above) for full details of the bargraph connections.

The optional keypad can be connected as follows:

Table 5.11. HD44780: "lcdtime" wiring - keypad

printer port<->keypad
namepinpin
D02 Y1
D13 Y2
D24 Y3
D35 Y4
D46 Y5
D57 Y6
D68 Y7
D79 Y8
nSTRB1 Y9
nSEL17 Y10 (only if not used for backlight)
nACK10 X1
BUSY11 X2
PAPEREND12 X3
SELIN13 X4
nFAULT15 X5

The backlight wiring should be attached to nSEL, pin 17. Because the portato program (mentioned above) also uses this pin to control the bargraph, you cannot use the backlight control together with the bargraph.

8bit ("LCM-162" style)

This interface is pretty similar to the 8bit connection type except that the RS, RW and ENABLE signals are wired differently.

This device is usually found directly wired in the Nextgate NSA network appliances, so no soldering is necessary.

Serial LPT

This interface uses a handful of wires to interface to the HD44780. Suitable for high noise, long connections. Designed by Andrew McMeikan .

I (Joris) have extended this driver and the wiring a bit. It now supports keys again (it had earlier supported keys, but some time did not).

Further I have extended the driver and the wiring to be able to run using 2 instead of 3 output pins. That's even one less pin ! :)

Of course the use of fewer lines than the other wirings can not stay without drawbacks. In this case the simplicity of the long feeding wires is compensated by some intelligence in the decoding of the data. If you have no experience with the soldering iron, I do not recommend to build this wiring.

OK, so here is the wiring. First of the 'simple' 3 wires version. IC1 is the shift register, a 4094. Do not forget to connect the 5V to pin 16 and GND to pin 8 of the IC.

Figure 5.7. HD44780: Serial LPT wiring ('simple')



                                      IC1
                                   -----------
                                  |   4094    |
                            5V    | shift reg |                    display
                             O    |           |                            keys
                             |   1|           |4
                             +----|STR      Q0|--------------------o 11 D4   Y1
                             |    |           |5
           Data              |   2|         Q1|--------------------o 12 D5   Y2
   D3 5 o-------------------------|D          |6
                             |    |         Q2|--------------------o 13 D6   Y3
                             |   3|           |7
   D4 6 o-------------------------|CK       Q3|--------------------o 14 D7   Y4
                             |    |           |14
                             |  15|         Q4|--------------------o         Y5
                             +----|OE         |13
                                  |         Q5|--------------------o 4  RS   Y6
                                  |           |12
                                  |         Q6|--------------------o         Y7
                                  |           |11
                                  |         Q7|--------------------o         Y8
                                  |           |9
                                  |         QS|--               +--o 5  RW
                                  |         __|10               |
                                  |         QS|--              ===
                                  |           |
                                   -----------

   D2 4 o----------------------------------------------------------o 6 EN

   D7 9 o----------------------------------------------------------o 6 EN2
                                                                     (2nd LCD)


          5V  O-----+--------+-------------------------------+-----o 2 VCC
                    |        |                               |
                    |        |                               |
                    |100n    O 16                           .-.
                   ---      IC1                             | |<---o 3 Vlcd
                   ---       O 8                            | |10k
                    |        |                              '-'
   GND              |        |                               |
 18..25 o-----------+--------+-----------------------+-------+-----o 1 GND
                                                     |
                                                    === GND



The second possible wiring is with 2 output lines. This one is a bit more complex. If you do not understand the schematic, do not build it.

Figure 5.8. HD44780: Serial LPT wiring ('complex')



                                      IC2
                                   -----------
                                  |  74HCT164 |
                                  | shift reg |                    display
                                  |           |                            keys
           Data                  1|           |3
   D3 5 o---------------------+---|D        Q0|--------------------o 11 D4   Y1
                              |   |           |4
                              |  2|         Q1|--------------------o 12 D5   Y2
                              +---|D          |5
                                  |         Q2|--------------------o 13 D6   Y3
                                  |           |6
                                  |         Q3|--------------------o 14 D7   Y4
                                  |           |10
           Clock                 8|         Q4|--------------------o         Y5
   D4 6 o-------------------------|CK         |11
                                  |         Q5|--------------------o 4  RS   Y6
               ___       9|\ 8   9|_          |12
           +--|___|--+----| >o----|R        Q6|--------------------o         Y7
           |   22k   |    |/      |           |13
           |        ---   IC1     |         Q7|---+             +--o 5  RW
           |        ---           |           |   |     5V      |
           |         |100p         -----------    |     O      ===
           |         |                            |     |
           |        ===                           |    .-.
           |                                      |    | |22k
           +--------------------------------------+    | |
           |                                           '-'
           |   ___      11|\ 10                         |   5|\ 6
           +--|___|--+----| >o-------------------||-----+----| >o--o 6 EN
               22k   |    |/                    22p          |/
                    ---   IC1                                IC1
                    ---
                     |22p
                     |            IC1=74HCT14 (6x Schmitt trigger inverter)
                    ===


        5V  O--+-------+------+------+-----------------------+-----o 2 VCC
               |       |      |      | 13|\ 12               |
               |       |      |      +---| >o-               |
               |100n   O 14   O 14       |/                 .-.
              ---     IC1    IC2                            | |<---o 3 Vlcd
              ---      O 7    O 7       1|\ 2      3|\ 4    | |10k
               |       |      |       +--| >o-   +--| >o-   '-'
   GND         |       |      |       |  |/      |  |/       |
 18..25 o------+-------+------+-------+----------+-----+-----+-----o 1 GND
                                                       |
                                                      === GND



Serial LPT Keypad

Note

To understand this part of the serialLpt documentation, you also need to read the keypad section in this document.

serialLpt wiring supports a keypad. The 3 wires version supports 8 keys, or if you use multiple return lines up to 8 x 5 = 40 lines. The 2 wires version supports 7 keys, or with multiple return lines 7 x 5 = 35 keys.

Table 5.12. HD44780: Serial LPT - Keypad return lines

printer port<->keypad
namepinpin
nACK10 X1
BUSY11 X2
PAPEREND12 X3
SELIN13 X4
nFAULT15 X5

On lines longer than, say a meter, you should buffer the return line(s). If you only have 1 return line, you can buffer it with two remaining buffers from the 74HCT14:

Figure 5.9. HD44780: Serial LPT - Keypad return lines buffered



               1|\ 2    13|\ 12   ___
   keypad o-----| >o------| >o---|___|---+---o input pin on LPT port
   return       |/        |/      220E   |
                IC1       IC1           ---
                                        --- 1nF
                                         |
                                        ===



Serial LPT Backlight

Also a backlight is supported. You will also need a port from the 74HCT14 for that. The BL output below should be connected to the BL input in the backlight section

Figure 5.10. HD44780: Serial LPT - Backlight extra circuit



                 ___       3|\ 4
     Data o-----|___|--+----| >o----o BL output
   LPT-D3       470k   |    |/
                      ---   IC1
                      ---
                       |100nF
                       |
                      ===



spi

This connection type drives a LCD in serial mode (supported on Hitachi HD66712, Samsung KS0073 and KS0074 (and clones) controllers) connected to some Linux SPI device.

This connection type is currently only supported on Linux. It is strongly recommended to use a SPI implementation with hardware support, e.g. on the Raspberry Pi.

As the SPI communication to the display cannot drive a backlight switch, this connection type features a BacklightDevice option that can use a GPIO pin exposed via sysfs (see eLinux GPIO).

FTDI FT2232D USB chip "ftdi"

You can use a FTDI FT2232D dual channel USB <-> parallel FIFO chip to connect a display via the USB bus. The chip is switched to bitbang mode and drives both channels as outputs to control the display in 8bit mode.

Table 5.13. HD44780: 8bit FTDI

FTDI chip<->LCD
namepinnamepin
ADBUS024 D07
ADBUS123 D18
ADBUS222 D29
ADBUS321 D310
ADBUS420 D411
ADBUS519 D512
ADBUS618 D613
ADBUS717 D714
BDBUS040 RS4
BDBUS139 RW5
BDBUS238 EN6
BDBUS337 BLBacklight (optional)

You can configure the USB vendor/product ID in LCDd.conf. The wiring of the control lines can optionally be reconfigured, please look at the driver source if you really need that.

Note

The backlight line is driven high when the backlight is on. Therefore the standard backlight circuit (Figure 5.6, “HD44780: Backlight Wiring”) will not work. Use the following instead.

Figure 5.11. hd44780/ftdi: Backlight Wiring


                                             O 5V
                                             |
                                             +--------o 15 backlight

                                             +--------o 16 GND backlight
                                             |
                           small resistor   .-.
                           10 - 47 ohm      | |
                           depending on     | |
                           display          '-'
                                             |
                                             |c
                          ___            b |/
     BL pin o------------|___|-------------|
                          4k7              |\
                                       BC547 |e
                                             |
                                            === GND


Alternatively you can use a single channel FTDI FT245BM USB <-> parallel FIFO chip and use the display in its 4 bit mode.

Table 5.14. HD44780: 4bit FTDI

FTDI chip<->LCD
namepinnamepin
D025 D411
D124 D512
D223 D613
D322 D714
D421 EN6
D520 RS4
D619 RW5
D718 BLBacklight (optional)

The following special configuration settings are required to use a single channel FTDI FIFO chip:

Example 5.1. HD44780: Configuration for FTDI 4bit


[hd44780]
ConnectionType=ftdi
ftdi_mode=4
ftdi_line_EN=0x10
ftdi_line_RS=0x20
ftdi_line_RW=0x40
ftdi_line_backlight=0x80


LIS2 USB device "lis2"

LIS2 from VLSystem (http://www.vlsys.co.kr) is a full featured USB VFD module with four channel fan controls. This device can be accessed as a serial device with the help of the kernel module ftdi_sio.ko that maps the USB port to a serial port (e.g. /dev/ttyUSBx).

MPlay Blast USB device "mplay"

MPlay Blast from VLSystem (http://www.vlsys.co.kr) is a full featured USB VFD module with two channel fan controls and two channel temperature sensors. This device can be accessed as a serial device with the help of the kernel module ftdi_sio.ko that maps the USB port to a serial port (e.g. /dev/ttyUSBx).

LCD on Serial panel device "los-panel"

The LoS-Panel is a DIY device built using an Atmel ATtiny2313 and supports the following features:

  • Drives displays with one controller.

  • Switchable backlight.

  • One 4x4 matrix keypad and 4 direct keys.

Note

The direct keys are reported as a fifth column of a matrix keypad to LCDd.

Column and rows are reported reverse (column 1 / row 1 is in the lower right corner) to LCDd which expects (1/1) to be the upper left corner. You have to take this into account when configuring keys.

See http://mlf.home.xs4all.nl/los/ for more information on this device.

VDR LCD serial device "vdr-lcd"

… to be documented …

Please address Matteo Pillon for further information.

VDR-Wakeup module "vdr-wakeup"

The VDR-Wake module by Frank Jepsen is a serial IO extension module for the famous Linux-based VDR that allows to connect an LCD to it and supports LCDproc.

See http://www.jepsennet.de/vdr/ (German) for more information on VDR-Wakeup.

EZIO-100 and EZIO-300 by Portwell

Portwell EZIO-100 and EZIO-300 are 20x2 HD44780-compatible devices featuring a serial port interface to the host on "COM2", and a 4-key keypad. These devices are typically found in firewall appliances by Portwell, Caswell, Check Point and others.

The backlight is always on. The serial port is operating at 2400 bps (2400-N-8-1), which the driver defaults to with this connection type. The keypad keys map to the default KeyMatrix_4_x settings in the [HD44780] section of LCDd.conf.

See http://drivers.portwell.com/CA_Manual/EZIO/EZIO-FINAL.PDF for the EZIO-100 technical document. See http://drivers.portwell.com/CA_Manual/EZIO/EZIO-300.pdf for the EZIO-300 technical document.

Pertelian X2040 "pertelian"

The Pertelian X2040 includes an HD44780 display with enclosure and USB connection. In order to work with LCDproc in Linux you need the usbserial.ko and ftdi_sio.ko kernel modules loaded. The display will then be available on a serial port /dev/ttyUSBx.

See the X4020 product page for more information.

PIC-an-LCD serial device "picanlcd"

The PIC-an-LCD module is also supported. It is not connected to the LPT port but to a serial port, which saves you from a lot of potential problems. To use it, specify the device to which you have connected the module in the config file with the Device setting. The default is /dev/lcd. It does not support a keypad nor backlight switching.

Note

As of 2012 these devices are not sold anymore. Search the Internet Archive for a copy of http://dalewheat.com/pdf/PIC-an-LCD.pdf if you need the manual.

LCD serializer device "lcdserializer"

LCD serializer connection is technically the same as PIC-an-LCD with the same advantages, it uses the serial port making things really simple. Unlike PIC-an-LCD LCD serializer is not a commercial product. it's just a project found digging on the net and freely available. You have all the tools and the code to build it yourself and to customize the behaviour of the device.

What you need

  • Some electronic knowledge and familiarity with the soldering iron

  • A PIC16F84 (I used PIC16F84A) or PIC16C54

  • JDM PIC programmer

  • gputils and picprog installed on your GNU/Linux box

Burning the PIC

First, you need to download the ASM source for your PIC and then make the hex:

$ gpasm lcd16f84_custom.asm

Now the binary is ready to be flashed to the PIC. Connect the programmer with the PIC installed and issue the following command to see it burning ;-):

$ picprog --erase --burn --input lcd16f84.hex --pic /dev/ttyS0
Running lcdproc

It's time to build the operating circuit, remember this driver uses a baud rate of 9600, so JP2 need to be closed.

Now power on the board. You should see OK on the LCD screen. Otherwise double-check all the connections.

Change LCDd.conf to include the following statements in the [hd44780] section:

ConnectionType=lcdserializer
Device=/dev/ttyS0

Finally, start the daemon and relax watching lcdproc running.

BWCT USB LCD module "bwctusb"

The BWCT USB LCD module, sold by Bernd Walter Computing Technology (http://www.bwct.de/lcd.html) is a little board that can be piggy-packed to a HD44780 display and connects that to USB.

The board, driven by the bwctusb connection type, does neither support a keypad for input, nor more than one single-controller display, nor does it allow setting the backlight or brightness. But you can set the display's contrast using software (see the Contrast configuration parameter).

Special configuration options

If there is more than one BWCT USB module connected to the system, the SerialNumber configuration parameter allows selecting which display is used in LCDd.

Till Harbaum's "lcd2usb"

LCD2USB is a cheap but powerful do-it-yourself interface to connect HD44780 based displays via USB, consisting of easily available parts only. The device supports software adjustable contrast and backlight as well as dual controller displays (required for 4*27 and 4*40).

It is based upon an Atmel AVR Mega8 CPU with a pure software implementation of the USB protocol for the Atmel AVR microcontroller series.

The whole interface incl. the hardware layout is under a GPL like license. This means that you can take these schematics and use it as a basis for your own interface e.g. for a graphic LCD.

Two keys can be connected to the LCD2USB interface board. They can generate three key events that can be mapped to key names using the DirectKey_1 to DirectKey_3 commands: one for each key and the third if the keys are pressed simultaneously. With this 3-key setup, menus can be used (see example below).

This driver supports the original LCD2USB interface board as described above as well as compatible devices like those sold by Lcdmod Kit or those developed by Malte Pöggel.

Special configuration options

Besides the standard configuration options for hd44780 displays, the lcd2usb connection type supports three additional options: Contrast to set the display's contrast, Brightness to set the display's brightness when the backlight is switched on and OffBrightness to set the display's brightness when is backlight is switched off. All three options expect a number in the range from 0 to 1000.

Example 5.2. HD44780: Configuration for LCD2USB


[menu]
MenuKey=Escape
EnterKey=Enter
DownKey=Down

[hd44780]
ConnectionType=lcd2usb
Contrast=850
Brightness=800
OffBrightness=0
Keypad=yes
Backlight=yes
Size=20x2
KeyDirect_1=Enter
KeyDirect_2=Down
KeyDirect_3=Escape


Tip

In order to make the lcd2usb connection type work with a 2-controller display you may need to set the vSpan config option accordingly.

Dick Streefland's "USBtiny"

USBtiny is a software implementation of the USB low-speed protocol for the Atmel ATtiny microcontrollers. It is also the name of a 'reference circuit' using the ATtiny2313.

The reference circuit features an IR receiver for remote controls and a LCD. Due to hardware limitations of the ATtiny2313 the LCD does not have switchable backlight, adjustable contrast, any keys, nor does it support displays with more than one controller. If you want these features and do not require the IR receiver we recommend to take a look at the LCD2USB device.

Note

LCDproc does not make use of the IR receiver. 3rd party software is required to make it do anything, e.g. LIRC.

USS-720 USB-to-IEEE 1284 Bridge (Belkin F5U002) "uss720"

The USS-720 USB-to-IEEE 1284 Bridge is a fully featured USB to parallel chip that is used in most (but not all) Belkin F5U002 USB Parallel Printer Adapters. Because these adapters are inexpensive and readily available on the second-hand market, they provide an excellent solution for users who want to experiment with a parallel port but only have USB ports on their computers.

Because the chip acts as a parallel port, the driver maintains the same features and wiring as the 8-bit "winamp" driver. However, because most USB Parallel Printer Adapters use a centronics printer connector, be sure to convert the pin numbering of the parallel port pins in the "winamp" wiring to the pin numbering of the centronics port. Many tables are available on the internet that illustrate how the pin numbering differs between the two.

Special configuration options

Because several manufacturers used the USS720 chip in their USB Parallel Printer Adapters, the VendorID and ProductID options are configurable in the LCDd.conf file.

Note

Not all Belkin F5U002 USB Parallel Printer Adapters used the USS720 chip. Look for the dark grey adapters with the removable USB cable for best results.

I2C with Port-Expander

If you have an I2C port available that is supported by your kernel (through /dev/i2c*), you can add a I2C port expander there (PCF8574P in this example).

Figure 5.12. HD44780: PCF8574P port expander on I2C bus


                                       IC1
                                   -----------
                                  | PCF8574P  |
                                  | I2C-Port- |                            HD44780
                                  | Expander  |                            display
                                  |           |4
                                  |         P0|----------------------------o 11 D4
                                  |           |5
           I2C-Bus              14|         P1|----------------------------o 12 D5
    SCL o-------------------------|SCL        |6
                                  |         P2|----------------------------o 13 D6
                                15|           |7
    SDA o-------------------------|SDA      P3|----------------------------o 14 D7
                                  |           |9
                                  |1        P4|----------------------------o 4  RS
           Set I2C-Address  +-----|A0         |10
           here:            |     |2        P5|----------------------------o 5  RW
           GND: Bit:=0      +-----|A1         |11
           VCC: Bit:=1      |     |3        P6|----------------------------o 6  EN
                            +-----|A1         |                      ___
           Here: 0x00       |     |           |                 +---|___|--o 15 backlight
                           ===    |           |                 |c   10R
                                  |           |12    ___       b|/
                                  |13       P7|-----|___|-----|
                                 -|INT        |      1k       |\
                                  |           |           bc557 |e
                                   -----------                  |
                                                                |
    +5V o-----------+------------------+---------------------+--+----------o 2  VCC
                    |                  |                     |
                    |                  |                     |
                    |10uF              O 16                 .-.
                   ---                IC1                   | |<-----------o 3  Vlcd
                   ---                 O 8                  | |10k
                    |                  |                    '-'
                    |                  |                     |
    GND o-----------+-------+----------+---------------------+-------+-----o 1  GND
                            |                                        |
                           === GND                                   +-----o 16 GND Backlight


Configuration

Example 5.3. HD44780: Configuration for I2C with port expander


[HD44780]
ConnectionType=i2c
Device=/dev/i2c-0
Port=0x20
Backlight=yes
Size=40x2
DelayBus=false
DelayMult=1
Keypad=no
#i2c_line_RS=0x10
#i2c_line_RW=0x20
#i2c_line_EN=0x40
#i2c_line_BL=0x80
#i2c_line_D4=0x01
#i2c_line_D5=0x02
#i2c_line_D6=0x04
#i2c_line_D7=0x08
# BacklightInvert=yes
# The Backlight Invert is used if a 0 turns the backlight on, and 1 turns it off, i.e. npn transistor


If your port expander has different wiring you can re-assign the pins in the config file

Example 5.4. HD44780: Configuration for I2C with port expander Alternative Wiring


-   PCF8574AP: P0 P1 P2 P3 P4 P5 P6 P7
-              |  |  |  |  |  |  |  |
-   HD44780:   RS RW EN BL D4 D5 D6 D7


Example 5.5. HD44780: Configuration for I2C with port expander alternative config


[HD44780]
ConnectionType=i2c
Device=/dev/i2c-0
Port=0x20
Size=40x2
DelayBus=false
DelayMult=1
Keypad=no
i2c_line_RS=0x01
i2c_line_RW=0x02
i2c_line_EN=0x04
i2c_line_BL=0x08
i2c_line_D4=0x10
i2c_line_D5=0x20
i2c_line_D6=0x40
i2c_line_D7=0x80
Backlight=yes
BacklightInvert=yes
#The Backlight Invert is used if a 0 turns the backlight on, and 1 turns it off,
i.e. PNP transistor


The Device configuration setting denotes the device file of your I2C bus (here /dev/i2c-0). You have to load the kernel standard module i2c-dev.ko and the bus driver, but no I2C chip modules (e.g. pcf8574.ko)!

The Port config option contains the I2C address of the I2C port expander (here 0x20, the PCF8574 from the example above, with all address bits set to 0). Bit 8 of the address (normally 0 in I2C addresses) has a special meaning: It tells the driver to treat the device as PCA9554 or similar, a device that needs a 2-byte command, and it will be stripped off the address.

Table 5.15. HD44780: Examples of I2C port expander addresses

Port valueMeaning
0x200x27PCF8574 with A[012]=07
0x380x3fPCF8574A with A[012]=07
0xa00xa7PCA9554 with A[012]=07
0xa00xa7PCA9554A with A[012]=07

ethlcd Device

The ethlcd (http://manio.skyboo.net/ethlcd/) device is simply an LCD display driven by an ATmega microcontroller, controlled and powered by "home-made" Power over Ethernet. The hardware and software are open source.

Features

  • ethernet connection using ENC28J60 ethernet controller

  • Power over Ethernet (data and power using single UTP cable)

  • Atmel's ATmega168 microcontroller

  • 6 buttons (MENU, UP, DOWN, LEFT, RIGHT, ENTER)

  • backlight control in three states: ON, Night-Mode (partialy ON) and OFF

  • beeper

  • device act as a TCP server - LCDproc driver is connecting to device just by creating a TCP socket - no need to PC-side additional hardware besides NIC

Figure 5.13. HD44780: ethlcd - block diagram



   _____________________________________________________
  |                    buttons                          |
  |                       ^                             |
  |                       |                             |
  |  _________       ___________         ____________   |
  | |         |     |           |       |            |  |
  | |         |     |           |       |            |  |
  | |   LCD   |     |           |  SPI  |  ENC28J60  |  |  UTP cable
  | | HD44780 |<--- | ATmega168 | <---> |  ethernet  |<========+------> PC running
  | |         |     |           |       | controller |  |      |         LCDproc
  | |         |     |           |       |            |  |      |
  | |_________|     |___________|       |____________|  |      |
  |                       |                             |      |
  |                       |                             |      |
  |                     beeper                          |      |
  |_____________________________________________________|      |
   ethlcd                                                  AC Adapter



The device is "visible" to LCDproc just like any other HD44780 device. The difference is the wiring - instead of connecting the display directly to PC (via serial/parallel/usb port), it is connected via ethernet and the communication is done over TCP connection. The main feature is - that to power and control the LCD is needed single UTP cable. To use the driver, specify the device IP address or hostname, on which the ethlcd device is accessible by setting in config file the Device value. The default is ethlcd.

USBLCD adapter

The USBLCD adapter from Adams IT Services (http://www.usblcd.de/) is a small interface board which allows you to connect an alphanumerical display module based on the HD44780 or compatible controller to the USB. The display will be powered by the USB. It features a switchable backlight (on or off) and can be used with 16x2, 16x4 or 20x4 displays.

The usblcd connection type communicates with a kernel driver by using a device file /dev/usb/lcdx. The kernel driver providing this device currently only exists for Linux kernels newer than 2.4.20-pre7.

Note

As of 2007 these device are not sold anymore. This driver has been ported from lcdproc 0.4.5 to support existing users.

USB-4-all controller

The USB-4-all controller board from Sprut (http://www.sprut.de/electronic/pic/projekte/usb4all/usb4all.htm) is a small interface board which allows you to connect different hardware to the USB. The subdriver for LCDproc supports dual HD44780 displays and a 4x4 keypad as well as software adjustable contrast and brightness (backlight).

Table 5.16. HD44780: USB-4-all - Display connection

USB-4-allLCD1LCD2
namepinnamename
RB728D7D7
RB627D6D6
RB526D5D5
RB425D4D4
RB324R/WR/W
RB223RSRS
RB021EN
RC011 EN

Table 5.17. HD44780: USB-4-all - Keypad connection

USB-4-allkeypad
namepinname
RA02X1
RA13X2
RA24X3
RA35X4
RA46Y1
RA57Y2
RC617Y3
RC718Y4

Table 5.18. HD44780: USB-4-all - Brightness and contrast connection

USB-4-allDesc
namepin
RC112brightness
RC213contrast

Figure 5.14. HD44780: USB-4-all brightness control


                          o 5V (PIC Pin 20)
                          |
                          |e
               ___    b |/
   RC1 o------|___|-----|    pnp
               10k      |\
                          |c
                          |
                          -
                         | | 10R
                         | |
                          -
                          |
                          +---> LCD 15 (+ Backlight)

                          +---> LCD 16 (- Backlight)
                          |
                         === GND


Figure 5.15. HD44780: USB-4-all contrast control


                           o 5V (PIC Pin 20)
                           |
                           -
                          | |4,7k
                          | |
                           -
                           |     ____
                           +----|____|-----+----> LCD 3 (Contrast)
                           |c    680R      |
               ___     b |/                |+
   RC2 o------|___|------|  npn           --- 10uF
               22k       |\               ---
                           |e              |
                           |               |
                           |               |
                          ===             === GND


Raspberry Pi

Warning

This sub-driver is obsolete and probably won't get bug and security fixes. Use the gpio connection type instead.

This connection type supports a LCD connected to the GPIO header P1 on a Raspberry Pi. Displays with one or two controllers are supported.

It supports a switchable backlight connected to pin P1-11 by default. Use the switch circuit as described in Figure 5.11, “hd44780/ftdi: Backlight Wiring”.

Warning

The signal level on the GPIO pins is 3.3 V and they are said not to be 5 V tolerant. Therefore the R/W pin of the display must be wired to GND to prevent 5V logic appearing on the GPIO pins. For the same reason the backlight cicuit from Figure 5.6, “HD44780: Backlight Wiring” must not be used.

Powering a LCD that uses 5 V from pin P1-02 will work. Powering a LCD from 3.3 V (pin P1-01) will only work if it is designed for 3.3 V operation.

Table 5.19. HD44780: Default pin mapping for Raspberry Pi

Connector<->LCD
Pin NamePin NumberNamePin
GPIO18P1-12 D714
GPIO23P1-16 D613
GPIO24P1-18 D512
GPIO25P1-22 D411
GPIO08P1-24 EN6
GPIO07P1-26 RS4
GNDP1-06 RW5
GPIO22P1-15 EN2Second controller (optional)
GPIO17P1-11 BLBacklight (optional)

GPIO07 and GPIO08 used for RS and EN signal are also used by the SPI bus. If you loaded the SPI driver you will need to assign them to a different GPIO, e.g. GPIO04 and GPIO22.

When using a display with two controllers the vspan option has to be configured as well (e.g. vspan=2,2 for a 40x4 display).

Special Raspberry Pi configuration options

This connection driver can be configured to use other pins than the one described in the table above. Using the pin_<LCD pin name> configuration option, any LCD pin can be assigned to any GPIO pin.

Important

The values for the pin_<LCD pin name> configuration option are the number part from the GPIO signal name, not the pin number from the header connector! To find out which signal is routed to which connector pin refer to the RPi Low-level peripherals description.

The connection driver contains a check for possible signal names. You will receive an error message if you try to assign a pin to a signal that is not available on connector P1 or P5.

Example 5.6. HD44780: Alternate configuration for Raspberry Pi GPIO pins


[hd44780]
ConnectionType=raspberrypi
Backlight=yes
Size=16x2

pin_D4=25
pin_D5=24
pin_D6=23
pin_D7=18
pin_EN=8
pin_RS=7
pin_BL=17



Adafruit Pi Plate

Warning

This sub-driver is obsolete and probably won't get bug and security fixes. Use the gpio connection type together with the gpio-mcp23s08 kernel module.

The Adafruit RGB Positive 16x2 LCD+Keypad for Raspberry Pi (aka Pi Plate, see (http://www.adafruit.com/products/1109)) combines a 16x2 Character LCD, up to 3 backlight pins AND 5 keypad pins using only the two I2C pins on the Rasperry Pi.

Note that this connection type drives all RGB pins of the backlight at the same time, resulting in a white backlight. You will need to modify the source code if you want to have some other color.

Example 5.7. HD44780: Configuration example for Pi Plate connection type


[hd44780]
ConnectionType=piplate
Device=/dev/i2c-1
Port=0x20
Size=16x2
Backlight=yes

Keypad=yes
KeyDirect_1=Enter
KeyDirect_2=Up
KeyDirect_3=Down
KeyDirect_4=Left
KeyDirect_5=Right


PiFace Control and Display

Warning

This sub-driver is obsolete and probably won't get bug and security fixes. Use the gpio connection type together with the gpio-mcp23s08 kernel module.

The PiFace Control and Display for Raspberry Pi from OpenLX SP Ltd combines a 16x2 Character LCD and navigation buttons using the SPI bus on the Rasperry Pi.

Note

The PiFace Control and Display features a IR receiver, which LCDproc does not make use of. You have to setup and use LIRC for that. See Setting up PiFace Control And Display to use a remote.

Example 5.8. HD44780: Configuration example for PiFace Control and Display connection type


[hd44780]
ConnectionType=pifacecad
Device=/dev/spidev0.1
Size=16x2
Backlight=yes

Keypad=yes
KeyMatrix_1_1=Left
KeyMatrix_1_2=Down
KeyMatrix_1_3=Up
KeyMatrix_1_4=Right
KeyMatrix_1_5=Escape
KeyMatrix_1_6=Enter
KeyMatrix_1_7=Left
KeyMatrix_1_8=Right


GPIO

This connection type supports an LCD connected to GPIO lines that can be controlled via the linux sysfs interface. This is common for System-On-Chip (SOC) processors and i2c port expanders. Currently it supports displays with one or two controllers.

A GPIO pin can be configured for backlight switch. Use the switch circuit as described in Figure 5.11, “hd44780/ftdi: Backlight Wiring”.

Warning

The configuration option for R/W pin of the display is optional. If the pin is configured, it is always held in low state since the driver always performs write operations and keeps the direction of data pins as output. This is what you need for i2c port expanders. If you omit configuration of R/W pin (maybe you are manually wiring the display to a SoC), the R/W pin must be wired to GND. This is also necessary to prevent 5V logic appearing on I/O pins which are not 5V tolerant.

Note

The driver exports the configured GPIOs to sysfs automatically, before using them. At exit it tries to unexport them again, but this only succeeds if the daemon is still running with root permissions. If the daemon was configured to drop root privileges after initialization, the GPIOs will remain accessible from sysfs and unloading the respective kernel module will fail.

Table 5.20. HD44780: Example pin mapping for Beaglebone Black

Connector<->LCD
Pin NameGPIO NumberNamePin
P8_3680 D714
P8_3481 D613
P8_4077 D512
P8_3976 D411
P8_2661 EN6
P8_1865 RS4
GND  RW5
P8_1426 EN2Second controller (optional)
P8_1547 BLBacklight (optional)

Special GPIO configuration options

The GPIO connection driver can be configured to assign any LCD pin to any GPIO pin using the pin_<LCD pin name> configuration option.

When using a display with two controllers the vspan option has to be configured as well (e.g. vspan=2,2 for a 40x4 display).

Example 5.9. HD44780: Example configuration for Beaglebone Black GPIO pins


[hd44780]
ConnectionType=gpio
Backlight=yes
Size=16x2

pin_D4=76
pin_D5=77
pin_D6=81
pin_D7=80
pin_EN=61
pin_RS=65
pin_BL=47



Compiling

Make sure that the HD44780 files are built when you run ./configure. This can be done by specifying --enable-drivers=all or by including hd44780 in the list of enabled drivers (e.g. --enable-drivers=hd44780).

Configuration in LCDd.conf

[hd44780]

Port = PORT

For parallel connections, specify the address of the parallel port the LCD is connected to. Common values for PORT are 0x278, 0x378 and 0x3BC. If not given, the default is 0x378.

For I2C connection types this sets the slave address.

Device = DEVICE

If you are using a serial or I2C connection, you need to set this parameter to the device your LCD is connected to. For example, if the display is connected to the first serial port, you have to set it to /dev/ttyS0. The default value is /dev/lcd.

ConnectionType = { 4bit | 8bit | serialLpt | winamp | lcm162 | picanlcd | lcdserializer | los-panel | vdr-lcd | vdr-wakeup | pertelian | lis2 | mplay | usblcd | bwctusb | lcd2usb | usbtiny | uss720 | usb4all | ftdi | i2c | piplate | spi | pifacecad | ethlcd | raspberrypi | gpio | ezio }

Select the type of the wiring / display connection. See also (Table 5.1, “HD44780: Connection Types”).

Model = { standard | extended | winstar_oled | pt6314_vfd }

Some devices (ie. WINSTAR WEH001602A OLED or PTC PT6314 VFD) require additional initialization or configuration incompatible with "classic" LCD or just have extra features, such as internal commands for brightness handling. If you have such display setting this option may help in problems with initialization or adds extra functionality.

  • The default, standard or default, is for "classic" HD44780 displays.

  • extended, hd66712 or ks0073 is for displays which have "extended mode" turned on with special instruction. If you have a Samsung KS0073, PowerTip Corp. PC2004LRU, other based on HD66710/HD66712 chip or an other 'almost HD44780-compatible', set Model to this value to get into extended, 4-line linear addressing mode.

    Use this instead of deprecated option ExtendedMode.

  • winstar_oled or weh00xxyya is for WINSTAR WEH00xxyyA OLED displays and allows performing proper initialization of display device, especially after display reset without powering it off.

    It also allows handling backlight setting using internal commands for such displays.

  • pt6314_vfd is for some Princeton Technology Corp.'s PT6314 VFDs and allows handling brightness of display.

You only may need to set this parameter if you have a non-standard HD44780 display such as specified above and have problems with it and/or want reveal extra functionality with these displays.

This option should be independent of connection type.

Speed = BITRATE

For a serial connection, set to the serial port bitrate. To use the default value for the chosen interface, just set to 0.

CharMap = { hd44780_default | hd44780_euro | ea_ks0073 | sed12780f_0b | hd44780_koi8_r | hd44780_cp1251 | hd44780_8859_5 | upd16314 | weh001602a_1 | none }

Set the character mapping depending on the display you have:

  • The default, hd44780_default, is for "classic" HD44780 displays.

  • hd44780_euro is for displays with a ROM mask supporting the european charset (ROM code A02).

  • ea_ks0073 is the charmap for Electronic Assembly's KS0073 based displays. These devices have a richer charset, including many icons and many more characters of the ISO-8859-1 than standard HD44780s.

  • sed12780f_0b is for some SED 1278 displays.

  • The none charmap does not translate any characters. It displays the characters the display controllers actually has stored in its CGROM for that position instead. This setting is intended for debugging purpose.

You only need to set this parameter if you have a non-standard HD44780 display or charmap.

If LCDproc was configured with '--enable-extra-charmaps' option the following character mappings are available, too:

  • hd44780_koi8_r maps input from a client in Russian KOI8-R to displays with a ROM mask supporting the european charset (ROM code A02).

  • hd44780_cp1251 maps input from a client in Russian CP1251 (Windows-1251) to displays with a ROM mask supporting the european charset (ROM code A02).

  • hd44780_8859_5 maps input from a client in Russian ISO 8859-5 to displays with a ROM mask supporting the european charset (ROM code A02).

  • upd16314 is for displays with a Nec uPD16314 vacuum fluorescent display (VFD) controller with ROM code 002 character set. If your display has ROM code 001 character set you may use the hd44780_euro charmap instead.

  • weh001602a_1 is for displays such as the WINSTAR WEH001602A OLED display with bank font 1 (Western Europe I) selected. Clients should use ISO 8859-1. See FontBank to select the font bank.

Tip

See server/drivers/hd44780-charset.h in LCDproc's source directory for the actual mappings.

FontBank = { 0 | 1 | 2 | 3 }

For some displays such as the WINSTAR WEH001602A, set the font bank to be used.

  • 0 (default) is the English/Japanese font bank.

  • 1 is the Western Europe I font bank. You can use the following CharMap with this font bank: weh001602a_1.

  • 2 is the English/Rusian font bank.

  • 3 is the Western Europe II font bank.

You only need to set this parameter if you have a HD44780 display such as the WINSTAR WEH001602A, which allows selecting the font bank during initialization. Additionally you may need to set correct CharMap.

Note

Setting this to nonzero value on standard HD44780 is usually harmless, but some non-standard displays may use bits used for FontBank selection, so it is safer to leave this option at default value for displays not supporting Font bank.

Keypad = { yes | no }

Tell whether you have a keypad connected. You may also need to configure the keypad layout further on in this file.

Brightness = BRIGHTNESS

Set the initial brightness when the backlight is on for the lcd2usb connection type. Legal values are 0 - 1000, with 800 being the default.

OffBrightness = BRIGHTNESS

Set the initial off-brightness, i.e. the brightness when the backlight is off, for the lcd2usb connection type. The legal range is 0 - 1000. If not given, it defaults to 300.

Contrast = CONTRAST

Set the initial contrast for the bwctusb and lcd2usb connection types. Legal values for CONTRAST are 0 - 1000. If not given, it defaults to 500 which may be too low or too high for the selected connection type. So, if the screen is blank or dark, please try playing with the contrast a bit.

Backlight = { none | external | internal | internalCmds }

Specify if you have a switchable backlight and if yes, can select method for turning it on/off:

  • none - no switchable backlight is available. For compability also boolean 0, n, no, off and false are aliases.

  • external - use external pin or any other method defined with ConnectionType backlight handling. For backward compability also this value is chosen for boolean TRUE values: 1, y, yes, on and true.

  • internal means that backlight is handled using internal commands according to selected display model (with Model option). Depending on model, Brightness and OffBrightness options can be taken into account.

  • internalCmds means that commands for turning on and off backlight are given with extra options BacklightOnCmd and BacklightOffCmd, which would be treated as catch up (last resort) for other types of displays which have similar features.

You can provide multiple occurences of this option to use more than one method. This can be useful for example for glowing buttons with external pin when backlight is on and using internal command to set high brightness of display.

Default is model specific (depends on Model option): Winstar OLED and PT6314 VFD enables internal backlight mode, for others it is set to none.

BacklightCmdOn = COMMAND(s)

Commands for enabling internal backlight for use with Backlight=internalCmds. Up to 4 bytes can be encoded, as integer number (hex) in big-endian order. Ignored if Backlight does not specify internalCmds, required otherwise.

Note

This is advanced option, if command contains bits other than only brighness handling, they must be set accordingly to not disrupt display state. If for example 'FUNCTION SET' command is used for this purpose, bits of interface length (4-bit / 8-bit) must be set according to selected ConnectionType.

BacklightCmdOff = COMMAND(s)

Commands for disabling internal backlight for use with Backlight=internalCmds. Up to 4 bytes can be encoded, as integer number (hex) in big-endian order. Ignored if Backlight does not specify internalCmds, required otherwise. See above note about BacklightCmdOn.

OutputPort = { yes | no }

Tell if you have the additional output port ("bargraph") and you want to be able to control it with the lcdproc OUTPUT command.

Lastline = { yes | no }

Specifies whether the lowest pixel line of a character is pixel addressable or if it controls an underline effect. The default is yes, meaning a pixel addressable last pixel line.

Size = WIDTH x HEIGHT

Specifies the size of the LCD. Default: 20x4 In case of multiple combined displays, this should be the total size.

vSpan = HEIGHT ,

The "vertical span" when using the driver with multi-controller displays or with multiple displays that are treated as a single virtual display. It is a comma separated list of the heights of each display. In multi-controller displays it lists the number of lines each controller is responsible for.

E.g. vSpan=2,2,1 means you have three physical displays, the first two having two lines each, and the third having one line, that together form a virtual display that is 5 lines high.

The sum of the HEIGHTs must match the total height given in Size=.

ExtendedMode = { yes | no }

If you have a KS0073 or an other 'almost HD44780-compatible', set this flag to get into extended,4-line linear addressing mode.

Note

Deprecated, use Model=extended for such displays.

LineAddress = ADDR

If the next line of your display doesn't start 0x20 higher in DDRAM you can override the default value of the ExtendedMode with this parameter.

DelayMult = DELAY

If your display is slow and cannot keep up with the flow of data from LCDd, garbage can appear on the LCDd. Set this delay multiplier to 2 or 4 to increase the delays. The default is 1 for a non-multiplied delay.

DelayBus = { yes | no }

You can reduce the inserted delays by setting this to no. On fast PCs it is possible your LCD does not respond correctly. Default: yes.

KeepAliveDisplay = SECONDS

Some displays (e.g. vdr-wakeup) need a message from the driver to indicate that it is still alive. When set to a value greater than 0 the character in the upper left corner is updated every SECONDS seconds. The default 0 does not cause any extra updates.

RefreshDisplay = SECONDS

If you experience occasional garbage on your display you can use this option as workaround. If set to a value greater than 0 it forces a full screen refresh every SECONDS seconds. Default: 0.

KeyDirect_NUM = KEY , KeyMatrix_X_Y = KEY

If you have a keypad you can assign keystrings to the keys. See the keypad section for used terms and the section on the specific connection type how to wire it.

To map, for example, the directly connected key 4 to the string Enter, use KeyDirect_4=Enter. For matrix keys use the X and Y coordinates of the key; e.g. KeyMatrix_1_3=Enter.

VendorID = VENDORID

USB vendor ID to look for in certain USB connection types. When using an FTDI chip with connection type ftdi, the default value is 0x4003. When using a USS720 chip with connection type uss720, the default value is 0x1293.

ProductID = PRODUCTID

USB product ID to look for in certain USB connection types. When using an FTDI chip with connection type ftdi, the default value is 0x6001. When using a USS720 chip with connection type uss720, the default value is 0x0002.

UsbDescription = DESCRIPTION

USB Description string to look for in FTDI connection types. If not given, the first USB device will be used. If given, the first matching device will be used.

SerialNumber = SERIALNO

Serial number of the USB device to look for with bwctusb and FTDI connection types. If not given, the first BWCT/FTDI USB device found will be used.

Miscellanea

This text has originally been taken from a message by Bill Farrow .

Updated February 2000, Benjamin Tse

Updated October 2001, Joris Robijn

Converted to Docbook March 2002, Rene Wagner

Updated April 2002, Rene Wagner

Updated and extended April 2006 to November 2007, Peter Marschall