Skip to content

Latest commit

 

History

History
62 lines (42 loc) · 3.56 KB

README.md

File metadata and controls

62 lines (42 loc) · 3.56 KB

HT16K33 Drivers 3.3.0

This repo provides Python drivers for the Holtek HT16K33 controller chip and various display devices based upon it, such as the Adafruit 0.8-inch 8x16 LED Matrix FeatherWing and the Raspberry Pi Pico.

The drivers supports both CircuitPython and MicroPython applications. They communicate using I²C.

Importing the Drivers

The driver package comprises a parent generic HT16K33 class and child classes for various displays themselves. All your code needs to do is import the latter. For example:

from ht16k33segment import HT16K33Segment

You can then instantiate the driver object. This requires a configured I2C bus object.

You will need both the display driver file and ht16k33.py in your project folder.

Reducing Memory Usage

Adding the driver code may prove too much for certain CircuitPython devices which have limited amounts of memory. To overcome this, run the mpy-cross compiler. This will compile the raw Python into a highly compact form in a .mpy file. Copy ht16k33.mpy and the device-specific .mpy file to your device in place of the .py versions.

The repo’s mpy directory contains pre-compiled versions for CircuitPython applications.

Display Drivers

Driver
(Click for docs)
Example Product
Small 4-digit, 7-segment LED  Adafruit 0.56-inch 4-digit, 7-segment LED display
Large 4-digit, 7-segment LED  Adafruit 1.2-inch 4-digit, 7-segment LED display
Small 4-digit, 14-segment LED SparkFun Qwiic Alphanumeric Display,
Adafruit 0.54in Alphanumeric Display
8x8 monochrome matrix LED  Adafruit Mini 0.8-inch 8x8 LED Matrix
8x8 bi-colour matrix LED Adafruit 1.2-inch 8x8 bi-color LED matrix backpack
16x8 FeatherWing matrix LED Adafruit 0.8-inch 8x16 LED Matrix FeatherWing

Further drivers may be added in due course.

Documentation

You can find documentation for all of the drivers at smittytone.net.

Release Notes

  • 3.3.0 5 August 2022
    • Add rotate() method to HT16K33Segment.
  • 3.2.0 26 July 2022
  • 3.2.0 16 February 2022
  • 3.0.2 23 November 2020
    • Refactor out some ht16k33matrix.py code.
  • 3.0.1 7 November 2020
    • Correct variable name in ht16k33matrix.py.
  • 3.0.0 6 November 2020
    • Initial public release.

Licence and Copyright

This repository’s source code and documentation is copyright 2022, Tony Smith (@smittytone).

The HTK16K33 driver and subsidiary display drivers are licensed under the MIT License.