CN108829440B - Method and system for converting logic configuration array into logic execution command - Google Patents

Method and system for converting logic configuration array into logic execution command Download PDF

Info

Publication number
CN108829440B
CN108829440B CN201810552166.2A CN201810552166A CN108829440B CN 108829440 B CN108829440 B CN 108829440B CN 201810552166 A CN201810552166 A CN 201810552166A CN 108829440 B CN108829440 B CN 108829440B
Authority
CN
China
Prior art keywords
array
function block
relation
task
sequence
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.)
Active
Application number
CN201810552166.2A
Other languages
Chinese (zh)
Other versions
CN108829440A (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.)
Fuzhou Diting Technology Co ltd
Original Assignee
Fuzhou Diting Technology Co ltd
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 Fuzhou Diting Technology Co ltd filed Critical Fuzhou Diting Technology Co ltd
Priority to CN201810552166.2A priority Critical patent/CN108829440B/en
Publication of CN108829440A publication Critical patent/CN108829440A/en
Application granted granted Critical
Publication of CN108829440B publication Critical patent/CN108829440B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30003Arrangements for executing specific machine instructions
    • G06F9/30007Arrangements for executing specific machine instructions to perform operations on data operands
    • G06F9/30029Logical and Boolean instructions, e.g. XOR, NOT
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/30145Instruction analysis, e.g. decoding, instruction word fields
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Programmable Controllers (AREA)

Abstract

The invention provides a method and a system for converting a logic configuration array into a logic execution command, which are used for creating an array, wherein the array comprises a function block relation array for storing input and output relation values of each function block, a program page calculation sequence array for storing a table address of each function block relation array and a table address for storing the calculation sequence array of each program page; storing the configured logic relationship and the specific input/output value in a corresponding array; sequentially scanning the array, and sequentially executing the contents of all the functional blocks according to a specific algorithm pre-written by each functional block, so as to realize logic operation, wherein the scanning sequence is as follows: task page calculation order array→program page calculation order array→function block relation array. The invention expresses the complex logic relation among the functional blocks through the array, analyzes the arrays by scanning the arrays in sequence, and executes the content of the functional blocks, thereby realizing logic operation, being simple and efficient and being applicable to any hardware controller.

Description

Method and system for converting logic configuration array into logic execution command
Technical Field
The present invention relates to the field of industrial control automation, and in particular, to a method for converting a logic configuration array into a logic execution command.
Background
Along with the continuous improvement of the industrial automation degree, the application of PLC/DCS/IPC/ARM and the like is more and more extensive, but the technical requirements on the PLC/DCS/IPC/ARM and the like are also higher and higher. In the process of using the PLC/DCS/IPC/ARM and the like, engineers build the logic relationship by applying the circuit principle thinking, then the logic relationship is compiled into an execution statement of a computer by programming software and is downloaded to the PLC/DCS/IPC/ARM and the like, and the PLC/DCS/IPC/ARM and the like execute the downloaded command so as to achieve the logic relationship effect expected by the engineers.
Because different controller manufacturers use programming software of their own, and because of the factors of software and hardware design architecture, different execution sentences are presented for the same logic relationship, so that users need to realize the same logic relationship by using different execution sentences, and the logic universality is greatly reduced.
Disclosure of Invention
The invention aims to provide a method and a system for converting a logic configuration array into a logic execution command, wherein complex logic relations among functional blocks are represented by the array, data in the array are analyzed by sequentially scanning the array, and the content of the functional blocks is executed, so that logic operation is realized, the working complexity of engineers is greatly reduced, the efficiency is improved, and the method and the system are suitable for any hardware controller.
The method is realized as follows: a method of converting a logical configuration array into a logical execution command, comprising:
step S1, creating an array comprising a function block relation array, a program page calculation sequence array and a task page calculation sequence array, wherein:
the function block relation array stores the input-output relation value of each function block;
the program page calculation sequence array stores the table address of the function block relation array;
the task page calculation sequence array stores the table address of the program page calculation sequence array;
s2, storing the configured logic relationship and the specific input/output value in a corresponding array;
step S3, scanning the array in sequence, and sequentially executing the content of the functional blocks according to a specific algorithm pre-written by each functional block, so that logic operation is realized, and the scanning sequence is as follows: task page calculation order array→program page calculation order array→function block relation array.
Further, when the task page calculation sequence array is scanned, jumping into the corresponding program page calculation sequence array according to the table address of the stored program page calculation sequence array to continue scanning; when the program page calculation sequence array is scanned, jumping into the corresponding function block relation array according to the stored table address of the function block relation array to continue scanning; when the function block relation array is scanned, according to the input-output relation value of each function block, the function block algorithm is called to calculate through the input pin information of the function block, and then the calculation result is processed to the output pin of the function block.
Further, the array may further include a main task computing order array, where the main task computing order array stores a table address of each task page computing order array; the scan order is: a master task calculation sequence array, a task page calculation sequence array, a program page calculation sequence array and a function block relation array; when the main task computing sequence array is scanned, jumping into the corresponding task page computing sequence array according to the stored table address of the task page computing sequence array to continue scanning.
The system of the invention is realized as follows: a system for converting a logical configuration array into a logical execution command, comprising:
the creation array module is used for creating an array, and comprises a function block relation array, a program page calculation sequence array and a task page calculation sequence array, wherein:
the function block relation array stores the input-output relation value of each function block;
the program page calculation sequence array stores the table address of the function block relation array;
the task page calculation sequence array stores the table address of the program page calculation sequence array;
the configuration module is used for configuring the logic relation of each functional block and setting specific input and output values of each functional block, and simultaneously storing the configured logic relation and the set input and output values in corresponding arrays;
the scanning execution module is used for sequentially scanning the array, and sequentially executing the content of the functional blocks according to a specific algorithm pre-written by each functional block, so that the logic operation is realized, and the scanning sequence is as follows: task page calculation order array→program page calculation order array→function block relation array.
Further, when the scanning execution module scans the task page calculation sequence array, the scanning execution module jumps into the corresponding program page calculation sequence array according to the table address of the stored program page calculation sequence array to continue scanning; when the program page calculation sequence array is scanned, jumping into the corresponding function block relation array according to the stored table address of the function block relation array to continue scanning; when the function block relation array is scanned, the input and output relation value of each function block is stored, the function block algorithm is called to calculate through the input pin information of the function block, and then the calculation result is processed to the output pin of the function block.
Further, the array may further include a main task computing order array, where the main task computing order array stores a table address of each task page computing order array; the scan order is: a master task calculation sequence array, a task page calculation sequence array, a program page calculation sequence array and a function block relation array; when the main task computing sequence array is scanned, jumping into the corresponding task page computing sequence array according to the stored table address of the task page computing sequence array to continue scanning.
The invention has the following advantages: the invention expresses the complex logic relation among all the functional blocks through the array, analyzes the data in all the arrays by scanning the arrays in sequence, converts the data into the logic relation, executes the content of the functional blocks, thereby realizing the logic operation, and the numerical information of the arrays is the same as long as the logic relation is the same, and the execution result is the same; greatly reduces the work complexity of engineers, improves the efficiency, and is applicable to any hardware controller (including PLC/DCS/IPC/ARM and the like).
Drawings
The invention will be further described with reference to examples of embodiments with reference to the accompanying drawings.
FIG. 1 is a flow chart of the method of the present invention.
FIG. 2 is a schematic diagram of a functional block relation array according to the present invention.
FIG. 3 is a block diagram illustrating a program page calculation order array according to the present invention.
FIG. 4 is a block diagram illustrating a task page computation order array according to the present invention.
Fig. 5 is a schematic diagram of a structure of main task computing sequence data according to the present invention.
FIG. 6 is a schematic diagram of a scan array according to the present invention.
Detailed Description
Referring to fig. 1, the method for converting a logic configuration array into a logic execution command according to the present invention includes:
step S1, creating an array comprising a function block relation array, a program page calculation sequence array and a task page calculation sequence array, wherein:
as shown in fig. 2, the function block relation array stores the input-output relation value of each function block;
as shown in fig. 3, the program page calculation order array stores a table address of each function block relation array;
as shown in fig. 4, the task page calculation order array stores a table address of each program page calculation order array;
as shown in FIG. 5, in particular embodiments, the array of the present invention may further comprise a master task computing order array that holds the table address of each task page computing order array;
s2, storing the configured logic relationship and the specific input/output value in a corresponding array;
step S3, as shown in FIG. 6, the array is scanned sequentially, and the content of the functional blocks is executed sequentially according to a specific algorithm pre-written by each functional block, so that logic operation is realized, wherein the scanning sequence is as follows: main task calculation sequence array- & gt task page calculation sequence array- & gt program page calculation sequence array- & gt function block relation array.
When the main task computing sequence array is scanned, jumping into the corresponding task page computing sequence array according to the stored table address of the task page computing sequence array to continue scanning;
when the task page calculation sequence array is scanned, jumping into the corresponding program page calculation sequence array according to the stored table address of the program page calculation sequence array to continue scanning;
when the program page calculation sequence array is scanned, jumping into the corresponding function block relation array according to the stored table address of the function block relation array to continue scanning;
when the function block relation array is scanned, according to the input-output relation value of each function block, the function block algorithm is called to calculate through the input pin information of the function block, and then the calculation result is processed to the output pin of the function block.
According to the method of the present invention, as shown in fig. 1 to 6, the present invention further provides a system for converting a logic configuration array into a logic execution command, the system comprising:
the creation array module is used for creating an array, and comprises a function block relation array, a program page calculation sequence array and a task page calculation sequence array, wherein:
the function block relation array stores the input-output relation value of each function block;
the program page calculation sequence array stores the table address of the function block relation array;
the task page calculation sequence array stores the table address of the program page calculation sequence array;
in a specific embodiment, the array of the present invention may further include a main task computing order array, where the main task computing order array stores a table address of each task page computing order array;
the configuration module is used for configuring the logic relation of each functional block and setting specific input and output values of each functional block, and simultaneously storing the configured logic relation and the set input and output values in corresponding arrays;
the scanning execution module is used for sequentially scanning the array, and sequentially executing the content of the functional blocks according to a specific algorithm pre-written by each functional block, so that the logic operation is realized, and the scanning sequence is as follows: main task calculation sequence array- & gt task page calculation sequence array- & gt program page calculation sequence array- & gt function block relation array.
When the main task computing sequence array is scanned, jumping into the corresponding task page computing sequence array according to the stored table address of the task page computing sequence array to continue scanning;
when the scanning execution module scans the task page calculation sequence array, jumping into the corresponding program page calculation sequence array according to the table address of the stored program page calculation sequence array to continue scanning;
when the program page calculation sequence array is scanned, jumping into the corresponding function block relation array according to the stored table address of the function block relation array to continue scanning;
when the function block relation array is scanned, the input and output relation value of each function block is stored, the function block algorithm is called through the input pin information of the function block to calculate, and then the calculation result is processed to the output pin of the function block.
In summary, the invention expresses the complex logic relationship among the functional blocks through the array, analyzes the data in each array by scanning the array in sequence, converts the data into the logic relationship, and executes the content of the functional blocks, thereby realizing the logic operation, and the numerical information of the arrays is the same as long as the same logic relationship is achieved, and the execution result is the same; greatly reduces the work complexity of engineers, improves the efficiency, and is applicable to any hardware controller (including PLC/DCS/IPC/ARM and the like).
While specific embodiments of the invention have been described above, it will be appreciated by those skilled in the art that the specific embodiments described are illustrative only and not intended to limit the scope of the invention, and that equivalent modifications and variations of the invention in light of the spirit of the invention will be covered by the claims of the present invention.

Claims (6)

1. A method for converting a logic configuration array into a logic execution command, comprising: comprising the following steps:
step S1, creating an array comprising a function block relation array, a program page calculation sequence array and a task page calculation sequence array, wherein:
the function block relation array stores the input-output relation value of each function block;
the program page calculation sequence array stores the table address of each function block relation array;
the task page calculation sequence array stores the table address of each program page calculation sequence array;
s2, storing the configured logic relationship and the specific input/output value in a corresponding array;
step S3, scanning the array in sequence, and sequentially executing the contents of all the functional blocks according to a specific algorithm pre-written by each functional block, so that logic operation is realized, and the scanning sequence is as follows: task page calculation order array→program page calculation order array→function block relation array.
2. The method of claim 1, wherein the converting the set of logical configuration into the logical execute command comprises: when the task page calculation sequence array is scanned, jumping into the corresponding program page calculation sequence array according to the stored table address of the program page calculation sequence array to continue scanning; when the program page calculation sequence array is scanned, jumping into the corresponding function block relation array according to the stored table address of the function block relation array to continue scanning; when the function block relation array is scanned, according to the input-output relation value of each function block, the function block algorithm is called to calculate through the input pin information of the function block, and then the calculation result is processed to the output pin of the function block.
3. The method of claim 1, wherein the converting the set of logical configuration into the logical execute command comprises: the array also comprises a main task computing sequence array, wherein the main task computing sequence array stores the table address of each task page computing sequence array; the scan order is: a master task calculation sequence array, a task page calculation sequence array, a program page calculation sequence array and a function block relation array; when the main task computing sequence array is scanned, jumping into the corresponding task page computing sequence array according to the stored table address of the task page computing sequence array to continue scanning.
4. A system for converting a logical configuration array into a logical execution command, comprising: comprising the following steps:
the creation array module is used for creating an array, and comprises a function block relation array, a program page calculation sequence array and a task page calculation sequence array, wherein:
the function block relation array stores the input-output relation value of each function block;
the program page calculation sequence array stores the table address of the function block relation array;
the task page calculation sequence array stores the table address of the program page calculation sequence array;
the configuration module is used for configuring the logic relation of each functional block and setting specific input and output values of each functional block, and simultaneously storing the configured logic relation and the set input and output values in corresponding arrays;
the scanning execution module is used for sequentially scanning the array, and sequentially executing the content of the functional blocks according to a specific algorithm pre-written by each functional block, so that the logic operation is realized, and the scanning sequence is as follows: task page calculation order array→program page calculation order array→function block relation array.
5. The system for converting a logical configuration array into a logical execute command according to claim 4, wherein: when the scanning execution module scans the task page calculation sequence array, jumping into the corresponding program page calculation sequence array according to the table address of the stored program page calculation sequence array to continue scanning; when the program page calculation sequence array is scanned, jumping into the corresponding function block relation array according to the stored table address of the function block relation array to continue scanning; when the function block relation array is scanned, the input and output relation value of each function block is stored, the function block algorithm is called to calculate through the input pin information of the function block, and then the calculation result is processed to the output pin of the function block.
6. The system for converting a logical configuration array into a logical execute command according to claim 4, wherein: the array also comprises a main task computing sequence array, wherein the main task computing sequence array stores the table address of each task page computing sequence array; the scan order is: a master task calculation sequence array, a task page calculation sequence array, a program page calculation sequence array and a function block relation array; when the main task computing sequence array is scanned, jumping into the corresponding task page computing sequence array according to the stored table address of the task page computing sequence array to continue scanning.
CN201810552166.2A 2018-05-31 2018-05-31 Method and system for converting logic configuration array into logic execution command Active CN108829440B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810552166.2A CN108829440B (en) 2018-05-31 2018-05-31 Method and system for converting logic configuration array into logic execution command

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810552166.2A CN108829440B (en) 2018-05-31 2018-05-31 Method and system for converting logic configuration array into logic execution command

Publications (2)

Publication Number Publication Date
CN108829440A CN108829440A (en) 2018-11-16
CN108829440B true CN108829440B (en) 2023-05-02

Family

ID=64145440

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810552166.2A Active CN108829440B (en) 2018-05-31 2018-05-31 Method and system for converting logic configuration array into logic execution command

Country Status (1)

Country Link
CN (1) CN108829440B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110928602B (en) * 2019-12-06 2022-09-20 浙江中控技术股份有限公司 FBD program operation method and device
CN115827787B (en) * 2023-02-15 2023-06-20 仁通融合(南京)信息技术有限公司 Internet Yun Zhiku management method

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101872184A (en) * 2010-06-04 2010-10-27 南大傲拓科技江苏有限公司 Programming and control method of sequence control diagram of programmable controller
TW201511020A (en) * 2013-03-15 2015-03-16 Netlist Inc Memory system with configurable error thresholds and failure analysis capability

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6285966B1 (en) * 1998-06-25 2001-09-04 Fisher Controls International, Inc. Function block apparatus for viewing data in a process control system
US7376717B2 (en) * 2003-04-17 2008-05-20 Lenovo (Singapore) Pte Ltd. Method and apparatus for automatically configuring a computer for different local area networks
CN100470469C (en) * 2006-08-29 2009-03-18 深圳达实智能股份有限公司 Realization method of configuration control
US20090254573A1 (en) * 2008-04-04 2009-10-08 General Motors Corporation Plant floor event protocol and schema
CN100541364C (en) * 2008-05-13 2009-09-16 四方电气(集团)有限公司 Programmable logic control method based on field bus communication
CN102299933B (en) * 2010-06-22 2015-07-01 中国国电集团公司 Engineering configuration management method and system for distributed control system (DCS)
CN103745634B (en) * 2013-12-21 2016-05-04 柳州职业技术学院 Motor Control Experiment System based on PLC and application process thereof
CN106569801B (en) * 2016-10-18 2020-04-10 中国运载火箭技术研究院 Configuration display and control system based on complex parameters
CN106483930A (en) * 2016-11-18 2017-03-08 华中科技大学 A kind of method of automatic configuration of mixed type restructural CANopen slave station

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101872184A (en) * 2010-06-04 2010-10-27 南大傲拓科技江苏有限公司 Programming and control method of sequence control diagram of programmable controller
TW201511020A (en) * 2013-03-15 2015-03-16 Netlist Inc Memory system with configurable error thresholds and failure analysis capability

Also Published As

Publication number Publication date
CN108829440A (en) 2018-11-16

Similar Documents

Publication Publication Date Title
CN108829440B (en) Method and system for converting logic configuration array into logic execution command
US11198219B2 (en) Controller, control system, and control method
CN106909123B (en) Control programming auxiliary assembly
CN103941650A (en) Logic and movement integrated controller
CN110704364A (en) Automatic dynamic reconstruction method and system based on field programmable gate array
US20190012168A1 (en) Program generating apparatus
CN111352620A (en) Visual configuration programming method and system
CN103324541A (en) Method for automatically transmitting data between software
CN103942081A (en) Method for generating IL instruction lists of PLC ladder diagrams
CN111267111B (en) Robot control method, device and system
CN104090519A (en) System for being in communication with PLC extended module and implementation method thereof
CN107145944B (en) Genetic algorithm and system based on FPGA efficient training
CN108762751A (en) A kind of logic figure configuration and the method and system for changing into data flow
CN110147226B (en) System, method and device for automatically generating program according to functional block diagram
CN108121285B (en) Application software collaborative compiling method and device based on continuous function diagram
CN103838616A (en) Tree program branch based computer program immediate compiling method
Eassa et al. RISC-V based implementation of Programmable Logic Controller on FPGA for Industry 4.0
CN112180808B (en) Servo control method, device, system, computer equipment and storage medium
CN107678393B (en) Intelligent spraying control system and method based on soft PLC
CN113433885A (en) Method for converting ladder diagram of PLC programming system into structured text
KR101896112B1 (en) Integration of CAD and CAE for the optimum design of an automotive part
CN104461569A (en) C/C++ program generation assisting method based on MATLAB
JP2008299763A (en) Distributed object development tool
CN109522044B (en) Motion control card configuration file generation method and device and computer readable memory
CN114489777B (en) Communication method and device for automation system and peripheral

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
TA01 Transfer of patent application right

Effective date of registration: 20191210

Address after: 350100 third floor, e, workshop 2, No. 99, Gujing, mabao village, Shangjie Town, Minhou County, Fuzhou City, Fujian Province

Applicant after: Fuzhou diting Technology Co.,Ltd.

Address before: 350100 workshop e, No. 99, Gujing, mabao village, Shangjie Town, Minhou County, Fuzhou City, Fujian Province

Applicant before: FUZHOU ZHIMA INTELLIGENT TECHNOLOGY Co.,Ltd.

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant