4 programming, B3l−27 – Siemens CP 343-1 User Manual

Page 27

Advertising
background image

6 Configuring and Programming the CP as a PROFINET IO Device

B3L−27

CP 343-1 Lean for Industrial Ethernet / Manual Part B3L

Release 03/2007
C79000-G8976-C198-04

No further parameter assignment of the modules is necessary.

Note
By selecting suitable network components and setting the network properties

(Section 9.2) make sure that in PROFINET IO mode, the PROFINET line can be

operated without exception at 100 Mbps full duplex.

6.4

Programming

By programming, you specify the sequence of the user program for the CPU and
therefore also access to the I/O data.

To write and read process data, use the FCs PNIO_SEND (FC11) or PNIO_RECV
(FC12) from the SIMATIC NET block library in your user program.

How to use the existing functions (FCs) in your user program for PROFINET IO
device mode is described in the following sections of this chapter.

You will find an example matching the configuration described in the previous
chapter in Section 6.5.

6.4.1

Interface for Programming on the PROFINET IO Device

FCs

Two functions (FCs) are available for data exchange using the STEP 7 user
program:

S PNIO_SEND (FC11)

This FC reads the preprocessed process inputs of the CPU and transfers them

to the PROFINET IO controller (configured I addresses).
The preprocessed process inputs are available in a DB or bit memory area.

S PNIO_RECV (FC12)

The block accepts the data transferred by the PROFINET IO controller

(configured O addresses) and writes it to the data areas of the CPU reserved

for process outputs.

You will find the precise syntax of the FCs and the meaning of the block
parameters in the chapter on FCs in the general part of the manual or in the online
help for the block library in STEP 7.

Advertising