×
Siemens Industry Online Support
Siemens AG
Entry type: FAQ Entry ID: 22407622, Entry date: 01/03/2006
(0)
Rate

How can you get the diagnostics buffer to be displayed in WinCC flexible?

  • Entry
  • Associated product(s)

Introduction:
In WinCC flexible it is not possible to have the S7 diagnostics buffer displayed via a function as in ProTool.
You can usually replace the function with the SFM function (system error messages).
If you nevertheless still need the S7 diagnostics buffer, then the procedure below demonstrates how you can do this via SFC51.
Using the SFC51 you can output the S7 message numbers and the time stamp on an operator panel.

Approach:
The diagnostics buffer is read out with SFC51 RDSYSST and stored in a data block in the CPU. The contents of the data block are displayed in a picture created with WinCC flexible.

Conditions:
This sample program was created with STEP 7 V5.3 + SP1 and WinCC flexible 2004 SP1 HF1.
The connection between the CPU and the PC (CP5611) is via the MPI interface.

Instructions:
Proceed as follows to have the diagnostics buffer of an S7-3XX CPU displayed in WinCC flexible:
 

No. Procedure
1 Load the SFC51_3X.zip file into your configuration computer. In the SIMATIC Manager you unpack the SFC51_3X.zip file and save the project.
The "SCF51_Diagnostics_buffer_300" project includes a program for a CPU S7 315-2DP and an MP370 Touch configuration (the program can also be run on other S7 CPUs).

Sfc51_3x.zip ( 3013 KB )  

2 Transfer the STEP 7 blocks:

Transfer the blocks OB1, FB1 and DB1 into the S7 controller. The SFC51 is already in the S7 controller.

3 Open the WinCC flexible configuration:

In the SIMATIC Manager you open the WinCC flexible configuration. (right-click and "Open Object" or via "Edit > Open object").

4 Transfer the WinCC flexible configuration:

Transfer the WinCC flexible configuration into the operator panel.
How to transfer a project is described in the relevant device manual.

5 Function description:


Fig. 01

When you first call the page there are no entries in the fields.
Press the "Update view" button to set a bit in the controller.
This bit calls the SFC51 in FB1 (read-out of an SSL parts list or excerpt of an SSL parts list).

The SFC51 reads out the diagnostics buffer and writes the data into a DB. This DB data is then displayed in the "Read S7 diagnostics buffer".

Using the "Page +" / "Page -" buttons you can scroll five diagnostics messages backwards and forwards.

Notes:

  • Only the message numbers and time stamp are output. (No message text).
  • The diagnostics buffer is not updated automatically. To update the data you must always press the "Update view" button.

Notes:

  1. The number of diagnostics messages that can be read out depends on the CPU used.
  2. The assignment of event numbers to the message texts is described in Entry ID: 1214574 .
  3. The parameters for SFC51 for the CPU S7-300 are described in Entry ID: 8861817 .
  4. The parameters for SFC51 for the CPU S7-400 are described in the "Context Help" in the SIMATIC Manager.

To display the diagnostics buffer of an S7-400 CPU in WinCC flexible you can proceed as described above.
The sample project is stored in the  SFC51_4X.zip file.

SFC51_4x.zip ( 3031 KB )