A2 A1 A0
I2C BUS SLAVE ADDRESS
32 (decimal), 20 (hexadecimal)
33 (decimal), 21 (hexadecimal)
34 (decimal), 22 (hexadecimal)
35 (decimal), 23 (hexadecimal)
36 (decimal), 24 (hexadecimal)
37 (decimal), 25 (hexadecimal)
38 (decimal), 26 (hexadecimal)
39 (decimal), 27 (hexadecimal)
I2C BUS SLAVE ADDRESS
■ FIGURE 4. Addressing scheme.
56 (decimal), 38 (hexadecimal)
57 (decimal), 39 (hexadecimal)
58 (decimal), 3A (hexadecimal)
59 (decimal), 3B (hexadecimal)
60 (decimal), 3C (hexadecimal)
61 (decimal), 3D (hexadecimal)
62 (decimal), 3E (hexadecimal)
63 (decimal), 3F (hexadecimal)
I used a hybrid of through-hole and SMD/SMT
(Surface Mount Device/Surface Mount Technology),
which turns out to be much easier to construct than
you might think if you were raised on through hole-only
techniques. While the SMT parts can be hand soldered
one pin at a time using a fine tip soldering iron and
flux-core solder, I have evolved to a hot air technique. I
use solder paste from a syringe to “dot” the SMT pads,
place the parts with tweezers, and when the entire side
of the PCB is complete I go over it with a hot air gun
intended for heat shrink tubing. Violá! The paste turns to
molten solder and due to its density forms little puddles
centered on the pads while the SMT parts float and snap
to the center too, making perfect joints. It’s so much fun
to watch! The important lesson here is to only use small
amounts of solder paste.
Feedback from builders pointed out that SMT LEDs
are really hard to identify, and were often placed backwards. I have edited the EAGLE silk screen to use a diode
symbol for my future projects. The cathode (bar) end of
the symbol matches the paint dot or stripe on the SMT
56 November 2008
LED, but you likely need a 10 power eye loupe to see it.
Also, by convention, the LED parts are placed in their
carrier tape with the cathode towards the sprocket holes.
I deliberately didn’t write operating instructions to go
with the first article, as I enjoy discovering how products
operate when I’m the customer and use them for the first
time. Nothing kills the moment more than having to wade
through a thick manual. The Holiday Lights Controller
interface is very simple, but just in case you’d like
directions I’ve written a brief text file and bundled it
with the download for this project from the Nuts & Volts
website ( www.nutsvolts.com).
The I/O Card MkII
I have changed the circuitry on the I/O card to use
another AVR µC in place of the fixed function I2C chip,
which remains a nice part for other applications.
I2C signals from the controller card still pass along the
I2C bus and go to each I/O card which, in turn, has its
own base address set by the DIP switches. All cards hear
all messages on the bus but only act on those messages
directed to a particular card.
The number of messages has been reduced to
decrease bus activity — which was the original bottle neck
— and rely on the local AVR to set triac phase-angle timing. This way, all channels operate together, removing
slight brightness variations from one channel to the next.
Two types of messages are sent: one is the data to be
stored for each channel’s dimmer delay and the other
message is the AC zero-cross sync. This is sent to all the
■ FIGURE 5. AC and I2C timing diagram.