Add support for 64-bit image drawing with MAX7219 8x8 LED Matrix
The MAX7219 driver has been extended to add support for bitmap drawing on an 8-by-8 LED matrix panel. Consumers can specify the targeted chip, which corresponds to a LED matrix panel, and provide a 64-bit image buffer specifying the pixels which should illuminate.
This commit is contained in:
parent
503e66a500
commit
22f84a15c3
5 changed files with 161 additions and 1 deletions
95
examples/max7219_8x8/digit_font.h
Normal file
95
examples/max7219_8x8/digit_font.h
Normal file
|
@ -0,0 +1,95 @@
|
|||
const uint8_t DIGITS[][8] = {
|
||||
{
|
||||
0x0,
|
||||
0x3c,
|
||||
0x66,
|
||||
0x6e,
|
||||
0x76,
|
||||
0x66,
|
||||
0x66,
|
||||
0x3c
|
||||
}, {
|
||||
0x0,
|
||||
0x18,
|
||||
0x18,
|
||||
0x38,
|
||||
0x18,
|
||||
0x18,
|
||||
0x18,
|
||||
0x7e
|
||||
}, {
|
||||
0x0,
|
||||
0x3c,
|
||||
0x66,
|
||||
0x6,
|
||||
0xc,
|
||||
0x30,
|
||||
0x60,
|
||||
0x7e
|
||||
}, {
|
||||
0x0,
|
||||
0x3c,
|
||||
0x66,
|
||||
0x6,
|
||||
0x1c,
|
||||
0x6,
|
||||
0x66,
|
||||
0x3c
|
||||
}, {
|
||||
0x0,
|
||||
0xc,
|
||||
0x1c,
|
||||
0x2c,
|
||||
0x4c,
|
||||
0x7e,
|
||||
0xc,
|
||||
0xc
|
||||
}, {
|
||||
0x0,
|
||||
0x7e,
|
||||
0x60,
|
||||
0x7c,
|
||||
0x6,
|
||||
0x6,
|
||||
0x66,
|
||||
0x3c
|
||||
}, {
|
||||
0x0,
|
||||
0x3c,
|
||||
0x66,
|
||||
0x60,
|
||||
0x7c,
|
||||
0x66,
|
||||
0x66,
|
||||
0x3c
|
||||
}, {
|
||||
0x0,
|
||||
0x7e,
|
||||
0x66,
|
||||
0xc,
|
||||
0xc,
|
||||
0x18,
|
||||
0x18,
|
||||
0x18
|
||||
}, {
|
||||
0x0,
|
||||
0x3c,
|
||||
0x66,
|
||||
0x66,
|
||||
0x3c,
|
||||
0x66,
|
||||
0x66,
|
||||
0x3c
|
||||
}, {
|
||||
0x0,
|
||||
0x3c,
|
||||
0x66,
|
||||
0x66,
|
||||
0x3e,
|
||||
0x6,
|
||||
0x66,
|
||||
0x3c
|
||||
}
|
||||
};
|
||||
|
||||
const int DIGITS_LEN = sizeof(DIGITS)/8;
|
Loading…
Add table
Add a link
Reference in a new issue