STM32, ChibiOS and a 8×8 LED Matrix

STM32, ChibiOS and 8x8 LED Matrix

1 A compact display driver: the MAX7219

The MAX7219 is a compact, serial input/parallel output common-cathode display driver. Included on-chip there are a BCD code-B decoder, the multiplex scan circuitry, segment and digit drivers, and an 8×8 static RAM that stores each digit. Only one external resistor is required to set the segments current.

1.1 Common uses

LED matrix DIY kit
Fig.1 – A 8×8 LED matrix DIY kit.

This chip is often used to drive 7-segment display having up to 8 digits or up to 64 individual LEDs. It is not unusual find this chip in DIY kits to be mounted on a small PCBs like that used in this article (See Fig. 1).

This chip could be found in different packages and uses a non-standard SPI (Data is clocked even if CS remains high but is needed a low to high transition to complete communication.If you are not familiar with SPI communication read Meeting SPI). MAX7221 is similar to MAX7219 except for two parameters:

  1. MAX7221 segment drivers are slew-rate limited to reduce electromagnetic interference;
  2. its serial interface is fully SPI compatible.

continue reading…

ChibiCube hardware explained

ChibiCube hardware explained

1 In this article

By this article, we will show schematic of ChibiCube in order to understand how it works and hot it has been designed.

2 Toward ChibiCube schematic

As mentioned in the previous article, ChibiCube addresses all its LEDs through the combination of anode and cathode signals. Each floor of the cube is configured as common anode, while the various cathode signals are separately connected to the outputs of the Shift Register. Setting the anode voltage to a value equal or greater than the high logical threshold of our SR, for the same principle illustrated in the tutorial Meeting SPI, we can address single LEDs of the floor. To make it simple, consider a cube 4x4x4: the diagram of a single floor would appear as in Fig.1.

ChibiCube plane schematic
Fig.1 – A schematic of a plane from a 4×4 LED cube.

This schematic is different from the one shown in SPI tutorial in some points:

  • The SR is a 16 bit one and is a LED driver. Output current is fixed choosing R-EXT and we don’t need for a resistor on each LED;
  • To make schematic simple, LEDs are oriented as a 4×4 matrix;
  • The common anode is addressed by MCU thought a P-MOS, instead being connected directly to power supply;

continue reading…

Introducing ChibiCube

Introducing ChibiCube

1 About

ChibiCube is a 3D LED matrix 8x8x8 composed by monochromatic LEDs individually addressable: that means not only every single LED could be in a ON or OFF state but everyone could be set at different light intensity.

2 Inception

In December 2012, students Ciro Domenico Pagano from University of Salerno, Antonio Galano from Federico II University of Naples and Vincenzo Brillante from University of Sannio start their training at Naples site of ST Microelectronics.

In order to understand uses of ChibiOS and STM32 MCUs, their Tutor Giovanni Di Sirio suggested the design of a small 4x4x4 LED cube. This first version was made on a prototyping board and driven by a STM32F407 Discovery using parallel wiring.

Months later, the cube was engineered in a new version 8x8x8 upgradable to 16x16x16 connecting 4 PCBs together.

ChibiCube prototype
Fig.1 – A prototype of a 4x4x4 LED cube.

continue reading…