Zum Hauptteil springen

wokwi-max7219-matrix Dot Matrix Reference

8x8 LED Dot Matrix with MAX7219 Controller

MAX7219 LED Dot Matrix

Pin names

NameDescription
VCCVoltage supply
GNDGround
DINData input
CSChip Select
CLKClock input
DOUTData output

Attributes

NameDescriptionDefault value
chainHow many units to chain together"1"
colorLED color (when lit)"red"
layoutMatrix connection layout: "parola" or "fc16""parola"

Chaining

Each dot matrix units is an 8x8 LED matrix. All the LEDs in the matrix have the same color. You can make the display wider by setting the "chain" attribute. For example, setting "chain" to 4 will chain four dot matrix units horizontally, resulting in 32x8 matrix (four times 8x8 matrix).

If you want to chain units in a custom way (e.g. select a different pixel color for each unit, chain them vertically, etc), connect the DOUT pin of one unit to the DIN pin of the next unit. You also need to connect the CLK / CS pins of the units together. See 32x32 LED Matrix Tunnel for an example.

Matrix layout

There are several type of matrix layout, based on the commonly available modules. You can set the "layout" property to choose the desired pixel layout:

  • "parola" - See the Parola documentation for information about the layout of these modules
  • "fc16" - The FC-16 modules are available from EBay and AliExpress. They usually come in a chain of four 8x8 matrices, so they have 32x8 pixels in total.

Choosing the wrong layout will cause your text / drawing to be rotated and / or mirrored.

Examples

ResultAttrs
{ "color": "green" }
{ "chain": "4" }

Simulator examples