|
Devices compatible with TwinCAT PLC/IO
On this page:
TwinCAT supports Solution Import Tags (Reference) to setup automatically the mapping.
→ For more information go to Importing Tags from TwinCAT.
The TwinCAT communication driver is supported only in Windows Solutions. |
Stations syntax: <AmsNetID> ; <AmsSrvPort>
Where :
E.g.: 192.168.1.1.1.1; 801
The syntax for the TwinCAT communication points is:
<DeviceTagName>: Tag Name in PLC.
E.g.: .TAGNAME
The software platform supports two specific prefixes in the Address field in the DevicePoints table: TEMPLATE:
and DATE:
. The TEMPLATE:
prefix is used before the PLC address when the point references a DataTemplate or an array. The DATE:
prefix is used when the point represents a TwinCAT DATE
or DATE_AND_TIME
variable.
When working with arrays that contain DATE
or DATE_AND_TIME
types and are also part of a DataTemplate, both prefixes are combined in the following order:
TEMPLATE:DATE:<my_address>
In the RelativeAddress field of a DataTemplate, used for tag template expansion, only the DATE:
prefix is applied, without the TEMPLATE:
prefix.
If an array is not zero-indexed, the Address field in the DevicePoints table must include the array's starting index in brackets.
Example 1:
If the TwinCAT array is defined as intArray : ARRAY[2..5] OF INT
,
then the value in the Address column should be:TEMPLATE:intArray[2]
Example 2:
If the TwinCAT array is defined as intMatrix : ARRAY[2..5, 0..3, 4..7] OF INT
,
then the value in the Address column should be:TEMPLATE:intMatrix[2][0][4]
For zero-indexed arrays (e.g., ARRAY[0..N]
), it is not necessary to specify the initial index in the address. In those cases, you can simply use the array name (e.g., intArray
) in the Address column.
When defining a DataTemplate for a TwinCAT struct that includes an array with a non-zero starting index, the initial index must be specified in the RelativeAddress column of the corresponding DataTemplate member, following the same approach demonstrated in the examples above. The TwinCAT Tag Importer handles this automatically.
TwinCAT Revision History | |
---|---|
Version | Notes |
2.5.0.1 | Initial release on new documentation standards. |