JPH03294924A - State event matrix data forming method and state event matrix data processor - Google Patents

State event matrix data forming method and state event matrix data processor

Info

Publication number
JPH03294924A
JPH03294924A JP9690090A JP9690090A JPH03294924A JP H03294924 A JPH03294924 A JP H03294924A JP 9690090 A JP9690090 A JP 9690090A JP 9690090 A JP9690090 A JP 9690090A JP H03294924 A JPH03294924 A JP H03294924A
Authority
JP
Japan
Prior art keywords
matrix
state
state event
processing
matrix data
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.)
Pending
Application number
JP9690090A
Other languages
Japanese (ja)
Inventor
Masahiko Watanabe
政彦 渡邊
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.)
Tokyo Gas Co Ltd
Tesco Inc
Original Assignee
Tokyo Gas Co Ltd
Tesco 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 Tokyo Gas Co Ltd, Tesco Inc filed Critical Tokyo Gas Co Ltd
Priority to JP9690090A priority Critical patent/JPH03294924A/en
Publication of JPH03294924A publication Critical patent/JPH03294924A/en
Pending legal-status Critical Current

Links

Landscapes

  • Stored Programmes (AREA)

Abstract

PURPOSE:To facilitate the program design by making a subordinate matrix in accordance with the contents in which contents of a processing of a task is complicated. CONSTITUTION:It is a slave matrix 41 that shows the contents of a processing and a transition of contents 311, it is a slave matrix 42 that shows the contents of contents 321, and it is a slave matrix 43 that shows the contents of contents 312. Also, for instance, the contents of a processing and a transition of one contents 5221 of a slave matrix 42 are further entrusted to a sub-slave matrix 622. In such a way, as for the contents of a complicated processing, a subordinate matrix is made and they are described therein, therefore, even if the program becomes larger, its design and analysis can be executed easily.

Description

【発明の詳細な説明】 以下の順序に従って本発明を説明する。[Detailed description of the invention] The present invention will be described in the following order.

A、産業上の利用分野 B1発明の概要 C0背景技術[第9図、第10図] D1発明が解決しようとする問題点 E0問題点を解決するための手段 F8作用 G、実施例[第1図乃至第8図コ H0発明の効果 (A、産業上の利用分野) 本発明は行と列のうちのいずれか一方にタスクの状態を
示すステートを他方にタスクへの入力を示すイベントを
取りコンテントにタスクの処理・遷移が記されソフトウ
ェア開発分野で利用されるステートイベントマトリック
スデータの形成方法及び該ステートイベントマトリック
スデータを処理して特定言語によるプログラムを自動的
に生成するステートイベントマトリックスデータ処理装
置に関するものである。
A. Industrial field of application B1 Overview of the invention C0 Background art [Figures 9 and 10] D1 Problems to be solved by the invention E0 Means for solving the problems F8 Effects G. Examples [First Figures to Figure 8 H0 Effects of the Invention (A, Field of Industrial Application) The present invention has a state that indicates the state of a task in one of the rows and columns, and an event that indicates an input to the task in the other. A method for forming state event matrix data in which task processing/transition is described in the content and used in the software development field, and a state event matrix data processing device that processes the state event matrix data to automatically generate a program in a specific language. It is related to.

(B、発明の概要) 本発明は、ステートイベントマトリックスデータによっ
て入力と状態と処理の関係を階層的に表現できるように
するため、 ステートイベントマトリックスの少なくとも一部のコン
テントについてそのタスクの処理を表現する子のマトリ
ックスをつくり、更に子のマトリックスの少なくとも一
部のコンテントについて孫のマトリックスをつ(るとい
うように複雑な処理のコンテントについては下位のマト
リックスをつくってそれに記すようにするものであり、
こうすることによって入力と状態と処理・遷移の関係が
複雑な制御をマトリックスデータにより解り易く表現す
ることが可能になる。
(B. Summary of the Invention) The present invention expresses the processing of a task with respect to at least part of the content of the state event matrix in order to express the relationship among inputs, states, and processing in a hierarchical manner using state event matrix data. For complex processing content, such as creating a matrix of children to be processed and then creating a matrix of grandchildren for at least part of the content of the child matrix, a lower matrix is created and recorded in it.
By doing so, it becomes possible to easily express control with complex relationships among inputs, states, and processes/transitions using matrix data.

そして、そのマトリッスクデータをコンピュータにより
適宜処理することによってCPLIを動作させることが
可能なプログラムに変換することができ、プログラムの
設計が非常に容易になる。
Then, by appropriately processing the matrix data by a computer, it can be converted into a program capable of operating CPLI, which greatly facilitates the design of the program.

(C,背景技術)[第9図、第10図]コンピュータに
より制御を行うシステムにおいてそのコンピュータが実
行する内容はフローチャート上に記述することはできる
が、入力と状態と処理の関係は記述することができない
。そのため、コンピュータの実行するプログラムについ
ての入力と、状態と、処理との関係についての不具合あ
るいはその原因を突き止めることが難しく、時間もかか
る。特に、大規模でかつ複雑なリアルタイム制御システ
ムで動作するタスクは数多くの入力イベントを処理しな
ければならず、しかもその処理は現在の状態により変化
し、また状態そのものも変化する。従って、このような
複雑なリアルタイムシステム程フローチャートから不具
合とその原因を突き止めることが難しい。
(C, Background Art) [Figures 9 and 10] In a system controlled by a computer, the content executed by the computer can be described on a flowchart, but the relationship between inputs, states, and processes must be described. I can't. Therefore, it is difficult and time-consuming to identify problems or causes of problems in the relationship between inputs, states, and processes of programs executed by the computer. In particular, tasks operating in large-scale and complex real-time control systems must process numerous input events, and the processing changes depending on the current state, and the state itself changes. Therefore, the more complex the real-time system is, the more difficult it is to identify the malfunction and its cause from the flowchart.

そこで、入力と状態と処理の関係をマトリックスにより
表現することが行われる。第9図はそのようなマトリッ
クスデータの書式を示すものである。
Therefore, the relationships among inputs, states, and processes are expressed using a matrix. FIG. 9 shows the format of such matrix data.

図面において、aはマトリックスのモード番号を記すと
ころ、bl、b2、・・・・・・(第9図に示した例に
おいてはb2までしかないがもっと多いのが普通である
。)は該マトリックスの行にとられたところのタスクの
状態を示す各ステート1.2、・・・・・・である。c
l、C2、・・・・・・は該マトリックスの列にとられ
たところのタスクに入力される各イベント1.2、・・
・・・・である。d、d、・・・・・・は行と列との各
交点であるコンテントで、ここには遷移先と処理fun
cl、func2、・・・・・・が記される。尚、eは
遷移先を示すところ、fは処理を示すところである。
In the drawing, a indicates the mode number of the matrix, and bl, b2, ... (in the example shown in Fig. 9, there are only up to b2, but there are usually more numbers) are the mode numbers of the matrix. Each state 1.2, . . . indicates the state of the task taken in the row. c.
l, C2, . . . are each event 1.2, .
It is... d, d, ... are the contents that are the intersections of rows and columns, and here are the transition destination and processing fun.
cl, func2, . . . are written. Note that e indicates a transition destination, and f indicates a process.

このような書式によるマトリックスによって下記の仕様
を表わすと第10図に示すようになる。
The following specifications are expressed by a matrix in this format as shown in FIG. 10.

仕様 マイクロマウスが横断歩道にいる。(マイクロマウスは
停止中) マイクロマウスは信号機が青になると横断歩道を歩行す
る。
Specification Micromouse is at the crosswalk. (Micromouse is stopped) Micromouse walks at the crosswalk when the traffic light turns green.

歩行中、信号機が黄または赤になると走る。While walking, run when the traffic light turns yellow or red.

歩行中、信号機が赤になると走りながらおじぎをする。While walking, when the traffic light turns red, I bow while running.

横断が終るとその場で止まる。When it finishes crossing, it stops there.

第10図から明らかなように、マトリックスによれば、
入力・状態・処理の種別が一目でわかり、試験ケースが
いくつかあるかが一目でわかり、そして、ある状態にあ
る入力があった場合の動作も一目でわかる。また、マト
リックスによれば機能を前面にだし、状態フラグ変数に
何をセットするかという処理が表にまとまっている。従
って、処理シーケンスに注目したフローチャート(PA
D)によるよりもマトリックスによる方がきわめて入力
と状態と処理の関係を把握し易いという利点があるとい
える。
As is clear from Figure 10, according to the matrix,
You can see at a glance the types of inputs, states, and processes, you can see at a glance whether there are several test cases, and you can also see at a glance the behavior when an input is in a certain state. Also, according to the matrix, functions are brought to the forefront and processes such as what to set in status flag variables are summarized in a table. Therefore, a flowchart focusing on the processing sequence (PA
It can be said that the advantage of using a matrix is that it is much easier to understand the relationships among inputs, states, and processing than using D).

(D、発明が解決しようとする問題点)ところで、上述
したマトリックスによっても表現することが難しくなる
程システムのタスクが複雑化しており、平面的に入力と
状態との関係を把える従来のマトリックスデータでは複
雑な制御を行うシステムには対応できな(なりつつある
。ステートイベントマトリックスデータが活用されてき
たのは分析局面においてのみであり、設計局面において
活用されていないのはまさに従来のステートイベントマ
トリックスデータが平面的(非階層的)にしか入力と状
態と処理の関係を把えることができなかったためである
(D. Problem to be solved by the invention) By the way, system tasks have become so complex that they are difficult to express even with the above-mentioned matrix, and conventional matrices that grasp the relationship between inputs and states in a two-dimensional manner Data cannot handle systems that perform complex control (and it is becoming so. State event matrix data has been used only in the analysis phase, and it is precisely the conventional state event matrix data that has not been utilized in the design phase. This is because matrix data can only grasp the relationship between input, state, and processing in a two-dimensional (non-hierarchical) manner.

そこで、本発明は複雑な入力と状態と処理の関係を階層
的に表現するステートイベントマトリックスデータの形
成方法及びそのステートイベントマトリックスデータを
実際にCPUによって実行できる特定言語でのプログラ
ムに自動的に変換することのできるステートイベントマ
トリックスデータ処理装置を提供することを目的とする
Therefore, the present invention provides a method for forming state event matrix data that hierarchically expresses the relationship between complex inputs, states, and processes, and automatically converts the state event matrix data into a program in a specific language that can actually be executed by a CPU. An object of the present invention is to provide a state event matrix data processing device capable of processing data.

(E、問題点を解決するための手段) 本発明ステートイベントマトリックスデータ形成装置は
、ステートイベントマトリックスの少なくとも一部のコ
ンテントについてそのタスクの処理を表現する子のマト
リックスをつ(す、更に子のマトリックスの少なくとも
一部のコンテストについて孫のマトリックスをつくると
いうように複雑な処理のコンテントについては下位のマ
トリックスをつくってそれに記し、その下位のマトリッ
クスに委ねた上位のマトリックスのコンテントにはその
下位のマトリックスを遷移先として指定するコードを記
すようにしたものである。
(E. Means for Solving Problems) The state event matrix data forming device of the present invention creates a matrix of children expressing the processing of the task for at least part of the content of the state event matrix. For the content of complex processing such as creating a grandchild matrix for at least part of the contest of a matrix, create a lower matrix and write it in it, and the content of the upper matrix entrusted to the lower matrix is written in the lower matrix. The code that specifies the transition destination is written.

本発明ステートイベントマトリックスデータ処理装置は
、親となるステートイベントマトリックスをメ°モリの
一つのエリアに、各子のステートイベントマトリックス
をメモリの別のエリアに、各孫のステートイベントマト
リックスを更に別のエリアというように次元の異なる各
マトリックスをメモリに記憶し、別のメモリ又はメモリ
エリアに記憶されたプログラムに基づいてCPUによっ
てその階層的ステートイベントマトリックスをデータ処
理することにより特定言語でのプログラムに変換するよ
うにしたことを特徴とする。
The state event matrix data processing device of the present invention stores a parent state event matrix in one area of memory, each child state event matrix in another area of memory, and each grandchild state event matrix in another area. Each matrix with different dimensions, such as an area, is stored in memory, and the hierarchical state event matrix is converted into a program in a specific language by data processing by the CPU based on a program stored in another memory or memory area. It is characterized by being made to do.

(F、作用) 本発明ステートイベントマトリックスデータ形成方法に
よれば、ステートイベントマトリックスのうち処理が複
雑なコンテストについてはその処理の内容を1つのマト
リックスによって表現し、そのマトリックスに処理の内
容の表現を委ねたコンテントにはそのマトリックスを遷
移先と1.て記することとしたので、必要に応じて順次
マトリックスデータな階層化することができ、入力、状
態、処理の関係が極めて複雑なものであっても概要から
詳細へと階段的に整理して表現できる。
(F. Effect) According to the state event matrix data forming method of the present invention, for a contest with complicated processing among the state event matrices, the processing contents are expressed by one matrix, and the processing contents are expressed in the matrix. For the entrusted content, set the matrix as the transition destination and 1. Since we have decided to write it down as follows, it is possible to sequentially hierarchize matrix data as needed, and even if the relationship between input, status, and processing is extremely complex, it can be organized step by step from the outline to the details. I can express it.

従って、プログラムが大きくなってもその把握がやり易
いようにでき、設計、分析をやり易(することが可能で
ある。
Therefore, even if the program becomes large, it can be easily understood, and design and analysis can be performed easily.

本発明ステートイベントマトリックスデータ処理装置に
よれば、入力状態、処理の関係を階層化して表現したス
テートイベントマトリックスデータをメモリ(例えばR
AM)に記憶し、それを別のメモリ(例えばROM)に
記憶されたプログラムに従ってCPUによって特定言語
のプログラムに変換処理するので、CPUを実際に動作
させることができるプログラムを自動的に生成すること
ができる。即ち、ステートイベントマトリックスデータ
はシステム制御の設計、分析がし易いものであるが、命
令が順序良(配置されているものではないのでそのまま
ではプログラムとしては使用できない。しかるに、本発
明ステートイベントマトリックスデータ処理装置によれ
ば、それを自動的に処理してプログラムに変換すること
ができ、プログラムの作成をきわめて容易にすることが
できる。
According to the state event matrix data processing device of the present invention, the state event matrix data representing the relationship between input states and processing in a hierarchical manner is stored in a memory (for example, R
AM) and converts it into a program in a specific language by the CPU according to a program stored in another memory (for example, ROM), thereby automatically generating a program that can actually operate the CPU. Can be done. That is, state event matrix data is easy to design and analyze system control, but since the instructions are not arranged in an orderly manner, it cannot be used as a program as it is.However, the state event matrix data of the present invention According to the processing device, it is possible to automatically process it and convert it into a program, making it extremely easy to create a program.

(G、実施例)[第1図乃至第8図] 以下、本発明を図示実施例に従って詳細に説明する。(G, Example) [Figures 1 to 8] Hereinafter, the present invention will be explained in detail according to illustrated embodiments.

第1図は本発明ステートイベントマトリックスデータの
形成方法の一例を示す説明図である。
FIG. 1 is an explanatory diagram showing an example of a method for forming state event matrix data according to the present invention.

同図において、1は親となるステートイベントマトリッ
クスであり、モードとしてOが与えられている。このモ
ードはモード欄2に記されている。本例において行数、
列数が共に2であり、第1の行がイベント1、第2の行
がイベント2、第1の列がステート1、第2の列がステ
ート2になっている。そして、3はコンテントである。
In the figure, 1 is the parent state event matrix, and O is given as the mode. This mode is written in mode column 2. In this example, the number of rows,
The number of columns is 2, the first row is event 1, the second row is event 2, the first column is state 1, and the second column is state 2. And 3 is content.

イベント1とステート1のコンテント308、イベント
2とステート1のコンテント321及びイベント1とス
テート2のコンテント3,2はその具体的処理の内容の
表現が下位の子ストリックス44□、43に委ねられて
いる。イベント2とステート2のコンテント3゜たけは
その処理の内容の表現が委ねられていない。尤も、第1
図に示したものはあくまで一例に過ぎず、親マトリック
ス(モード0)の全コンテントについて処理・遷移の内
容の表現を子のマトリックスに委ねる場合もあり得るし
、たった1つのコンテントについて処理・遷移の内容の
表現を子のマトリックスに委ねる場合もあり得る。
For the content 308 of event 1 and state 1, the content 321 of event 2 and state 1, and the contents 3 and 2 of event 1 and state 2, the expression of the specific processing content is entrusted to the lower child matrix 44□, 43. ing. Content 3 of event 2 and state 2 is not entrusted with expressing the contents of the process. Of course, the first
What is shown in the figure is just an example, and there may be cases where the expression of processing/transition contents for all contents of the parent matrix (mode 0) is entrusted to the child matrix, or expression of processing/transition contents for only one content. There may be cases where the representation of content is left to child matrices.

第1図に示す例において、コンテント3.1の処理・遷
移の内容を示すのが子マトリックス4.であり、これは
0.1というモードが与えられている。コンテント32
.の内容を示すのが子のマトリックス42であり、モー
ドが0.2である。コンテント3.2の内容を示すのが
子マトリックス4、であり、モードが0.3である。
In the example shown in FIG. 1, child matrix 4.1 shows the processing/transition details of content 3.1. , which is given a mode of 0.1. Content 32
.. The child matrix 42 shows the contents of , and the mode is 0.2. Child matrix 4 indicates the contents of content 3.2, and the mode is 0.3.

そして、モード0.2の子マトリックス4□の一つのコ
ンテント52□、の処理・遷移の内容が更に孫マトリッ
クス6□2(モード0.2.2)に委ねられている。ま
た、モード0.3の子マトリックス4sの一つのコンテ
ント5311の処理・遷移の内容は孫マトリックス6□
(モード0.3゜1)に記されている。
The processing and transition of one content 52□ of the child matrix 4□ of mode 0.2 is further entrusted to the grandchild matrix 6□2 (mode 0.2.2). In addition, the processing/transition contents of one content 5311 of the child matrix 4s of mode 0.3 are the grandchild matrix 6 □
(mode 0.3°1).

このように、本ステートイベントマトリックスデータの
形成方法は一つのマトリックスによってリアルタイム制
御システムを表わすのではな(、ある一つのマトリック
スを親マトリックスとし、その親マトリックスのいくつ
かあるコンテントのうちの少なくとも一部のコンテント
については処理・遷移の内容を子のマトリックスに記す
。そして、必要に応じて各子のマトリックスの一部又は
全部のコンテントについても処理・遷移の内容を孫のマ
トリックスに記す。本例では孫のマトリックスまでしか
ないが、必要に応じてひ孫のマトリックス更にはそのひ
孫のマトリックスに対する子のマトリックス、孫のマト
リックスを形成するようにしても良いのである。そして
、処理の具体的内容の表現を下位のマトリックスに委ね
たコンテントにはその下位のマトリックスを指定する記
号が記されている。このような階層化したステートイベ
ントマトリックスデータによれば、非常に複雑な制御シ
ステムでも表現でき、制御システムの分析をやり易くす
ることになるが、それだけでな(制御システムをステー
トイベントマトリックスデータの形でつ(り上けで行く
ことができるようになるのである。従って、システムの
プログラムの設計が非常に容易にすることができ、しか
も入力と状態と処理の関係についての不具合が発見し易
く、またその原因も突き止め易い。
In this way, this state event matrix data formation method does not represent a real-time control system by one matrix (i.e., one matrix is used as a parent matrix, and at least some of the contents of the parent matrix are represented by one matrix). For the content of , the content of processing/transition is written in the child matrix.Then, if necessary, the content of processing/transition for some or all of the contents of each child matrix is also written in the grandchild matrix.In this example, Although there is only a grandchild matrix, if necessary, it is also possible to form a great-grandchild matrix, a child matrix, and a grandchild matrix for that great-grandchild matrix.Then, the specific content of the processing can be expressed. Content entrusted to a lower matrix is marked with a symbol that specifies the lower matrix.With such hierarchical state event matrix data, even a very complex control system can be expressed, and the control system's This makes analysis easier, but it also allows the control system to be accessed in the form of state-event matrix data.Therefore, the design of the program for the system becomes very difficult. Moreover, it is easy to discover defects in the relationship between input, state, and processing, and it is also easy to find the cause.

また、各マトリックスはそれが親であるか、子であるか
孫であるかを問わず、ステートの初期値がステート1に
なっている。そして、ステートの遷移には2つのタイプ
が存在する。第1のタイプはマトリックス内部で行う遷
移であり、ローカルトランジションと称されている。第
2のタイプはマトリックス内部、外部での遷移であり、
グローバルトランジションと称される。そして、ローカ
ルトランジションの場合には遷移先を示す欄には単純に
遷移するステートの番号が記される。これは第9図に示
す場合と同じである。そして、状態遷移がない場合には
遷移先を示す欄には−という記号が記される。これも従
来の場合と同じである。
Further, the initial value of the state of each matrix is state 1, regardless of whether it is a parent, child, or grandchild. There are two types of state transitions. The first type is a transition that takes place within the matrix and is called a local transition. The second type is transition inside and outside the matrix,
It is called a global transition. In the case of a local transition, the number of the state to be transitioned to is simply written in the column indicating the transition destination. This is the same as the case shown in FIG. If there is no state transition, a - symbol is written in the column indicating the transition destination. This is also the same as the conventional case.

グローバルトランジションの場合には第2図に示すよう
にイベント1とステート1の交点のコンテントの遷移先
を記す欄に〉、/の記号を使って表示される。この例は
O>210.1>2であるが、1番左側のOは遷移が為
されるマトリックスのモードOであることを示している
。〉はモードとステートの間をセパレートするものであ
り、〉の右の2は遷移先のステート番号が2であること
を示している。/は1つの遷移表示部分と他の遷移表示
部分とをセパレートするものである。7/よりも左側の
上記したO>2はモード0のマトリックスのステートを
ステート2に遷移することを表わしている。また、/よ
りも右側の0.1>2はモード0.1のマトリックスの
ステートをステート2に遷移することを表わしている。
In the case of a global transition, as shown in FIG. 2, the symbol > and / are used to display the content transition destination at the intersection of event 1 and state 1. In this example, O>210.1>2, and the leftmost O indicates the mode O of the matrix in which the transition is made. > is used to separate a mode and a state, and the 2 to the right of > indicates that the transition destination state number is 2. / separates one transition display portion from another transition display portion. The above-mentioned O>2 on the left side of 7/ indicates that the state of the mode 0 matrix is transitioned to state 2. Further, 0.1>2 on the right side of / indicates that the state of the matrix of mode 0.1 is transitioned to state 2.

遷移の数が2よりも多くなることもある。The number of transitions may be greater than two.

第3図は本明細書のC0背景技術の中で記述した仕様(
「マイクロマウスが横断歩道にいる。」に始まり、「横
断が終るとその場で止まる。」で終る仕様。第7頁参照
)をステートイベントマトリックスにして表わしたもの
を示す。
Figure 3 shows the specifications (
It starts with "Micromouse is at a crosswalk." and ends with "When it finishes crossing, it stops on the spot." (see page 7) is expressed as a state event matrix.

第3図においては便宜上第1図において使用したのと別
の独自の符号を使用する。
In FIG. 3, unique symbols different from those used in FIG. 1 are used for convenience.

このステートイベントマトリックスは親ステートイベン
トマトリックス21と子マトリックス22からなり、階
層化されている。親ステートイベントマトリックス21
はモードがO(モード欄211に記述)とされ、子ステ
ートイベントマトリックス22はモードが0.1 (モ
ード欄21に記述)とされている。この子ステートイベ
ントマトリックス22は親ステートイベントマトリック
ス21の一つのコンテントの内容を表現したものである
。そして、子ステートイベントマトリックス22に内容
の表現を委ねたステートイベントマトリックス21のそ
のコンテントには子ステートイベントマトリックス22
が存在することを示す記号21□を記述することにより
親子関係(階層関係)を表現する。子ステートイペント
マトノックス22のモード0.1のうちの0は親にあた
るステートイベントマトリックスのモードが0であるこ
とを示している。また、そのモード0.1のうちの1は
内容の表現を委ねた親マトリックス22のコンテントの
上記記号212内の数値と一致している。従って、記号
21□から子ステートイベントマトリックス22が存在
することと共にどのマトリックスがそれであるかが解る
のである。
This state event matrix consists of a parent state event matrix 21 and a child matrix 22, and is hierarchical. Parent state event matrix 21
The mode is O (described in the mode column 211), and the mode of the child state event matrix 22 is 0.1 (described in the mode column 21). This child state event matrix 22 is a representation of one content of the parent state event matrix 21. The content of the state event matrix 21 whose content has been entrusted to the child state event matrix 22 is expressed by the child state event matrix 22.
A parent-child relationship (hierarchical relationship) is expressed by writing a symbol 21□ indicating the existence of a parent-child relationship (hierarchical relationship). 0 of the modes 0.1 of the child state event matrix 22 indicates that the mode of the parent state event matrix is 0. Further, 1 of the modes 0.1 matches the numerical value in the symbol 212 of the content of the parent matrix 22 to which the expression of the content is entrusted. Therefore, from the symbol 21□, it is known that the child state event matrix 22 exists and which matrix it is.

モードO(モード欄21.に記述)のステートイベント
マトリックス(即ち、親ステートイベントマトリックス
)21には、スタート(第1のイベント欄21.)、信
号機情報(第2のイベント欄214)、ストップ(第3
のイベント欄21、)の3つの入力に対してのみ注目し
た処理、遷移が表わされている。そして、モード0゜1
 (モード欄221に記述)のステートイベントマトリ
ックス(即ち、子ステートイベントマトリックス)22
には信号機情報(親テートイベントマトリックス21の
第2のイベント欄214)の詳細である青(第1のイベ
ント欄22□)、黄(第2のイベント欄22.)、赤(
第3のイベント欄224)の三つの入力に対してのみ注
目した処理、遷移を表わしている。
The state event matrix (that is, the parent state event matrix) 21 for mode O (described in the mode column 21.) includes start (first event column 21.), traffic light information (second event column 214), stop ( Third
Processes and transitions focused only on the three inputs in the event column 21, ) are shown. And mode 0゜1
(described in the mode column 221) state event matrix (i.e. child state event matrix) 22
The details of the traffic light information (the second event column 214 of the parent Tate event matrix 21) are blue (first event column 22□), yellow (second event column 22.), and red (
It shows processing and transitions focused only on the three inputs in the third event column 224).

つまり、モードOのステートイベントマトリックス)2
1の方は仕様の概要を示し、モード0゜1のステートイ
ベントマトリックス22の方は仕様の詳細を示している
In other words, the state event matrix of mode O)2
1 shows an overview of the specifications, and state event matrix 22 in mode 0°1 shows details of the specifications.

このような階層化したステートイベントマトリックスデ
ータによれば、非常に複雑な制御システムでも表現する
ことができるので制御システムの設計が容易になる。ま
た、設計ミスの発見も容易になる。
With such hierarchical state event matrix data, even a very complex control system can be expressed, making it easy to design the control system. It also makes it easier to discover design errors.

第4図は上記方法によって階層的に形成されたたステー
トイベントマトリックスデータを処理してCPUを駆動
させることができる特定言語、例えばC言語でのプログ
ラムにするステートイベントマトリックスデータ処理装
置を示すものであり、第5図はそれの外部記憶装置、具
体的にはディスク装置内のファイル配列を示すものであ
る。
FIG. 4 shows a state event matrix data processing device that processes the state event matrix data hierarchically formed by the above method and converts it into a program in a specific language, for example, C language, which can drive the CPU. 5 shows the file arrangement in the external storage device, specifically, the disk device.

同図において、11はエンジニアリングワークステーシ
ョン本体、12はデイスプレィ、13はキーボード、1
4はマウス、1己は外部記憶装置、本例では具体的には
ディスク装置である。
In the figure, 11 is the main body of the engineering workstation, 12 is the display, 13 is the keyboard, 1
4 is a mouse, and 1 is an external storage device, specifically a disk device in this example.

ステートイベントマトリックスデータは入力装置である
キーボード13あるいはマウス14の操作によってワー
クステーション本体11に入力される。また、入力され
たステートイベントマトリックスデータはデイスプレィ
12に表示されディスク装置15に記憶され、プリンタ
16にプリントアウトされ得るようになっている。特に
、ワークステーション本体11からディスク装置15に
向けてステートイベントマトリックスデータが出力され
た場合は第5図に示すように各モード毎にファイルとし
て記憶されるようになっている。この点については後で
詳細に説明する。
State event matrix data is input into the workstation main body 11 by operating the keyboard 13 or mouse 14, which are input devices. Further, the input state event matrix data is displayed on the display 12, stored in the disk device 15, and can be printed out on the printer 16. In particular, when state event matrix data is output from the workstation main body 11 to the disk device 15, it is stored as a file for each mode as shown in FIG. This point will be explained in detail later.

そして、ディスク装置15に記憶されたステートイベン
トマトリックスデータは、任意にデイスプレィ12、プ
リンタ16に出力することができ、また、キーボード1
3あるいはマウス14の操作によりディスク装置15に
記憶されているステートイベントマトリックスデータを
変更することもできるのである。
The state event matrix data stored in the disk device 15 can be optionally output to the display 12 and printer 16, and can also be output to the keyboard 1.
3 or by operating the mouse 14, the state event matrix data stored in the disk device 15 can be changed.

従来、プログラマによってコーディングされたプログラ
ムコードな第4図に示すステートイベントマトリックス
処理装置によって自動的にコーディングすることができ
るが、そのプログラムコードの生成手順を以下に説明す
る。尚、プログラムコードはリアルタイムモニタのメイ
ル機能があることを前提として生成される。第6図は生
成されるプログラムコードのフローチャートである。
Conventionally, a program code coded by a programmer can be automatically coded by the state event matrix processing device shown in FIG. 4, but the procedure for generating the program code will be described below. Note that the program code is generated on the assumption that the real-time monitor has a mail function. FIG. 6 is a flowchart of the generated program code.

第7図は第3図で示したステートイベントマトリックス
データのうちのイベントデータ構成図であり、このイベ
ントデータは、ステートイベントマトリックスデータの
作成と同様にステートイベントマトリックスデータ処理
装置によって作成され、外部記憶装置であるディスク装
置15に格納される。具体的には、traffic−s
ignalイベント構成データについてはエリア33に
、5topイベント構成データについてはエリア34に
、blueイベント構成データについてはエリア35に
、yellowイベント構成データについてはエリア3
6に、redイベント構成データについてはエリア37
に格納される。
FIG. 7 is an event data configuration diagram of the state event matrix data shown in FIG. It is stored in the disk device 15 which is a device. Specifically, traffic-s
ignal event configuration data in area 33, 5top event configuration data in area 34, blue event configuration data in area 35, and yellow event configuration data in area 3.
6, area 37 for red event configuration data.
is stored in

そして、traffic−signalイベント(第3
図の214)の構成図は第7図の41に、5topイベ
ント(第3図の216)の構成図は第7図の42に、b
lueイベント(第3図の22□)の構成図は第7図の
43に、yelloWイベント(第3図の22s)の構
成図は第7図の44に、そして、redイベント(第3
図の224)の構成図は第7図の45に示す通りである
。尚、5tartイベント(第3図の213)は、本例
では非メイル型トリガ入カイベントとして扱っているた
めイベント構成図は不要である。
Then, the traffic-signal event (third
The configuration diagram of 214) in Figure 7 is 41 in Figure 7, and the configuration diagram of the 5top event (216 in Figure 3) is 42 in Figure 7.
The configuration diagram of the blue event (22□ in Figure 3) is shown at 43 in Figure 7, the configuration diagram of the yellow event (22s in Figure 3) is shown at 44 in Figure 7, and the red event (22□ in Figure 3) is shown at 44 in Figure 7.
The configuration diagram of 224) in the figure is as shown at 45 in FIG. Note that the 5tart event (213 in FIG. 3) is treated as a non-mail type trigger input event in this example, so an event configuration diagram is not necessary.

ステートイベントマトリックスデータ処理は、作成した
上記ステートイベントマトリックスデータ(尚、モード
Oのステートイベントマトリックスデータ21について
はディスク装置15のエリア31に格納、モード0.1
のステートイベントマトリックスデータ22については
ディスク装置15のエリア32に格納)及び上記イベン
ト構成データ(上述のようにエリア33〜37に格納)
を基にして以下の処理を進めてプログラムコードを生成
する。尚、生成プログラムコードはディスク装置15の
エリア38に格納される。
State event matrix data processing is performed using the created state event matrix data (state event matrix data 21 in mode O is stored in area 31 of the disk device 15, mode 0.1
The state event matrix data 22 of is stored in area 32 of the disk device 15) and the event configuration data (stored in areas 33 to 37 as described above)
Based on this, proceed with the following processing to generate program code. Note that the generated program code is stored in the area 38 of the disk device 15.

ステートイベントマトリックスのモードナンバー(第3
図の211.22+ )からC言語変数である状態構造
体を下記のように形成する。
State event matrix mode number (3rd
211.22+) in the figure, a state structure which is a C language variable is formed as follows.

尚、int mo; Oはモード欄21.に基づいて生
成し、intmo−1のo−iはモード欄22.に基づ
いて生成する。
Note that int mo; O is in the mode column 21. The o-i of intmo-1 is generated based on the mode column 22. Generate based on.

次に、イベント構成データ(第7図の41.42.43
.44.45)及びステートイベントマトリックスデー
タ(第3図の214.216.22□、22..224
)からC言語変数である入力イベント構造体を下記のよ
うに生成する。
Next, event configuration data (41.42.43 in Figure 7)
.. 44.45) and state event matrix data (214.216.22□, 22..224 in Figure 3)
) to generate an input event structure, which is a C language variable, as follows.

尚、event−tyl)e :は第7図の41 + 
、 event−paral ;は同じ< 41 a 
、traffic−signal;は第3図の214に
基づいて生成する。以下、5top、blue、yel
 low、 redも同様にして生成する。
Incidentally, event-tyl) e: is 41 + in Figure 7.
, event-paral ; is the same < 41 a
, traffic-signal; are generated based on 214 in FIG. Below, 5top, blue, yellow
Low and red are generated in the same way.

ステートイベントマトリックス(第3図の21.22)
から予めステートイベントマトリックスデータ処理装置
に定義されているマトリックス構造体のタグを用いてC
言語変数であるマトリックステーブルの初期化を行う。
State event matrix (21.22 in Figure 3)
C using the matrix structure tags defined in advance in the state event matrix data processing device.
Initialize the matrix table, which is a language variable.

尚、上記の[3]の3は第3図の216に基づき生成、
[2]の2は第3図の217に基づき生成、(2、1n
itial )の2は第3図の218に基づき生成、1
ntialは第3図の219に基づき生成、(−1,n
on)の−1,nonは第3図の211oに基づき生成
、(−1、malcnt)のmalcntは第3図の2
1゜に基づき生成する。
Note that 3 in [3] above is generated based on 216 in Fig. 3,
2 in [2] is generated based on 217 in Figure 3, (2, 1n
2 of (itial) is generated based on 218 in Fig. 3, 1
ntial is generated based on 219 in Figure 3, (-1, n
-1, non of on) is generated based on 211o in Figure 3, malcnt of (-1, malcnt) is generated based on 2 in Figure 3.
Generated based on 1°.

ステートイベントマトリックデータ処理装置に定義され
た第6図のCソースコードの51の部分に下記のCプロ
グラムコードを埋める。
The following C program code is filled in the part 51 of the C source code of FIG. 6 defined in the state event matrix data processing device.

尚、event−type==0のOは第7図の413
に基づいて生成、event =2;の2は第3図の2
1.1に基づいて生成する。
Note that O in event-type==0 is 413 in Figure 7.
Generated based on, 2 of event = 2; is 2 of Fig. 3
1.1.

次に、第6図の52の部分に下記のCプログラムコード
を埋める。
Next, fill in the following C program code in the part 52 in FIG.

そして、第6図の51の部分、52の部分を埋める上記
した処理と同様に第3図のステートイベントマトリック
スデータ22のコントロール処理mo−1entの生成
を行う。
Then, control processing mo-1ent of the state event matrix data 22 in FIG. 3 is generated in the same way as the above-described processing for filling in the portions 51 and 52 in FIG. 6.

上記のCプログラムコードはディスクの装置15のエリ
ア38にファイルとして格納される。
The above C program code is stored as a file in the area 38 of the disk device 15.

このような手順によってプログラムコードが自動的に生
成されるのである。
Program code is automatically generated by such a procedure.

第8図は本発明を活かしたソフトウェア開発の工程を示
すフローチャートである。
FIG. 8 is a flowchart showing the steps of software development utilizing the present invention.

先ず、第1図に示すような階層化されたステートイベン
トマトリックスデータを作成(エデイツト)する[ステ
ップ(イ)]。次に、作成したステートイベントマトリ
ックスデータの構文チエツク、整合性チエツクを行う[
ステップ(b)]。
First, hierarchical state event matrix data as shown in FIG. 1 is created (edited) [step (a)]. Next, check the syntax and consistency of the created state event matrix data [
step (b)].

そして、エラーがあるかどうかの判定を行う[ステップ
(C)]。イエスYesという判定結果がでた場合には
ステップ(a)に戻る。逆にノウNoという判定結果が
でた場合にはステートイベントマトリックス上でシミュ
レーションを行い[ステップ(a)] 、その後、エラ
ーがあるがどうかの判定を行う[ステップ(e)]。イ
エスYESという判定結果が出た場合にはステップ(a
)に戻る。ノウNoという判定結果が出た場合にはステ
ートイベントマトリックスデータを特定言語、例えばC
言語によるプログラムに変換する[ステップ(f)]。
Then, it is determined whether there is an error [step (C)]. If the determination result is YES, the process returns to step (a). On the other hand, if the determination result is No, a simulation is performed on the state event matrix [step (a)], and then it is determined whether there is an error or not [step (e)]. If the judgment result is YES, step (a)
). If the judgment result is No, the state event matrix data is written in a specific language, such as C.
Convert to a language program [step (f)].

これによってプログラムの作成が完了する。This completes the creation of the program.

(H,発明の効果) 以上に述べたところから明らかなように、本発明ステー
トイベントマトリックスデータの形成方法によれば、ス
テートイベントマトリックスのうち処理が複雑なコンテ
ントについてはその処理の内容を下位のマトリックスに
よって表現し、その下位のマトリックスに処理の内容の
表現を委ねたコンテントにはそのマトリックスを遷移先
と記すこととしたので、必要に応じて順次マトリックス
データを階層化することができ、入力、状態、処理の関
係が極めて複雑なものであっても概要から詳細へと段階
的に整理して表現できる。従って、プログラムが膨大に
なってもその把握がやり易くなり、単に分析がやり易い
のみならず設計もやり易くなる。
(H, Effect of the Invention) As is clear from the above description, according to the method for forming state event matrix data of the present invention, for content whose processing is complicated in the state event matrix, the content of the processing is transferred to the lower level. For content that is expressed by a matrix and whose processing content is entrusted to a lower-level matrix, that matrix is designated as the transition destination, so matrix data can be layered sequentially as necessary, and input, Even if the relationships between states and processes are extremely complex, they can be organized and expressed step by step from the outline to the details. Therefore, even if the program becomes huge, it becomes easier to understand it, and it becomes not only easier to analyze but also easier to design.

本発明ステートイベントマトリックスデータ処理装置に
よれば、入力、状態、処理の関係を階層化して表現した
ステートイベントマトリックスデータをメモリに記憶し
、それを別のメモリに記憶されたプログラムに従ってC
PUにより特定言語のプログラムに変換処理するので、
そのままではCPUを制御できないステートイベントマ
トリックスデータを自動的に特定言語のプログラムに、
即ちCPUを動作させることができる形に生成すること
ができる。従って、プログラムの作成が極めて容易にな
る。
According to the state event matrix data processing device of the present invention, state event matrix data representing the relationships among inputs, states, and processes in a hierarchical manner is stored in a memory, and the state event matrix data is processed according to a program stored in another memory.
Since the PU converts it into a specific language program,
State event matrix data that cannot be used to control the CPU as it is is automatically converted into a program in a specific language.
That is, it can be generated in a form that allows the CPU to operate. Therefore, creating a program becomes extremely easy.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は本発明ステートイベントマトリックスデータの
形成方法の一つの実施例の説明図、第2図はグローバル
トランジションの説明図、第3図はステートイベントマ
トリックスデータの具体例の説明図、第4図及び第5図
は本発明ステートイベントマトリックスデータ処理装置
の一つの実施例を示すもので、第4図は装置の概略構成
図、第5図は外部記憶装置内のファイル配置例を示す図
、第6図は生成されるCコードフローチャート、第7図
はイベントのデータ構成図、第8図は本発明を活用して
のプログラムの作成工程の一例を示すフローチャート、
第9図及び第10図は背景技術を説明するためのもので
、第9図は従来のステートイベントマトリックスデータ
の説明図、第10図は従来のステートイベントマトリッ
クスデータの一具体例の説明図である。 符号の説明 1.21・・・・・・親マトリックス、3・・・・・・
コンテント、 4.22・・・・・・子マトリックス、5・・・・・・
コンテント、 6・・・・・・孫マトリックス、 15・・・・・・メモリ(外部記憶装置)。 第 3 図 生成されろCソースコードフローチャート第6図 罎働 第 8 図 第10図
FIG. 1 is an explanatory diagram of one embodiment of the method for forming state event matrix data of the present invention, FIG. 2 is an explanatory diagram of global transition, FIG. 3 is an explanatory diagram of a specific example of state event matrix data, and FIG. and FIG. 5 show one embodiment of the state event matrix data processing device of the present invention, FIG. 4 is a schematic configuration diagram of the device, FIG. 5 is a diagram showing an example of file arrangement in an external storage device, and FIG. 6 is a flowchart of the generated C code, FIG. 7 is an event data configuration diagram, and FIG. 8 is a flowchart showing an example of the program creation process using the present invention.
9 and 10 are for explaining the background technology, FIG. 9 is an explanatory diagram of conventional state event matrix data, and FIG. 10 is an explanatory diagram of a specific example of conventional state event matrix data. be. Explanation of symbols 1.21...Parent matrix, 3...
Content, 4.22...Child matrix, 5...
Content, 6...Grandchild matrix, 15...Memory (external storage device). Figure 3 Generated C source code flowchart Figure 6 Implementation Figure 8 Figure 10

Claims (2)

【特許請求の範囲】[Claims] (1)行と列のうちのいずれか一方にタスクの状態を示
すステートを他方にタスクへの入力を示すイベントをと
りコンテントにタスクの処理が記されたステートイベン
トマトリックスデータを形成するステートイベントマト
リックスデータの形成方法において、 少なくとも一部のコンテントについては、そのタスクの
処理を表現する子のマトリックスをつくり、該コンテン
トに該子のマトリックスを指定する記号を記し、子のマ
トリックスについても必要に応じて一部又は全部のコン
テントについてタスクの処理を表現する孫のマトリック
スをつくり、該コンテントに該孫のマトリックスを指定
する記号を記すというようにタスクの処理の内容が複雑
なコンテントに対応して下位のマトリックスをつくるこ
とを特徴とするステートイベントマトリックスデータ形
成方法
(1) A state event matrix that forms state event matrix data in which one of the rows and columns has a state that indicates the state of the task, and the other has an event that indicates the input to the task, and the content describes the processing of the task. In the data formation method, for at least some content, create a child matrix that represents the processing of the task, write a symbol specifying the child matrix in the content, and change the child matrix as necessary. A grandchild matrix expressing the task processing is created for some or all of the contents, and a symbol specifying the grandchild matrix is written in the content. State event matrix data formation method characterized by creating a matrix
(2)メモリの一部のエリアに、行と列のうちのいずれ
か一方にタスクの状態を示すステートを他方にタスクの
入力を示すイベントを取りコンテントにタスクの処理が
記された親となるステートイベントマトリックスデータ
を記憶し、上記記憶部の別のエリアに上記親となるステ
ートイベントマトリックスデータの少なくとも一部のコ
ンテントについてのタスクの処理を表現した子のステー
トイベントマトリックスデータを記憶し、上記記憶部の
さらに別のエリアに上記子となるステートイベントマト
リックスデータの少なくとも一部のコンテントのタスク
の処理を表現した孫のステートイベントマトリックスデ
ータを記憶するようにし、 上記メモリの他のエリアあるいは他のメモリに予め記憶
しておいたプログラムに基づいて上記ステートイベント
マトリックスデータをCPUにより処理することにより
上記ステートイベントマトリックスデータを所定言語に
よるプログラムに変換するようにした ことを特徴とするステートイベントマトリックスデータ
処理装置
(2) In a part of the memory, one of the rows and columns has a state that indicates the state of the task, and the other has an event that indicates the input of the task, and becomes a parent whose content describes the processing of the task. storing state event matrix data; storing child state event matrix data expressing task processing for at least part of the content of the parent state event matrix data in another area of the storage unit; The grandchild state event matrix data representing the processing of the task of at least a part of the content of the child state event matrix data is stored in another area of the memory, and the data is stored in another area of the memory or another memory. A state event matrix data processing device, characterized in that the state event matrix data is converted into a program in a predetermined language by processing the state event matrix data by a CPU based on a program stored in advance in a CPU.
JP9690090A 1990-04-12 1990-04-12 State event matrix data forming method and state event matrix data processor Pending JPH03294924A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP9690090A JPH03294924A (en) 1990-04-12 1990-04-12 State event matrix data forming method and state event matrix data processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP9690090A JPH03294924A (en) 1990-04-12 1990-04-12 State event matrix data forming method and state event matrix data processor

Publications (1)

Publication Number Publication Date
JPH03294924A true JPH03294924A (en) 1991-12-26

Family

ID=14177248

Family Applications (1)

Application Number Title Priority Date Filing Date
JP9690090A Pending JPH03294924A (en) 1990-04-12 1990-04-12 State event matrix data forming method and state event matrix data processor

Country Status (1)

Country Link
JP (1) JPH03294924A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2011071016A1 (en) * 2009-12-09 2011-06-16 株式会社日立製作所 System design support device and method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2011071016A1 (en) * 2009-12-09 2011-06-16 株式会社日立製作所 System design support device and method

Similar Documents

Publication Publication Date Title
JP2525275B2 (en) Database operation method
CN105302578B (en) A kind of portal total management system of towed layout configuration
CN111930378B (en) Method, device and system for realizing Web end project form designer
CN112364496B (en) Avionics simulation panel generation system based on HTML5 and VUE technologies
US20040133854A1 (en) Persistent document object model
Davis HIPO (hierarchy plus input-process-output)
AU731839B2 (en) System for translating visual display object files and method of operation thereof
JP2004502993A (en) Trainable and scalable automated data / knowledge translator
EP1818835A1 (en) Document processing device, and document processing method
US20090132906A1 (en) Document processing device and document processing method
US7805452B2 (en) Data processing device and data processing method
JPWO2006051713A1 (en) Document processing apparatus and document processing method
JPH03294924A (en) State event matrix data forming method and state event matrix data processor
US20090235156A1 (en) Document processing device and document processing method
CN113778411B (en) Graphical programming method and application device
EP1821221A1 (en) Document processing device and document processing method
JP4566196B2 (en) Document processing method and apparatus
US20080250311A1 (en) Document Processing Device, and Document Processing Method
JPWO2006051712A1 (en) Document processing apparatus and document processing method
EP1821220A1 (en) Data processing device, document processing device, and document processing method
CN121478668B (en) A Visual Modeling-Scripting-Mind Mapping Test Case Design System and Methodology for Embedded Systems
CN120631339B (en) A hybrid development method, device, medium, and product for a table editor.
EP0523650A2 (en) Object oriented processing method
JPH08305554A (en) Program execution method and apparatus based on hierarchical state transition decision table
US20090077369A1 (en) Data Processing Device And Data Processing Method