Panel OPC address
As the first step in configuring an OPC peripheral address, OPCCLIENT should be chosen as driver type from the list of drivers in the peripheral address panel.
Click the Configure... button go to the setting of the peripheral address for the data point element:
Address active
If the option Address active is selected, the address is used by the driver (see Reference tables).
If an inactive address exists, the attributes can be set or get, but the driver does not use these. That means for this data point you cannot send any values to the PLC or receive from the PLC.
Server
Editable; list with available servers. The symbolic name as it was entered in the config file is displayed here. It should be chosen as the first part of the peripheral address.
Group
Editable; list with the available groups. A click on the Edit group button next to the list brings you to the configuration panel for the selected group (see Panel OPC group).
Item
The fully qualified itemId must be entered here. If the server supports address browsing, the items available in the server are displayed in the combo box after the server name is selected.
The items are read from server only with the first display of the panel. Afterwards the items are read from the data point. The list can be updated with the Get item IDs button (from server). A childpanel opens, which shows the items listed in a TreeView (see also Panel OPC server).
The peripheral address is composed from the three entries under Server, Group and Item; "$" is used as a separator:
Server$Group$Item
It must be considered that the individual parts of the address may each only be 100 characters in length. This also applies when creating the internal data points for the groups and the servers. ItemID may similarly not contain more than 100 characters. Keep this restriction in mind when configuring the server.
A click on OK or Apply causes the peripheral address to be configured on the data point.
The fields Server, Group and Item must not be empty, otherwise an error message is displayed while configuring the peripheral address on a data point element.
Trans. type
The setting allows to adjust the transformation used to the data format required by the server. Below you find a mapping of the selectable transformations and their OPC server VARIANT data type counterparts.
Name in list box | Data type requested by OPC server |
---|---|
uchar | VT_UI1 |
integer16 | VT_I2 |
uinteger16 | VT_UI2 |
integer32 | VT_I4 |
uinteger32 | VT_UI4 |
integer64 | VT_I8 |
uinteger64 | VT_UI8 |
float32 | VT_R4 |
float64 | VT_R8 |
boolean | VT_BOOL |
string | VT_BSTR |
time | VT_DATE |
bitstring | VT_UI4 |
If the transformation type "default" is selected, the conversion of the format is executed automatically, depending on the DPE type. In this case following transformations are used for the data point element types:
Data Point Element Type | Used conversion |
---|---|
DPELEMENT_CHAR DPELEMENT_DYNCHAR |
uchar |
DPELEMENT_INT DPELEMENT_DYNINT |
integer32 |
DPELEMENT_UINT DPELEMENT_DYNUINT DPELEMENT_32BIT DPELEMENT_DYN32BIT |
uinteger32 |
DPELEMENT_LONG | integer64 |
DPELEMENT_ULONG DPELEMENT_DYNULONG DPELEMENT_64BIT DPELEMENT_DYN64BIT |
uinteger64 |
DPELEMENT_FLOAT DPELEMENT_DYNFLOAT |
float64 |
DPELEMENT_BIT DPELEMENT_DYNBIT |
boolean |
DPELEMENT_TEXT DPELEMENT_DYNTEXT |
string |
DPELEMENT_TIME DPELEMENT_DYNTIME |
time |
When using dyn_* data point elements an array of the mapped data types is used for the transformation.
You have to select a data type. Select either a specific data type or the "Default" option. If you do not select a type, the following error message is shown:
N/A, Error message: got invalid Transformationtype for...".
The low level old/new comparison must be deactivated when string transformations and arrays are mapped on dyn... variables.
Transfer of bitstrings
It is possible to split an OPC item (integer resp. uinteger) to single Bit-DPEs in WinCC OA. For this case you have to set a peripheral address with transformation "bitstring" and define a subindex for each bool DPE. The subindex n means the bit number n.
e.g. For single array_bool[num] num = 0...31 select the transformation bitstring with different subindex: 0,1,10,30,31, the server send an integer: 0,1,1024,1025, 2^30 and 2^31 -> the bit are correctly set on the client side (value and time).
The entry selected here is not entirely independent of the server, since the server cannot convert every chosen format into any other format as wished. In the best case a loss of data occurs (from rounding or truncation of the places after the decimal point), and in the worst case no data arrives at all.
Direction in/out
Specifies the direction. If an item is writable in the OPC server, it is configured in WinCC OA as out (individual). If it is readable, it is configured as in(put). If it is writable and readable, it is configured as in/out(put). The option Out (Group) can be selected for the transformation type bitstring and it is converted into UINT.
-
The direction is set automatically when the server name is accepted. The combo box becomes inactive.
-
If the server supplies no information about the items, the item must be entered and the direction must be manually selected.
Readback
"Readback" is a feature to make the IOTransitionTimeout compatible with the OPC update mechanism:
When an I/O address is written, the driver waits for a value for this address from the periphery for IOTransitionTimeout seconds. If no value arrives within this time the driver concludes that the write did not succeed.
OPC Servers on the other hand do not immediately reply to a value but only after update rate Milliseconds. So if IOTransition timeout is smaller than update rate, there will be no callback and the driver assumes that the IOTransaction did not succeed. (Although it may have gone well.)
To prevent this situation the OPC Driver starts a read operation immediately after the write to read the value back (hence "readback") from the periphery. The readback functionality can be deactivated using the ioReadBack = "no" entry. The entry is set in the [opc] section. The default value is "yes".
Low Level old/new comparison
Enables/disables the ComDrv Low Level comparison. In contrast to the dead band smoothing for the group, which relates to all items in the group, the Low Level comparison concerns the data point element / the item. Thus for example in a group that does no dead band smoothing, one or more items can still be smoothed.
If the low level old/new comparison shall consider some specific userbits (for opc quality changes), you have to set the respective smoothBit config entries. E.g.:
smoothBit = "Userbit 1"
smoothBit = "Userbit 2"
Driver number
The allocation to a driver occurs here. The number given here must be equal to the command line option with which the driver was started.
Example
If the driver to which the peripheral address is to be allocated was started with
WCCOAopc -num 2
then 2 must be entered here.
OK
With this button, the changes are accepted and the panel closed.
Cancel
With this button, the changes are cancelled and the panel closed.
Apply
With this button the changes are accepted, but the panel is not closed.