Using the output detection feature of the high-brightness
LED driver STP08CDC596 evaluation board
Introduction
This document describes how to implement a complete solution for driving a high-brightness
LED array. Based on STP08CDC596 drivers and controlled by an ST7FLITE3x
microcontroller, there are two versions of the evaluation board:
■ STEVAL-ILL002V1 using OSRAM LEDs
■ STEVAL-ILL002V2 using Toshiba LEDs
Note:The STP08CDC596 LED driver is replaced by the new, higher performing STP08DP05 LED
driver. The two available versions of the evaluation board with the STP08DP05 replace the
STEVAL-ILL002V1 and the STEVAL-ILL002V2, and are described in application note
AN2478.
The new boards available are:
■ STEVAL-ILL002V3 using OSRAM LEDs
■ STEVAL-ILL002V4 using VISHAY LEDs
Forty high-brightness LEDs are arranged on the board in a 5x8 matrix. The matrix is driven
by five 8-channel STP08CDC596 drivers.
The main features of the evaluation board are:
■ Brightness and blinking regulation
■ Animated text
■ Error detection on output
■ GUI (graphic user interface)
■ DC-DC converter
The innovative feature of the STP08CDC596 is the full output error detection function which
enables output status checking without invasive testing (via software only).
Figure 1.STEVAL-ILL002Vx evaluation board
For more information about other boards based on the STPxxC/L596 driver family, refer to
application note AN2141 which provides details concerning the basic features of the driver
family, the microcontroller interface and chip power dissipation. Refer to user manual
UM0181 for information about how to get started using the evaluation boards.
The STEVAL-ILL002Vx evaluation board can be powered with voltages from 7 V up to 32 V.
The SMPS DC-DC converter block is based on the L5970D step-down switching regulator
and the DC-DC block is based on the LE50ABD voltage regulator. The power topology
makes it possible to power the board using a laptop power supply.
Figure 2 shows the block diagram of the evaluation board.
The brain of the board is the 8-bit ST7FLITE39 microcontroller. It receives inputs from the
control panel, sends and receives data from the LED drivers through the serial peripheral
interface (SPI) and enables PC communication through the serial communications interface
(SCI). The control panel consists of switches, potentiometers and jumpers. Switches are
used to reset the microcontroller and to enter Detection mode. Potentiometers change the
brightness and text speed. Jumpers are used to simulate errors (open and short circuit) on
the LED matrix.
A LED matrix consists of 40 LEDs arranged in a 5x8 matrix. A dedicated PC GUI displays
the status of the LEDS.
4/11
AN2415Operation mode switching
2 Operation mode switching
To enter Error Detection or Normal mode, the drivers must receive a particular sequence on
the OE and LE pins.
When a one-clock-wide short pulse “101” is sent on the OE pin, the drivers enter the
switching phase. If the LE pin is sampled as high voltage at the 4th rising edge of CLK, the
drivers switch to Error Detection mode (Figure 3). Otherwise, they switch to Normal mode
(Figure 4).
Note:In the firmware, with SW2 pressure only the drivers enter Error Detection mode, and after an
error detection check, they re-enter Normal mode.
Figure 3.Error Detection mode
Figure 4.Normal mode
2.1 Normal mode
In Normal mode, the serial data is transferred from the microcontroller to the drivers via the
SPI. The serial data from microcontroller is sent to the drivers via the SDI pin, undergoes a
shift in the Shift Register, and exits via the SDO pin. The LE pin can latch the serial data in
the Shift Register to the output latch. The OE pin enables the output driver sink current.
Current is modulated by the potentiometer, which changes the PWM duty cycle on the OE
pin (PWM frequency is set at 244 Hz).
5/11
Firmware implementationAN2415
Note:At start-up, the evaluation board works in Normal mode.
2.2 Error detection mode
After entering Error Detection mode as shown in Figure 3, it is recommended to send all
data to the drivers as “1”.
As long as the OE pin is high, the serial data can still be shifted to the Shift Register via the
SDI pin, and out via the SDO pin. The LE pin can also send the data in the Shift Register to
the output latch.
When the state of the OE pin is pulled down to low voltage for at least 2 µs, the drivers
execute the error detection function and load the error status into the Shift Register. The
error status codes saved in the Shift Register can then be shifted out via the SDO pin bit-bybit along with the clock. The SDO pin of the last driver of the chain is connected to the MISO
pin of the microcontroller. Incoming data can be sent to the PC through the SCI and
displayed on the GUI. For more information, refer to the timing diagram shown in Figure 5.
3 Firmware implementation
The purpose of this application note is to explain how to manage the error detection features
of the drivers. Refer to AN2141 for an explanation of the basic driver features.
3.1 Timing diagram
At power-up, the microcontroller sends data to the drivers’ Shift Register via the SPI
configured at 250 kHz. The maximum communication frequency for this driver is 25 MHz to
satisfy high volume data transmissions. (Please refer to the device datasheet for more
details). The two potentiometers are connected to ADC inputs. The analog voltage inputs
are converted to a digital value. According to this digital value, it will change the PWM
duty-cycle signal for brightness and data time delay for text speed. By default, the
microcontroller works in Normal mode and only enters Error Detection mode when an
external interrupt pin connected to SW2 is triggered. The related ISR disables the SPI I/O
function and sends a specific sequence to the driver via the CLK, OE, and LE pins as shown
in Figure 5.
After the driver has received the specific sequence, the microcontroller enables the SPI and
sends 0xFF data for each driver. The drivers have already entered Error Detection mode
and the microcontroller maintains pin OE low for detecting the error status. Drivers send
back the LED status to the microcontroller via the MISO pin (connected to the SDO pin).
Then, the microcontroller resumes Normal mode operation, sending the specific sequence
to the drivers. Figure 5 shows each phase, switching from Error Detection to Normal modes.
6/11
AN2415Firmware implementation
Figure 5.Timing diagram
Note:T
Note:The SDO of the E driver is connected to the MISO pin of the MCU.
must be at least 2 µs to detect the error status.
A
3.2 Option byte
Figure 6 shows the option byte settings.
Figure 6.MCU option bytes
3.3 GUI features
A dedicated graphical user interface (GUI) displays the LEDs, status on the PC. The serial
parameters are: 4800, 8, N, 1 (baud rate, 8 bit, parity none, 1 bit stop). The microcontroller,
7/11
Application diagramAN2415
after resuming Normal mode, manages the SCI peripheral and sends data to the PC using
the ST232ABN driver interface.
STP08CDC596 LED driversSTP08CDC596TTR STMicroelectronics
CAN connector - 9 pin
Potentiometers with
axis
Switch
4 Revision history
Table 2.Revision history
DateRevisionChanges
7-Sept-20061Initial release.
31-Jan-20072
08-Feb-20073Bill of materials table modified.
30-Aug-20074Minor text changes
10/11
Bill of materials table and LED matrix board application diagram
modified.
AN2415
Please Read Carefully:
Information in this document is provided solely in connection with ST products. STMicroelectronics NV and its subsidiaries (“ST”) reserve the
right to make changes, corrections, modifications or improvements, to this document, and the products and services described herein at any
time, without notice.
All ST products are sold pursuant to ST’s terms and conditions of sale.
Purchasers are solely responsible for the choice, selection and use of the ST products and services described herein, and ST assumes no
liability whatsoever relating to the choice, selection or use of the ST products and services described herein.
No license, express or implied, by estoppel or otherwise, to any intellectual property rights is granted under this document. If any part of this
document refers to any third party products or services it shall not be deemed a license grant by ST for the use of such third party products
or services, or any intellectual property contained therein or considered as a warranty covering the use in any manner whatsoever of such
third party products or services or any intellectual property contained therein.
UNLESS OTHERWISE SET FORTH IN ST’S TERMS AND CONDITIONS OF SALE ST DISCLAIMS ANY EXPRESS OR IMPLIED
WARRANTY WITH RESPECT TO THE USE AND/OR SALE OF ST PRODUCTS INCLUDING WITHOUT LIMITATION IMPLIED
WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE (AND THEIR EQUIVALENTS UNDER THE LAWS
OF ANY JURISDICTION), OR INFRINGEMENT OF ANY PATENT, COPYRIGHT OR OTHER INTELLECTUAL PROPERTY RIGHT.
UNLESS EXPRESSLY APPROVED IN WRITING BY AN AUTHORIZED ST REPRESENTATIVE, ST PRODUCTS ARE NOT
RECOMMENDED, AUTHORIZED OR WARRANTED FOR USE IN MILITARY, AIR CRAFT, SPACE, LIFE SAVING, OR LIFE SUSTAINING
APPLICATIONS, NOR IN PRODUCTS OR SYSTEMS WHERE FAILURE OR MALFUNCTION MAY RESULT IN PERSONAL INJURY,
DEATH, OR SEVERE PROPERTY OR ENVIRONMENTAL DAMAGE. ST PRODUCTS WHICH ARE NOT SPECIFIED AS "AUTOMOTIVE
GRADE" MAY ONLY BE USED IN AUTOMOTIVE APPLICATIONS AT USER’S OWN RISK.
Resale of ST products with provisions different from the statements and/or technical features set forth in this document shall immediately void
any warranty granted by ST for the ST product or service described herein and shall not create or extend in any manner whatsoever, any
liability of ST.
ST and the ST logo are trademarks or registered trademarks of ST in various countries.
Information in this document supersedes and replaces all information previously supplied.
The ST logo is a registered trademark of STMicroelectronics. All other names are the property of their respective owners.