JPH0498531A - Automatic program generating device with block diagram processing function - Google Patents

Automatic program generating device with block diagram processing function

Info

Publication number
JPH0498531A
JPH0498531A JP21671590A JP21671590A JPH0498531A JP H0498531 A JPH0498531 A JP H0498531A JP 21671590 A JP21671590 A JP 21671590A JP 21671590 A JP21671590 A JP 21671590A JP H0498531 A JPH0498531 A JP H0498531A
Authority
JP
Japan
Prior art keywords
program
block diagram
program generation
variable
partial
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
JP21671590A
Other languages
Japanese (ja)
Other versions
JP2724240B2 (en
Inventor
Yasuko Sano
佐野 康子
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.)
Toshiba Corp
Original Assignee
Toshiba Corp
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 Toshiba Corp filed Critical Toshiba Corp
Priority to JP21671590A priority Critical patent/JP2724240B2/en
Publication of JPH0498531A publication Critical patent/JPH0498531A/en
Application granted granted Critical
Publication of JP2724240B2 publication Critical patent/JP2724240B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Abstract

PURPOSE:To extremely improve the working efficiency for generation of a program by providing a program generating means, a block diagram program generating means, and a variable attribute control means. CONSTITUTION:A block diagram program generating means 4 analyzes the contents shown by the block diagram form system specifications 7 in accordance with the program generation goal received from a program generation control means 12. Then the means 4 decides the name of the variable to be used in a part program that is generated thereafter so that the same name is given to the variable having the same meaning as the variable that is used in another part program after generating a variable attribute deciding pattern based on an internal knowledge base of its own and sending the pattern to a variable attribute control means 5. Thus a desired part program is obtained. As a result, the reduction of labor and the working efficiency can be more improved for generation of a program.

Description

【発明の詳細な説明】 [発明の目的] (産業上の利用分野) 本発明は、例えばプロセス制御システム等からなる対象
システムにおけるシステム仕様に合ったプログラムを自
動生成するプログラム自動生成装置に係わり、特に、制
御対象を動作させるための速度基準などを示すブロック
図で表現されたブロック図形式システム仕様をそのまま
使用して目的とするプログラムを生成する機能を有する
ブロツク図処理機能付きプログラム自動生成装置に関す
る。
[Detailed Description of the Invention] [Object of the Invention] (Industrial Application Field) The present invention relates to an automatic program generation device that automatically generates a program that matches the system specifications of a target system such as a process control system. In particular, it relates to an automatic program generation device with a block diagram processing function, which has a function of generating a target program by directly using a block diagram format system specification expressed in a block diagram showing speed standards for operating a controlled object, etc. .

(従来の技術) 一般に、複数の部分プログラムの内部で使用される各変
数を一括管理して、同じ意味を持つ変数の名称に統一す
ることにより、複数の部分プログラムを集合して一つの
統合プログラムを生成するようにしている。このような
統合プログラムを作成するプログラム自動生成装置は例
えば第7図に示すように構成されている。
(Prior art) In general, multiple partial programs are collected into one integrated program by collectively managing each variable used within multiple partial programs and unifying the names of variables that have the same meaning. I am trying to generate . An automatic program generation device for creating such an integrated program is configured as shown in FIG. 7, for example.

すなわち、このプログラム自動生成装置1は、大きく分
けて、プログラム生成制御手段2と複数のプログラム生
成手段3と変数属性管理手段5とで構成され、外部から
システム仕様6が入力すると、このシステム仕様6に基
づいてこのシステム仕様6に示される内容に適合したプ
ログラム8を自動生成する。
That is, this automatic program generation device 1 is roughly divided into a program generation control means 2, a plurality of program generation means 3, and a variable attribute management means 5, and when a system specification 6 is input from the outside, this system specification 6 is Based on this, a program 8 that conforms to the contents shown in the system specifications 6 is automatically generated.

そして、プログラム生成手段2は、入力されたシステム
仕様6の内容に基づいてプログラム8を生成すべく統合
プログラムの構成を決定し、各部分プログラム毎に該当
部分プログラムを生成するプログラム生成手段3を選択
して、全体のプログラム生成を制御する機能を有する。
Then, the program generation means 2 determines the configuration of the integrated program to generate the program 8 based on the contents of the input system specifications 6, and selects the program generation means 3 for generating the corresponding partial program for each partial program. It has the function of controlling the entire program generation.

また、各プログラム生成手段3は、プログラム生成制御
手段2からいかなる目的を持った部分プログラムを生成
すべきかという情報、すなわち[プログラム生成ゴール
]を受は取り、その目的に応じた部分プログラムを生成
する。具体的手法としては、プログラムの各部品を検索
し、プログラムの目的に応して展開して部分プログラム
を生成する部品合成手法等が主に採用されている。
Furthermore, each program generation means 3 receives information about what purpose a partial program should be generated from the program generation control means 2, that is, [program generation goal], and generates a partial program according to the purpose. . As a specific method, a component synthesis method is mainly adopted in which each component of a program is searched and expanded according to the purpose of the program to generate a partial program.

また、変数属性管理手段5は、各プログラム生成手段3
において部分プログラムを生成する際に、その部分プロ
グラム内で使用される変数の意味を表した変数属性決定
パターンを受は取り、その変数属性決定パターンで示さ
れる意味に適合した変数名称を該当プログラム生成手段
3へ返信する。
Further, the variable attribute management means 5 includes each program generation means 3.
When generating a partial program, a variable attribute determination pattern representing the meaning of variables used in the partial program is received, and variable names that match the meanings indicated by the variable attribute determination pattern are generated for the corresponding program. Reply to method 3.

しかしながら、第7図に示したようなプログラム自動生
成装置1においてもまだ改良すべき次のような課題があ
った。
However, the automatic program generation device 1 as shown in FIG. 7 still has the following problems that need to be improved.

すなわち、通常、前述したプラントの制御等に用いられ
るプログラマブルコントローラのプログラムを設計する
場合には、制御に用いられる各種機器の詳細情報を表現
したシステム仕様の他に、第8図に示したような、機器
が動作する時の速度基準の与え方等を示したブロック図
形式の仕様が用いられる。しかし、第7図に示す従来方
式の部品合成によるプログラム自動生成装置1では、各
種機器の詳細情報を基にしたプログラムの自動生成には
対応できるが、第8図に示すようなブロック図形式の仕
様に対しては、うまくプログラム自動生成が行われない
という問題点があった。
In other words, when designing a program for a programmable controller used for plant control, etc., as described above, in addition to system specifications that express detailed information on various devices used for control, the system specifications shown in Figure 8 are usually used. , a block diagram format specification is used that shows how to provide speed standards when the equipment operates. However, the conventional program automatic generation device 1 based on component synthesis shown in FIG. 7 is capable of automatically generating programs based on detailed information of various devices; There was a problem in that the automatic program generation did not work properly for the specifications.

このような場合は、第8図に示すブロック図形式の仕様
を設計者が通常形式で表現されたシステム仕様に書直し
たのち、プログラム自動生成装置1へ入力する必要があ
った。しかし、この通常形式のシステム仕様に書直す作
業は非常に繁雑であるので、プログラム作成作業能率が
低下する問題があった。また、正確にシステム仕様に書
直しできない変数等も存在し、高精度のプログラムを生
成できない場合もある。さらに、間違って書直す懸念も
ある。
In such a case, it was necessary for the designer to rewrite the specification in the block diagram format shown in FIG. 8 into a system specification expressed in a normal format, and then input it to the automatic program generation device 1. However, since the work of rewriting the system specifications in the normal format is very complicated, there is a problem that the efficiency of the program creation work is reduced. Furthermore, there are variables that cannot be rewritten accurately to the system specifications, and it may not be possible to generate a highly accurate program. Furthermore, there is a concern that the text may be rewritten incorrectly.

(発明が解決しようとする課題) このように、従来のプログラム自動生成装置においては
、ブロック図形式の仕様に対しては、円滑にプログラム
自動生成が行われない問題があった。
(Problems to be Solved by the Invention) As described above, in the conventional automatic program generation apparatus, there is a problem that automatic program generation cannot be performed smoothly for specifications in the block diagram format.

本発明は、このような事情に鑑みてなされたもので、従
来におけるプログラムの部品合成等のプログラム生成手
段が持つ特長を生かしつつ、ブロック図形式の仕様が入
力された場合にもそのままプログラム生成か可能となり
、プログラム生成の作業能率を大幅に向上でき、さらに
高いプログラム精度を得ることができるブロック図処理
機能付きプログラム自動生成装置を提供することを目的
とする。
The present invention has been made in view of these circumstances, and while taking advantage of the features of conventional program generation means such as program component synthesis, it is also possible to directly generate a program even when a block diagram format specification is input. It is an object of the present invention to provide an automatic program generation device with a block diagram processing function, which can greatly improve work efficiency of program generation and obtain even higher program accuracy.

[発明の構成] (課題を解決するための手段) 上記課題を解決するために、本発明のブロック図処理機
能付きプログラム自動生成装置においては、外部から入
力された通常形式で表現されたシステム仕様及びブロッ
ク図形式で表現されたブロック図形式システム仕様に基
づいて、複数の部分プログラムからなる統合プログラム
の構成を決定して、各部分プログラムを生成する場合の
目的や条件を示すプログラム生成ゴールを出力してプロ
グラム生成を制御するプログラム生成制御手段と、この
プログラム生成制御手段から出力されたプログラム生成
ゴール及び入力されたシステム仕様に基づいて目的とす
る部分プログラムを生成するプログラム生成手段と、プ
ログラム生成制御手段から出力されたプログラム生成ゴ
ール及び入力されたブロック図形式システム仕様および
必要に応じてシステム仕様を参照して目的とする部分プ
ログラムを生成するブロック図プログラム生成手段と、
このブロック図プログラム生成手段及びプログラム生成
手段がそれぞれ部分プログラムを生成する場合に、生成
する各部分プログラム内で使用する変数名称を、変数の
持つ意味に基づいて一括管理し、与えられた変数の意味
に相当する変数名称をブロック図プログラム生成手段及
びプログラム生成手段へ送出する変数属性管理手段とを
備えたものである。
[Structure of the Invention] (Means for Solving the Problems) In order to solve the above problems, in the automatic program generation device with a block diagram processing function of the present invention, system specifications expressed in a normal format input from an external Based on the block diagram format system specifications expressed in block diagram format, the configuration of an integrated program consisting of multiple partial programs is determined, and a program generation goal indicating the purpose and conditions for generating each partial program is output. program generation control means for generating a target partial program based on a program generation goal output from the program generation control means and input system specifications; block diagram program generation means that generates a target partial program by referring to the program generation goal output from the means, the input block diagram format system specifications, and the system specifications as necessary;
When the block diagram program generation means and the program generation means respectively generate partial programs, the variable names used in each generated partial program are collectively managed based on the meanings of the variables, and the meanings of the given variables are The variable attribute management means for sending a variable name corresponding to the variable name to the block diagram program generation means and the program generation means.

(作用) このように構成された本発明のブロック図処理機能付き
プログラム自動生成装置に入力可能なシステム仕様の種
類は、通常形式で表現された従来のシステム仕様とブロ
ック図形式で表現されたブロック図形式システム仕様と
の2種類である。
(Operation) The types of system specifications that can be input to the automatic program generation device with block diagram processing function of the present invention configured as described above are conventional system specifications expressed in a normal format and blocks expressed in a block diagram format. There are two types: diagram format system specifications.

そして、プログラム生成制御手段が、入力された各シス
テム仕様の内容に基づき生成すべき統合プログラムの全
体の構成を決定し、各部分プログラムを生成するに適し
たプログラム生成手段を選択して、そのプログラム生成
手段に対して、いかなる目的を持った部分プログラムを
生成すべきかという情報(すなわち、プログラム生成ゴ
ール)を送出して各プログラム生成手段に対して各部分
プログラムの生成を促す。
Then, the program generation control means determines the overall configuration of the integrated program to be generated based on the contents of each input system specification, selects a program generation means suitable for generating each partial program, and programs the program. Information indicating what purpose a partial program should be generated (ie, program generation goal) is sent to the generation means to prompt each program generation means to generate each partial program.

プログラム生成手段では、プログラム生成制御手段より
入力したプログラム生成ゴールに応じて、それぞれのプ
ログラム生成手段が持つ機能を活用し、目的とする部分
プログラムを生成する。この時、プログラム生成手段で
は、部分プログラムの内部で使用する変数(または定数
)の名称を決定する際に、変数属性決定パターンを変数
属性管理手段に送出して、他の部分プログラムで使用し
ている変数と同じ意味を持つ変数に同じ名称が付与され
るように変数名称を決定する。
The program generation means utilizes the functions of each program generation means to generate a target partial program according to the program generation goal inputted from the program generation control means. At this time, when determining the names of variables (or constants) to be used within the partial program, the program generation means sends the variable attribute determination pattern to the variable attribute management means so that it can be used in other partial programs. Variable names are determined so that the same name is given to variables that have the same meaning as the existing variable.

さらに、前記プログラム生成制御手段は、入力されたブ
ロック図形式システム仕様、および、必要により、シス
テム仕様の内容を参照し、決定されたプログラム全体の
構成に対し、ブロック図形式システム仕様を用いて、い
かなる目的を持った部分プログラムを生成すべきかとい
う情報を表したプログラム生成ゴールをブロック図プロ
グラム生成手段に送出して部分プログラムの生成を促す
Furthermore, the program generation control means refers to the input block diagram format system specifications and, if necessary, the contents of the system specifications, and uses the block diagram format system specifications for the determined overall program configuration. A program generation goal representing information about what purpose a partial program should be generated is sent to the block diagram program generation means to prompt generation of the partial program.

ブロック図プログラム生成手段では、プログラム生成制
御手段より入力したプログラム生成ゴールに応じて、そ
のブロック図形式システム仕様に表現されている内容を
解析し、目的とする部分プログラムを生成する。この時
、ブロック図プログラム生成手段では、部分プログラム
の内部で使用する変数の名称を決定する際に、変数属性
決定パターンをブロック図プログラム生成手段が持つ知
識に基づいて生成し、変数属性管理手段に送出して、他
の部分プログラムで使用している変数と同じ意味を持つ
変数に同じ名称が付与されるように変数名称を決定する
The block diagram program generation means analyzes the contents expressed in the block diagram format system specifications according to the program generation goal inputted from the program generation control means, and generates a target partial program. At this time, when determining the names of variables used within the partial program, the block diagram program generation means generates a variable attribute determination pattern based on the knowledge of the block diagram program generation means, and sends the variable attribute determination pattern to the variable attribute management means. Variable names are determined so that the same name is given to variables that have the same meaning as variables that are sent and used in other partial programs.

変数属性管理手段では、各プログラム生成手段から変数
の意味を表した変数属性決定パターンを受信すると、そ
の意味に適合した変数名称が既に定義されていれば、そ
の変数名称を返信し、まだ定義されていなければ、新し
い変数名称を定義して、その変数名称を該当プログラム
生成手段へ返信する。
When the variable attribute management means receives a variable attribute determination pattern representing the meaning of a variable from each program generation means, if a variable name matching the meaning has already been defined, it returns that variable name and determines whether it is still defined. If not, a new variable name is defined and the variable name is returned to the corresponding program generation means.

このように、本発明によるプログラム自動生成装置では
、入力されたシステム仕様とブロック図形式システム仕
様に基づいて、全体が意味的に統合されたプログラムを
自動生成することが可能となる。
In this manner, the automatic program generation device according to the present invention can automatically generate a program that is semantically integrated as a whole based on the input system specifications and the block diagram format system specifications.

(実施例) 以下、本発明の一実施例を図面を用いて説明する。(Example) An embodiment of the present invention will be described below with reference to the drawings.

第1図は実施例のブロック図処理機能付きプログラム自
動生成装置の概略構成を示すブロック図である。第7図
と同一機能を有する部分には同一符号を付して詳細な説
明を省略する。
FIG. 1 is a block diagram showing a schematic configuration of an automatic program generation device with a block diagram processing function according to an embodiment. Components having the same functions as those in FIG. 7 are designated by the same reference numerals and detailed explanations will be omitted.

この実施例のプログラム自動生成装置11は、大きく分
けて、プログラム生成制御手段12と、1番からm番ま
で番号か付されたm個のプログラム生成手段3と、1個
のブロック図プログラム生成手段4と、変数属性管理手
段5とで構成され、外部からシステム仕様6またはブロ
ック図形式システム仕様7が入力すると、このシステム
仕様6及びブロック図形式システム仕様7に基づいてこ
のシステム仕様6及びブロック図形式システム仕様7に
示される内容に適合したプログラム8を自動生成する。
The automatic program generation device 11 of this embodiment is roughly divided into a program generation control means 12, m program generation means 3 numbered from 1 to m, and one block diagram program generation means. 4 and a variable attribute management means 5, and when a system specification 6 or a block diagram format system specification 7 is input from the outside, the system specification 6 and block diagram are A program 8 conforming to the contents shown in the formal system specification 7 is automatically generated.

1番からn番まで番号か付されたn個の各システム仕様
6内には、例えばプロセス制御システム等を設計する場
合に必要となる各種仕様か格納されており、設計者によ
ってキーボードや文字入力手段等により入力されたもの
や、入力されたものを各種変換手段により所定のデータ
形式に変換されたものが含まる。
Each of the n system specifications 6, numbered from 1 to n, contains various specifications required when designing a process control system, etc., and is used by the designer to use the keyboard or input characters. This includes data input by means, etc., and data converted from input into a predetermined data format by various conversion means.

また、ブロック図形式システム仕様7は、第2図に示す
ように、プラントを構成する各種機器か動作する時の速
度基準の与え方などを示したブロック図形式の仕様を表
すものであり、設計者か各種入力手段を介して入力した
もの、あるいは、その入力したものを変換手段により所
定のデータ形式に変換したものである。
In addition, the block diagram format system specification 7, as shown in Figure 2, is a block diagram format specification that shows how to give speed standards for the operation of various devices that make up the plant. The data may be input by a person through various input means, or the input may be converted into a predetermined data format by a conversion means.

これらシステム仕様6およびブロック図形式システム仕
様7か、プログラム自動生成装置11の入力となる。
These system specifications 6 and block diagram format system specifications 7 are input to the automatic program generation device 11.

プログラム生成制御手段12は、入力されたシステム仕
様6およびブロック図形式システム仕様7の内容に基づ
き複数の部分プログラムからなる統合プログラムの構成
を決定し、各部分プログラム毎に、該当部分プログラム
をプログラム生成手段3及びブロック図プログラム生成
手段4のうちのいづれて生成するかを選択決定し、選択
された生成手段に対して、いかなる目的を持った部分プ
ログラムを生成すべきかという情報を示すプログラム生
成ゴールを送出して該当プログラム生成手段3又は4に
対して該当部分プログラムの生成を指令する。
The program generation control means 12 determines the configuration of an integrated program consisting of a plurality of partial programs based on the contents of the input system specifications 6 and block diagram format system specifications 7, and generates a corresponding partial program for each partial program. It selects and decides which of the means 3 and the block diagram program generation means 4 to generate, and provides the selected generation means with a program generation goal indicating information about what purpose the partial program should be generated. It sends out an instruction to the corresponding program generation means 3 or 4 to generate the corresponding partial program.

各プログラム生成手段3は、プログラム生成制御手段1
2より受信したプログラム生成ゴールに応して、それぞ
れ自己か保有する機能を活用し、生成する部分プログラ
ムの内部で使用する変数(または定数)の名称を、変数
属性決定パターンを変数属性管理手段5に送出して他の
部分プログラムで使用している変数と同じ意味を持つ変
数に同し名称が付与されるようにして決定することによ
り、目的とする部分プログラムを生成する。
Each program generation means 3 includes a program generation control means 1
According to the program generation goal received from 2, the variable attribute management means 5 utilizes its own functions to determine the names of variables (or constants) used inside the partial program to be generated, and the variable attribute determination pattern. The target partial program is generated by assigning the same name to variables that have the same meaning as variables used in other partial programs.

また、ブロック図プログラム生成手段4は、同様にプロ
グラム生成制御手段12より受信したプログラム生成ゴ
ールに応じて、ブロック図形式システム仕様7に表現さ
れている内容を解析し、これから生成しようとする部分
プログラムの内部で使用する変数の名称を、自己の内部
に有する知識ベースに基づいて変数属性決定パターンを
生成して変数属性管理手段5に送出して、前述と同様に
、他の部分プログラムで使用している変数と同じ意味を
持つ変数に同し名称が付与されるようにして決定するこ
とにより、目的とする部分プログラムを生成する。
Further, the block diagram program generation means 4 analyzes the contents expressed in the block diagram format system specification 7 according to the program generation goal similarly received from the program generation control means 12, and generates a partial program to be generated from now on. Generates a variable attribute determination pattern for the names of variables used internally based on the knowledge base it has internally, sends it to the variable attribute management means 5, and uses it in other partial programs in the same way as described above. A target partial program is generated by assigning the same name to a variable that has the same meaning as a variable.

さらに、変数属性管理手段5は、プログラム生成手段3
及びブロック図プログラム生成手段4から変数属性決定
パターンを受信すると、その意味に適合した変数名称か
既に定義されていれば、その変数名称を該当プログラム
生成手段3.4に返信する。一方、受信した変数属性決
定パターンの意味に適合した変数名称かまだ定義されて
いなければ、新しい変数名称を定義して、その変数名称
を該当プログラム生成手段3,4に返信する。
Further, the variable attribute management means 5 includes the program generation means 3
When a variable attribute determination pattern is received from the block diagram program generation means 4, if a variable name matching the meaning has already been defined, the variable name is sent back to the corresponding program generation means 3.4. On the other hand, if a variable name matching the meaning of the received variable attribute determination pattern has not yet been defined, a new variable name is defined and the variable name is returned to the corresponding program generating means 3, 4.

第2図は、設計者がブロック図形式の仕様を入力し、変
換手段により所定のデータ形式によるブロック図形式シ
ステム仕様7を得る場合の手順を示す模式図である。
FIG. 2 is a schematic diagram showing a procedure when a designer inputs a block diagram format specification and obtains a block diagram format system specification 7 in a predetermined data format using a converting means.

すなわち、プログラムの設計者は、マウスやキーボード
、スタイラスペンなとの入力手段を用いてブロック図7
1を入力する。この入力されたブロック図71は、最終
プログラム内で用いられる変数に相当する要素の持つ性
質を記号と文字情報として表現したものや、最終プログ
ラムにおいて演算子として表現されるもの、あるいは、
それらの合成されたものを、ブロック72として表現し
、ブロックフシ相互間のデータの流れを結線73として
表現している。
In other words, the program designer uses an input means such as a mouse, keyboard, or stylus pen to input the block diagram 7.
Enter 1. This input block diagram 71 is one that expresses the properties of elements corresponding to variables used in the final program as symbols and character information, or that is expressed as operators in the final program, or
Their combination is expressed as a block 72, and the flow of data between the blocks is expressed as a connection 73.

例えば、第2図のブロック図71は■〜■までの6個の
ブロック72で構成され、各ブロック71内には[NO
,1機械コ等の機械名称。
For example, the block diagram 71 in FIG. 2 is composed of six blocks 72 from ■ to ■.
, 1 machine name, etc.

[低速]等の機能(ファンクション)、記号で表記され
たブロック種別(タイプ)、結線73で示される接続関
係等の情報が含まれる。
Information such as a function such as [low speed], a block type expressed by a symbol, and a connection relationship indicated by a connection line 73 is included.

変換手段74は、ブロック図71が入力されると、各々
のブロック72とそれらブロックフシ相互間の接続を示
す各結線73の情報を翻訳して、ブロック図形式システ
ム仕様7を得る。
When the block diagram 71 is input, the converting means 74 translates information on each block 72 and each connection line 73 indicating the connection between the blocks 72 and obtains a block diagram format system specification 7.

ブロック図形式システム仕様7は、個々のブロック72
に相当する情報と、そのブロック72の前後に付随する
結線73を示す情報とを表現したブロック情報75の集
合にて構成されている。そして、各ブロック情報75は
、前述した各ブロック72と同様に、[入カコ [出力
] [ゲート][加算]等の機器種別情報、(2,1)
(1,1)等の接続情報、機械名称、機能等の各情報を
含む。
Block diagram format system specification 7 shows individual blocks 72
The block information 75 is composed of a set of block information 75 expressing information corresponding to the block 72 and information indicating the connections 73 attached before and after the block 72. And, like each block 72 described above, each block information 75 includes device type information such as [input, output, gate, addition], (2, 1), etc.
Contains connection information such as (1, 1), machine name, function, etc.

第3図は、ブロック図形式システム仕様7がプログラム
自動生成装置11に入力された時、プログラム生成制御
手段12およびブロック図プログラム生成手段4、変数
属性管理手段5の間で、とのような情報の受は渡しかあ
るのかを示す模式図である。
FIG. 3 shows that when the block diagram format system specification 7 is input to the automatic program generation device 11, the following information is generated between the program generation control means 12, the block diagram program generation means 4, and the variable attribute management means 5. It is a schematic diagram showing whether there is a delivery or delivery.

すなわち、ブロック図形式システム仕様7が入力される
と、プログラム生成制御手段12は、入力されたブロッ
ク図形式システム仕様7に適合する部分プログラムを生
成させるためのプログラム生成ゴール14を生成し、ブ
ロック図プログラム生成手段4に送出する。この時、入
力されたブロック図形式システム仕様7に含まれるブロ
ック情報75か、いくつかの集合に分割される場合には
、必要なブロック情報75の集合毎にプログラム生成ゴ
ール14を生成して、ブロック図プログラム生成手段4
へ送出する。
That is, when the block diagram format system specification 7 is input, the program generation control means 12 generates a program generation goal 14 for generating a partial program that conforms to the input block diagram format system specification 7, and It is sent to the program generation means 4. At this time, if the block information 75 included in the input block diagram format system specification 7 is divided into several sets, a program generation goal 14 is generated for each set of necessary block information 75, Block diagram program generation means 4
Send to.

ブロック図プログラム生成手段4は変数決定部41とブ
ロック構造解析部42とプログラム生成部43とを有し
ている。さらに、変数決定部41内には、変数属性決定
パターン選択知謀ベース44及び変数決定パターンのひ
な型45が記憶されている。
The block diagram program generation means 4 includes a variable determination section 41, a block structure analysis section 42, and a program generation section 43. Further, in the variable determining unit 41, a variable attribute determining pattern selection intelligence base 44 and a template 45 of variable determining patterns are stored.

そして、プログラム生成制御手段12からプログラム生
成ゴール14を受信すると、このプログラム生成ゴール
14の内容とブロック図形式システム仕様7を参照しな
がらプログラム生成処理を開始する。すなわち、先ず、
変数決定部41において、同決定部41が有する変数属
性決定パターン選択知識ベース44に従って変数属性決
定パターン16を生成し、変数属性管理手段5に送る。
When the program generation goal 14 is received from the program generation control means 12, the program generation process is started while referring to the contents of the program generation goal 14 and the block diagram format system specification 7. That is, first,
The variable determining section 41 generates a variable attribute determining pattern 16 according to the variable attribute determining pattern selection knowledge base 44 that the determining section 41 has, and sends it to the variable attribute managing means 5.

変数属性管理手段5は、通常、変数の名称とその属性を
格納している変数管理データベースを有しており、ブロ
ック図プログラム生成手段4から前述した変数属性決定
パターン16が送られてくると、この変数属性決定パタ
ーン16に表現されている情報を用いて、同じ意味を持
つ変数を変数管理データベースより検索し、変数が存在
すれば、その名称を変数名称13としてブロック図プロ
グラム生成手段4へ返信する。一方、変数が存在しなけ
れば、その変数に対し新しい名称を与えて、変数属性決
定パターン16に示された属性とともに変数管理データ
ベースに登録して、新しい名称を変数名称13としてブ
ロック図プログラム生成手段4へ返信する。
The variable attribute management means 5 normally has a variable management database that stores variable names and their attributes, and when the variable attribute determination pattern 16 described above is sent from the block diagram program generation means 4, Using the information expressed in this variable attribute determination pattern 16, a variable with the same meaning is searched from the variable management database, and if a variable exists, its name is returned to the block diagram program generation means 4 as a variable name 13. do. On the other hand, if the variable does not exist, a new name is given to the variable and registered in the variable management database together with the attribute shown in the variable attribute determination pattern 16, and the new name is used as the variable name 13 by the block diagram program generation means. Reply to 4.

このようにして、変数決定部41では、ブロック図形式
システム仕様7の中の個々のブロック情報のうち変数に
相当するブロック情報75のすべてに対して変数属性管
理手段5を介して変数名称13を決定する。
In this way, the variable determining unit 41 assigns variable names 13 to all block information 75 corresponding to variables among the individual block information in the block diagram format system specifications 7 via the variable attribute management means 5. decide.

以上の変数名称13の決定処理が終了すると、ブロック
構造解析部42において、個々のブロック情報75と、
その相互間の接続情報に基づいて、ブロック構造を解析
し、プログラムの骨格を形成する。
When the above-described variable name 13 determination processing is completed, the block structure analysis unit 42 analyzes the individual block information 75,
Based on the mutual connection information, the block structure is analyzed and the program skeleton is formed.

最後に、プログラム生成部43において、変数決定部4
1で決定された変数名称13と、ブロック構造解析部4
2で求められたプログラムの骨格を組み合わせて、例え
ば第6図に示す部分プログラム15を生成し、プログラ
ム生成制御手段12に送信する。
Finally, in the program generation section 43, the variable determination section 4
The variable name 13 determined in step 1 and the block structure analysis unit 4
By combining the program skeletons obtained in step 2, a partial program 15 shown in FIG. 6, for example, is generated and sent to the program generation control means 12.

次に、ブロック図プログラム生成手段4における部分プ
ログラム15の前述した作成処理を第4図の流れ図を用
いてさらに詳細に説明する。
Next, the above-described creation process of the partial program 15 in the block diagram program generation means 4 will be explained in more detail using the flowchart of FIG.

流れ図が開始されると、ステップC1にて、変数決定手
段41が、その時点で処理の対象になっている第2図に
示す全てのブロック情報75の処理が終了でいるか否か
判断して、終了していなければ、ステップP1にて、未
処理のブロック情報75を取り出す。そして、ステップ
C2において、取り出した個々の未処理のブロック情報
75に対して変数名称13を決定すべきブロック情報7
5か否かを判定する。変数名称13を決定すべきブロッ
ク情報、75てあれば、ステップP2にて、変数属性決
定パターン選択知識ベース44に従って変数属性決定パ
ターンのひな型45を選択する。
When the flowchart starts, in step C1, the variable determining means 41 determines whether or not the processing of all the block information 75 shown in FIG. 2 that is the object of processing at that point has been completed. If the process has not been completed, unprocessed block information 75 is extracted in step P1. Then, in step C2, block information 7 for which variable names 13 are to be determined for each unprocessed block information 75 taken out.
5 or not. If the block information 75 for which the variable name 13 is to be determined is present, a template 45 of the variable attribute determination pattern is selected in accordance with the variable attribute determination pattern selection knowledge base 44 in step P2.

さらに、ステップP3にて選択された変数属性決定パタ
ーンのひな型45を、処理中のブロック情報75に基づ
いて展開して変数属性決定パターン16を生成する。ス
テップP4にて、生成された変数属性決定パターン16
を変数属性管理手段5に送出して、該当パターンに相当
する意味を持つ変数名称13を得る。
Furthermore, the model 45 of the variable attribute determination pattern selected in step P3 is expanded based on the block information 75 being processed to generate the variable attribute determination pattern 16. Variable attribute determination pattern 16 generated in step P4
is sent to the variable attribute management means 5 to obtain a variable name 13 having a meaning corresponding to the corresponding pattern.

処理対象になっているブロック情報75の処理が済むと
、ステップP5にて、ブロック構造解析部42において
、ブロック情報75相互間の接続を解析してプログラム
の骨格を求め、プログラム生成部43において、変数決
定部41で決定された変数名称13を埋め込んで、第6
図に示す部分プログラム15を生成する。
After the block information 75 to be processed has been processed, in step P5, the block structure analysis unit 42 analyzes connections between the block information 75 to obtain a program skeleton, and the program generation unit 43 The variable name 13 determined by the variable determination unit 41 is embedded, and the sixth
A partial program 15 shown in the figure is generated.

さらに、−例として、第2図に示す■のブロック72の
ブロック情報75に基づいて該当ブロック72の変数名
称13が決定されるまでの変数決定部41における詳細
処理動作を第5図を用いて説明する。なお、この処理動
作は第4図の流れ図におけるステップP2、P3、P4
に相当する。
Furthermore, as an example, the detailed processing operation in the variable determining unit 41 until the variable name 13 of the corresponding block 72 is determined based on the block information 75 of the block 72 shown in FIG. explain. Note that this processing operation is performed in steps P2, P3, and P4 in the flowchart of FIG.
corresponds to

第5図において、ブロック情報75は、ブロック72の
意味を持つものであり、このブロック情報・75に基づ
いて変数名称13を決定する。変数決定部41では、先
ず最初に、ブロック情報75に対し、個々のブロック7
2に対する変数属性決定パターン16を生成するための
ひな型を選択するための知識である変数属性決定パター
ン選択知識ベース44に従って変数属性決定パターンの
ひな型45を選択する。すなわち、同図の■のブロック
情報75の場合は、変数属性決定パターン選択知識ベー
ス44の中のrule−1、[block−type 
 がgate−aまたはgate−bで、functi
on  が速度を表す用語なら、変数属性決定パターン
のひな型は、b I k−gate−1である。]とい
う知識により、変数属性決定パターンのひな型45とし
て、blk−gate−1か選択される。
In FIG. 5, block information 75 has the meaning of block 72, and the variable name 13 is determined based on this block information 75. In the variable determination unit 41, first, each block 7 is determined from the block information 75.
A template 45 of a variable attribute determination pattern is selected according to a variable attribute determination pattern selection knowledge base 44 that is knowledge for selecting a template for generating a variable attribute determination pattern 16 for 2. In other words, in the case of the block information 75 indicated by ■ in the figure, rule-1, [block-type] in the variable attribute determination pattern selection knowledge base 44
is gate-a or gate-b, and functi
If on is a term expressing speed, then the model variable attribute determination pattern is b I k-gate-1. ], blk-gate-1 is selected as the template 45 of the variable attribute determination pattern.

次に、選択された変数属性決定パターンのひな型45と
、ブロック情報45を参照しながら、変数属性決定パタ
ーン16を生成する。すなわち、参照しているブロック
情報75か、第2図に示すように、 BLKOOL−4 block−type:  gate−amachin
e:    NO,1機械function:   高
速 てあり、 変数属性決定パターンのひな型45の条件が、(Ima
chine  ?t)  (runction  ?f
’)であるので、ここで、 7m −NO,1機械、 ?r−高速 となり、この条件からひな型 [(!  (machine   7m)   (ru
nc   ?f)(sensel  運転指令)コ から、変数属性決定パターン16、 [! (machine  NO,1機械)  (fu
nc  高速)(sensel  運転指令)コ か生成される。
Next, the variable attribute determination pattern 16 is generated while referring to the selected variable attribute determination pattern template 45 and the block information 45. That is, the referenced block information 75 or, as shown in FIG. 2, BLKOOL-4 block-type: gate-amachin
e: NO, 1 Machine function: High speed, the condition of template 45 of variable attribute determination pattern is (Ima
Chine? t) (runction?f)
'), so here, 7m - NO, 1 machine, ? r - high speed, and from this condition the template [(! (machine 7m) (ru
nc? f) From (sensel operation command), variable attribute determination pattern 16, [! (machine NO, 1 machine) (fu
nc high speed) (sensel operation command) is generated.

さらに、変数決定部41では、生成した変数属性決定パ
ターン16を、変数属性管理手段5へ送出して、変数名
称1B [lMCH3PC0M ] を決定させる。
Further, the variable determining unit 41 sends the generated variable attribute determination pattern 16 to the variable attribute management means 5 to determine the variable name 1B [lMCH3PC0M].

第6図は、−例として、仕様として設計者が入力したブ
ロック図71と、そのブロック図71に基づいてブロッ
ク図プログラム生成手段4か生成した部分プログラム1
5との対比を示す図である。
FIG. 6 shows, for example, a block diagram 71 input by the designer as a specification and a partial program 1 generated by the block diagram program generation means 4 based on the block diagram 71.
5 is a diagram showing a comparison with No. 5. FIG.

このように構成されたブロック図処理機能付きプログラ
ム自動生成装置であれば、設計者は多数のシステム仕様
に基づいてこの各システム仕様を満足する統合プログラ
ムを自動作成する場合は、その各システム仕様の中に、
通常形式で表現された通常のシステム仕様6の他に、ブ
ロック図形形式で表現された例えば第2図に示すブロッ
ク図形式システム仕様7が混在したとしても、そのブロ
ック図形式システム仕様7を通常のシステム仕様6に書
直す必要がなく、通常のシステム仕様と同様の取扱いで
入力できる。そして、ブロック図形式システム仕様7お
よび通常の各システム仕様6の指定する複数の部分プロ
グラムからなる統合プログラムが自動生成される。
With an automatic program generation device with a block diagram processing function configured in this way, a designer can automatically create an integrated program that satisfies each system specification based on a large number of system specifications. inside,
In addition to the normal system specification 6 expressed in the normal format, even if there is a mixture of the block diagram format system specification 7 expressed in the block diagram format as shown in FIG. 2, the block diagram format system specification 7 is There is no need to rewrite system specifications 6, and they can be input in the same way as normal system specifications. Then, an integrated program consisting of a plurality of partial programs specified by the block diagram format system specification 7 and each normal system specification 6 is automatically generated.

よって、設計者はブロック図形式システム仕様を通常の
システム仕様に書直す必要がないので、プログラム作成
作業能率を大幅に向上できる。
Therefore, the designer does not need to rewrite the block diagram format system specification into a normal system specification, so the efficiency of program creation work can be greatly improved.

また、プロセス制御等のプログラムを設計する場合に、
各機器が動作する時の速度基準等をブロック形式でその
まま入力できるので、通常のシステム仕様に書直す場合
に発生する微小な誤差等も排除できるので、システム仕
様6,7により忠実なプログラムを作成することができ
る。
Also, when designing programs such as process control,
Since the speed standards etc. for each device's operation can be entered directly in block format, minute errors that occur when rewriting to normal system specifications can be eliminated, allowing the creation of programs that are more faithful to system specifications 6 and 7. can do.

なお、本発明は上述した実施例に限定されるものではな
い。実施例においては、プロセス制御システムに用いる
プログラムを自動生成する場合について説明したが、特
にプロセス制御システムに限定されるものではなく、シ
ステム仕様がブロック図形式で表現できる全ての情報処
理システムに適用できることはいうまでもない。
Note that the present invention is not limited to the embodiments described above. In the embodiment, a case has been described in which a program for use in a process control system is automatically generated. However, the present invention is not limited to process control systems in particular, and can be applied to all information processing systems whose system specifications can be expressed in a block diagram format. Needless to say.

また、ブロック図プログラム生成手段4の設置数も必要
に応して適宜変更できる。
Further, the number of installed block diagram program generation means 4 can be changed as necessary.

[発明の効果コ 以上説明したように本発明のブロック図処理機能付きプ
ログラム自動生成装置によれば、通常形式で表現された
システム仕様の他に、ブロック図形式の仕様か入力され
た場合にもプログラムか自動生成される。したかって、
プラント制御等のプログラムを設計する際に用いられる
、機器が動作する時の速度基準の与え方等を、ブロック
図形式の仕様として与えることが可能である。よって、
プログラム生成作業の省力化、能率化をより一層向上さ
せることができる。さらに、生成されたブ第1図乃至第
6図は本発明の一実施例に係わるブロック図処理機能付
きプログラム自動生成装置を示すものであり、第1図は
概略構成を示すブロック図、第2図はブロック図形式シ
ステム仕様の生成過程を示す図、第3図はプログラム生
成制御手段とブロック図プログラム生成手段及び変数属
性管理手段との間の各種データの授受を説明するための
図、第4図はブロック図プログラム生成手段の動作を示
す流れ図、第5図は変数決定部におけるデータの参照関
係と変数属性管理手段との間のデータ授受の具体例を示
す図、第6図は設計者が入力した仕様とこれに基づいて
生成された部分プログラムとの対比を示す図であり、第
7図は従来のプログラム自動生成装置の概略構成を示す
ブロック図、第8図は一般的なブロック図形式システム
仕様を示す図である。
[Effects of the Invention] As explained above, according to the automatic program generation device with block diagram processing function of the present invention, in addition to the system specifications expressed in the normal format, even when specifications in the block diagram format are input, The program is automatically generated. I wanted to,
It is possible to provide specifications in the form of a block diagram, such as how to provide speed standards when equipment operates, which are used when designing programs such as plant control. Therefore,
It is possible to further improve the labor saving and efficiency of program generation work. Furthermore, generated blocks FIG. 1 to FIG. 6 show an automatic program generation device with a block diagram processing function according to an embodiment of the present invention, and FIG. 1 is a block diagram showing a schematic configuration, and FIG. 3 is a diagram illustrating the generation process of a block diagram format system specification; FIG. 3 is a diagram illustrating the exchange of various data between the program generation control means, the block diagram program generation means, and the variable attribute management means; and FIG. The figure is a flowchart showing the operation of the block diagram program generation means, FIG. FIG. 7 is a block diagram showing a schematic configuration of a conventional automatic program generation device, and FIG. 8 is a general block diagram format. FIG. 3 is a diagram showing system specifications.

3・・・プログラム生成手段、4・・・ブロック図プロ
グラム生成手段、5・・・変数属性管理手段、6・・・
システム仕様、7・・・ブロック図形式システム仕様、
8・・・プログラム、11・・・プログラム自動生成装
置、12・・・プログラム生成制御手段、13・・・変
数名称、14・・・プログラム生成ゴール、15・・・
部分プログラム、16・・・変数属性決定パターン、4
1・・・変数決定部、42・・・プロ・ツク構造解析部
、43・・・プログラム生成部、44・・・変数属性決
定、<ターン選択知識ベース、45・・・変数属性決定
ノくターンのひな型、71・・・ブロック図、72・・
・プロ・ツク、73・・結線、74・・・変換手段、7
5・・・プロ・ツク情報。
3... Program generation means, 4... Block diagram program generation means, 5... Variable attribute management means, 6...
System specifications, 7...Block diagram format system specifications,
8... Program, 11... Program automatic generation device, 12... Program generation control means, 13... Variable name, 14... Program generation goal, 15...
Partial program, 16... Variable attribute determination pattern, 4
DESCRIPTION OF SYMBOLS 1... Variable determination unit, 42... Pro-tsuk structure analysis unit, 43... Program generation unit, 44... Variable attribute determination, <turn selection knowledge base, 45... Variable attribute determination unit. Turn template, 71...Block diagram, 72...
- Pro Tsuk, 73... Connection, 74... Conversion means, 7
5... Pro Tsuku information.

Claims (1)

【特許請求の範囲】 外部から入力された通常形式で表現されたシステム仕様
及びブロック図形式で表現されたブロック図形式システ
ム仕様に基づいて、複数の部分プログラムからなる統合
プログラムの構成を決定して、各部分プログラムを生成
する場合の目的や条件を示すプログラム生成ゴールを出
力してプログラム生成を制御するプログラム生成制御手
段と、このプログラム生成制御手段から出力されたプロ
グラム生成ゴール及び前記入力されたシステム仕様に基
づいて目的とする部分プログラムを生成するプログラム
生成手段と、 前記プログラム生成制御手段から出力されたプログラム
生成ゴール及び前記入力されたブロック図形式システム
仕様および必要に応じて前記システム仕様を参照して目
的とする部分プログラムを生成するブロック図プログラ
ム生成手段と、このブロック図プログラム生成手段及び
前記プログラム生成手段がそれぞれ部分プログラムを生
成する場合に、生成する各部分プログラム内で使用する
変数名称を、変数の持つ意味に基づいて一括管理し、与
えられた変数の意味に相当する変数名称を前記ブロック
図プログラム生成手段及びプログラム生成手段へ送出す
る変数属性管理手段とを備えたブロック図処理機能付き
プログラム自動生成装置。
[Claims] The configuration of an integrated program consisting of a plurality of partial programs is determined based on a system specification expressed in a normal format and a block diagram system specification expressed in a block diagram format input from the outside. , a program generation control means for controlling program generation by outputting a program generation goal indicating the purpose and conditions for generating each partial program; and a program generation goal output from the program generation control means and the input system. a program generation unit that generates a target partial program based on specifications; and a program generation goal output from the program generation control unit, the input block diagram format system specification, and reference to the system specification as necessary. A block diagram program generation means that generates a target partial program, and when this block diagram program generation means and the program generation means each generate a partial program, variable names used in each generated partial program, A program with a block diagram processing function, comprising variable attribute management means for collectively managing variables based on their meanings and sending variable names corresponding to the meanings of given variables to the block diagram program generation means and program generation means. Automatic generation device.
JP21671590A 1990-08-17 1990-08-17 Automatic program generator with block diagram processing function Expired - Lifetime JP2724240B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP21671590A JP2724240B2 (en) 1990-08-17 1990-08-17 Automatic program generator with block diagram processing function

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP21671590A JP2724240B2 (en) 1990-08-17 1990-08-17 Automatic program generator with block diagram processing function

Publications (2)

Publication Number Publication Date
JPH0498531A true JPH0498531A (en) 1992-03-31
JP2724240B2 JP2724240B2 (en) 1998-03-09

Family

ID=16692786

Family Applications (1)

Application Number Title Priority Date Filing Date
JP21671590A Expired - Lifetime JP2724240B2 (en) 1990-08-17 1990-08-17 Automatic program generator with block diagram processing function

Country Status (1)

Country Link
JP (1) JP2724240B2 (en)

Also Published As

Publication number Publication date
JP2724240B2 (en) 1998-03-09

Similar Documents

Publication Publication Date Title
JP2592955B2 (en) Automatic program generator
JPH10207523A (en) Automatic programming device and method therefor
US5130932A (en) Generating device for production system simulator
JPH06290237A (en) Product drawing generating device
JP2009116429A (en) Control program creation device and control program creation method
JPH0498531A (en) Automatic program generating device with block diagram processing function
JPH1196398A (en) Method and device for generating analytical mesh
JP2724241B2 (en) Automatic program generator with block diagram parts processing function
JPH0528088A (en) Method for automatically generating hardware constitution information
JPH0498533A (en) Automatic program generating device with macroblock diagram processing function
JP3102222B2 (en) Knowledge acquisition method and its implementation device
JPH11305903A (en) Data preparing device for process monitoring picture display, process monitoring picture display device and program record medium
JP2937381B2 (en) Integrated circuit design method and design apparatus
JPH05241806A (en) Design specification inverse preparing device
JP2537976B2 (en) Circuit diagram automatic generation method
JPH0728521A (en) Automatic generating method for simulation program
JP2847369B2 (en) Expert model construction equipment
JPH1097552A (en) Card data conversion device
JPH0635983A (en) Circuit diagram generation systme
JP2002049647A (en) Design support system
JP2012208939A (en) Process setting support processing program and task program generation processing program
JPH0683909A (en) Wiring designing device for printed wiring circuit board
JP2009258814A (en) Process setting support processing program and business program generation processing program
JPS62145422A (en) Automatically generating method for source program
JPS63303469A (en) Cad system for designing multi-power source logic circuit

Legal Events

Date Code Title Description
R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313111

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20071128

Year of fee payment: 10

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20081128

Year of fee payment: 11

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20081128

Year of fee payment: 11

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20091128

Year of fee payment: 12

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20091128

Year of fee payment: 12

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20101128

Year of fee payment: 13

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20101128

Year of fee payment: 13