Moscow, Azovskaya 14
+7 (495) 310-97-15
Mo-Fr: 9.00 - 18.00 (Moscow time)
Order a call
Callback
Your name *
Enter phone *
Your Email *
Call me back

Programmer's Guide. Example

Programmer's Guide. Structure of the controller program

ANNOTATION

This document describes the purpose, conditions of use and characteristics of the application software (PPO) of the programmable logic controller (PLC). The Industrial Computer (PC) application software is described in the Operator's Manual. Links to PC software are provided in this document as needed.

CONTENT

1. PURPOSE AND TERMS OF APPLICATION OF THE PROGRAM

1.1. Purpose of the PLC software

1.2.Conditions for the use of software PLC

2. CHARACTERISTICS OF THE PROGRAM

2.1. PLC structure

2.2. PLC data structures

2.3. Custom function blocks used in Unity software

3. CONTACTING THE PROGRAM

4. INPUT AND OUTPUT DATA
5. MESSAGES

1. PURPOSE AND CONDITIONS OF APPLICATION OF THE PROGRAM
The PTS of interlocks and water level protection in the steam generators of power units No. 1, 2 of the Power Plant is designed to protect the pipe system of steam generators when the water level drops, as well as to protect the system from feed water ingress into the turbine flow path at an increased level in the steam generator.

Protection of the technological process is provided by a complex of technological equipment:

Fittings on the main feed water line (VP-9);

Fittings on the main feed water line (VP-10);

Fittings on the purge line (U5-01);

Fittings on the purge line (U5-02);

Fittings on the feed water bypass line (VP11);

Commands for turning on the emergency booster electric pump (APEN-1);

Commands for turning on the emergency booster electric pump (APEN-2);

Turbine generator shutdown command (TG3);

Turbine generator shutdown command (TG4);

Issuance of process signaling on level decrease in 4 out of 6 SGs

Issuance of technological signaling of protection operation by + 300 mm

Power regulator off command on purge line +75mm

Command to turn off the power regulator on the blowdown line 500 tons

Issuance of process signaling at +125mm

Issuance of process signaling at +75mm

Issuance of process signaling by ±50mm

Issuance of technological signaling at -120mm

Issuance of process signaling for 500t/hour

The functioning of the system is provided by application software (PPO).

The application software includes industrial computer application software (PC application software) and programmable controller application software (PLC application software).

1.1. Purpose of the PLC software

The PLC software as part of the PTS implements the following functions:

– redundancy of controllers;

– receiving and processing input-output signals from three identical input-output baskets;

– Receives and filters input discrete signals from possible “bounce” of contacts.

– Receives and processes analog input signals:

• provides control of the signal going beyond the permissible limits (signal unreliability);

• performs analog signal scaling;

• performs hysteresis of threshold values;

• analyzes the states of three signals from the composition of the baskets and a selection of reliable values;

• performs filtering of the signal by the rate of increase or decrease of the signal value.

– Issuance of discrete signals to the equipment (activation of protection);

– Control of deviations of parameters from tasks and achievement of set values;

- Issuance of executive actions on process signaling lamps at the control room;

– Implementation of protection and blocking algorithms;

– Data exchange with adjacent systems via Modbus/TCP/IP channel;

- Checking the controller modules for errors, and generating messages for the workstation about the state of the controller equipment, as well as to the control panel;

– Monitoring of emergency situations of the system equipment;

- PLC software provides the ability to receive from an industrial computer, as well as from the control panel of the control panel, keys that disable certain protections and blocking the system.

1.2. Conditions for using the PLC software

The general architecture of the system is shown in Figure 1. 


Структурная схема ПО


















Figure 1. General architecture of application software

The PTS complex includes the following hardware and purchased software components:

1) Two P266 CPU-based QUANTUM programmable logic controllers (PLCs) operating in hot standby mode. Runtime Unity Pro 4.1 XL.

2) Industrial computer, consisting of:

– personal computer (embedded industrial computer);

– operating system Windows XP Pro SP3;

– CITECT 7 visualization package

PLCs interact with external subsystems via the Ethernet network (from the PLC side) and via I/O channels.

The interaction between the PLC and the industrial computer is carried out via the Ethernet network.

TCP includes application software components developed in accordance with this project:

Unity Pro application installed on the PLC.

Citect application installed on a PC.

2. PROGRAM FEATURES
2.1. PLC structure

The PLC application software is implemented as an application (see Figure 1) written in the Unity v.4.1 environment. The application name is upg.stu.

The upg.stu application provides the implementation of the functionality of the system implemented on the PLC for all modes of operation.

The application contains:

• hardware and software configuration;

• a set of functional modules, each of which is implemented by sections written in the LD (ladder diagram) language;

• a set of functional blocks developed within the framework of the project;

• database;

• animation tables.

The application includes the following functional modules, each of which contains one or more program modules, as shown in Table 1.

Table 1

Section name Functionality

Init The section is executed on the first cycle after startup and ensures that all parameters are initialized.

AI_to_AM Analog input signal processing section. The corresponding signal block is called to assign a value to an internal variable and check the validity of the channel.

DI_to_DM Section for processing input discrete variables. The function block of the corresponding signal is called to assign a value to an internal variable and check the validity of the channel.

Comparing Section for comparing received values from three different distributed I/O bins. The signals are compared according to logic 2 out of 3. If two signals are identical and the third is different, then the latter is invalidated.

Section name Functionality

Alarms Digital and analog signal processing section to determine whether limit values have been reached. Development of alarms and commands for the execution of interlocks and protections.

INTERLOCK Blocking and protection algorithm formation section. This section writes to the variables associated with the actuators.

SIM Section for controlling simulation and testing modes of the controller.

DIAGNOSTIC Section for generating controller diagnostic information.

Within the sections, the following subroutines are used:

table 2

Section name Functionality

CompAI A function block designed to compare three different analog values, output the resulting value, as well as diagnostic information for each of the channels.

CompDI A function block designed to compare three discrete signals coming from three different baskets, output the resulting value, as well as diagnostic information for each of the channels.

BlockF A function block designed to detect an unacceptably fast fall or rise in an analog value. In the event of an open or short circuit, this FB will remove this signal from processing, which will not allow stopping the process.

GetDI A function block designed to receive and process discrete signals. Carries out a filtering of "bounce" of contacts.

Within the sections, the following subroutines are used:

table 2

Section name Functionality

CompAI A function block designed to compare three different analog values, output the resulting value, as well as diagnostic information for each of the channels.

CompDI A function block designed to compare three discrete signals coming from three different baskets, output the resulting value, as well as diagnostic information for each of the channels.

BlockF A function block designed to detect an unacceptably fast fall or rise in an analog value. In the event of an open or short circuit, this FB will remove this signal from processing, which will not allow stopping the process.

GetDI A function block designed to receive and process discrete signals. Carries out a filtering of "bounce" of contacts

The industrial computer only allows the release keys to be manipulated by changing the state of the bits via the control word. The PLC reports its status via the status word. Description of individual fields (bits) of data words is given in the Programmer's Guide.

Variables in the PLC are encoded as follows:

AI - analog input to the PLC;

AIM – PLC/PC internal analog input;

DI – discrete input to the PLC;

DM – PLC/PC internal discrete input;

2.3. Custom function blocks used in Unity software
2.3.1 CompAI analogue channel comparison function block.

.Описание перечня переменных











Figure 2 CompAI analogue channel comparison function block

This FB is used to compare three different analog values. If one of the analog parameters goes beyond the average value of the other two, then its value is not taken into account and an error message is written to the property of this channel. If all three channels are healthy (are within an acceptable mismatch tolerance), then the result will be the larger of the existing values.

2.3.2 CompDI Analog Channel Comparison Function Block

Описание переменных















Figure 3. Function block for comparing discrete channels CompDI

This FB is used to compare three pairs of discrete signals. If two values in a pair of signals are the same, then this will mean an open or short circuit. In this case, this pair is not taken into account and is withdrawn from circulation. The system issues a message about the nature of the violation that caused it. If the total value in three different pairs is different, then the block algorithm decommissions those that do not match the previous two.

2.3.3 Function block for calculating the rate of fall of the analog value BlockF

Описание переменных










Figure 4. Function block for calculating the rate of fall of the analog value BlockF

This FB is used to calculate the rate of rise and fall of a value on analog channels. If there is a wire break on an analog sensor or a sharp drop in the physical value, then the parameter read from this sensor will begin to drop sharply. This FB is designed to capture events about a short circuit or a break and write an error sign to the channel status word. That is, if an open or short circuit occurs, this channel will be taken out of circulation.

2.3.4 GetAI analogue channel scaling function block

Описание переменных

Figure 5. GetAI analog link scaling function block

This FB is used to convert the program units of the controller (INT) into the values of real units of the technological process (REAL). If the parameter goes beyond the limits of the permissible error (OFFSET), no error is generated on the channel and the parameter stops at the maximum or minimum value. If the parameter stands out more than the normalized error, then an error is generated on the channel with a decoding of the nature of the violation.

2.3.5 GetDI Discrete Channel Processing Function Block

Описание переменных









Figure 6. GetDI Discrete Channel Processing Function Block

This FB is used to filter "bounce" on a discrete channel. In case of loss of communication with the channel, the specified value is written to the input of this FB, as a result of which the default value will be written to the resulting output at the output of the functional block.

2.3.6 HLLA4 Threshold Generation Function Block

Описание переменных

Figure 7. HLLA4 Threshold Generation Function Block

This FB serves to implement four threshold violations, which can be used both for issuing system violations and for implementing them in algorithms for implementing blocking and protection. In order for the violation not to disappear immediately when the area of the set value is returned, a hysteresis function is provided that affects the nature of the output of signals about the violation.

2.3.7 Sinusoidal interference generation function block SIMPMEHA

Описание переменных

Figure 8. SIMPMEHA sinusoidal noise generation function block

This FB is used to implement the controller modes associated with debugging and simulating the operation of the installation. This signal on the diagram looks like a sinusoidal curve, with a range of spread given by the limits (input variables). This interference is designed to "mix" to the magnitude of the analog signal and to give it dynamic properties and visual realism.

2.3.8 Function block for generating pulses of a given length SIMPULSE

Описание переменных







Figure 9. Function block for generating pulses of a given length SIMPULSE

This FB is used to implement the controller modes associated with debugging and simulating the operation of the installation. This signal on the diagram looks like a meander, with different ranges of tops and bottoms. The time values of the meander vertices are given by the time limits (input variables).

2.3.9 SIMPV Analog Variable Generation Function Block

Описание переменных











Figure 10. SIMPV Analog Variable Generation Function Block

This FB is used to generate analog signals for the modes of simulating the operation of devices and debugging the controller.

3. CONTACTING THE PROGRAM
The on-site program is configured to automatically start when the controller is turned on. The program status is shown on the controller display. The program settings can be configured from a portable computer included in the delivery of the system.

4. INPUT AND OUTPUT DATA
The input data of the system is the information coming from the control object to the PTS through the communication devices with the object (distributed peripherals), as well as commands entered by the operator from the PC.

The output of the system is the information transmitted to the control object from the PTS through the communication device with the object. Information is displayed in the PC in the form of screen forms and enters in the form of an alarm to the control room panel.

5. MESSAGES
Messages transmitted via the PLC-PC interface are described in the Programmer's Guide. Part 2. PLC-PC Interface. Messages issued to the operator are described in the document "Operator's Guide".

#Programmersmanual, #ProgrammersGuide, #Algorithmdescription, #PLC, #interface

Be the first to comment

You comment add