Short description
Access to parameters of the ctrlX AUTOMATION device via PROFINET IO acyclic read/write record services
Siemens standard function block RDREC and WRREC
Functional description
- Required RunTime AXS 0316 or newer
- Mapping of (E)IDN parameters (16)32Bit addressing to PROFINET IO acyclic read/write record services 16Bit addressing
- Addressing PROFINET IO
The PROFINET IO acyclic read/write record services have the addressing scheme slot, subslot, index. The submodule is selected via slot and subslot, which establishes the relationship to the axis/instance.
In order to prevent parallel accesses, only the always existing submodule in subslot 1 can be accessed.
The entire record is always written, an offset function is not possible for read or write.
- Mapping/Alias
A shortened IDN is used for access.
The IDN is shortened to 13 bits and corresponds to the mapping area reserved above.Thus all EIDNs the SI=SE=0 are reachable.For access to 32-bit addressing EIDNs, the list parameters P-0-2301 are used as IDN and P-0-2300 as EIDN with the same index as alias.
TIA Engineering Software
- Addressing PROFINET IO submodul to function bloc RDREC (Siemens)
- Axis1 first Parameter HWio submodul number Input or Output, to read/write parameters from the first Axis.
- Axis2 first Parameter HWio submodul number Input or Output, to read/write parameters from the second Axis
- Examples Mapping Parameter
- P-0-1234 -- dez 1234 = 0x04D2 hex plus hex 1000 for P parameter --> 0x14D2
- S-0-0037 -- dez 37 = 0x0025 hex --> 0x0025
0x14D2
P-0-1234
S-0-1050.2.160
S-0-1050.2.160 reachable via P-0-1234
Â
Supported data lengths
PROFINET IO supports data lengths via the acyclic read/write record services up to 64k bytes.
Up to 5k bytes (5120 bytes) per request are possible via acyclic mapping/aliasing. Therefore, list parameters longer than 5k bytes cannot be accessed through this service. In the case of such access, an error 0xDE80B003 (ReadResponse.PNIORW.InvalidIndex.MappedParameterToLarge) is sent during reading. In case of a write attempt with more than 5k bytes of data, a 0xDF80B102 (WriteResponse.PNIORW.WriteLengthError.LengthToLarge) is sent and the entire write process is not executed internally.
Hint MLEN function bloc RDREC
List parameters
When accessing list parameters, the list header is generated in the communication layer so that it is not transmitted via the PROFINET IO acyclic record.
During a read access, the header is removed from the user data, the information about the maximum length is therefore not transmitted. In a write access, the header is generated from the length of the transmitted payload and the maximum length is not adjusted.
Endianess
The transported data is transferred in the native format of the ctrlX device (little endian) and not adapted to the PROFINET IO (big endian). Thus, the data structure must be taken into account by the user when interpreting/generating the data.
Conversion
All parameters containing ID number lists are converted accordingly to 16-bit IDNs, replaced by the corresponding alias parameter.
Error handling
Errors when accessing the parameters are reported accordingly to the PROFINET IO read/write record response.
Parameters can only be written with the total length, a partial writing is rejected with an error. List parameters contain the length information during data transmission, thus also a length check/ change is secured.
Parameters can be read with a partial length. If a read record request with a greater length than the parameter is requested, the entire parameter is transmitted and the length is shortened accordingly.
PROFINET IO status code
Format: 32bit unsigned integer
Error List
Bits
Worth
Definition
Meaning
31 - 24
0xDE
Norm
Read Response
Â
0xDF
Norm
Write Response
23 - 16
0x80
Norm
PNIORW
15 - 08
0xB0
Norm
Invalid Index details see Bits 0-7
Â
0xB1
Norm
Write Length Error - detail see Bits 0-7
Â
0xB6
Norm
Access Denied - Parameter is read only
07 - 00
0x01
Manufacturer-specific
Not in Supported Range 0x0000-0x1FFF (Invalid Index)
Â
0x02
Manufacturer-specific
Parameter not available (Invalid Index)
Â
0x03
Manufacturer-specific
Mapped parameters to large (>5k bytes)
Â
0x01
Manufacturer-specific
Length to small (Write Length Error)
Â
0x02
Manufacturer-specific
Length to large (Write Length Error)
Â
0x03
Manufacturer-specific
Value to small (Write Length Error)
Â
0x04
Manufacturer-specific
Value to large (Write Length Error)
Â