Machine and plant diagnostics with ProDiag TIA Portal, SIMATIC S7-1500 CPU https://support.industry.siemens.com/cs/ww/en/view/109740151 Siemens Industry Online Support Legal information Legal information Use of application examples Application examples illustrate the solution of automation tasks through an interaction of several components in the form of text, graphics and/or software modules. The application examples are a free service by Siemens AG and/or a subsidiary of Siemens AG ("Siemens"). They are non-binding and make no claim to completeness or functionality regarding configuration and equipment. The application examples merely offer help with typical tasks; they do not constitute customer-specific solutions. You yourself are responsible for the proper and safe operation of the products in accordance with applicable regulations and must also check the function of the respective application example and customize it for your system. Siemens grants you the non-exclusive, non-sublicensable and non-transferable right to have the application examples used by technically trained personnel. Any change to the application examples is your responsibility. Sharing the application examples with third parties or copying the application examples or excerpts thereof is permitted only in combination with your own products. The application examples are not required to undergo the customary tests and quality inspections of a chargeable product; they may have functional and performance defects as well as errors. It is your responsibility to use them in such a manner that any malfunctions that may occur do not result in property damage or injury to persons. © Siemens AG 2022 All rights reserved Disclaimer of liability Siemens shall not assume any liability, for any legal reason whatsoever, including, without limitation, liability for the usability, availability, completeness and freedom from defects of the application examples as well as for related information, configuration and performance data and any damage caused thereby. This shall not apply in cases of mandatory liability, for example under the German Product Liability Act, or in cases of intent, gross negligence, or culpable loss of life, bodily injury or damage to health, non-compliance with a guarantee, fraudulent non-disclosure of a defect, or culpable breach of material contractual obligations. Claims for damages arising from a breach of material contractual obligations shall however be limited to the foreseeable damage typical of the type of agreement, unless liability arises from intent or gross negligence or is based on loss of life, bodily injury or damage to health. The foregoing provisions do not imply any change in the burden of proof to your detriment. You shall indemnify Siemens against existing or future claims of third parties in this connection except where Siemens is mandatorily liable. By using the application examples you acknowledge that Siemens cannot be held liable for any damage beyond the liability provisions described. Other information Siemens reserves the right to make changes to the application examples at any time without notice. In case of discrepancies between the suggestions in the application examples and other Siemens publications such as catalogs, the content of the other documentation shall have precedence. The Siemens terms of use (https://support.industry.siemens.com) shall also apply. Security information Siemens provides products and solutions with Industrial Security functions that support the secure operation of plants, systems, machines and networks. In order to protect plants, systems, machines and networks against cyber threats, it is necessary to implement – and continuously maintain – a holistic, state-of-the-art industrial security concept. Siemens’ products and solutions constitute one element of such a concept. Customers are responsible for preventing unauthorized access to their plants, systems, machines and networks. Such systems, machines and components should only be connected to an enterprise network or the Internet if and to the extent such a connection is necessary and only when appropriate security measures (e.g. firewalls and/or network segmentation) are in place. For additional information on industrial security measures that may be implemented, please visit https://www.siemens.com/industrialsecurity. Siemens’ products and solutions undergo continuous development to make them more secure. Siemens strongly recommends that product updates are applied as soon as they are available and that the latest product versions are used. Use of product versions that are no longer supported, and failure to apply the latest updates may increase customer’s exposure to cyber threats. To stay informed about product updates, subscribe to the Siemens Industrial Security RSS Feed at: https://www.siemens.com/cert. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 2 Table of contents Table of contents Legal information .............................................................................................................................. 2 1 2 Introduction ............................................................................................................................. 4 1.1 Overview .................................................................................................................... 4 1.2 Principle of operation ................................................................................................. 5 1.3 Components used...................................................................................................... 7 Engineering ............................................................................................................................. 8 2.1 Hardware setup ......................................................................................................... 8 © Siemens AG 2022 All rights reserved 2.2 Configuration ............................................................................................................. 8 2.2.1 Create ProDiag function blocks ................................................................................. 8 2.2.2 Define supervision settings on the ProDiag FB .......................................................10 2.2.3 SIMATIC ProDiag supervision icons as of TIA Portal V17 ......................................11 2.2.4 Create global supervisions ......................................................................................12 2.2.4.1 Operand supervisions ..............................................................................................12 2.2.4.2 Position supervisions ...............................................................................................13 2.2.5 Create local supervisions ........................................................................................14 2.2.5.1 Action supervisions ..................................................................................................15 2.2.5.2 Reaction supervisions .............................................................................................16 2.2.6 Create supervisions on PLC data type ....................................................................17 2.2.7 Instancing PLC data type supervisions ...................................................................18 2.2.8 Assign ProDiag FB to the instance data block of an FB .........................................19 2.2.9 Poll error bits in the program ...................................................................................20 2.2.10 Multiple selection for defining supervisions .............................................................21 2.2.11 Create supervisions in the GRAPH sequence chain ...............................................22 2.2.11.1 Interlock ...................................................................................................................22 2.2.11.2 Supervision ..............................................................................................................23 2.2.12 Configure multilingual names in S7 GRAPH ...........................................................24 2.2.13 Setting initial value acquisition of the GRAPH sequence chain ..............................25 2.2.14 Reset initial values at GRAPH FB ...........................................................................26 2.2.15 Setting parameters of the GRAPH sequence chain ................................................28 2.2.16 Define ProDiag supervision settings........................................................................28 2.2.17 Sample supervision type error message with accompanying value ........................31 2.2.17.1 Specific text field: Enter accompanying values via context menu (text list name) .......................................................................................................................32 2.2.17.2 Specific text field: Enter accompanying values via context menu (text list ID) .......34 2.2.17.3 Specific text field: Enter associated value without context menu ............................36 2.2.18 Configure identical time stamps ..............................................................................37 2.2.19 Export/import supervision settings for ProDiag and S7 GRAPH .............................39 2.2.20 Export and import ProDiag supervisions and properties of a ProDiag FB ..............40 2.3 3 Download project .....................................................................................................41 Appendix ................................................................................................................................42 3.1 Service and support .................................................................................................42 3.2 Industry Mall ............................................................................................................43 3.3 Links and literature ..................................................................................................43 3.4 Change documentation ...........................................................................................43 Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 3 1 Introduction 1 Introduction 1.1 Overview Starting in the TIA Portal Version V14, you have the option of supervising your machine or plant using the ProDiag functionality and intervening in case of a fault. The supervision alarms that you can create for different kinds of faults give you specific information on the supervision type, on the location and cause of the fault. You can also output notes on the removal of the determined faults. This means you cannot only detect faults, but you can also identify a possible risk of error in advance and take appropriate countermeasures. This application example demonstrates a fictional conveyor belt system with two lifts, realized in WinCC V8. The belt transports crates to each of the two lifts in alternation, where they are then stacked up. The conveyor belt system is controlled with an operator device (HMI) and monitored with ProDiag. The various supervisions can be simulated on the operator device, as well as displayed. © Siemens AG 2022 All rights reserved Figure 1-1: System overview This application example describes the following aspects: • Configuration of machinery and plant supervision with ProDiag. • Various supervision types. • Diagnostics of supervision errors on the operator device. Advantage The supervisions are not programmed with ProDiag, only configured. In this way, you can monitor your machine and your plant without modifying the code of the user program. You can diagnose machines and plants right at the operator device without a programming device. Automatic synchronization keeps all displays on the operator device continuously up-to-date. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 4 1 Introduction 1.2 Principle of operation User program The sequence for the fictional conveyor belt system and the simulation thereof are programmed within the user program (WinCC V8). The program was created with the goal of displaying as many properties of the machine and plant diagnostics as possible. This example considers the user program as a given, so it will not be described in more detail. Monitoring with ProDiag ProDiag lets you create global and local supervisions. You can configure global supervisions on Boolean tags inside a tag table, a global data block or an ARRAY data block. Local supervisions can be configured on Boolean parameters of a function block. The user program is thus left unchanged. ProDiag provides various types of supervision. They are listed together with applications in the Table below. Table 1-1: Supervision types with ProDiag © Siemens AG 2022 All rights reserved Supervision type Application in the example Tag/parameter Operand supervision Monitors the compressed air and the power supply when the conveyor belt system is switched on. SeqData [DB15] "SeqData".compressedAir "SeqData".powerVoltage Interlock supervision Monitors whether the interlock conditions (e.g. lift door closed) are met for the motion of the lift unit. LiftCmd [FB190] #interlockAuto #interlockMan Action supervision Monitors whether the lift unit has left its starting position within a specified time. LiftCmd [FB190] #sensorLiftUp #sensorLiftDown Reaction supervision Monitors whether the lift unit has reached its end position within a specified time. LiftCmd [FB190] #sensorLiftUp #sensorLiftDown Position supervision Monitors whether a crate is removed from a certain position on the belt when the conveyor belt system is switched off. SeqData [DB15] "SeqData".newCase "SeqData".sensorStop1 "SeqData".sensorStop2 "SeqData".sensorStop3 Error message Issues a text-based message if the specified frequency has been selected too low or high. The corresponding text from a text list will be displayed based on the status. "SeqData".freqError Operand supervision in PLC data type Monitors whether a lift is being directed in both directions simultaneously. typeStartLift • startLiftUp • startLiftDown In order to execute / turn on supervisions, you need to assign them to ProDiag FBs. You can create ProDiag function blocks in the "PRODIAG (incl.IDB)" language using the "Add new block" dialog. The ProDiag function block will be automatically called in the ProDiag organization block. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 5 1 Introduction Note A maximum of 100 ProDiag FBs can be used in one project. As of V2.0, you can assign up to 1000 supervisions to one ProDiag FB, allowing for greater ease of design from a technical standpoint. In smaller plants without a plant hierarchy, you can combine all supervisions in a single ProDiag monitoring block. Monitoring with GRAPH With the GRAPH programming language, supervisions have already been integrated within each individual step. GRAPH provides two different supervision types. They are listed together with applications in the Table below. Table 1-2: Supervision types with GRAPH © Siemens AG 2022 All rights reserved Supervision type Application in the example Interlock You can use an Interlock to program conditions which determine the execution of individual actions. Actions of a step that are linked with the Interlock will only be executed when the interlock condition is met. If the interlock condition is not met, there will be an error. You can create messages that will appear if this is the case. However, the error has no effect on the transition to the next step. In this example, we monitor for whether the door of the lift unit is closed and the lift unit is free. Supervision A Supervision lets you program conditions with which you can monitor an entire step. If the condition is met, an error will be pending and the step remains active. That means that the sequence chain will not switch to the next step. In this example, we monitor only the steps in which the lift units are in motion. If the motion has not been completed within a specified time (step duration exceeded), then a message will be issued and the step will remain active. Unlike with an Interlock, the Supervision must be acknowledged. Display in the runtime The errors that occur in the fictional conveyor belt system are displayed and diagnosed in the runtime. WinCC V8 provides various objects for this purpose. The Table below lists the objects. Table 1-3: WinCC objects for displaying supervision errors WinCC object Application in the example ProDiag overview The "ProDiag overview" object shows the current status of the configured supervisions. If an error occurs, the error type and the error category will be displayed. You can open the "Alarm view" with the integrated button. GRAPH overview The "GRAPH overview" object displays the following: • The current status. • The current step number. • The name of the step in the GRAPH sequence chain "LiftSeq". • Previous and next step. In case of an error in the sequence, the affected step will be displayed. You can open the "Alarm view" or the "PLC code view" with the buttons. Alarm view The ProDiag messages are displayed in the "Alarm view". You can open the "PLC code view" for the selected message by clicking the button. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 6 1 Introduction WinCC object 1.3 Application in the example PLC code view The "PLC code view" object shows the current program status of the selected ProDiag message or the GRAPH sequence chain "LiftSeq". The object supports the programming languages LAD, FDP and GRAPH. The PLC code view is possible for the following supervision alarms: • With global supervisions, only for Interlocks. • With local supervisions, for all base supervisions on input parameters. Program changes are automatically detected and updated. Criteria analysis display The "Criteria analysis display" object shows you the operands in the user program that have errors when these errors triggered a selected ProDiag or GRAPH message. Components used The following hardware and software components were used to create this Application Example: © Siemens AG 2022 All rights reserved Table 1-4 Component Quantity Item number Note CPU 1516F-3 PN/DP 1 6ES7516-3FN01-0AB0 Alternatively, any other CPU from the S7-1500 product family can be used. Memory card, 24 MB 1 6ES7954-8LF02-0AA0 - STEP 7 Professional V18 1 6ES7822-1..08-.. - WinCC V8 1 6AV6371-1..08-.. - The listed components can be obtained from the Siemens Industry Mall, for example. This application example consists of the following components: Table 1-5 Component File name Note Documentation PLC 109740151_ProDiag_PLC_DOC_V60_en.pdf - Documentation WinCC V8 109740151_ProDiag_WinCCV8_DOC_V60_en.pdf - PLC Project 109740151_ProDiag_PLC_PROJ_V60.zip - WinCC V8 Project 109740151_ProDiag_WinCCV8_PROJ_V60.zip - Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 7 2 Engineering 2 Engineering 2.1 Hardware setup The following Figure shows the hardware setup of the application. Figure 2-1: Hardware setup SIMATIC CPU 1516 SIMATIC WinCC PN PN DP © Siemens AG 2022 All rights reserved Note The installation guidelines for the devices must be observed. 2.2 Configuration 2.2.1 Create ProDiag function blocks A ProDiag FB is created in the PRODIAG programming language, for example with the "Add new block" dialog. Follow the steps below: 1. Double-click in the "Program blocks" folder on the command "Add new block". The "Add new block" dialog opens. 2. Click the "function block" button. 3. Give the new ProDiag FB the name "LiftProDiagFB". 4. In this section, select "Language > PRODIAG (incl. IDB)". 5. To enter more properties of the new ProDiag function block, click "Additional information". An area with further input fields is displayed. 6. Enter the desired properties. 7. Tick the box for "Add new and open" if you wish to open the ProDiag function block right away. 8. Confirm your entries with "OK". Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 8 2 Engineering © Siemens AG 2022 All rights reserved Figure 2-2: "Add new block" dialog Alternatively, you can also create ProDiag FBs in the following manner: Note • When creating a global supervision, the ProDiag FB is created automatically. No user action is required for this. • When calling an FB with local supervision. • On the instance data block of an FB. • In the ProDiag overview table. You can structure your monitoring to match the machinery and plant units by creating a ProDiag FB for each unit. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 9 2 Engineering 2.2.2 Define supervision settings on the ProDiag FB Global enabler You can use the global enabler to control the call of the ProDiag FB in the ProDiag OB. The global enabler must be a global Boolean tag. The ProDiag FB is only called if this tag has the signal state "TRUE". This gives you granular control over the shutdown of all supervisions of the ProDiag FB, for example. Define a global enabler as follows: 1. Right-click on the ProDiag FB "LiftProDiagFB" and select "Properties..." from the context menu. The Properties dialog box of the ProDiag FB will open. 2. In the "General" tab, click on "Supervision settings". 3. Specify the global Boolean tag "SeqData".globalEnabler as the global enabler. (The application example does not use the global enabler.) © Siemens AG 2022 All rights reserved Figure 2-3: "Global enabler" dialog Note You can also use the global enabler to prevent a message flood, for example. Category enabler Using the category enabler, you can activate and deactivate the supervisions for each individual category of the ProDiag FB. You will configure a category enabler in accordance with the global enabler. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 10 2 Engineering 2.2.3 SIMATIC ProDiag supervision icons as of TIA Portal V17 SIMATIC ProDiag uses various supervision icons. These supervision icons tell you at a glance which supervision you are looking at. The round icons indicate instantiated supervisions. The square icons indicate supervision definitions. Table 2-1: SIMATIC ProDiag supervision icons Icon Meaning This icon indicates a global supervision instance that was created directly in a tag table or in a global DB. This icon shows you instantiated type supervisions of PLC data types or function blocks. This icon indicates that a type definition for a supervision was created directly in the block interface of a function block or in a PLC data type. © Siemens AG 2022 All rights reserved This icon shows you inherited supervisions from PLC data types and function blocks (multiinstances). Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 11 2 Engineering 2.2.4 Create global supervisions In the application example, global supervisions are created on Boolean tags in the global data block "SeqData". 2.2.4.1 Operand supervisions When the conveyor belt system is switched on, the compressed air supply must be ready for operation. Otherwise, a supervision alarm in the "Error" category will be issued. In the application example, the compressed air is monitored with the "SeqData".compressedAir tag. Proceed as follows to create the operand supervision: 1. Open the global DB "SeqData". 2. Right-click the tag "SeqData".compressedAir and then click "Add new supervision". 3. Select "Operand" as the "Type of supervision". 4. In the event of an error, the monitored tag will have the state "False". 5. Set a "Delay time", e.g. 0 ms. 6. For "Condition 1", select the tag "SeqData".plantOn (conveyor belt system is switched on). Tick the "True" checkbox for the condition trigger. If needed, you can add up to three conditions. © Siemens AG 2022 All rights reserved 7. Select "Error" as the "Category". 8. Select the ProDiag FB "LiftProDiagFB" that was created earlier. You can also create a new ProDiag FB. An "Error flag" will be automatically created in the instance data block of the ProDiag FB for the supervision. The error flag indicates whether an error has occurred. You can query this error flag in your program, for example to switch off the machine in the event of certain errors. 9. Under "Specific text field", enter the text "Compressed air not OK". For another input sample, see: Example for the Error message supervision type Figure 2-4: Operand supervision The supervision for the power supply, "SeqData".powerVoltage, is created in the same way as the compressed air supervision. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 12 2 Engineering 2.2.4.2 Position supervisions When the conveyor belt system is at a standstill, it monitors whether a crate is removed from the first position. If a crate is missing, a supervision alarm in the "Warning" category is issued. In the application example, the tag "SeqData".newCase (sensor, crate present) is monitored for this purpose. Proceed as follows to create the position supervisions: 1. Right-click the tag "SeqData".newCase and then click "Add new supervision". 2. Select "Position" as the "Type of supervision". 3. In the event of an error, the monitored tag will have the state "False". 4. Set a "Delay time", e.g. 0 ms. 5. The conveyor belt system must be at rest. As the "Condition", select the tags "SeqData".autoStarted (automatic operation started) and "SeqData".autoStopped (automatic operation stopped). Tick the "False" checkbox for both for the trigger condition. The tag "SeqData".stateCase[0] (status: crate present) must also be set. Tick the "True" checkbox for the condition trigger. © Siemens AG 2022 All rights reserved 6. Select "Warning" as the "Category". 7. Select the ProDiag FB "LiftProDiagFB" that was created earlier. You can also create a new ProDiag FB. An "Error flag" will be automatically created in the instance data block of the ProDiag FB for the supervision. The error flag indicates whether an error has occurred. You can query this error flag in your program, for example to switch off the machine in the event of certain errors. 8. Under "Specific text field", enter the text "Case at entrance missing". Figure 2-5: Position supervision The position supervision is carried out on the following stoppers in line with the position supervision on "SeqData".newCase. • "SeqData".sensorStop1 • "SeqData".sensorStop2 • "SeqData".sensorStop3 Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 13 2 Engineering 2.2.5 Create local supervisions Local supervisions are created at the Boolean input parameters of the function block "LiftCmd". The FB controls the outputs of a lift unit; it is called twice in the program. Thus, you only need to configure the supervisions once. You can use them for both lift units. Interlock supervisions The outputs of the lift unit may only be set if the door of the lift unit is closed. Interlock supervision monitors whether the enable signals required for the "Move lift unit upward" motion are present and/or whether the door is closed. The enable signals are issued to the FB parameter #interLockAuto (automatic interlock) when the "LiftCmd" FB is called. If the enable signals are not all present, a supervision alarm of the "Error" category will be issued. In the application example, the FB parameter #interLockAuto is monitored for this purpose. Create the interlock supervision as follows: 1. Open the FB "LiftCmd". 2. Right-click the parameter #interLockAuto and then click "Add new supervision". 3. For "Type of supervision", select "Interlock". 4. In the event of an error, the monitored parameter has the state "False". © Siemens AG 2022 All rights reserved 5. Set a "Delay time", e.g. 0 ms. 6. The "Actuator" #autoLift.startLiftUp (start moving lift unit upward) and the "Condition" #autoStarted (automatic operation started) must be set. For both, tick the "True" checkbox for the trigger of the condition. 7. Select "Error" as the "Category". 8. Under "Specific text field", enter the text "Door at lift not closed or lift blocked". Figure 2-6: Interlock supervision Interlock supervision for the motion "Lift unit upwards" and with the parameter #interLockMan are created according to this interlock supervision. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 14 2 Engineering Note With local supervisions, the ProDiag FB "LiftProDiagFB" is not assigned to the individual parameters, but rather to the instance data block "InstMainFB" of the "MainFB" FB that originates the call. See chapter 2.2.8 2.2.5.1 Action supervisions Action supervision checks whether the motion "Lift unit upwards" has left the starting position within a specified time. If the lift unit remains stationary, a supervision alarm in the "Error" category will be issued. In the application example, the FB parameter #sensorLiftDown (sensor: lift unit downwards) is monitored for this purpose. Create the action supervision as follows: 1. Right-click the parameter #sensorLiftDown and then click "Add new supervision". 2. Select "Action" as the "Type of supervision". 3. In the event of an error, the monitored parameter has the state "True". 4. Set a "Delay time", e.g. 200 ms. © Siemens AG 2022 All rights reserved 5. The "Action" #outLiftUp (output: lift unit upwards) must be set. Tick the "True" checkbox for the condition trigger. 6. Select "Error" as the "Category". 7. Under "Specific text field", enter the text "Lift has not left lower start position". Figure 2-7: Action supervision Action supervision for the motion "Lift downwards" is created according to this action supervision. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 15 2 Engineering 2.2.5.2 Reaction supervisions Reaction supervision checks whether the motion "Lift unit upwards" has reached the end position within a specified time. If the lift unit remains stationary before this, a supervision alarm in the "Error" category will be issued. In the application example, the FB parameter #sensorLiftUp (sensor: lift unit upwards) is monitored for this purpose. Create the reaction supervision as follows: 1. Right-click the parameter #sensorLiftUp and then click "Add new supervision". 2. Select "Reaction" as the "Type of supervision". 3. In the event of an error, the monitored parameter has the state "False". 4. Set a "Delay time", e.g. 5000 ms. 5. The "Action" #outLiftUp (output: lift unit upwards) must be set. Tick the "True" checkbox for the condition trigger. 6. Select "Error" as the "Category". 7. Under "Specific text field", enter the text "Lift has not reached upper end position". © Siemens AG 2022 All rights reserved Figure 2-8: Reaction supervision Reaction supervision for the motion "Lift downwards" is created according to this reaction supervision. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 16 2 Engineering 2.2.6 Note Create supervisions on PLC data type For supervisions on PLC data types, you only have access to the "Operand" supervision type. Since the fictional conveyor belt system has two lifts, a PLC data type has been created with the tags "startLiftUp" and "startLiftDown" for starting the lift unit. Operand supervision issues an error message if the lift unit is started in both directions at the same time. Proceed as follows to create the operand supervision: 1. Open the PLC data type "typeStartLift". 2. Right-click the tag "startLiftUp" and then click "Add new supervision". 3. Select "Operand" as the "Type of supervision". 4. In the event of an error, the monitored tag will have the state "True". 5. Set a "Delay time", e.g. 0 ms. 6. For "Condition 1", select the tag "startLiftDown". Tick the "True" checkbox for the condition trigger. 7. Select "Error" as the "Category". © Siemens AG 2022 All rights reserved 8. Under "Specific text field", enter the text "Lift is started in both directions.". Figure 2-9: Operand supervision Supervision of the tags "startLiftDown" will be created accordingly. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 17 2 Engineering 2.2.7 Instancing PLC data type supervisions Use in global data blocks and tag tables If you use the PLC data type as a tag declaration in a global data block or a tag table, then the supervisions will be instanced directly. The supervisions are marked with the icon. Figure 2-10: Use in global data block Use in blocks © Siemens AG 2022 All rights reserved The ProDiag supervisions in PLC data types are supported in an FB, but only in the section "Static". If you use the PLC data type in the block interface of an FB in the "Static" section, then all supervisions will be automatically instanced when the block is called. The supervisions are marked with the icon. Figure 2-11: Use in FB Note If you use the PLC data type in an OB, FC or in an FB outside of the "Static" section in the block interface, then the ProDiag supervisions contained therein will not be supported. The following message will appear in the Inspector window: "No ProDiag supervisions available" Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 18 2 Engineering 2.2.8 Assign ProDiag FB to the instance data block of an FB The parameters subject to supervision in the interface of a block must be assigned to a ProDiag FB via the instance of an FB. Follow the steps below: 1. Double-click in the project tree on the folder "PLC supervisions & alarms". The alarms and supervisions editor opens. 2. Click the tab "Supervisions > Supervision instances". The instance data blocks will be displayed with all local supervisions. 3. Click the Extras button in the "ProDiag FB" column. 4. In the selection dialog, select the ProDiag FB "LiftProDiagFB" that was created earlier. You can also create a new ProDiag FB. © Siemens AG 2022 All rights reserved Figure 2-12: Assign ProDiag FB The ProDiag FB can also be assigned in the properties of the instance data block. Follow the steps below: 1. Right-click on the instance data block "InstMainFB". 2. Click the "Properties" button in the context menu. 3. In the Properties dialog, click on "Attributes". 4. Under "Assigned ProDiag FB", select the ProDiag FB "LiftProDiagFB". You can also create a new ProDiag FB here. Figure 2-13: Assign ProDiag FB Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 19 2 Engineering 2.2.9 Poll error bits in the program Poll the group error bit of a ProDiag FB For each ProDiag FB, it is possible to poll various types of group error bits in the user program. This can be done to halt the machine in case of certain faults, for example. The group error bits are also accessible via the "InstLiftProDiagFB" instance data block of the ProDiag FB. There are two different types of group error bit: • Group error bit for the supervision types (All, O, I, R, A, P, Merr and Mtxt) • Group error bit for the categories (C1, C2, C3, C4, C5, C6, C7 and C8) The following Figure shows the group error bit "All" in the data structure of the status tags in the ProDiag IDB. The bit can be used in the user program. © Siemens AG 2022 All rights reserved Figure 2-14: Polling group error bit in the program Poll error bit of a supervision For each supervision, it is possible to poll an error bit in the user program. This can be done in order to halt the machine in case of certain faults, for example. The error bits are accessible via the "InstLiftProDiagFB" instance data block of the ProDiag FB. The following Figure shows the error bit "Err" in the data structure of the operand supervision. The bit can also be used in the user program. Figure 2-15: Polling operand supervision error bit in the program Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 20 2 Engineering 2.2.10 Multiple selection for defining supervisions You can create a large number of supervisions in the PLC tag table, in the interfaces of function blocks, and in global data blocks with an operator action. Only Boolean tags will be considered. Highlight the tags, for example those in the global data block, and select "Add new supervision" from the context menu. © Siemens AG 2022 All rights reserved Figure 2-16: Multiple selection of supervisions A supervision will be created for each highlighted tag. The "Supervisions" tab in the "Properties" Inspector window will open for the first tag. Here you will create the settings for each individual supervision separately. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 21 2 Engineering 2.2.11 Create supervisions in the GRAPH sequence chain With the GRAPH programming language, supervisions have already been integrated within each individual step. Messages are generated here automatically. 2.2.11.1 Interlock An Interlock lets you monitor the feasibility of an action. In this example, we monitor for whether the door at the entrance to the lift unit is closed and the lift unit is not blocked. If the interlock condition is not met, then a message will be issued. Proceed as follows to enter a specific alarm text: 1. Open the step in the Single step view. 2. Select "Interlock -(C)-". 3. Open the Inspector window and select the "Properties" tab. 4. In the "Alarm text" field, enter the desired alarm text. This text will be added to the interlock message with the alarm text field "<Step-specific text field>". © Siemens AG 2022 All rights reserved Figure 2-17: GRAPH Interlock Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 22 2 Engineering 2.2.11.2 Supervision A Supervision lets you monitor an entire step. In this example, the step duration will be monitored. If the specified step duration is exceeded, then a message will be issued and the sequence chain will not advance to the next step. Proceed as follows to enter a specific alarm text: 1. Open the step in the Single step view. 2. Select "Supervision -(v)-". 3. Open the Inspector window and select the "Properties" tab. 4. In the "Alarm text" field, enter the desired alarm text. This text will be added to the supervision alarm with the alarm text field "<Step-specific text field>". © Siemens AG 2022 All rights reserved Figure 2-18: GRAPH Supervision Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 23 2 Engineering 2.2.12 Configure multilingual names in S7 GRAPH The names of steps and transitions can be configured in multiple languages, allowing for multilingual output of names in alarms, the PLC code view and in the GRAPH overview. 1. In the S7 GRAPH FB "LiftSeq" [FB12], highlight the step you wish to edit. 2. Open the "Properties" in the Inspector window. 3. In the "Texts" tab, you can assign names in multiple languages (the languages that are enabled in the project). © Siemens AG 2022 All rights reserved Figure 2-19: Multilingual names in S7 GRAPH Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 24 2 Engineering 2.2.13 Setting initial value acquisition of the GRAPH sequence chain Initial value acquisition lets you analyze the cause that triggered a supervision alarm. To do this, we record the initial values of the operands in your program that are programmed upstream of the supervised operands. To activate initial value acquisition, proceed as follows: 1. Open the Properties of the GRAPH sequence chain "LiftSeq". 2. Update the version in the "General > Block" tab. In this example, the block version is V5.0. 3. Switch to the "Attributes" tab. 4. Enable "Initial value acquisition". © Siemens AG 2022 All rights reserved Figure 2-20: Attributes of the GRAPH sequence chain Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 25 2 Engineering 2.2.14 Reset initial values at GRAPH FB With a GRAPH FB V5.0 or later, you can use the input parameter "RESET_CRIT" to reset the signal state of the two static parameters "H_IL_ERR" (Interlock) and "H_SV_FLT" (Transition) back to FALSE after the criteria analysis. In this way, no more old values will be displayed in the HMI PLC Code Viewer. This is useful if you change the programming of interlocks and transitions and no longer need the initial values that have thus become out-of-date. The signal states are not automatically reset to FALSE by the programming change. To reset the signal states of the two system-internal static parameters (and thus reset the initial values), proceed as follows: 1. Make sure that the GRAPH function block has at least version 5.0. 2. Open the GRAPH FB "LiftSeq", click in the block interface, and select "Edit > Interface parameters > Maximum interface parameters" from the menu bar. © Siemens AG 2022 All rights reserved Figure 2-21: Resetting initial values at the "RESET_CRIT" parameter Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 26 2 Engineering 3. Open the FB "MainFB" and right-click on the GRAPH FB. 4. Select "Update block call" from the context menu. After the update, the GRAPH FB "LiftSeq" will be displayed with its maximum parameters. 5. When the GRAPH function block is called, interconnect the input parameter "RESET_CRIT" in your user program with a Boolean tag such as "SeqData".resetCrit. © Siemens AG 2022 All rights reserved Figure 2-22: Resetting initial values at the "RESET_CRIT" parameter Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 27 2 Engineering 2.2.15 Setting parameters of the GRAPH sequence chain In order for the program status of the GRAPH sequence chain to be displayed on the "GRAPH overview" HMI object, the parameters of the GRAPH sequence chain must be visible in the HMI as well as accessible from the HMI. Proceed as follows to set it up: 1. Open the GRAPH sequence chain "LiftSeq". 2. Open the "Edit" menu. 3. Enable "Internal parameters visible/accessible from HMI". Selecting this is only possible when the GRAPH sequence chain is opened in the editor and in focus. © Siemens AG 2022 All rights reserved Figure 2-23: GRAPH sequence chain parameter settings 2.2.16 Define ProDiag supervision settings In the ProDiag supervision settings, you will define the settings that apply to all supervisions in the entire TIA Portal project. The ProDiag supervision settings can be found in the project tree under "Common data". Define categories "Categories" allow you to divide pending errors into different urgency levels. The categories can: • either be issued as a part of a supervision alarm or as a group error bit in the "ProDiag overview" object on an HMI device. • be adapted to your requirements; for example, you can assign each category its own message class. The dialog is located under "Common data > Supervision settings > General > Categories". By default, there are three categories: "Error", "Warning" and "Info". In addition, you can create and enable/disable five more categories. The "Error" category cannot be disabled. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 28 2 Engineering Figure 2-24 Category settings Define sub-categories Sub-categories let you more finely differentiate the information within a supervision alarm. © Siemens AG 2022 All rights reserved Define default settings of the supervision types You can change the default settings for the various supervision types in the "Type of supervision" section. Here you can set the delay time as well as the signal state that an operand or a condition will be monitored for. Figure 2-25: Default settings of the supervision types Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 29 2 Engineering Define ProDiag alarm texts You can define the structure of the supervision alarms in the "Alarm text" section. To create an alarm text, proceed as follows: 1. In the "Alarm text" tab, select the desired area for which you wish to create an alarm text, for example "Basic supervisions > Tags". 2. Drag the desired alarm text fields from the "Supported alarm text fields" field and drop them into the "Alarm text" text box. You can change the order of the individual text fields at any time. 3. If you wish to delete a text field, then right-click the text field in question and select "Delete" from the context menu. 4. Select a desired delimiter for the text fields. © Siemens AG 2022 All rights reserved Figure 2-26: Alarm text structure You can define the alarm text structures of the various supervisions according to the Basic supervisions. With local supervisions, insert the alarm text fields "<Instance name>" and "<Parameter Name>" in place of "<Tag name>". Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 30 2 Engineering 2.2.17 Sample supervision type error message with accompanying value With blocks that report errors and output a status, you can have error texts be issued in a supervision alarm in case of an error. In the example below, the "Frequency" FB checks the input frequency and outputs an error and the following status (error number): • 16#8001 (32769 decimal): Input frequency lower than 5. • 16#8002 (32770 decimal): Input frequency greater than 10. The texts are assigned to the values of a tag in the text list "TextListStatus". In order for the error texts to be output in a supervision alarm based on the status, proceed as follows: 1. In the "SeqData" DB, define the tags "freqError" (data type: Bool) and "freqStatus" (data type: UInt). 2. Interconnect the "error" and "status" parameters of the "Frequency" FB with the defined DB tags. In the example, the FB is called in the FB "LiftSim". © Siemens AG 2022 All rights reserved Figure 2-27: Call and parameter assignment of the "Frequency" FB 3. In the "PLC1" folder in the project tree, open the text list editor by double-clicking on "PLC alarm text lists". 4. Add a new text list and give it a name, for example "TextListStatus". 5. In the "Selection" column, select the setting "Decimal" for the text list. 6. In the "Range from / Range to" columns under "Text list entries", enter the status (error numbers) used in the "Frequency" FB. Define the alarm texts under "Entry". Figure 2-28: Adding text list Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 31 2 Engineering 7. Configure a supervision with the following properties for the DB tag: – Type of supervision: Error message: – Supervised tag: "SeqData".freqError – Delay time: T#0ms – Category: 1: Error – ProDiag FB: LiftProDiagFB (for example) © Siemens AG 2022 All rights reserved Figure 2-29: Supervision definition 2.2.17.1 Specific text field: Enter accompanying values via context menu (text list name) 1. In the field "Tag 1 (SD_4)", enter the DB tag "SeqData".frequency. 2. In the field "Tag 2 (SD_5)", enter the DB tag "SeqData".freqStatus. 3. In "Specific text field", enter the following strings: – Frequency value – Error message from Text List Figure 2-30: Definition of the specific text field Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 32 2 Engineering Add a dynamic parameter (tag) 1. Right-click behind the "Frequency value" text. 2. Click "Insert dynamic parameter (tag)…" in the context menu. 3. Under "Tag", select "Tag 1 (SD_4)". 4. Under "Display type", select "Floating-point" and confirm your entries. In the event of an error, the error message will be issued with the current input frequency. © Siemens AG 2022 All rights reserved Figure 2-31: Adding a dynamic parameter (tag) Add dynamic parameter (text list name) 1. Right-click behind the "...Text list" text. 2. Click "Insert dynamic parameter (text list name)…" in the context menu. 3. Under "Text list name", select the text list "TextListStatus". 4. Under "Tag for text list entry", select the "tag" "Tag 2 (SD_5)" and confirm your entries. In the event of an error, the error message will be pulled from the error text list "TextListStatus". The text selection depends on the tag "SeqData".freqStatus. Figure 2-32: Adding a dynamic parameter (text list name) Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 33 2 Engineering Result Figure 2-33: Result of specific text field with accompanying values Once the DB tag "freqError" assumes the signal state "TRUE", the supervision alarm will be issued with the text from the specific text field. The accompanying value for the frequency (as a floating-point number) and the error tect (from the text list) will also be displayed. © Siemens AG 2022 All rights reserved 2.2.17.2 Specific text field: Enter accompanying values via context menu (text list ID) The text list names can be changed. If the list name changes, the reference to the name will stop working. Instead of the text list name, you can also use the automatically assigned text list ID, which is immutable. To do this, assign the text list ID to a tag and use the tag in the context menu as the tag for the text list ID. The supervision configuration under "General" corresponds to Figure 2-29. 1. In the "Tag 1 (SD_4)" field, enter the DB tag "SeqData".textListID. 2. In the field "Tag 2 (SD_5)", enter the DB tag "SeqData".freqStatus. 3. In "Specific text field", enter the following strings: – Error message from Text list ID Figure 2-34: Definition of the specific text field Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 34 2 Engineering Add dynamic parameter (text list ID) 1. Right-click behind the "...Text list ID" text. 2. Click in the context menu on "Insert dynamic parameter (text ID)…" 3. Under "Tag for text list ID", select the tag "Tag 1 (SD_4)". 4. Under "Tag for text list entry", select the tag "Tag 2 (SD_5)" and confirm your entries. In the event of an error, the error message will be pulled from the error text list "TextListStatus". The text selection depends on the tag "SeqData".freqStatus. © Siemens AG 2022 All rights reserved Figure 2-35: Adding a dynamic parameter (text list name) Result Figure 2-36: Result of specific text field with accompanying values Once the DB tag "freqError" assumes the signal state "TRUE", the supervision alarm will be issued with the text from the specific text field. The accompanying value for the frequency (as a floating-point number) and the error tect (from the text list) will also be displayed. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 35 2 Engineering 2.2.17.3 Specific text field: Enter associated value without context menu The supervision configuration under "General" corresponds to Figure 2-29. 1. In "Specific text field", enter the following accompanying values: Error message from Textlist: @4%5X@: @4%t#TextListStatus@ In the event of an error, the error message will be pulled from the error text list "TextListStatus". 2. In the "Tag 1 (SD_4)" field, enter the DB tag "SeqData".freqStatus. © Siemens AG 2022 All rights reserved Figure 2-37: Definition of the specific text field Once the DB tag "freqError" assumes the signal state "TRUE", the supervision alarm will be issued with the text from the specific text field. The error number will be displayed in decimal format with the error text from the text list. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 36 2 Engineering 2.2.18 Configure identical time stamps A ProDiag function block of version 2.0 or later gives you the ability to specify a central time stamp tag in the ProDiag supervision settings. You can then use this tag across the entire project in every CPU. The central time stamp tag is used as a global tag or a global data block element in the respective CPU. All ProDiag supervision alarms within a program cycle will be assigned the same system time if the messages are sent by ProDiag function blocks with the "Use central time stamp" option enabled. Configuration of identical time stamps is only necessary if you are using multiple ProDiag function blocks. To use a central time stamp, follow these steps: 1. Define the following two tags in the global data block "SeqData": – "identTimeStamp" (data type: LDT) – "retVal" (data type: Int) 2. Add the instruction "RD_SYS_T" to the organization block "Main", then parameterize the "OUT" output with the DB tag "SeqData".identTimeStamp. © Siemens AG 2022 All rights reserved 3. Interconnect the "RET_VAL" parameter with the DB tag "SeqData".retVal. Figure 2-38: Read instruction for clock time 4. Open the "Common data" folder in the project tree. 5. Open the "Supervision settings" dialog. 6. In the area navigation, switch to the "General > Central time stamp" tab. 7. Enter the "SeqData".identTimeStamp DB tag, defined above, in the "Time stamp tag" field. Figure 2-39: Configuring identical time stamps Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 37 2 Engineering 8. Right-click on the ProDiag FB "LiftProDiagFB" and select "Properties" from the context menu. 9. Switch to the "Attributes" tab and tick the checkbox for the "Use central time stamp" option. 10. Click OK to close the dialog. © Siemens AG 2022 All rights reserved Figure 2-40: Enabling central time stamp Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 38 2 Engineering 2.2.19 Export/import supervision settings for ProDiag and S7 GRAPH You can export the supervision settings for ProDiag and S7 GRAPH in a ".dat" file, which lets you import them into a new project. Proceed as follows to export or import the supervision settings: 1. Go to the "Common data" folder in the project tree and open the "Supervision settings". 2. Click the icon for a. "Export supervision settings" to export the settings. Select a storage location. b. "Import supervision settings" to import the settings. Select the file you want to import. Figure 2-41: Exporting/importing global settings a © Siemens AG 2022 All rights reserved b Note The ProDiag supervision settings build on alarm classes. In some cases you may need to export the alarm classes as a ".dat" file as well. Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 39 2 Engineering 2.2.20 Export and import ProDiag supervisions and properties of a ProDiag FB In addition to the supervisions from the ProDiag overview tables "Tag supervisions" and "FB supervision definitions", you can also export/import the properties of one or more ProDiag FBs. To export the supervisions and properties of one or more ProDiag FBs, proceed as follows: 1. In the project tree, open the "PLC supervisions & alarms" editor. 2. Switch to the "Global supervisions" tab. 3. Click the icon for a. "Exports global supervisions" to export the tag supervisions. Select a storage location. b. "Imports global supervisions" to import the settings. Select the file you want to import. Figure 2-42: PLC supervisions & alarms a © Siemens AG 2022 All rights reserved b When importing, you can select what you wish to import and how. Besides importing the supervisions, the "Supervision settings" can also be imported at the same time. Figure 2-43: PLC supervisions & alarms Note Further information on the export/import functions can be found in the Online help or in the STEP 7 and WinCC Engineering V18 system manual in the chapter entitled: Exporting supervisions and properties of a ProDiag FB Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 40 2 Engineering 2.3 Download project The configuration must now be compiled and downloaded to the PLC. Download to PLC To download the configuration to the PLC, follow the steps below: 1. Highlight the controller's "PLC_1" folder in the project tree. 2. Click on the "Download to device" button in the function bar. © Siemens AG 2022 All rights reserved Figure 2-44: PLC download Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 41 3 Appendix 3 Appendix 3.1 Service and support Industry Online Support Do you have any questions or need assistance? Siemens Industry Online Support offers round the clock access to our entire service and support know-how and portfolio. The Industry Online Support is the central address for information about our products, solutions and services. Product information, manuals, downloads, FAQs, application examples and videos – all information is accessible with just a few mouse clicks: support.industry.siemens.com Technical Support The Technical Support of Siemens Industry provides you fast and competent support regarding all technical queries with numerous tailor-made offers – ranging from basic support to individual support contracts. © Siemens AG 2022 All rights reserved Please send queries to Technical Support via Web form: support.industry.siemens.com/cs/my/src SITRAIN – Digital Industry Academy We support you with our globally available training courses for industry with practical experience, innovative learning methods and a concept that’s tailored to the customer’s specific needs. For more information on our offered trainings and courses, as well as their locations and dates, refer to our web page: siemens.com/sitrain Service offer Our range of services includes the following: • Plant data services • Spare parts services • Repair services • On-site and maintenance services • Retrofitting and modernization services • Service programs and contracts You can find detailed information on our range of services in the service catalog web page: support.industry.siemens.com/cs/sc Industry Online Support app You will receive optimum support wherever you are with the "Siemens Industry Online Support" app. The app is available for iOS and Android: support.industry.siemens.com/cs/ww/en/sc/2067 Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 42 3 Appendix 3.2 Industry Mall The Siemens Industry Mall is the platform on which the entire siemens Industry product portfolio is accessible. From the selection of products to the order and the delivery tracking, the Industry Mall enables the complete purchasing processing – directly and independently of time and location: mall.industry.siemens.com 3.3 Links and literature Table 3-1 © Siemens AG 2022 All rights reserved No. 3.4 Topic \1\ Siemens Industry Online Support https://support.industry.siemens.com \2\ Link to the article page of the application example https://support.industry.siemens.com/cs/ww/en/view/109740151 \3\ System manual - SIMATIC STEP 7 Basic/Professional V18 and SIMATIC WinCC V18 https://support.industry.siemens.com/cs/ww/en/view/109815056 Change documentation Table 3-2 Version Date V1.0 10/2016 First version V2.0 12/2016 Added WinCC Runtime Professional V3.0 09/2017 Added initial value acquisition (criteria analysis) V4.0 07/2018 Update and addition of new functions with TIA Portal V15 V4.1 03/2019 Changed text in chapter 2.2.7 V5.0 08/2022 Update and addition of new functions with TIA Portal V17 V6.0 09/2023 Extension of WinCC V8, splitting into PLC and WinCC documents Machine and plant diagnostics with ProDiag Article ID: 109740151, V6.0, 09/2023 Change 43
0
You can add this document to your study collection(s)
Sign in Available only to authorized usersYou can add this document to your saved list
Sign in Available only to authorized users(For complaints, use another form )