Siemens Industry Online Support
Siemens AG
Entry type: Application example Entry ID: 21402122, Entry date: 08/13/2014

Technology CPUs: Technology Template "Error Messages"

  • Entry
  • Associated product(s)

The Technology CPUs (CPU 31xT) signal if an error has occurred in the technology objects of the integrated technology. These errors are stated as ErrorIDs (hexadecimal codes) in the technology data blocks in the control section of the CPU. The errors are as well signalled at the outputs of the technology function blocks, also in the form of hexadecimal codes. The user must interpretate this codes by using the documentation.

For an easier analysis of the error codes, the technology template "Error Messages" offers two function blocks for error display. These function blocks are used to monitor the technology objects and the technology function calls in the user program. If an error occurs, they display the error in the form of a plain-text message.

The two blocks can be integrated simply by copying them into the user program. The display of errors as plain-text messages is realized with the help of text libraries, which are also included in the template. Each error code is assigned to a specific error message which is then transmitted to the STEP 7 message system via the system function ALARM_S (SFC 18) and displayed. In STEP 7 the text libraries can be edited, modified or extended with individual message texts according to requirements. The application example shows in the following three ways how to realize the message display:

  • In the SIMATIC Manager (STEP 7 Classic):
    For the message display the SIMATIC Manager provides the function "CPU Messages" which can be used without requiring any further configuration.
  • In WinCC flexible (STEP 7 Classic):
    In a STEP 7 Classic project with integrated WinCC flexible an operator panel (or WinCC flexible RT) is projected which includes an "Alarm View" to disply the CPU Messages.
  • In WinCC Comfort (TIA-Portal):
    In the TIA Portal an operater panel (e. g. Comfort Panel TP900) is projected which includes an "Alarm View" to disply the CPU Messages. The operator panel has a connection to a "Device Proxy" in the same project, which represents the T-CPU from the STEP 7 Classic project.


Content of Downloads


Documentation 21402122_CPU31xT_error_message_DOKU_v422_en.pdf ( 2647 KB )
STEP 7 Project (STEP 7 Classic)
Function blocks of the "Error Messages" template
21402122_CPU31xT_error_message_CODE_v422.zip ( 158 KB )
STEP 7 Project (STEP 7 Classic)
Sample project to the "Error Messages" template
(function blocks above included)

For the example a T-CPU and STEP 7 as from V5.4,
S7 Technology as from V4.1 and WinCC flexible 2008 are required. Due the examples use virtual axes, no drive is required.

21402122_CPU31xT_error_message_example_CODE_v422.zip ( 8139 KB )
STEP 7 Projekt (TIA-Portal)
Sample project with Comfort Panel and Proxy CPU to run an operator panel TP900 with a T-CPU.

For the example STEP 7 Professional V13 and WinCC Comfort V13 are required. The TP900 can be simulated in the TIA Portal.

21402122_CPU31xT_error_message_example_HMI_v422.zip ( 2444 KB )

Last Changes
Additional textlist to display userdefined axis designations with the error messages. HMI projecting in the TIA Portal by means of a Proxy CPU (e. g. when using Comfort Panels). Extended to S7 Technology V4.2.

Security information
In order to protect technical infrastructures, systems, machines and networks against cyber threats, it is necessary to implement – and continuously maintain – a holistic, state-of-the-art IT security concept. Siemens’ products and solutions constitute one element of such a concept. For more information about cyber security, please visit