You can find a list of the most common commands inside of Visual Logic. [LIST=1]
- Create a Custom Panel
- Add a button to the custom panel
- Add a task to the custom panel
- Add a device to the task (green "+" icon on the left side of the page)
- Use the "Create Parameter" option for the IP Address
- Select "ok" and expand the "API" node in the tree.
Here is a basic example of a panel that can run a custom control or perform a transition on an ME:
<abs contexttype="opengear" style="">
<meta>
<lookup id="hosts">
<entry key="MyCarbonite.color">-1145302</entry>
<entry key="MyCarbonite.port">7788</entry>
<entry key="MyCarbonite.host">params.getValue('MyCarbonite_IPAddress', 0)</entry>
<entry key="MyCarbonite.scripthost">true</entry>
<entry key="MyCarbonite.devicetype">Carbonite</entry>
</lookup>
<params>
<param access="1" maxlength="0" name="MyCarbonite_IPAddress" oid="MyCarbonite_IPAddress" type="STRING" value="SWITCHER_IP_ADDRESS" widget="0"/>
</params>
</meta>
<button buttontype="push" height="228" left="17" name="<html><center>ME 1<br/>AUTO</center></html>" top="17" width="305">
<task tasktype="ogscript">/*! block id=1004 !*/
rosstalk.sendMessage(params.getValue('MyCarbonite_IPAddress', 0), 7788, "MEAUTO ME:" + 1);
/*!!
<block id="1004" type="MyCarbonite_carbonite_transition" x="10" y="100" w="243" MESRC="ME" MENUM="1" />
!!*/
/*!!<checksum>9641aec170b7ac6cdd2ee7db9b48b11d</checksum>!!*/</task>
</button>
<button buttontype="push" height="228" left="327" name="<html><center>Run Custom Control<br/>Bank 1<br/>CC 1</center></html>" top="10" width="305">
<task tasktype="ogscript">/*! block id=1005 !*/
rosstalk.sendMessage(params.getValue('MyCarbonite_IPAddress', 0), 7788, "CC " + 1 + ":" + 1);
/*!!
<block id="1005" type="MyCarbonite_carbonite_runCC" x="41" y="102" w="243" BANK="1" CC="1" />
!!*/
/*!!<checksum>b2aa5fb5f2c39ce13ff11c57accbed2c</checksum>!!*/</task>
</button>
<label height="45" left="20" name="Carbonite IP:" style="txt-align:east" top="259" width="201"/>
<param expand="true" height="55" left="226" oid="MyCarbonite_IPAddress" top="254" widget="3" width="383"/>
</abs>

#DashBoard