Page 85
PROFINET, Documentation
optoNCDT 1900 / Profinet
8.6.5.3
Record Float Parameter 0x2510, Examples
Via this record float parameters of the sensor can be read and written. First, use the header to write the parameter ID to the record via
subindex 1. Then you can write the float value to subindex 3 or read the complete record starting from subindex 0. The written param-
eter ID remains stored in the record. Restarting the sensor resets the parameter ID to the default parameter ID.
Subindex
Access
Data type
Name
0
Read
UINT8
Subindex 0
1
Read/Write
UINT16
Parameter ID
2
Read/Write
UINT8
Reserved
3
Read/Write
FLOAT
Float value
4
Read
STRING(14)
Name of the parameter
5
Read
STRING(8)
Unit of the parameter
6
Read
FLOAT
Reserved
7
Read
FLOAT
Reserved
Fig. 42 Float parameter record 0x2510
Example: Writing parameter ID in TIA Portal
In the header, set the subindex to 1.
Set the write length to 2 because the
parameter ID is 2 bytes in size.
WRREC_DB
REQ :=
ID :=
INDEX :=
LEN :=
DONE =>
BUSY =>
ERROR =>
STATUS =>
RECORD :=
Status/Result Output
Enable-Flag
HW-ID
Object Index
8Byte + Data Length
10
0x2510
273
1
0
0 0 0x01 0 0x02
0x3A
0xC7
Write-Header (8 Byte)
Reserved Reserved
Subindex
Reserved
Data length
(UINT32-LE)
ParamID 51002
PARAMID: 51002
0 0 0
This is followed by 2 bytes of user data
of the parameter ID you want to write.
You can also write multiple subindexes at
once by writing beyond the length of the
subobject.