Highly skilled writers of PLC programs focus only on these two things

Oct 21, 2024 Leave a message

For the preparation of PLC programs, as long as the content and quality of these two aspects of the gate, with the correctness, reliability, convenience, simplicity and readability is a very good program!

 

First, the content of the PLC program

 

PLC applications should be maximized to meet the control requirements of the controlled object, in the conception of the main body of the program after the framework, it is necessary to take it as the main line, one by one to write a program to achieve the control functions or sub-tasks. After continuous he adjustment and improvement. So that the program can complete the required control functions. In addition, the PLC application program should usually include the following aspects:

 

info-1-1

1, initialization procedures in the PLC power-up, generally have to do some initialization operations. Its role is to make the necessary preparations for the start, and to avoid system malfunction. Initialization program is mainly: some data areas, counters to zero; so that some of the data area to restore the required data; some of the output is set or reset; display some of the initial state and so on.

 

2, signal detection, fault diagnosis, data display, equipment contact and other content can be reserved as a routine. These contents can be added when the program design is basically completed. They can also be relatively independent program segments.

 

3, protection, chain program. Various applications, protection and chain is an indispensable part. It can put an end to the control logic caused by illegal operation and chaos, to ensure that the operation of the system is safer and more reliable. Therefore, protection and chaining should be carefully considered. Usually in the PLC outside the chain and protection measures should also be set.

 

4, PLC main program and subroutines. This is directly related to process control logic and operations, generally can be categorized according to space or time to write a subroutine, each subroutine is best to pre-allocate enough independent data storage area or data block, the program variable name unified planning, complex places must be detailed notes. Through the process, the full collection of equipment parameters and operator demand information, in order to write a set of easy acceptance of the qualified program.

 

info-1-1

 

Second, the quality of the PLC program


For the same control requirements, even if the same model of PLC, with different design methods written by the program, its structure may be different. Although several programs can achieve the same control function, but the quality of the program may vary greatly. The quality of the program can be measured by the following aspects:


1. the correctness of the program:


One of the most fundamental aspects of a good or bad application program is correctness. The so-called correct program must be able to withstand the test of the system operation practice, leaving the evaluation of the program made by this article are meaningless.


2, the reliability of the program is good:


A good application program can ensure that the system in normal and abnormal (short-term power-down and then power, some of the controlled amount of oversize, a link has a fault, etc.) can operate safely and reliably under the working conditions, but also to ensure that there is an illegal operation (such as pressing or mistakenly touched the button should not be acted on) and other circumstances do not appear system control errors.


3, easy to adjust the parameters of good:


One of the superiority of PLC control is good flexibility, easy to modify the program or parameters and change some of the system's functions. For example, some systems in certain circumstances need to change the parameters of certain control quantities (such as timer or counter settings, etc.), in the design of the program must consider how to write to be easy to modify.

 

info-1-1

 

4, the program should be concise:

 

The program should be written as concise as possible to reduce the statements of the program, which can generally reduce the program scanning time and improve the response speed of the PLC to the input signal. Of course, if too much use of those instructions with longer execution time, sometimes although the program has fewer statements, but its execution time is not necessarily short.

 

5, the program's readability:

 

The program is not only for the designer to see, the system maintenance personnel should also be read. In addition, in order to facilitate communication, but also requires a certain degree of readability of the program.

Send Inquiry

whatsapp

Phone

E-mail

Inquiry