This repository is dedicated to fast parallel communications on Raspberry Pi. The speed is essential when communicating with large liquid crystal displays, as a lot of data has to be transferred for a single full screen picture. Note that serial SPI communication is used for some devices that have SPI communication that is fast enough.
No additional library or program is used - instead C code is written to use standard Linux driver for pin access and SPI communication. To create C library execute make
(library in local directory) or make install
(shared library).
General purpose C library for parallel communications on Raspberry Pi
- supports 6800 and 8080 protocols, both 4 bits and 8 bits
- supports arbitrary GPIO pins from 0 to 27
- supports writing and reading, reading is optional
- supports objective oriented programming, initialisation returns the pointer to chip instance
- all RPi data lines by default in read/input mode in order to avoid possible conflict and destruction of GPIO pins
Version 2 also offers additional improvements:
- More precise timing;
- Code streamlined by consolidating duplicates.
* on writing between two half-bytes (4 bits protocol): tclock; on writing after full byte: tproc; on reading between two half-bytes (4 bits protocol): larger of tclock and thold; on reading after full byte: larger of tproc and thold.
More information on parallel protocols
C library made to use standard Linux driver SPI communication
Python library for HD44780 controller chip (requires parallel C library)
Python test file for the Python Library (reqires HD44780.py)
Note: If you don't want to control backlight from the program, set bl=-1
. If you are not interested in backlight PWM, set pwm=False
. If there are problems, try to make waiting times longer.
Python library for RA6963 controller chip (requires parallel C library)
Python test file for the Python Library (reqires RA6963.py)
Note: If you don't want to control backlight from the program, set bl=-1
. If you are not interested in backlight PWM, set pwm=False
. If there are problems, try to make waiting times longer.
Python library for ST7565 controller chip (requires spi C library)
Python test file for the Python Library (reqires ST7565.py)
Note: If you don't want to control backlight from the program, set bl=-1
. If you are not interested in backlight PWM, set pwm=False
. If there are problems, try to make waiting times longer.
Python library for ST7920 controller chip (requires parallel C library)
Python test file for the Python Library (reqires ST7920.py)
Note: If you don't want to control backlight from the program, set bl=-1
. If you are not interested in backlight PWM, set pwm=False
. If there are problems, try to make waiting times longer.
Python library for SSD1680 controller chip (requires spi C library)
Python test file for the Python Library (reqires SSD1680.py)