Discuss this article in the SERVO Magazine forums at http://forum.servomagazine.com
PUTTING THE SMART IN SMART MODULE.
A piece of hardware can
have the best specs in the
world, but without the right
programming it can be little
more than a fancy paperweight.
Users have a few options for
programming the 4D display
modules, and all of them are
within the universe of the
Workshop 4 IDE. The Workshop
4 IDE is a custom Integrated
Development Environment that
caters to users of all
programming skill levels.
The traditional development
environment is the Designer,
where users write textual code.
The code in this case is 4DGL —
a custom graphics language that draws familiar elements
from C and Java. Even for a purely textual environment, the
Designer has great visual flair. Different parts of the syntax
come in different bright colors that stand in stark contrast
to the black background. The 4D Systems website features
numerous guides to introduce users to the syntax of the
Designer and an entire code library of sample programs.
Even so, coding in pure text can be daunting to the
For that reason, the Workshop 4 also includes Visi —
a hybrid of the text-based Designer and a more graphical
interface that allows users to create the display they want
by dragging and dropping elements onto a template that
looks like the target smart display. The elements that can
be dragged and dropped include simple shapes, interactive
buttons for the touch screen, indicator lights, and gauges
for everything from rpm to temperature. Once you’ve
created the display you want, the touch of a button will
paste all the code to make it happen right into the Designer
side of the IDE.
For the completely text averse, the Workshop 4 also
includes the Visi-Genie which is a completely graphical way
to construct the module display. The Visi-Genie is much like
Visi, except it does not show a window with the code in
To get the code from the computer to the module,
4D Systems offers a custom programming cable. We were
ecstatic to see that the cable smartly used a USB
connection to plug into the computer. The other end of the
cable is a five-pin header that connects to the display
module. The cable handily sources 5V to power the module
We opted to use Visi for our experimenting purposes to
get a sense of both the textual programming and the
usefulness of the drag-and-drop graphical interface.
THE MODULE SPRINGS TO LIFE!
SERVO 03.2013 69