CN113759884A - Method and system for generating input/output point product file of distributed control system - Google Patents

Method and system for generating input/output point product file of distributed control system Download PDF

Info

Publication number
CN113759884A
CN113759884A CN202111313903.1A CN202111313903A CN113759884A CN 113759884 A CN113759884 A CN 113759884A CN 202111313903 A CN202111313903 A CN 202111313903A CN 113759884 A CN113759884 A CN 113759884A
Authority
CN
China
Prior art keywords
information
board card
variable
area
board
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202111313903.1A
Other languages
Chinese (zh)
Other versions
CN113759884B (en
Inventor
樊启祥
张军
许世森
黄斌
蒋敏华
赵贺
李辉
李卓
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Huaneng Group Co Ltd
Xian Thermal Power Research Institute Co Ltd
Huaneng Power International Inc
Original Assignee
China Huaneng Group Co Ltd
Xian Thermal Power Research Institute Co Ltd
Huaneng Power International Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Huaneng Group Co Ltd, Xian Thermal Power Research Institute Co Ltd, Huaneng Power International Inc filed Critical China Huaneng Group Co Ltd
Priority to CN202111313903.1A priority Critical patent/CN113759884B/en
Publication of CN113759884A publication Critical patent/CN113759884A/en
Application granted granted Critical
Publication of CN113759884B publication Critical patent/CN113759884B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B23/00Testing or monitoring of control systems or parts thereof
    • G05B23/02Electric testing or monitoring
    • G05B23/0205Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults
    • G05B23/0218Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults characterised by the fault detection method dealing with either existing or incipient faults
    • G05B23/0221Preprocessing measurements, e.g. data collection rate adjustment; Standardization of measurements; Time series or signal analysis, e.g. frequency analysis or wavelets; Trustworthiness of measurements; Indexes therefor; Measurements using easily measured parameters to estimate parameters difficult to measure; Virtual sensor creation; De-noising; Sensor fusion; Unconventional preprocessing inherently present in specific fault detection methods like PCA-based methods

Abstract

The invention discloses a method and a system for generating an input/output point product file of a distributed control system, which are used for reading information on a board card in a controller; partitioning a pre-allocated memory for storing an input/output point product file on the configuration tool, wherein the pre-allocated memory is specifically divided into a file header information area, a variable area, an instruction code area and a page information area; compiling information stored on a board card in a configuration tool memory to respectively obtain file header information, variable area information, instruction codes and page information; and correspondingly filling the file header information, the variable area information, the instruction codes and the page information into the file header information area, the variable area, the instruction code area and the page information area to obtain a product file. The product file generated by the invention occupies small memory space, has small network load and higher transmission efficiency when being downloaded and is not easy to lose packets.

Description

Method and system for generating input/output point product file of distributed control system
Technical Field
The invention relates to a distributed control system, in particular to a method and a system for generating a product file of an input/output point of the distributed control system.
Background
The IO compiling of a Distributed Control System (DCS) can check IO configuration errors which are not found by engineering personnel in a configuration process and eliminate potential safety hazards existing in the configuration on one hand, and on the other hand, a product file required by a controller can be formed through compiling, and the controller can execute corresponding logic codes only by analyzing and obtaining the compiled product file.
However, the product file formed by the existing IO compilation has the following defects: the product file occupies too much memory, which causes large network load in the downloading process, easy packet loss and tedious analysis of the controller.
Disclosure of Invention
Aiming at the problems in the prior art, the invention provides a method and a system for generating an input/output point product file of a distributed control system, wherein the generated product file occupies small memory space, has small network load and higher transmission efficiency when being downloaded, is not easy to lose packets, reduces the disturbance of product file downloading to a controller, and is convenient for the controller to analyze.
The invention is realized by the following technical scheme:
a method for generating a product file of an input/output point of a distributed control system comprises the following steps:
reading information on a board card in a controller;
partitioning a pre-allocated memory for storing an input/output point product file on the configuration tool to obtain a file header information area, a variable area, an instruction code area and a page information area;
compiling according to the information on the board card to respectively obtain file header information, variable area information, instruction codes and page information; the file header information comprises an IO branch type, the number of a program organization unit, a task level, an IO branch name and an IO branch number; the variable area information comprises the address of the board card, the version number of the board card, the channel number of the board card, the parameter number of the board card, the channel of the board card and the parameter of the board card; the page information comprises configuration information of IO nodes, IO branches and board cards;
and correspondingly filling the file header information, the variable area information, the instruction codes and the page information into the file header information area, the variable area, the instruction code area and the page information area to obtain the input/output point product file.
Preferably, the reading of the information on the card in the controller is specifically:
step 1.1, an IO node list under a controller is obtained, the number of IO nodes is K, and the serial number i =0 of the node is made;
step 1.2, accessing the IO Node [ i ], if the access is unsuccessful and i is less than K, i = i +1, and repeatedly executing step 1.2; if the access is unsuccessful and i = K, finishing reading the information on the board card; if the access is successful, executing the step 1.3;
step 1.3, acquiring all IO branches under an IO Node [ i ], wherein the number of the IO branches is M, and the serial number j of the IO branches is = 0;
step 1.4, accessing the IO Branch Node [ i ]. Branch [ j ], if the access is unsuccessful and j is less than M, j = j +1, and repeatedly executing step 1.4; if the access is not successful and j = M, executing step 1.9; if the access is successful, executing the step 1.5;
step 1.5, acquiring all board cards under the IO Branch Node [ i ]. Branch [ j ], wherein the number of the board cards is N, and the serial number k of the board cards is = 0;
step 1.6, accessing a board Node [ i ]. Branch [ j ]. Module [ k ] under the IO Branch, if the access is unsuccessful and k is less than N, then k = k +1, and repeatedly executing the step 1.6; if the access is unsuccessful and k = N, performing step 1.8; if the access is successful, reading the configuration file and the data file of the board card Node [ i ]. Branch [ j ]. Module [ k ], and executing the step 1.7;
step 1.7, if k < N, k = k +1, and step 1.6 is repeatedly executed; otherwise, executing step 1.8;
step 1.8, if j < M, j = j + 1; repeatedly executing the step 1.4; otherwise, executing step 1.9;
step 1.9, if i < K, i = i + 1; repeatedly executing the step 1.2; otherwise, finishing reading the information on the board card.
Preferably, the compiling is performed according to the information on the board card to obtain the header information, specifically: obtaining IO branch types, serial numbers of program organization units, task grades to which the IO branch types belong, IO branch names and IO branch serial numbers from information on the board card to obtain header file information;
compiling according to the information on the board card to obtain an instruction code, which specifically comprises the following steps: and obtaining all channel information of the board card according to the information on the board card, obtaining the type of each channel according to the channel information, and generating an instruction code corresponding to each channel according to the type of each channel.
Preferably, the compiling is performed according to the information on the board card to obtain the address of the board card, specifically: obtaining the IO node type, the IO node number, the IO branch number and the board number of the board card according to the information on the board card; and storing the IO node type, the IO node number, the IO branch number and the board card number as integer quantities of 4 bytes from high to low to obtain the address of the board card.
Preferably, compiling is performed according to the information on the board card to obtain the number of channels of the board card and the number of parameters of the board card, and specifically, the compiling is performed according to the following steps: the channel number of the board cards comprises the input channel number and the output channel number of the board cards, and the input channel number, the output channel number and the parameter number of the board cards are obtained according to the information on the board cards;
when the channel number and the parameter number of the board card in the variable area information are filled into the variable area, firstly compressing the input channel number, the output channel number and the parameter number of the board card into a four-byte variable according to a preset compression method, and converting the compressed four-byte variable into an IEC variable; filling the number of the channels and the number of the parameters of the board cards into a variable area in the form of IEC variables;
wherein, the preset compression mode is as follows: the variable Bit1-Bit12 stores the number of input channels of the board, the variable Bit13-Bit22 stores the number of output channels of the board, and the variable Bit23-Bit32 stores the number of parameters of the board.
Preferably, when the parameters of the board card in the variable area information are filled into the variable area, the parameters of the board card are converted into IEC variables, and then the parameters of the board card are filled into the variable area in the form of the IEC variables;
wherein, convert the parameter of integrated circuit board into the IEC variable through following mode:
a. converting the type of the parameters of the board card into a first IEC variable;
b. converting the value of the parameter of the board card into a second IEC variable;
c. and combining the first IEC variable and the second IEC variable into an IEC variable, and adding an offset address to the IEC variable, wherein the offset address is obtained according to the position of the board card parameter in the new building process.
Preferably, when the channel of the board card in the variable area information is filled into the variable area, the channel of the board card is converted into an IEC variable, and then the channel of the board card is filled into the variable area in the form of the IEC variable;
wherein, the passageway with the integrated circuit board is converted into the IEC variable through following mode: traversing all channels in the board card, and converting fields in the channels into IEC variables according to the types of the channels; the types of the channels are divided into switch input quantity with alarm, switch input quantity without alarm, switch output quantity with alarm, switch output quantity without alarm, analog input quantity with alarm, analog input quantity without alarm, analog output quantity with alarm and analog output quantity without alarm.
Preferably, the compiling is performed according to the information on the board card to obtain the page information, and specifically, the compiling is performed according to: and acquiring configuration information of all IO nodes, IO branches and the board card from the information on the board card to obtain page information.
Preferably, the page information is filled in the page information area in an XML format.
A decentralized control system input/output point product file generation system comprises:
the reading module is used for reading information on a board card in the controller;
the partitioning module is used for partitioning a pre-allocated memory for storing the input/output point product file on the configuration tool, and specifically dividing the pre-allocated memory into a file header information area, a variable area, an instruction code area and a page information area;
the compiling module is used for compiling the information on the board card to obtain header information, variable area information, instruction codes and page information; the file header information comprises an IO branch type, the number of a program organization unit, a task level, an IO branch name and an IO branch number; the variable area information comprises the address of the board card, the version number of the board card, the channel number of the board card, the parameter number of the board card, the channel of the board card and the parameter of the board card; the page information comprises configuration information of IO nodes, IO branches and board cards;
and the storage module is used for correspondingly filling the file header information, the variable area information, the instruction codes and the page information into the file header information area, the variable area, the instruction code area and the page information area to obtain the input/output point product file.
Compared with the prior art, the invention has the following beneficial technical effects:
the invention carries out sectional design on the structure of the product file, the storage structure of the product file is simple and clear, the occupied memory space is small, the storage space is saved, the transmission efficiency is higher when the configuration tool and the controller file are transmitted, the communication efficiency between the configuration tool and the controller is improved, fewer software and hardware resources are required by the controller in the process of receiving the product file, the disturbance of the product file downloading to the controller is reduced, and the stability of the controller system is improved. Meanwhile, the product file is stored in a segmented mode, so that the analysis of the controller is facilitated, and the efficiency of analyzing the product file by the controller is higher.
Furthermore, the parameter type and the parameter value of the board card are stored in the IEC variable form, so that the controller can be analyzed and read conveniently, the controller can allocate the memory according to the specific parameter type, and the memory waste of the controller is avoided.
Furthermore, the page information is stored in an XML format, so that the controller can analyze the page information conveniently and recover IO configuration.
Drawings
Fig. 1 is a flowchart of a method for generating a product file at an input/output point of a distributed control system according to the present invention.
Detailed Description
The present invention will now be described in further detail with reference to specific examples, which are intended to be illustrative, but not limiting, of the invention.
As shown in fig. 1, the method for generating a product file at an input/output point of a distributed control system according to the present invention includes:
reading information on a board card in a controller;
partitioning a pre-allocated memory for storing an input/output point product file on the configuration tool to obtain a file header information area, a variable area, an instruction code area and a page information area;
compiling according to the information on the board card to respectively obtain file header information, variable area information, instruction codes and page information; the file header information comprises an IO branch type, the number of a program organization unit, a task level, an IO branch name and an IO branch number; the variable area information comprises the address of the board card, the version number of the board card, the channel number of the board card, the parameter number of the board card, the channel of the board card and the parameter of the board card; the page information comprises configuration information of IO nodes, IO branches and board cards;
and correspondingly filling the file header information, the variable area information, the instruction codes and the page information into the file header information area, the variable area, the instruction code area and the page information area to obtain the input/output point product file.
The invention relates to a method for generating a product file of an input/output point of a distributed control system, which comprises the following specific implementation operation processes:
step 1, reading information (IO data) on a board card of a controller into a memory of a configuration tool for storage;
in the configuration tool, the organization form of the board cards is that N board cards can form a branch, M branches can form a node, and the number of the nodes in a single controller is K.
Step 1.1, an IO node list under a controller is obtained, and if the number of IO nodes is K, the number i =0 of the node is assumed;
step 1.2, accessing the IO Node [ i ], if the access is unsuccessful and i is less than K, i = i +1, and repeatedly executing the operation of step 1.2; if the access is unsuccessful and i = K, jumping to step 1.10; if the access is successful, executing the operation of the step 1.3;
step 1.3, obtaining all IO branches under the IO Node [ i ], and assuming that the number of the IO branches is M, making the serial number j of the IO branches = 0;
step 1.4, accessing the IO Branch Node [ i ]. Branch [ j ], if the access is unsuccessful and j is less than M, j = j +1, and repeatedly executing the operation of step 1.4; if the access is unsuccessful and j = M, jumping to step 1.9; if the access is successful, executing the operation of the step 1.5;
step 1.5, acquiring all board cards under the IO Branch Node [ i ]. Branch [ j ], and assuming that the number of the board cards is N, enabling the number k of the board cards to be = 0;
step 1.6, accessing a board Node [ i ]. Branch [ j ]. Module [ k ] under the IO Branch, if the access is unsuccessful and k is less than N, then k = k +1, and repeatedly executing the operation of step 1.6; if the access is unsuccessful and k = N, jumping to step 1.8; if the access is successful, reading the configuration file and the data file of the board card Node [ i ]. Branch [ j ]. Module [ k ], and executing the step 1.7;
step 1.7, if k < N, k = k +1, and the operation of step 1.6 is repeatedly executed; otherwise, jumping to step 1.8;
step 1.8, if j < M, j = j + 1; repeatedly executing the operation of the step 1.4; otherwise, jumping to step 1.9;
step 1.9, if i < K, i = i + 1; repeatedly executing the operation of the step 1.2; otherwise, jumping to step 1.10;
step 1.10, through steps 1.1-1.9, the reading of the data files and configuration files of all the boards is completed.
And 2, generating a product file of IO compilation according to the read IO data on the board card. Storing the content in the product file in a segmented form, wherein the content is specifically divided into file header information, variable area information, instruction codes and page information; the method comprises the steps of carrying out partition processing on a pre-allocated memory used for storing an input/output point product file on a configuration tool, specifically dividing the pre-allocated memory into a file header information area, a variable area, an instruction code area and a page information area, and respectively storing file header information, variable area information, instruction codes and page information. The specific process is as follows:
and 2.1, generating file header information of the product file, wherein the file header information comprises the IO branch type, the serial number of the program organization unit, the task level of the program organization unit, the IO branch name and the IO branch serial number. Specifically, the corresponding IO branch type, program organization unit number, task level, IO branch name and IO branch number are obtained from the memory of the configuration tool and stored in the file header information area as the header file information of the product file. The structure of the Program Organization Unit (POU) comprises a file header information area, a variable area, an instruction code area and a page information area, and the file header information, the variable area information, the instruction code and the page information are respectively stored. That is, the product file is stored in the POU format, and the program organization unit number in the file header information is the number of the program organization unit corresponding to the product file.
And 2.2, generating variable area information of the product file, wherein the variable area information comprises the address of the board card, the version number of the board card, the channel number of the board card, the parameter number of the board card, the channel of the board card and the parameters of the board card, and the version number of the board card, the channel number of the board card, the parameter number of the board card and the channel of the board card and the parameters of the board card are stored in the variable area in the form of IEC variables.
Step 2.2.1, generating the address information of the board card: obtaining the IO node type, the IO node number, the IO branch number and the board number of the board card according to the information on the board card; and storing the IO node type, the IO node number, the IO branch number and the board card number as integer quantities of 4 bytes from high to low to obtain the address of the board card. And writing the address information of the board card into a variable area of a pre-allocated memory for storing the product file.
And 2.2.2, acquiring the version number of the board card from the memory, converting the version number of the board card into an IEC variable and adding the IEC variable to a variable area of a pre-allocated memory for storing the product file.
Step 2.2.3, the number of channels of the board card includes the number of input channels and the number of output channels of the board card, the number of input channels, the number of output channels of the board card and the number of parameters of the board card are obtained, the number of input channels, the number of output channels of the board card and the number of parameters of the board card are compressed into a four-byte variable, and the compression mode is as follows: the variable Bit1-Bit12 stores the number of input channels of the board, the variable Bit13-Bit22 stores the number of output channels of the board, and the variable Bit23-Bit32 stores the number of parameters of the board. And converting the compressed four-byte variables into IEC variables, and writing the IEC variables into a variable area of a pre-allocated memory for storing the product file.
And 2.2.4, respectively processing the parameters of the board card, the input channel of the board card and the output channel of the board card into IEC variables, and writing the IEC variables into a variable area of a pre-allocated memory for storing the product file.
(1) Processing the parameters of the board card into IEC variables (the main function of the IEC variables is suitable for recording the values and the parameter types of the board card channel and the board card parameters), wherein the processing method comprises the following steps:
a. converting the type of the parameters of the board card into a first IEC variable;
b. converting the value of the parameter of the board card into a second IEC variable;
c. and combining the first IEC variable and the second IEC variable into an IEC variable, and adding an offset address to the IEC variable, wherein the offset address is obtained according to the position of the board card parameter in the new building process.
And storing the processed IEC variables in an IEC variable list of the board card.
(2) And after the parameters of the board card are processed, the input channel and the output channel of the board card are continuously processed. Traversing all the channels in the board card, and dividing the channels into a switch input quantity with alarm, a switch input quantity without alarm, a switch output quantity with alarm, a switch output quantity without alarm, an analog input quantity with alarm, an analog input quantity without alarm, an analog output quantity with alarm and an analog output quantity without alarm for storage. Fields in the corresponding channel are treated as IEC variables according to the type of channel. And storing the IEC variable of the board card in an IEC variable list of the board card.
(3) And writing the IEC variable of the board card into a variable area of the product file.
And 2.3, creating instruction codes (used for the controller to analyze and operate corresponding codes) according to the type of the board card, and storing the instruction codes in an instruction code list of the board card. And traversing all the channels of the board card, generating an instruction code according to the type of each channel, and storing the instruction code in an instruction code list of the board card. And writing all the instruction codes in the instruction code list into an instruction code area of a pre-allocated memory for storing the product file.
And 2.4, storing the configuration information of all IO nodes, IO branches and board cards in the memory of the configuration tool in an XML format in a page information area of a pre-allocated memory for storing the product file.
And correspondingly filling the file header information, the variable area information, the instruction codes and the page information into the file header information area, the variable area, the instruction code area and the page information area to obtain a product file. Through the steps, a complete IO point compilation product file can be generated.
The following are embodiments of the apparatus of the present invention that may be used to perform embodiments of the method of the present invention. For details of non-careless mistakes in the embodiment of the apparatus, please refer to the embodiment of the method of the present invention.
In an embodiment of the present invention, a system for generating an input/output point product file of a distributed control system is provided, which can be used to implement the method for generating an input/output point product file of a distributed control system.
Specifically, the system for generating the input/output point product file of the distributed control system includes:
the reading module is used for reading information on a board card in the controller;
the partitioning module is used for partitioning a pre-allocated memory for storing the input/output point product file on the configuration tool, and specifically dividing the pre-allocated memory into a file header information area, a variable area, an instruction code area and a page information area;
the compiling module is used for compiling the information stored on the board card in the configuration tool memory to obtain file header information, variable area information, instruction codes and page information; the file header information comprises an IO branch type, the number of a program organization unit, a task level, an IO branch name and an IO branch number; the variable area information comprises the address of the board card, the version number of the board card, the channel number of the board card, the parameter number of the board card, the channel of the board card and the parameter of the board card; the page information comprises configuration information of IO nodes, IO branches and board cards;
and the storage module is used for correspondingly filling the file header information, the variable area information, the instruction codes and the page information into the file header information area, the variable area, the instruction code area and the page information area to obtain the input/output point product file.
In yet another embodiment of the present invention, a computer device is provided that includes a processor and a memory for storing a computer program comprising program instructions, the processor for executing the program instructions stored by the computer storage medium. The Processor may be a Central Processing Unit (CPU), or may be other general-purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable gate array (FPGA) or other Programmable logic device, a discrete gate or transistor logic device, a discrete hardware component, etc., which is a computing core and a control core of the terminal, and is specifically adapted to load and execute one or more instructions in a computer storage medium to implement a corresponding method flow or a corresponding function; the processor provided by the embodiment of the invention can be used for the operation of the generation method of the input and output point product file of the decentralized control system.
In yet another embodiment of the present invention, the present invention further provides a storage medium, specifically a computer-readable storage medium (Memory), which is a Memory device in a computer device and is used for storing programs and data. It is understood that the computer readable storage medium herein can include both built-in storage media in the computer device and, of course, extended storage media supported by the computer device. The computer-readable storage medium provides a storage space storing an operating system of the terminal. Also, one or more instructions, which may be one or more computer programs (including program code), are stored in the memory space and are adapted to be loaded and executed by the processor. It should be noted that the computer-readable storage medium may be a high-speed RAM memory, or may be a non-volatile memory (non-volatile memory), such as at least one disk memory. One or more instructions stored in the computer-readable storage medium may be loaded and executed by a processor to implement the corresponding steps of the method for generating an input/output point product file of a distributed control system in the above embodiments.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solutions of the present invention and not for limiting the same, and although the present invention is described in detail with reference to the above embodiments, those of ordinary skill in the art should understand that: modifications and equivalents may be made to the embodiments of the invention without departing from the spirit and scope of the invention, which is to be covered by the claims.

Claims (10)

1. A method for generating a product file of an input/output point of a distributed control system is characterized by comprising the following steps:
reading information on a board card in a controller;
partitioning a pre-allocated memory for storing an input/output point product file on the configuration tool to obtain a file header information area, a variable area, an instruction code area and a page information area;
compiling according to the information on the board card to respectively obtain file header information, variable area information, instruction codes and page information; the file header information comprises an IO branch type, an IO branch name and an IO branch number; the variable area information comprises the address of the board card, the version number of the board card, the channel number of the board card, the parameter number of the board card, the channel of the board card and the parameter of the board card; the page information comprises configuration information of IO nodes, IO branches and board cards;
and correspondingly filling the file header information, the variable area information, the instruction codes and the page information into the file header information area, the variable area, the instruction code area and the page information area to obtain the input/output point product file.
2. The method as claimed in claim 1, wherein reading information on a board card in a controller comprises:
step 1.1, an IO node list under a controller is obtained, the number of IO nodes is K, and the serial number i =0 of the node is made;
step 1.2, accessing the IO Node [ i ], if the access is unsuccessful and i is less than K, i = i +1, and repeatedly executing step 1.2; if the access is unsuccessful and i = K, finishing reading the information on the board card; if the access is successful, executing the step 1.3;
step 1.3, acquiring all IO branches under an IO Node [ i ], wherein the number of the IO branches is M, and the serial number j of the IO branches is = 0;
step 1.4, accessing the IO Branch Node [ i ]. Branch [ j ], if the access is unsuccessful and j is less than M, j = j +1, and repeatedly executing step 1.4; if the access is not successful and j = M, executing step 1.9; if the access is successful, executing the step 1.5;
step 1.5, acquiring all board cards under the IO Branch Node [ i ]. Branch [ j ], wherein the number of the board cards is N, and the serial number k of the board cards is = 0;
step 1.6, accessing a board Node [ i ]. Branch [ j ]. Module [ k ] under the IO Branch, if the access is unsuccessful and k is less than N, then k = k +1, and repeatedly executing the step 1.6; if the access is unsuccessful and k = N, performing step 1.8; if the access is successful, reading the configuration file and the data file of the board card Node [ i ]. Branch [ j ]. Module [ k ], and executing the step 1.7;
step 1.7, if k < N, k = k +1, and step 1.6 is repeatedly executed; otherwise, executing step 1.8;
step 1.8, if j < M, j = j + 1; repeatedly executing the step 1.4; otherwise, executing step 1.9;
step 1.9, if i < K, i = i + 1; repeatedly executing the step 1.2; otherwise, finishing reading the information on the board card.
3. The distributed control system input/output point product file generation method according to claim 1, wherein compiling is performed according to information on a board card to obtain header information, specifically: obtaining the IO branch type, the IO branch name and the IO branch number from the information on the board card to obtain header file information;
compiling according to the information on the board card to obtain an instruction code, which specifically comprises the following steps: and obtaining all channel information of the board card according to the information on the board card, obtaining the type of each channel according to the channel information, and generating an instruction code corresponding to each channel according to the type of each channel.
4. The distributed control system input/output point product file generation method according to claim 1, wherein compiling is performed according to information on boards to obtain addresses of the boards, specifically: obtaining the IO node type, the IO node number, the IO branch number and the board number of the board card according to the information on the board card; and storing the IO node type, the IO node number, the IO branch number and the board card number as integer quantities of 4 bytes from high to low to obtain the address of the board card.
5. The method for generating the input/output point product file of the distributed control system according to claim 1, wherein compiling is performed according to information on boards to obtain the number of channels of the boards and the number of parameters of the boards, and specifically: the channel number of the board cards comprises the input channel number and the output channel number of the board cards, and the input channel number, the output channel number and the parameter number of the board cards are obtained according to the information on the board cards;
when the channel number and the parameter number of the board card in the variable area information are filled into the variable area, firstly compressing the input channel number, the output channel number and the parameter number of the board card into a four-byte variable according to a preset compression method, and converting the compressed four-byte variable into an IEC variable; filling the number of the channels and the number of the parameters of the board cards into a variable area in the form of IEC variables;
wherein, the preset compression mode is as follows: the variable Bit1-Bit12 stores the number of input channels of the board, the variable Bit13-Bit22 stores the number of output channels of the board, and the variable Bit23-Bit32 stores the number of parameters of the board.
6. The distributed control system input/output point product file generation method according to claim 1, wherein when filling parameters of boards in the variable area information into the variable area, the parameters of the boards are first converted into IEC variables, and then the parameters of the boards are filled into the variable area in the form of IEC variables;
wherein, convert the parameter of integrated circuit board into the IEC variable through following mode:
a. converting the type of the parameters of the board card into a first IEC variable;
b. converting the value of the parameter of the board card into a second IEC variable;
c. and combining the first IEC variable and the second IEC variable into an IEC variable, and adding an offset address to the IEC variable, wherein the offset address is obtained according to the position of the board card parameter in the new building process.
7. The distributed control system input/output point product file generation method according to claim 1, wherein when a channel of a board card in the variable area information is filled in the variable area, the channel of the board card is first converted into an IEC variable, and then the channel of the board card is filled in the variable area in the form of the IEC variable;
wherein, the passageway with the integrated circuit board is converted into the IEC variable through following mode: traversing all channels in the board card, and converting fields in the channels into IEC variables according to the types of the channels; the types of the channels are divided into switch input quantity with alarm, switch input quantity without alarm, switch output quantity with alarm, switch output quantity without alarm, analog input quantity with alarm, analog input quantity without alarm, analog output quantity with alarm and analog output quantity without alarm.
8. The method for generating the input/output point product file of the distributed control system according to claim 1, wherein compiling is performed according to information on a board card to obtain page information, specifically: and acquiring configuration information of all IO nodes, IO branches and the board card from the information on the board card to obtain page information.
9. The method of claim 1, wherein the page information is filled in the page information area in an XML format.
10. A system for generating input and output point product files of a decentralized control system is characterized by comprising:
the reading module is used for reading information on a board card in the controller;
the partitioning module is used for partitioning a pre-allocated memory for storing the input/output point product file on the configuration tool, and specifically dividing the pre-allocated memory into a file header information area, a variable area, an instruction code area and a page information area;
the compiling module is used for compiling the information on the board card to obtain header information, variable area information, instruction codes and page information; the file header information comprises an IO branch type, an IO branch name and an IO branch number; the variable area information comprises the address of the board card, the version number of the board card, the channel number of the board card, the parameter number of the board card, the channel of the board card and the parameter of the board card; the page information comprises configuration information of IO nodes, IO branches and board cards;
and the storage module is used for correspondingly filling the file header information, the variable area information, the instruction codes and the page information into the file header information area, the variable area, the instruction code area and the page information area to obtain the input/output point product file.
CN202111313903.1A 2021-11-08 2021-11-08 Method and system for generating input/output point product file of distributed control system Active CN113759884B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111313903.1A CN113759884B (en) 2021-11-08 2021-11-08 Method and system for generating input/output point product file of distributed control system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111313903.1A CN113759884B (en) 2021-11-08 2021-11-08 Method and system for generating input/output point product file of distributed control system

Publications (2)

Publication Number Publication Date
CN113759884A true CN113759884A (en) 2021-12-07
CN113759884B CN113759884B (en) 2022-02-01

Family

ID=78784799

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111313903.1A Active CN113759884B (en) 2021-11-08 2021-11-08 Method and system for generating input/output point product file of distributed control system

Country Status (1)

Country Link
CN (1) CN113759884B (en)

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
AU5194900A (en) * 1996-01-16 2000-10-26 British Telecommunications Public Limited Company Distributed processing
CN102542071A (en) * 2012-01-17 2012-07-04 深圳市同洲视讯传媒有限公司 Distributed data processing system and method
CN106647412A (en) * 2017-01-17 2017-05-10 爱普(福建)科技有限公司 Data sharing method between distributed controllers based on configuration element
CN108228077A (en) * 2016-12-14 2018-06-29 阿里巴巴集团控股有限公司 The management method of memory block, operation method, device, equipment, readable medium
CN110162306A (en) * 2018-02-14 2019-08-23 阿里巴巴集团控股有限公司 The just-ahead-of-time compilation method and apparatus of system
CN110377288A (en) * 2018-04-13 2019-10-25 赛灵思公司 Neural network compresses compiler and its compiling compression method
CN111240720A (en) * 2020-03-27 2020-06-05 武汉光谷信息光电子创新中心有限公司 Boot program upgrading method and device and storage medium
CN111488631A (en) * 2020-06-28 2020-08-04 中国核动力研究设计院 Nuclear-level security display device and configuration-analysis system thereof
CN111948998A (en) * 2020-08-24 2020-11-17 西安热工研究院有限公司 Distributed controller database downloading structure and method based on double buffer areas
CN212391726U (en) * 2020-08-24 2021-01-22 西安热工研究院有限公司 Distributed controller database downloading structure based on double buffer areas
CN113311788A (en) * 2021-04-13 2021-08-27 南京南瑞继保电气有限公司 Variable configuration processing method and device, computer storage medium and equipment
CN113434489A (en) * 2021-08-26 2021-09-24 西安热工研究院有限公司 Real-time database online capacity expansion method, system, equipment and storage medium

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
AU5194900A (en) * 1996-01-16 2000-10-26 British Telecommunications Public Limited Company Distributed processing
CN102542071A (en) * 2012-01-17 2012-07-04 深圳市同洲视讯传媒有限公司 Distributed data processing system and method
CN108228077A (en) * 2016-12-14 2018-06-29 阿里巴巴集团控股有限公司 The management method of memory block, operation method, device, equipment, readable medium
CN106647412A (en) * 2017-01-17 2017-05-10 爱普(福建)科技有限公司 Data sharing method between distributed controllers based on configuration element
CN110162306A (en) * 2018-02-14 2019-08-23 阿里巴巴集团控股有限公司 The just-ahead-of-time compilation method and apparatus of system
CN110377288A (en) * 2018-04-13 2019-10-25 赛灵思公司 Neural network compresses compiler and its compiling compression method
CN111240720A (en) * 2020-03-27 2020-06-05 武汉光谷信息光电子创新中心有限公司 Boot program upgrading method and device and storage medium
CN111488631A (en) * 2020-06-28 2020-08-04 中国核动力研究设计院 Nuclear-level security display device and configuration-analysis system thereof
CN111948998A (en) * 2020-08-24 2020-11-17 西安热工研究院有限公司 Distributed controller database downloading structure and method based on double buffer areas
CN212391726U (en) * 2020-08-24 2021-01-22 西安热工研究院有限公司 Distributed controller database downloading structure based on double buffer areas
CN113311788A (en) * 2021-04-13 2021-08-27 南京南瑞继保电气有限公司 Variable configuration processing method and device, computer storage medium and equipment
CN113434489A (en) * 2021-08-26 2021-09-24 西安热工研究院有限公司 Real-time database online capacity expansion method, system, equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
白永臣等: "硬盘数据存储格式与系统区域的备份", 《计算机时代》 *

Also Published As

Publication number Publication date
CN113759884B (en) 2022-02-01

Similar Documents

Publication Publication Date Title
CN110287163B (en) Method, device, equipment and medium for collecting and analyzing security log
CN107463706B (en) Hadoop-based mass wave recording data storage and analysis method and system
CN110928802A (en) Test method, device, equipment and storage medium based on automatic generation of case
CN110543427B (en) Test case storage method and device, electronic equipment and storage medium
CN111552669A (en) Data processing method and device, computing equipment and storage medium
CN104991860A (en) WEB front-end automated development method and system
CN109062906B (en) Translation method and device for program language resources
CN110769002A (en) LabVIEW-based message analysis method, system, electronic device and medium
CN112214366A (en) Test method, device, system, equipment and medium
CN114020272A (en) Serialized encoding and decoding methods and devices and electronic equipment
CN108170602B (en) Test case generation method and device, terminal and computer readable medium
CN113759884B (en) Method and system for generating input/output point product file of distributed control system
CN113741411B (en) Generation method and system of global variable point product file of distributed control system
CN104484174B (en) The treating method and apparatus of the compressed file of RAR forms
CN112905443A (en) Test case generation method, device and storage medium
CN112132271A (en) Neural network accelerator operation method, architecture and related device
CN113806231A (en) Code coverage rate analysis method, device, equipment and medium
CN109992293B (en) Method and device for assembling Android system component version information
CN112416365A (en) File conversion method, device and storage medium
CN112433950A (en) Method for automatically building test environment, electronic equipment and storage medium
CN111143182A (en) Method and device for analyzing process behaviors and storage medium
CN110597517A (en) Method and device for dynamically analyzing mat file
CN110008281A (en) A kind of processing method and processing device based on Redis database visualization data
CN109194529B (en) Interaction method and device for virtual SIM card and server apdu
CN111144086B (en) Log formatting method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant