Virtual IO - Examples
From Zenitel Wiki
Virtual I/O is a feature for activating scripts on station events.
Contents
Scripts
The scripts mentioned in this article can be downloaded here.
The use of scripts contains three steps:
- First the user need to upload a script to the station. It is possible to download scripts by clicking on the name. Scripts are kept during upgrade. The uploaded scripts should clearly state in the start of the file which parameters that are needed .
- The script needs to be configured with some custom parameters and assigned to a script slot. The number of parameters and their content varies from script to script.
- Assign a logical name to the script
- Write which script to activate and add parameters (note that shell scripts don't need to be uploaded, it is possible to write the script direclty inside the text field).
- If it is a lua script then the syntax is:
- lua <scriptname> <parameter1> <parameter2> <parameter3> ...
- Shell scripts follow the same syntax, but starts with "sh":
- sh <scriptname> <parameter1> <parameter2> <parameter3> ...
- If it is a lua script then the syntax is:
- Finally the execution of a script has to be assigned to a station event. The same script can be assigned to multiple events.
Configuration examples
Controlling relays located in safe area
Sometimes due to security requirements it is not allowed to operate the door lock from the relay in the Turbine station outside the door.
Instead of operating the relay in the door station, one can use the "Virtual I/O" feature to control the relay of an I/O unit (e.g. TKIS unit) which is located in a secure area.
Upload the script
There are three different scripts for relay control:
- Relay ON
- Relay OFF
- Relay activation with timer controlled deactivation
Script configuration
RelayOn script requires 3 parameters:
- username (default: admin)
- password (default: alphaadmin)
- Turbine IP address
RelayOff script requires 3 parameters:
- username (default: admin)
- password (default: alphaadmin)
- Turbine IP address
RelayWithTimer script requires 4 parameters:
- username (default: admin)
- password (default: alphaadmin)
- Turbine IP address
- Timer (the number of seconds the relay shoud stay active)
Script Event assignement
After a script slot has been created the user can choose which event(s) which will start the script(s).
TruPortal Integration
By using Virtual I/O the Pulse system trigger a script that can control the door lock in a TruPortal system.
Upload the script
Script configuration
TruPortal script requires 4 parameters:
- username
- password
- TruPortal device IP address
- Door number to activate
Script Event assignement
After a script slot has been created the user can choose which event(s) which will start the script.
Milestone Integration
By using Virtual I/O the Pulse system trigger a script that can control the Milestone Video Management System. In this example we want to activate a camera when the Turbine station calls the reception. The camera should switch off when the conversation ends.
Upload the script
Script configuration
Milestone script requires 3 parameters:
- Milestone server IP address
- TCP port number
- "Text" to send (example "Cam105")
A second slot is needed to deactivate the camera. Same parameters with text changed to "CamOff".
- Milestone server IP address
- TCP port number
- "Text" to send (example "CamOff")
Script Event assignement
After a script slot has been created the user can choose which events which will start the script.