Test_IO

Top  Previous  Next

Error-free configuration of the MPI/DP interface and the I/O

QUESTIONS:

How do you test the I/O using the S7-PLCSIM simulation program?

The I/O is configured automatically with CPU modules without DP connection (e.g. CPU314). When you plug a module into a PLC, then that module is recognized automatically by the CPU. This configuration cannot be simulated with a simulated automation system. If you load a program from an S7-300 CPU (which configures the I/O automatically) into S7-PLCSIM, the system data does not include an I/O configuration.

In practice, automatically configured S7-300 CPUs (CPUs without DP connection) behave in S7-PLCSIM in the same way as loading program blocks without system data. Also when programming non-existent I/O addresses the CPU does not go into the STOP state. The I/O is handled as if that arbitrary address were available.

All S7-300 CPUs with DP connection (like the CPU 315-2DP, for example) and all S7-400 CPUs handle the I/O in S7-PLCSIM as it is in reality. More information on this topic is also available in the Online Help for S7-PLCSIM under:

ยท "Modifying Your Hardware Configuration".

The following table explains how you can use S7-PLCSIM to test the I/O without any errors.

No.

Description

1

In order to test the I/O without any errors in a project with an S7-300 CPU without DP connection you must copy your program blocks into a project with an S7-300 CPU with DP connection (e.g. CPU 315-2DP). In the SIMATIC Manager you create a new STEP 7 project via "File > New ..." and in the next dialog you enter a project name and then save with OK.

2

Now in the SIMATIC Manager you mark the project name and finally insert an S7-300 station via "Insert > Station > SIMATIC 300 Station".

3

Open the hardware configuration and configure a CPU with DP connection, e.g. the CPU 315-2DP. Then save and compile the hardware configuration.

4

Now copy the blocks (OBs, FBs, FCs and DBs) from your old project into the newly created project with the CPU 315-2DP.

5

After loading the program blocks (including the system data blocks) into S7-PLCSIM the I/O is handled without errors.

Back to Questions