BECKHOFF Data Access
The BECKHOFF Control drives is capable to access all PLC variables. This chapter outlines the possibilities or accessing these data points and how to configure them.
DataTypes
Following data types are fully supported (read and event callbacks):
DataType | HumanOS System Data Type | TwinCAT Data Type |
---|---|---|
Boolean Value | System.Boolean | BOOL |
8bit unsigned integer | System.Byte | BYTE |
8bit unsigned integer | System.UInt8 | USINT |
16bit unsigned integer | System.UInt16 | WORD , UINT |
32bit unsigned integer | System.UInt32 | UDINT |
64bit unsigned integer | System.UInt64 | ULINT |
8bit signed integer | System.Int8 | SINT |
16bit signed integer | System.Int16 | INT |
32bit signed integer | System.Int32 | DINT |
64bit signed integer | System.Int64 | LINT |
32bit floating point | System.Single | REAL |
64bit floating point | System.Double | LREAL |
String values | System.String | STRING |
Boolean Array | System.Boolean[] | ARRAY [0..N] OF BOOL |
8bit unsigned integer Array | System.Byte[] | ARRAY [0..N] OF BYTE |
8bit unsigned integer Array | System.UInt8[] | ARRAY [0..N] OF USINT |
16bit unsigned integer Array | System.UInt16[] | ARRAY [0..N] OF WORD, UINT |
32bit unsigned integer Array | System.UInt32[] | ARRAY [0..N] OF UDINT |
64bit unsigned integer Array | System.UInt64[] | ARRAY [0..N] OF ULINT |
8bit signed integer Array | System.Int8[] | ARRAY [0..N] OF SINT |
16bit signed integer Array | System.Int16[] | ARRAY [0..N] OF INT |
32bit signed integer Array | System.Int32[] | ARRAY [0..N] OF DINT |
64bit signed integer Array | System.Int64[] | ARRAY [0..N] OF LINT |
32bit floating point Array | System.Single[] | ARRAY [0..N] OF REAL |
64bit floating point Array | System.Double[] | ARRAY [0..N] OF LREAL |
String values Array | System.String[] | ARRAY [0..N] OF STRING |
Writing is also possible, although not all memory ranges are supported.
Address
The native address of a data access point is the absolute variable name.
Example
PROGRAM PRG_Test
VAR
Int32Value : DINT;
END_VAR
{
"Id": "93DEE416-DF8C-4F89-8BCE-EB21EF4963A9",
"Name": "Int32Value",
"DataClass": "Event",
"DataType": "System.Int32",
"Address": "PRG_Test.Int32Value ",
"Access": {
"Read": true,
"Receive": true
}
}