|
Part 2: Controlling the Lights with
Software
by James Antonakos
Start ý Recap
ý Software Initialization ý Building
a Bit Pattern ý Outputting Data to the
Display ý Scrolling the Display Pattern
ý Handling Network Messages ý Other
Uses ý Sources and PDF
BUILDING A BIT PATTERN
Before a network or canned message can
begin scrolling across the LiteShow display, a bitmap containing the
binary patterns used to form all the display characters must be created
for it. Each character is contained in a 5 ý 7 array of on/off values
used to control the lamps. The patterns for the letters A, B, and
C are shown in Listing
3 to illustrate the organization.
To build the bitmap, each character from
a new message is used to locate its corresponding 5 ý 7 pattern, and
the pattern is copied into the bitmap. Spacing between character patterns
in the bitmap is accomplished by skipping one column of bits between
patterns. Thus, a message containing 20 characters results in a bitmap
containing 120 columns of data. Extra blank columns are added to the
end of the bitmap so that the display blanks from right to left as
the message scrolls off the display.
PREVIOUS
NEXT
Circuit Cellar provides up-to-date information for engineers. Visit
www.circuitcellar.com for
more information and additional articles.
For subscription information, call (860) 875-2199, subscribe@circuitcellar.com
or subscribe online.
ýCircuit Cellar, the Magazine for Computer Applications. Posted with
permission. |