The call interface pnio_recv in the user program – Siemens CP 343-1 User Manual
Page 32
6 Configuring and Programming the CP as a PROFINET IO Device
B3L−32
CP 343-1 Lean for Industrial Ethernet / Manual Part B3L
Release 03/2007
C79000-G8976-C198-04
Transfer the O addresses to the process outputs (DB11) with PNIO_RECV
For the configured O addresses, you will need to make data areas available on the
PROFINET IO device, for example in a DB (in this example in a DB11) that
contains not only the process data but also the data areas for the IOPS status
information.
Figure 6-8
Data Structure for PNIO_RECV in the PROFINET IO Device
The call interface PNIO_RECV in the user program
STL
Explanation
call fc 12
CPLADDR:=
W#16#0100
LEN
:=
7
IOPS
:=
P#DB11.DBX7.0 BYTE 1
NDR
:=
M 74.0
ERROR
:=
M 74.1
STATUS :=
MW 76
CHECK_IOPS := M74.2
RECV
:=
P#DB11.DBX0.0 BYTE 7
ADD_INFO:=
MW 26
//PNIO_RECV block call
//(read outputs from IO controller)
//Module address from hardware configuration
//No. of log. O addresses to transfer in bytes
//Per receive data byte one status bit in DB11
//Address for return parameter NDR
//Address for return parameter ERROR
//Address for return parameter STATUS
//Address for return parameter CHECK_IOPS
//Received data in DB11 (7 bytes)
//Diagnostic information