Microchip Technology APGRD004 Data Sheet
14
LED Lighting Solutions Design Guide
www.microchip.com/lighting
LED Lighting Solutions
DMX512
The DMX512 interface (ANSI E1.11) has gained great
popularity in theatrical/entertainment lighting applications
because of its simplicity and low cost. It is based on a 250
Kbaud asynchronous serial interface that uses the standard
RS-485 differential line transceivers. Transmitter and
receivers can be implemented on most PIC microcontrollers
in a few lines of code. PIC microcontrollers that offer a
EUSART peripheral allow for the simplest and most efficient
implementation of the protocol.
popularity in theatrical/entertainment lighting applications
because of its simplicity and low cost. It is based on a 250
Kbaud asynchronous serial interface that uses the standard
RS-485 differential line transceivers. Transmitter and
receivers can be implemented on most PIC microcontrollers
in a few lines of code. PIC microcontrollers that offer a
EUSART peripheral allow for the simplest and most efficient
implementation of the protocol.
Application note AN1076 offers an example implementation
of both a transmitter and typical DMX512 receiver on a
PIC18F2420 model.
of both a transmitter and typical DMX512 receiver on a
PIC18F2420 model.
The figure below shows an application example where
a PIC24FJ16GA002 implements a DMX512 receiver to
control three PWM output channels (each capable of 16-bit
resolution).
a PIC24FJ16GA002 implements a DMX512 receiver to
control three PWM output channels (each capable of 16-bit
resolution).
Literature on the Web
■
AN1076 – Using a PIC Microcontroller for DMX512
Communication
Wired Communication Solutions for Lighting
Many lighting applications require some form of
communication for remote control but also for diagnostic
purposes. Some of the most common interfaces used in
lighting are:
communication for remote control but also for diagnostic
purposes. Some of the most common interfaces used in
lighting are:
■
0-10V
■
DMX512
■
Digitally Addressable Lighting Interface (DALI)
0-10V Interface
All PIC microcontroller families offer models that integrate
an Analog-to-Digital converter peripheral with a minimum of
8-bit resolution that allows them to connect to the industry
standard 0-10V interface with minimum external component
count. Most Flash PIC microcontroller models offer a
10-bit resolution ADC, while 12-bit resolution is available
on selected models. Each I/O pin is protected by a pair of
(clipping) diodes so to prevent latch-up and damages that
could follow from the incorrect wiring of a 0-10V interface
(over-voltage).
an Analog-to-Digital converter peripheral with a minimum of
8-bit resolution that allows them to connect to the industry
standard 0-10V interface with minimum external component
count. Most Flash PIC microcontroller models offer a
10-bit resolution ADC, while 12-bit resolution is available
on selected models. Each I/O pin is protected by a pair of
(clipping) diodes so to prevent latch-up and damages that
could follow from the incorrect wiring of a 0-10V interface
(over-voltage).
There are different 0-10V specifications based on
the intended application. The 0-10V control interface
for controllable ballasts is defined in Annex E of the
IEC60929 specification. The 0-10V control interface for the
entertainment industry is defined by ANSI E1.3-2001.
the intended application. The 0-10V control interface
for controllable ballasts is defined in Annex E of the
IEC60929 specification. The 0-10V control interface for the
entertainment industry is defined by ANSI E1.3-2001.
Digitally Addressable Lighting Interface (DALI)
DALI is a bi-directional
digital protocol that
requires a two wire
connection system
similar to the 0-10V
interface, but offers
individual lamp or group
addressability in a bus
configuration. The low
speed Manchester
encoding system used
digital protocol that
requires a two wire
connection system
similar to the 0-10V
interface, but offers
individual lamp or group
addressability in a bus
configuration. The low
speed Manchester
encoding system used
allows for an inexpensive firmware implementation on
most any PIC microcontroller. Many PIC devices offering an
analog comparator peripheral can implement an advanced
power saving techniques as demonstrated in application
note AN809. Application note AN811 illustrates the
implementation of a bridge between DALI and a standard
RS-232 serial interface.
most any PIC microcontroller. Many PIC devices offering an
analog comparator peripheral can implement an advanced
power saving techniques as demonstrated in application
note AN809. Application note AN811 illustrates the
implementation of a bridge between DALI and a standard
RS-232 serial interface.
DALI Ballast Software Library
A DALI ballast software library is available for PIC MCUs
that comply with the latest release of the IEC60929
specification. Contact your local sales office for availability.
that comply with the latest release of the IEC60929
specification. Contact your local sales office for availability.
Literature on the Web
■
AN809 – Digitally Addressable DALI Dimming Ballast
■
AN811 – The RS-232/DALI Bridge Interface
RS-485
Transceiver
PIC24FJ16GA002
DMX512
E
U
S
A
R
S
A
R
T
PWM1
PWM2
PWM3
PIC24FJ16GA002 Controlling 3 PWM Output Channels
D
d
r
c
s
i
i
a
c
s
e
d
r
c
s
i
i
a
c
s
e