Code Monkey home page Code Monkey logo

pcd8544's Introduction

PDC8544 LCD python bindings for the Raspberry Pi

Documentation and Python library module for interfacing a PCD8544 LCD screen to a Rasbperry Pi. Cheap Nokia 5110 modules can be picked up on ebay with a breakout board for a few pounds.

PCD8544 Spec

Further technical details for the LCD screen can be found in the datasheet [PDF].

Pre-requisites

Compile and install the wiringPi python bindings from https://github.com/rm-hull/wiringPi. Make sure you install both python-dev and libi2c-dev. This library specifically requires the python binding baked into this software, which have not been pushed back to drogon.

Next, install PIL (Python Imaging Library) as follows:

$ sudo apt-get install zlibc libpng3 libfreetype6 libfreetype6-dev python-pip
$ sudo pip install pillow

Building and installing the software

After having cloned from github:

$ python setup.py clean build
$ sudo python setup.py install

This should install the files in your local dist-files ares (somewhere like /usr/local/lib/python2.7/distfiles/pcd8544).

Next, test at the hardware and software is working:

$ cd examples
$ sudo ./alphabet_text.py

Most of the ASCII character set should be displayed. There are a few other examples of graphics rendering in the same directory.

Wiring schematic

There appears to be different pin-out configurations on PCD8544 modules - beware!

Wiring Schematic

Although the python library (currently) used software-base bit-banging to do the SPI chattering, the pins chosen should be compatible with hardware SPI. The above diagram was modified for my wiring setup from an SVG from http://shiro.be/ - all rights of the original author reserved.

Stripboard Layout

With 4 push-buttons, resistor values 10K.

Stripboard Layout

Buttons (from top to bottom) are wired onto BCM pins as follows:

  • GPIO 14 (TxD)
  • GPIO 17
  • GPIO 25
  • GPIO 22

The finished article, and a video:

Built stripboard

TODO

  • Documentation

  • More examples

  • Introduce small/tiny font handling onto drawable PIL surfaces

  • Implement module for scanning push buttons

  • Hardware SPI rather than software emulation

References

Bitdeli Badge

pcd8544's People

Contributors

rm-hull avatar wsmithril avatar bitdeli-chef avatar pe7er avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.