
G P - 8 P / G P - 1 6 P S O F T W A R E
page 2 – 4
GPC-3 / Jan 2006
Programming the Panel – an Example
In order to do any useful work you’ll need to get past the canned scripts and
write one of your own. This section will attempt to help you work your way
through a simple example, that of using button 1 to turn a fader on on a surface.
As previously mentioned, the GUI ships with a decent help file. Even if you
don’t want to use all of the features at your disposal, you will need to actually
read a few of the help pages.
Since our chosen example involves sending a command to a surface, let’s
start by making sure the panel knows how to communicate with surface. But
before we can do anything, we need to make sure, in the case of multiple panels,
that we know which panel we are using. Select Device | Devices... to bring up
a list of panels the GUI is familiar with. If there is only one in the system, just
make sure that one is highlighted and press the Select button on the GP-16P
Devices form. If there are multiple entries, highlight the desired panel, then
press Select. Incidentally, this form is where you go to enter panels in the list
of known devices; the help file will explain how to do this. When you’re done
here, click Close to exit the form.
Now, let’s pretend the IP address of the surface we will control is
192.168.1.11. Select Device | Properties... to see the Device Properties form.
Surfaces should be highlighted in the left panel. In the box after Surface 1:
enter the IP address for the surface (this box will be grayed out if you are not
on line and connected to a panel). If you will be commanding other surfaces you
can enter their IP addresses now. When done, click OK. If you have changed
or added surfaces you will need to reboot the panel for the changes to take
effect.
A later section will show you how the other properties are used.
Now for the actual script. Select File | New... to discover the standard
Windows New File dialog box. Navigate to the desired directory where you
will store the script, then enter the name you have devised in the FileName: box
(I have chosen to use
MyScript.ss
for my example). If you fail to append
the
.ss
extension to the file name Windows will do that for you. Click Save
to create the file. A dialog box asks you if you would like to save you changes;
click Yes. Up pops the Script Wizard form. For the purposes of this script, just
click OK. But go ahead and delve into the Script Wizard when you get a
chance. It will make many things easier.
Now select View | Script Editor... If you’ve stayed with me this far the title
bar will say Script Editor: MyScript.ss. The top panel of the editor has a gray
background and contains text that has been generated for you by the Script
Generator. Code in that panel can’t be changed. You’ll enter your script in the
lower panel.
Carefully enter the following code in the lower panel. Enter everything
exactly as shown.