RPI_PCD8544

Features

  • 84x48 pixels matrix LCD
  • Uses PCD8544
  • Color: Monochrome
  • Backlight: White

Pinout

pcd8544_layout

  • GPIO0 - CLK - 17
  • GPIO1 - DIN - 18
  • GPIO2 - D/C - 27
  • GPIO3 - CS - 22
  • GPIO4 - RESET - 23

Setup for Python

Using Adafruit Python libraries:

Install the required packages:

git clone https://github.com/adafruit/Adafruit_Python_GPIO.git

cd Adafruit_Python_GPIO
sudo python setup.py install

sudo apt install python-dev python-imaging

git clone https://github.com/adafruit/Adafruit_Nokia_LCD.git

cd Adafruit_Nokia_LCD
sudo python setup.py install

Change the demos to use Software SPI:

In file examples/image.py:

# DC = 23
# RST = 24
# SPI_PORT = 0
# SPI_DEVICE = 0

SCLK = 17
DIN = 18
DC = 27
CS = 22
RST = 23

# disp = LCD.PCD8544(DC, RST, spi=SPI.SpiDev(SPI_PORT, SPI_DEVICE, max_speed_hz=4000000))
disp = LCD.PCD8544(DC, RST, SCLK, DIN, CS)

Run the demo:

sudo python examples/image.py

Setup for C

Using the library from Raspberry-Pi-Utils:

git clone https://github.com/ronanguilloux/Raspberry-Pi-Utils.git

cd Raspberry-Pi-Utils/PCD8544
cc -o pcd8544_cli pcd8544_cli.c PCD8544.c  -L/usr/local/lib -lwiringPi
cc -o pcd8544_rpi pcd8544_rpi.c PCD8544.c  -L/usr/local/lib -lwiringPi

Run programs:

sudo ./pcd8544_cli [options] <text to display>

or

sudo ./pcd8544_rpi

Links