Finally, we arranged all of them in a row using the
keyboard arrow keys; the result looks like Figure 9.
Next, we labeled each LED with its corresponding
binary weight from 7 (MSB) on the left to 0 (LSB) on the
far right. This time, we switched to the Controls 1 tab to
select the oLabel; using the Text Box in the drop-down
menu, we set the numbers from 7 to 0 as in Figure 10.
That configures the individual LEDs, but we also want to
see the numerical value of the eight digital signals, so that
requires a Text Box. To do this, we grabbed an o Text box
and dragged it under the LEDs to display
the numerical value (Figure 11). Then, we
dragged another oLabel and named it
Binary Value.
So, that’s about it for the digital signals.
Now, let’s add some window dressing to
our customized Interface.
Dressing Things Up
While the meters and buttons for
analog and digital signal monitoring are
now on the My_Interface.spm, what
remains is a way to finish things off. Let’s
do that with some yellow vertical and
horizontal borders. In our last example
To do this, simply do a shift-right-click on any of the
vertical bars and click the Duplicate button. This will bring
up more of the same. Next, use the arrow keys to resize
them and move them into place. The result should look
like Figure 12 when complete. You’ll notice that the
meters, buttons, and switches are now bordered by the
same horizontal and vertical bars as the menu area.
Saving Our Work
While the graphic part of the interface
is complete, we’re not done yet. What
remains is to save our work to the
My_Interface.spm file. To start, you’ll need
to click on the Macro Builder icon in the
tool bar to bring up the Macro Builder
drop-down menu (Figure 13). Then, click
on the Update from Current button that will
load in all the graphic code for the meters,
buttons, switches, labels, and text boxes
that have been added. What’s left is to click
on the traditional floppy disk icon to save
our work to the My_Interface.spm file.
Conclusion
That about does it for building the
graphics portion of our My_Interface.spm
58 May 2014
Figure 10. Adding LED labels.
Figure 11. Adding Binary Value.