Virtual - Connector setup
Using the Virtual Connector
The Virtual connector is meant to be used primarily as a middleware connector and can be thought of as a data container.
Parameters
The Virtual Connector is meant to be as abstract and simple as possible and it doesn't have any extra parameters.
Use cases
-
As a container for different values
Multiple items values from different connectors could be grouped and listed into a single item in the Virtual connector.
This allows the flexibility to have only one common place where the formatting of the data happens (no need to modify values for each original item).
Then the value of the virtual item could be used in a mapping as master to be finally published to an MQTT broker / topic. -
Do calculations in post processing
The Post Processing functionality in an item field allows to re-format the read value of that item.
That value will be saved in the SIA database. Sometimes it might be desirable for this value to also be reflected on the physical Instance (eg. a PLC).
A virtual item could then read the original value, and apply some post-processing on it (e.g. a mathematical expression).
A mapping could then be created from this virtual item (acting as master) to a PLC (acting as slave) triggering a writing to it. -
As a converter
Read a value from an item on PLC1 (for example, the temperature in degrees Celsius). A virtual item then makes a conversion to Fahrenheit (using post-processing). This is then used in a mapping to write the converted value on PLC2, keeping the original value on PLC1's item. -
As a testing bed
Create a virtual item that is then used as master in a mapping. The slave side of a mapping can be a remote HTTP server or an MQTT broker.
Manually setting a value on the virtual item, will trigger on demand an HTTP request or publish a message on the other end.