PIC Straight to the Point: LED Matrix
- Thiago Turcato
- Apr 26, 2020
- 2 min read
Updated: Apr 27, 2020
How to control a LED Matrix by using PIC 18F4550 and HT16K33 driver from Holtek
Procurando pela versão em português? Clique aqui.

Drive a LED Matrix directly from a microcontroller is I/O consuming task. HT16K33 is a good option that manages this task consuming only two I/Os from microcontroller: SDA and SCL for I2C communication.
Some months ago, I was working in a product project that needed a display where a good visualization two or three meters far from the product was important, including at night. The seven-segment display was the option used in many similar products in the market but there is a limitation: representation of letters, needed in the project. Unfortunately, the project was canceled but still, I found an excellent option, not as cheap as a seven-segment display (average USD 0.50 for 7-seg against USD 0.60 this solution, per digit) but the cost is fair for those who have a similar situation as I had (representation of letters and good view at distance) : 5 x 7 matrix display! The display is perfect sizewise compared to 7-segment displays: about 13 x 18 mm ( 1/2" x 13/32"), very close to popular 0.56 inch 7-segment display.

One issue is: how to drive these matrixes efficiently? As they are a 5 x 7 matrix, it means 35 LEDs to drive, which requires 12 I/Os, at least, if multiplexing. It is I/O consuming! Doing research, I found two popular driver options for those matrixes: MAX7219 (from Maxim) and HT16K33 (from Holtek). I confess I didn't try the first option and decided to test the second.

In the beginning, it was a little bit confusing to understand how HT16K33 and it's I2C registers work; the system didn't work in my first try. After understanding how to put I2C data together correctly, I found how easy it is to make it work!
All the development and explanations can be found in the video I posted on YouTube: https://youtu.be/97hqhEZ7Nx0. It is bilingual: English and Portuguese.
I hope you enjoy it! Feel free to send your feedback or question! Thiago
Comments