JP4888534B2 - Program development support apparatus and processing method - Google Patents
Program development support apparatus and processing method Download PDFInfo
- Publication number
- JP4888534B2 JP4888534B2 JP2009174115A JP2009174115A JP4888534B2 JP 4888534 B2 JP4888534 B2 JP 4888534B2 JP 2009174115 A JP2009174115 A JP 2009174115A JP 2009174115 A JP2009174115 A JP 2009174115A JP 4888534 B2 JP4888534 B2 JP 4888534B2
- Authority
- JP
- Japan
- Prior art keywords
- variable
- memory address
- comment
- internal memory
- operand
- 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.)
- Expired - Fee Related
Links
Images
Landscapes
- Programmable Controllers (AREA)
Description
この発明は、プログラム開発支援装置および処理方法に関するものである。 The present invention relates to a program development support apparatus and processing method.
プログラマブルコントローラ(PLC)内で動作する制御プログラムでは、命令語に対するオペランドとしてPLCのメモリアドレスを割り当てている。そこで、ユーザがPLCの制御プログラムを作成する場合、命令語のオペランドとしてPLCの内部メモリのメモリアドレスを入力する。このメモリアドレスの入力方法としては、メモリアドレスを直接入力する方法と、メモリアドレスにあらかじめ割り当てておいた変数を入力する方法とがある。この変数には、メモリアドレスに対応する名称や、I/Oコメントを割り当てることができる。 In a control program operating in a programmable controller (PLC), a PLC memory address is assigned as an operand for an instruction word. Therefore, when the user creates a PLC control program, the memory address of the PLC internal memory is input as an operand of the instruction word. As the memory address input method, there are a method of directly inputting a memory address and a method of inputting a variable assigned in advance to the memory address. A name corresponding to the memory address and an I / O comment can be assigned to this variable.
ところで、変数を入力する場合、一字一句正しい名称を入力する必要があるが、千個以上もある多数の全ての変数を正しく記憶し、入力するのは非常に煩雑であり、困難である。そこで、従来の制御プログラム開発支援装置では、プログラムエディタ上でオペランドとして使用することが可能な変数を一覧表示する機能を持っている。ユーザは、その一覧表示された変数の中から必要な変数を選択することができる。 By the way, when inputting a variable, it is necessary to input a correct name one by one. However, it is very complicated and difficult to correctly store and input all of a large number of variables of more than a thousand. Therefore, the conventional control program development support apparatus has a function of displaying a list of variables that can be used as operands on the program editor. The user can select a necessary variable from the listed variables.
また、オペランドに指定しようとしている変数を、名称の前方一致検索によって探し出す機能を備えたものもある。これは、プログラム開発支援装置は、予め使用可能な変数の名称を、例えば50音順などにソートした名称データベースを備え、ユーザが入力した名称をキーに、名称データベースの先頭から順にサーチして前方一致検索を行なう。そして、最初に条件に合致する名称を検出したならば、その名称を一覧リスト表示画面の先頭に来るように出力表示する。 Some have a function of searching for a variable to be specified as an operand by a forward matching search of names. This is because the program development support device has a name database in which the names of variables that can be used in advance are sorted in, for example, the order of the Japanese syllabary, etc. Perform a match search. When a name that matches the condition is first detected, the name is output and displayed so as to be at the head of the list display screen.
つまり、上記の一覧表示する機能の場合、常に全変数の先頭を一覧リスト表示画面の先頭に来るように出力表示し、ダウンスクロールなどして該当する変数を探すことになるが、後者の前方一致検索の場合、表示対象の変数は全変数である点では共通するものの一覧表示画面の最初に表示する先頭の変数が、前方一致検索で探し出された名称を表示する点で相違する。したがって、後者の前方一致検索を行なった場合も、アップスクロールやダウンスクロールすることにより、全ての変数を見ることはできる。また、入力された文字列から正しいプログラム用文字列を抽出し表示するプログラム開発装置が特許文献1に記載されている。 In other words, in the case of the above list display function, the output of all variables is always output and displayed so that it comes to the top of the list display screen, and the corresponding variable is searched by down-scrolling. In the case of a search, the variable to be displayed is common in that it is all variables, but the first variable displayed at the beginning of the list display screen is different in that the name found by the forward matching search is displayed. Therefore, even when the latter forward matching search is performed, all variables can be viewed by up-scrolling or down-scrolling. Japanese Patent Application Laid-Open No. 2004-228561 describes a program development apparatus that extracts and displays a correct program character string from an input character string.
上述の特許文献1に示された技術では、検索対象となるのは命令語の名称であり、命令語のオペランドではない。また、オペランドを検索対象とした従来技術では、検索対象が名称のみで、メモリアドレスやI/Oコメントの検索ができない。さらに、変数の名称(変数名)の前方一致検索のため、変数名やI/Oコメントの途中から出現する文字列しか憶えてない場合は、検索できない。さらに、結局全ての変数が出力されるため、変数名が多い場合は、一覧表示では見つけにくい。さらに、変数を一覧表示したときに名称しか表示されないため、その名称が実際にはどのアドレスに割り当てられているのかが分からず、使い勝手が良くない。
In the technique disclosed in
この発明は、プログラマブルコントローラ用のプログラム作成・編集の際に、内部メモリアドレス及びまたはI/Oコメントの検索性を高め制御プログラムの開発効率を高めることができるプログラム開発支援装置および処理方法を提供することを目的とする。 The present invention provides a program development support apparatus and a processing method capable of improving the search efficiency of an internal memory address and / or I / O comment and improving the development efficiency of a control program when creating / editing a program for a programmable controller. For the purpose.
上記した目的を達成するため、本発明のプログラム開発支援装置は、プログラマブルコントローラ用のプログラムを作成するプログラム開発支援装置において、プログラマブルコントローラの内部メモリアドレスを識別する文字列として割り当てた変数名と、その変数名に対応する内部メモリアドレスと、その変数名の付加情報であるI/Oコメントを関連づけた変数テーブルを備え、当該変数テーブル内の変数名,内部メモリアドレス,I/Oコメントの少なくとも1種類を検索対象とし、プログラムを構成する命令語のオペランドを入力後、検索開始ボタンが押された場合は、前記検索対象の中から、入力された文字列を含むデータを抽出し、そのデータに対応する内部メモリアドレス及びI/Oコメントの内の少なくとも一つの一覧を表示し、何も入力せずに検索開始ボタンが押された場合は変数テーブルを全て表示するする表示手段と、その表示示手段で表示された内部メモリアドレス及びまたはI/Oコメントから所望の内部メモリアドレス及びまたはI/Oコメントを指定する指定手段とを備え、その指定手段で指定された内部メモリアドレス及びまたはI/Oコメントに基づいて前記オペランドの入力が行なわれる機能と、前記オペランドの入力後、OKボタンが押された場合はそのままオペランドとして設定する機能を備えるようにした。 In order to achieve the above object, the program development support device of the present invention is a program development support device for creating a program for a programmable controller, and a variable name assigned as a character string for identifying an internal memory address of the programmable controller, A variable table is provided in which an internal memory address corresponding to a variable name is associated with an I / O comment that is additional information of the variable name, and at least one of a variable name, an internal memory address, and an I / O comment in the variable table. If the search start button is pressed after entering the operand of the instruction word that constitutes the program, the data including the entered character string is extracted from the search target and the data is supported A list of at least one of the internal memory addresses and I / O comments Internal shown and nothing display means for displaying all the variables table if the search start button without entering is pressed, from the internal memory address and or I / O comment displayed in the display shows means desired Designating means for designating a memory address and / or I / O comment, a function for inputting the operand based on the internal memory address and / or I / O comment designated by the designating means, and input of the operand Later, when the OK button was pressed, a function for setting it as an operand was provided .
参考例としてのプログラム開発支援装置は、プログラマブルコントローラの内部メモリアドレスを識別する文字列として割り当てた変数名を用いてそのプログラマブルコントローラ用のプログラムを作成するプログラム開発支援装置において、前記プログラムを構成する命令語のオペランドを入力する際、予め記憶保持した変数名の中から、入力された文字列を含む変数名を抽出し、その変数名の一覧を表示する変数名表示手段と、その変数名表示手段で表示された変数名から所望の変数名を指定する変数名指定手段とを備え、その変数名指定手段で指定された変数名に基づいて前記オペランドの入力が行なわれるようにするものにできる。 A program development support apparatus as a reference example is a program development support apparatus that creates a program for a programmable controller using a variable name assigned as a character string for identifying an internal memory address of the programmable controller. When inputting a word operand, a variable name display means for extracting a variable name including an input character string from variable names stored in advance and displaying a list of the variable names, and the variable name display means in comprising a from the displayed variable name and the variable name designating means for designating a desired variable name, can be provided with so that the input of the operands is performed based on the variable name specified in the variable name designating means.
また、プログラマブルコントローラの内部メモリアドレスを識別する文字列として割り当てた変数名を用いてそのプログラマブルコントローラ用のプログラムを作成するプログラム開発支援装置において、変数名、内部メモリアドレス、I/Oコメントからなる変数テーブルを備え、当該変数テーブル内の変数名,内部メモリアドレス,I/Oコメントの少なくとも1種類を検索対象とし、前記プログラムを構成する命令語のオペランドを入力する際、前記検索対象の中から、入力された文字列を含むデータを抽出し、そのデータに対応する変数名の一覧を表示する変数名表示手段と、その変数名表示手段で表示された変数名から所望の変数名を指定する変数名指定手段とを備え、その変数名指定手段で指定された変数名に基づいて前記オペランドの入力が行なわれるようにすることもできる。 Further, in a program development support apparatus that creates a program for a programmable controller using a variable name assigned as a character string for identifying an internal memory address of the programmable controller, a variable comprising a variable name, an internal memory address, and an I / O comment A table, and at least one of a variable name, an internal memory address, and an I / O comment in the variable table as a search target, and when inputting an operand of an instruction word constituting the program, Variable name display means for extracting data including the input character string and displaying a list of variable names corresponding to the data, and variable for specifying a desired variable name from the variable names displayed by the variable name display means Name specifying means, and the operation is performed based on the variable name specified by the variable name specifying means. It is also possible to make the input of the command is performed.
その場合に、前記変数名表示手段は、前記変数名の一覧を表示するに際し、内部メモリアドレスと、その該内部メモリアドレスの意味的な付加情報であるI/Oコメントの少なくとも一方を変数名に対応させて表示することができる。 In that case, when the variable name display means displays the list of variable names, at least one of an internal memory address and an I / O comment that is semantic additional information of the internal memory address is used as the variable name. It can be displayed in correspondence.
一方、本発明に係る処理方法は、プログラマブルコントローラ用のプログラムを作成するプログラム開発支援装置における処理方法であって、プログラマブルコントローラの内部メモリアドレスを識別する文字列として割り当てた変数名と、その変数名に対応する内部メモリアドレスと、その変数名の付加情報であるI/Oコメントを関連づけた変数テーブル内の前記変数名,前記内部メモリアドレス,前記I/Oコメントの少なくとも1種類を検索対象とし、前記プログラムを構成する命令語のオペランドを入力後、検索開始ボタンが押された場合は、前記検索対象の中から、入力された文字列を含むデータを抽出し、そのデータに対応する内部メモリアドレス及びI/Oコメントの内の少なくとも一つの一覧を表示し、何も入力せずに検索開始ボタンが押された場合は変数テーブルを全て表示する表示処理、その表示処理を実行して表示された内部メモリアドレス及びまたはI/Oコメントから所望の内部メモリアドレス及びまたはI/Oコメントを指定する指定処理、を実行し、その指定処理にて指定された内部メモリアドレス及びまたはI/Oコメントに基づいて前記オペランドの入力を行ない、前記オペランドの入力後、OKボタンが押された場合はそのままオペランドとして設定するようにした。 On the other hand, the processing method according to the present invention is a processing method in a program development support apparatus for creating a program for a programmable controller, and a variable name assigned as a character string for identifying an internal memory address of the programmable controller, and the variable name The search target is at least one of the variable name, the internal memory address, and the I / O comment in the variable table that associates the internal memory address corresponding to the I / O comment, which is additional information of the variable name, When a search start button is pressed after inputting an operand of an instruction word constituting the program, data including the input character string is extracted from the search target, and an internal memory address corresponding to the data is extracted. and to display at least one of a list of the I / O comment, nothing biopsy without input Display processing of displaying all the variables table If the start button is pressed, specify the desired internal memory address and or I / O comments from the internal memory address and or I / O comments displayed by executing the display process The specified operand is executed, and the operand is input based on the internal memory address and / or the I / O comment specified in the specified processing. If the OK button is pressed after the operand is input, the operation is continued. It was set as an operand .
本発明によれば、入力された文字列(キーワード)を含む変数名や、I/Oコメント,メモリアドレスの存在の有無を検索し、存在するもののみを抽出し変数名リストとして表示する。従って、指定した文字列(キーワード)が、変数名等のどの位置にあっても検出し、リストとして表示される。そして、オペランドとして使用可能な変数を一覧表示するときに、キーワードを含む変数だけに絞り込んだ一覧を表示することができるので、ユーザは、絞り込まれたリストの中から使用する変数を指定すればよく、目的とする変数を容易に検索できる。 According to the present invention, a variable name including an input character string (keyword), an I / O comment, and the presence / absence of a memory address are searched, and only the existing ones are extracted and displayed as a variable name list. Accordingly, the designated character string (keyword) is detected at any position such as a variable name and displayed as a list. And when displaying a list of variables that can be used as operands, it is possible to display a list narrowed down to only variables that contain keywords, so the user only has to specify the variable to be used from the narrowed list. The target variable can be easily searched.
検索対象は、上記の3つの全てとしても良いし、任意の2つ或いは1つとしても良い。検索対象をどのようにするかは、予め設定しておくと良い。検索対象の設定を適宜にすることにより、変数名のみならずI/Oコメントの途中に指定した文字列が存在する場合でも検索することができ、変数の検索性を高めることができる。 The search target may be all the above three, or may be any two or one. It is preferable to set in advance how to search. By appropriately setting the search target, it is possible to search not only the variable name but also the character string specified in the middle of the I / O comment, and the searchability of the variable can be improved.
一覧リストを表示するに際し、I/Oコメント等の情報も併せて表示することで、ユーザはその内容を理解しやすくなる。また、メモリアドレスを併せて表示するようにした場合には、一覧から変数を選択するときに、指定する変数名がどのアドレスに割り当てられているかを確認することができる。 When displaying the list, information such as I / O comments is also displayed , so that the user can easily understand the contents. When the memory address is also displayed, it is possible to confirm to which address the variable name to be specified is assigned when selecting the variable from the list.
この発明では、プログラマブルコントローラ用のプログラム作成・編集の際に、指定した文字列をキーに絞り込んで生成された変数の一覧リストを出力し、そこから内部メモリアドレス等を指定できるようになるので、制御プログラムの開発効率を高めることができる。 In this invention, when creating / editing a program for a programmable controller, it is possible to output a list of variables generated by narrowing down a designated character string to a key, and an internal memory address or the like can be designated therefrom, Control program development efficiency can be increased.
図1は、本発明の好適な一実施の形態を示している。制御プログラム開発支援装置10は、所定の通信ケーブルやネットワークなどの通信回線21を介してPLC20に接続される。制御プログラム開発支援装置10にて作成した制御プログラムは、通信回線21を介してPLC20にダウンロードされる。
FIG. 1 shows a preferred embodiment of the present invention. The control program
制御プログラム開発支援装置10は、各種の制御を司るMPU11と、キーボード,ポインティングデバイス等の入力装置からの入力を受ける入力部12と、表示装置に所定の情報を出力する表示部13と、記憶装置14と、通信インタフェース15とを備えている。本実施の形態では、この通信インタフェース15を介して制御プログラムをPLC20にダウンロードする。また、記憶装置14には、図2に示すような変数について割り当てられた名称である変数名とメモリアドレスとI/Oコメントを関連づけた変数テーブルが格納される。この変数テーブルは、全ての変数について登録されるが、その並び順は、例えば変数名に基づいて50音順などでソートした状態で格納される。このように変数名に基づいてソートするのは、特に全ての変数を一覧表示する場合の見やすさを考慮したものであり、必ずしもソートしていなくても良い。
The control program
図3は、本実施の形態の制御プログラム開発支援装置10の機能に着目して記載した構成図である。この制御プログラム開発支援装置10は、プログラムエディタと変数テーブルを有し、プログラムエディタは各命令語に対応するオペランドを入力するためのオペランド入力部を有する。プログラムエディタは、MPU11の1つの機能として実装される。プログラムエディタを用いて制御プログラムを作成・編集中に、所定の命令に対するオペランドを入力しようとした場合、オペランド入力部16を用い、変数の名称(変数名)やメモリアドレス等の文字列を入力する。
FIG. 3 is a configuration diagram focusing on the function of the control program
このオペランド入力部16は、入力部12の一機能であり、表示装置の所定エリアに表示させ、入力装置を操作してそのオペランド入力部16の各部に対して操作された命令内容を入力部12が取得し、MPU11に渡す。そして、MPU11が与えられた命令内容を理解し、所定の処理を実行する。
The
図4は、オペランド入力部16を示している。図4に示すように、上欄にタイトル表示領域16aが配置され、下欄左方にオペランド入力用エディットボックス16bが配置され、その下欄のオペランド入力用エディットボックス16bの右端には、三角形のマークが記された検索開始指示ボタン16cが配置され、さらにその右側にOKボタン16d,Cancelボタン16eがそれぞれ用意されている。
FIG. 4 shows the
このオペランド入力部はエディットボックスを有し、ユーザはこのエディットボックスにメモリアドレスまたは変数の名称(変数名)を入力することによって命令語に対応するオペランドを入力する。 This operand input unit has an edit box, and the user inputs an operand corresponding to an instruction word by inputting a memory address or a variable name (variable name) in this edit box.
タイトル表示領域16aは、現在処理中の命令に関する情報が表示される。つまり、例えば、作成・編集中の制御プログラム(ラダープログラム)を表示させた状態で、オペランドを入力する対象の命令をポインティングデバイスなどにより指定すると、その命令にすでにオペランドが設定されているか否かを判断し、未設定の場合には新規に入力することになるので、例えば「○○の入力」などと標記され、設定済みの場合には編集処理となるので、例えば「○○の編集」などと標記される。ここで、「○○」は、a接点,b接点など命令の種類が記述される。
The
オペランド入力用エディットボックス16bは、オペランドを入力するためのエリアであるが、本実施の形態では、さらにオペランドである変数を検出するためのキーワードを入力するエリアとしても用いられる。すなわち、図4に示すように、オペランド入力用テキストボックス16bに、キーボード等の入力装置を操作して「完了」なるキーワードを入力したとする。この状態では、オペランドである変数の名称(変数名)を入力したのか、その変数名を検索するためのキーワードを入力したのか不明である。そこで、検索開始指示ボタン16cが押下(クリック)されると、キーワードと判断し、変数テーブルにアクセスしてキーワードに一致するテキストを含む変数を抽出し、出力する(図5参照)。本実施の形態では、変数テーブル中の「変数名」と「I/Oコメント」の欄に格納されたテキスト中にキーワードを含む(存在場所は問わず)ものを抽出する。
The operand
また、OKボタン16dが押下(クリック)されると、変数の変数名を入力したと判断し、オペランドの設定を行なう。このとき、例えば変数テーブルを参照し、入力されたテキストと完全一致する変数名を持つ変数が存在するか否かを判断し、存在する場合には、その変数名に基づくオペランドの設定を行ない、存在しない場合には、所定のエラー処理をする。この処理は、従来と同様である。
When the
一方、図5のようにキーワードを、変数名,I/Oコメントのいずれかに含む変数をピックアップしてリスト表示されたならば、該当するもの(例えば、「工程2処理完了」)を選択する。この選択は、例えば、マウス等のポインティングデバイスを操作して該当する変数の位置にポインタを移動した状態で、ポインティングデバイスの所定のボタンをクリックして指定した状態で「エンターキー」を押下したり、所定のボタンのダブルクリックなど各種の方式をとれる。 On the other hand, as shown in FIG. 5, if a variable including a keyword in either a variable name or an I / O comment is picked up and displayed as a list, the corresponding item (for example, “process 2 process completed”) is selected. . This selection can be performed, for example, by operating a pointing device such as a mouse and moving the pointer to the position of the corresponding variable, clicking the specified button on the pointing device, and pressing the “enter key”. Various methods such as double-clicking a predetermined button can be taken.
これにより、図6に示すように、オペランド入力用エディットボックスに選択された変数名が表示される。よって、この状態でOKボタン16dをクリックすると、選択された変数名に基づき制御プログラム中の処理対象の命令に対するオペランドの設定が行なわれる。
As a result, as shown in FIG. 6, the selected variable name is displayed in the operand input edit box. Therefore, when the
また、上述したいずれのタイミングでも、Cancellボタン16eを押下(クリック)すると、オペランド入力部16を表示装置の所定エリアから消去する。
At any timing described above, when the Cancel
図7は、従来方式の一覧リスト表示した例を示している。全ての変数がリストアップされるため、図5と比較しても明らかなように、表示される変数の数が多く目的の変数を探すのが煩雑である。また、多くの場合、初期画面には目的の変数が表示されず、スクロールして見つけることになるので、スクロール中に見落とす可能性が高くなる。これに対し、図5に示すように、本実施の形態の方式によれば、変数が絞り込まれて表示されるので、容易に見つけることができる。 FIG. 7 shows an example of a conventional list display. Since all the variables are listed, it is complicated to search for the target variable with a large number of displayed variables, as is apparent from comparison with FIG. In many cases, the target variable is not displayed on the initial screen, but is found by scrolling, so there is a high possibility of being overlooked during scrolling. On the other hand, as shown in FIG. 5, according to the method of the present embodiment, since the variables are narrowed down and displayed, they can be easily found.
また、変数の名称とともに、メモリアドレスやI/Oコメントも併せて表示するため、内容を理解しやすく、より簡単かつ迅速に目的の変数を特定できる。さらに、従来方式では、全ての変数を一覧表示するか、前方一致検索して該当の変数を先頭に持ってくるだけであるため、図5に例示した「完了」なるキーワードを入力しても前方一致によって抽出することはできない。 In addition, since the memory address and I / O comment are displayed together with the variable name, the contents can be easily understood, and the target variable can be specified more easily and quickly. Furthermore, in the conventional method, all variables are displayed in a list, or a forward matching search is performed, and the corresponding variable is only brought to the top. Therefore, even if the “complete” keyword illustrated in FIG. It cannot be extracted by matching.
もちろん、変数の名称の一部を覚えていれば、上述した絞り込み処理が行えるが、全く覚えていない場合や、不正確で目的の変数を検出できない場合には、従来と同様に一覧リスト表示させる必要がある。そこで本実施の形態では、オペランド入力用エディットボックス16bに未入力の状態で検索開始指示ボタン16cが押下(クリック)されると、変数テーブルに格納された全ての変数を抽出し、リスト表示する機能を付加している。
Of course, if you remember a part of the variable name, you can perform the above-mentioned narrowing process, but if you don't remember at all, or if you cannot detect the target variable because it is inaccurate, display the list as before. There is a need. Therefore, in the present embodiment, when the search
次に、上述した図4から図6,図7の処理、つまり、検索開始指示ボタン16cが押下(クリック)されたことに伴い、変数リストを作成し表示する機能について説明する。係る機能は、図8に示すフローチャートをMPU11が実行することにより実現される。すなわち、検索開示指示ボタン16cが押下されると、まずnを0にセットし(S1)、現在のnの値が変数の総数未満か否かを判断する(S2)。本実施の形態では、変数テーブルの先頭が0番となっている。よって、変数の総数がNとすると、最終の変数はN−1番となり、n=Nとなる全ての変数に対する処理が終了したことになる。総数未満の場合は、未処理の変数が変数テーブルに残っているため、S3に進みn番目の変数データを取得する。取得する変数データは、変数テーブルに格納されたn番の変数について関連付けられた全てのデータである。
Next, the processing of FIGS. 4 to 6 and 7 described above, that is, a function for creating and displaying a variable list in response to the search
オペランド入力用テキストボックス16bにキーワードが入力されているか否かを判断する(S4)。そして、キーワードが入力されていると、取得した変数データ中の変数名とI/Oコメントの中に入力されたキーワードと一致する文字列があるか否かを判断する(S5)。
It is determined whether or not a keyword is entered in the operand
存在している場合には、取得した変数データを変数「変数名」,「メモリアドレス」,「I/Oコメント」に整形し(S6)、変数リストに追加する(S7)。なお、本実施の形態では、変数テーブルが、「変数名」,「メモリアドレス」,「I/Oコメント」となっているため、S6の処理は特に行なわなくても良いが、変数テーブルに他の目的のため上記3つ以外のデータも関連づけて登録されている場合には、S6を実行することにより必要なデータのみ抽出する。その後、nを1インクリメントし(S8)、S2に戻る。これにより、次の変数について上記の処理を行なうことができる。 If it exists, the acquired variable data is formatted into variables “variable name”, “memory address”, and “I / O comment” (S6), and added to the variable list (S7). In the present embodiment, since the variable table is “variable name”, “memory address”, and “I / O comment”, the process of S6 is not particularly required. If other data than the above three are registered in association with each other for the purpose, only necessary data is extracted by executing S6. Thereafter, n is incremented by 1 (S8), and the process returns to S2. Thereby, the above processing can be performed for the next variable.
また、処理対象のn番の変数の変数データにキーワードと一致する文字列が存在しない場合には、S4の分岐判断がNoとなり、S8に飛びnを1インクリメントし(S8)、S2に戻る。これにより、S6,S7がスキップされるため、変数リストには登録されず、次の変数に対する処理に移行する。 If there is no character string matching the keyword in the variable data of the nth variable to be processed, the branch determination in S4 is No, jumps to S8, increments n by 1 (S8), and returns to S2. As a result, S6 and S7 are skipped, so that the process is not registered in the variable list, and the process proceeds to the next variable.
また、キーワードが入力されていない場合には、S3の分岐判断がNoとなるので、S6に飛び、取得した変数データを変数「変数名」,「メモリアドレス」,「I/Oコメント」に整形した後、変数リストに追加する(S7)。その後、nを1インクリメントし(S8)、S2に戻る。これにより、次の変数について上記の処理を行なうことができる。 If no keyword is input, the branch determination in S3 is No, so the process jumps to S6 and the acquired variable data is formatted into the variables “variable name”, “memory address”, and “I / O comment”. Is added to the variable list (S7). Thereafter, n is incremented by 1 (S8), and the process returns to S2. Thereby, the above processing can be performed for the next variable.
そして、上述した処理を繰り返し実行し、最後の変数について処理をした後、S8を実行することにより、nが変数の数になるので、S2の分岐判断でNoとなる。すると、S9に飛び、S7を繰り返し実行して変数データを順次追加して生成された変数リストを表示する(S9)。 Then, the above-described process is repeatedly executed, and after the last variable is processed, S8 is executed, so that n becomes the number of variables, so No is determined in the branch determination of S2. Then, the process jumps to S9 to display a variable list generated by repeatedly executing S7 and sequentially adding variable data (S9).
上記のように、キーワードが入力された場合には、そのキーワードと一致する文字列を含むもののみが抽出されるため、表示された変数リストは絞り込まれたものとなる。また、キーワードが入力されていない場合には、S3からS6スキップするため、全ての変数データが変数リストに追加される。 As described above, when a keyword is input, only those including a character string that matches the keyword are extracted, so that the displayed variable list is narrowed down. If no keyword is input, S3 to S6 are skipped, so that all variable data is added to the variable list.
本実施の形態によれば、以下に挙げるような作用効果を奏するため、PLCの制御プログラムの開発効率を向上することができる。すなわち、(1)キーワードを含む変数だけを一覧表示するので、変数の検索性が向上する。(2)キーワードを変数名に含む変数だけでなく、キーワードをI/Oコメントに含む変数も検索の対象とすることができる。また、検索対象を変数名のみにするか、I/Oコメントのみにするか、両方とも対象とするかを選択することができる。(3)キーワードが、変数名やI/Oコメントの先頭にある変数だけではなく、その途中にある変数も検索対象とする。これによって、ユーザが変数の一部分しか憶えていなくても、オペランドとして入力しようとしている変数を検索することができる。(4)一覧表示に変数の変数名だけでなくメモリアドレスも表示されるので、オペランドとして選択した変数が実際にはどのアドレスに割り当てられているのかを確認することができる。 According to the present embodiment, since the following effects can be obtained, the development efficiency of the PLC control program can be improved. That is, (1) Since only the variables including the keyword are displayed in a list, the searchability of the variables is improved. (2) Not only the variable including the keyword in the variable name but also the variable including the keyword in the I / O comment can be searched. In addition, it is possible to select whether to search only variable names, only I / O comments, or both. (3) The search target is not only the variable at the beginning of the variable name or I / O comment, but also the variable in the middle of the keyword. Thereby, even if the user remembers only a part of the variable, it is possible to search for the variable to be input as the operand. (4) Since not only the variable name of the variable but also the memory address is displayed in the list display, it is possible to confirm to which address the variable selected as the operand is actually assigned.
上述した実施の形態では、変数名とI/Oコメントの両方に対して検索するようにしたが、いずれか一方でも良いし、或いは、メモリアドレスに対して検索するようにすることもできる。また、表示する一覧リストの形態としては、変数名とメモリアドレスとI/Oコメントを併記して表示するようにしたが、変数名を含む2種類或いは変数名のみでも良いし、さらに別の情報を表示するようにしても良い。 In the above-described embodiment, the search is performed for both the variable name and the I / O comment. However, either one may be performed, or the search may be performed for the memory address. Moreover, as a form of the list to be displayed, the variable name, the memory address, and the I / O comment are displayed together. However, only two types including the variable name or only the variable name may be displayed. May be displayed.
また、本願実施の形態では、プログラマブルコントローラ用のプログラム作成・編集の際に、命令語のオペランドとして入力する変数名の検索について述べたが、本発明はこれに限るものではない。例えば、PLCのメモリアドレスの状態をモニタする場合のメモリアドレスや変数名の入力時、あるいは、プログラム中の命令語を検索する場合のメモリアドレスや変数名の入力時等にも本発明を適用することは容易である。 In the embodiment of the present application, the search for a variable name to be input as an operand of an instruction word when creating or editing a program for a programmable controller has been described. However, the present invention is not limited to this. For example, the present invention is also applied when inputting a memory address or variable name when monitoring the state of a PLC memory address, or when inputting a memory address or variable name when searching for an instruction word in a program. It is easy.
10 プログラム開発支援装置
11 MPU
12 入力部
13 表示部
14 記憶装置
15 通信インタフェース
16 オペランド入力部
10 Program
12
Claims (2)
プログラマブルコントローラの内部メモリアドレスを識別する文字列として割り当てた変数名と、その変数名に対応する内部メモリアドレスと、その変数名の付加情報であるI/Oコメントを関連づけた変数テーブルを備え、
当該変数テーブル内の変数名,内部メモリアドレス,I/Oコメントの少なくとも1種類を検索対象とし、
プログラムを構成する命令語のオペランドを入力後、検索開始ボタンが押された場合は前記検索対象の中から、入力された文字列を含むデータを抽出し、前記検索対象の中から、入力された文字列を含むデータを抽出し、そのデータに対応する内部メモリアドレス及びI/Oコメントの内の少なくとも一つの一覧を表示し、何も入力せずに検索開始ボタンが押された場合は変数テーブルを全て表示する表示手段と、
その表示示手段で表示された内部メモリアドレス及びまたはI/Oコメントから所望の内部メモリアドレス及びまたはI/Oコメントを指定する指定手段とを備え、
その指定手段で指定された内部メモリアドレス及びまたはI/Oコメントに基づいて前記オペランドの入力が行なわれる機能と、
前記オペランドの入力後、OKボタンが押された場合はそのままオペランドとして設定する機能を備えたことを特徴とするプログラム開発支援装置。 In a program development support device that creates a program for a programmable controller,
A variable table that associates a variable name assigned as a character string for identifying an internal memory address of the programmable controller, an internal memory address corresponding to the variable name, and an I / O comment that is additional information of the variable name,
Search for at least one of variable names, internal memory addresses, and I / O comments in the variable table.
When the search start button is pressed after inputting the operand of the instruction word constituting the program, data including the input character string is extracted from the search target and input from the search target When data including character strings is extracted, a list of at least one of the internal memory address and I / O comment corresponding to the data is displayed, and a variable table when the search start button is pressed without inputting anything Display means for displaying all
Designating means for designating a desired internal memory address and / or I / O comment from the internal memory address and / or I / O comment displayed by the display indicating means;
A function for inputting the operand based on the internal memory address and / or I / O comment specified by the specifying means ;
A program development support apparatus comprising a function for setting an operand as it is when an OK button is pressed after inputting the operand .
プログラマブルコントローラの内部メモリアドレスを識別する文字列として割り当てた変数名と、その変数名に対応する内部メモリアドレスと、その変数名の付加情報であるI/Oコメントを関連づけた変数テーブル内の前記変数名,前記内部メモリアドレス,前記I/Oコメントの少なくとも1種類を検索対象とし、前記プログラムを構成する命令語のオペランドを入力後、検索開始ボタンが押された場合は、前記検索対象の中から、入力された文字列を含むデータを抽出し、そのデータに対応する内部メモリアドレス及びI/Oコメントの内の少なくとも一つの一覧を表示し、何も入力せずに検索開始ボタンが押された場合は変数テーブルを全て表示する表示処理、
その表示処理を実行して表示された内部メモリアドレス及びまたはI/Oコメントから所望の内部メモリアドレス及びまたはI/Oコメントを指定する指定処理、を実行し、その指定処理にて指定された内部メモリアドレス及びまたはI/Oコメントに基づいて前記オペランドの入力を行ない、前記オペランドの入力後、OKボタンが押された場合はそのままオペランドとして設定することを特徴とする処理方法。 A processing method in a program development support device for creating a program for a programmable controller,
The variable in the variable table in which a variable name assigned as a character string for identifying an internal memory address of the programmable controller, an internal memory address corresponding to the variable name, and an I / O comment that is additional information of the variable name are associated If at least one of the name, the internal memory address, and the I / O comment is to be searched and the search start button is pressed after inputting the operand of the instruction word constituting the program, the search target is The data including the input character string is extracted, the list of at least one of the internal memory address and I / O comment corresponding to the data is displayed , and the search start button is pressed without inputting anything. Display process to display all variable tables in case
Executing the display process, executing a designation process for designating a desired internal memory address and / or I / O comment from the displayed internal memory address and / or I / O comment, and executing the designated process. A processing method comprising: inputting an operand based on a memory address and / or an I / O comment, and setting the operand as it is when an OK button is pressed after the input of the operand .
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2009174115A JP4888534B2 (en) | 2009-07-27 | 2009-07-27 | Program development support apparatus and processing method |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2009174115A JP4888534B2 (en) | 2009-07-27 | 2009-07-27 | Program development support apparatus and processing method |
Related Parent Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2004170529A Division JP4420210B2 (en) | 2004-06-08 | 2004-06-08 | Program development support apparatus and processing method |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2009245456A JP2009245456A (en) | 2009-10-22 |
| JP4888534B2 true JP4888534B2 (en) | 2012-02-29 |
Family
ID=41307192
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2009174115A Expired - Fee Related JP4888534B2 (en) | 2009-07-27 | 2009-07-27 | Program development support apparatus and processing method |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP4888534B2 (en) |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN107291444A (en) * | 2017-05-11 | 2017-10-24 | 广东卓信环境科技股份有限公司 | PLC instructs generation method and device and PLC programmed methods |
| CN110488738A (en) * | 2019-07-23 | 2019-11-22 | 中车青岛四方机车车辆股份有限公司 | A code generation method and device |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2014178255A1 (en) | 2013-04-30 | 2014-11-06 | 富士電機株式会社 | Controller and map file conversion device |
| JP7147807B2 (en) * | 2020-06-26 | 2022-10-05 | 株式会社安川電機 | Engineering device, host control device, engineering method, processing execution method, and program |
Family Cites Families (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2734176B2 (en) * | 1990-06-19 | 1998-03-30 | 日産自動車株式会社 | How to create a sequence program |
| JPH09330107A (en) * | 1996-06-12 | 1997-12-22 | Meidensha Corp | Commenting method in ladder diagram creation CAD system for programmable controller |
| JPH10254688A (en) * | 1997-03-07 | 1998-09-25 | Toshiba Corp | Program creation support device |
-
2009
- 2009-07-27 JP JP2009174115A patent/JP4888534B2/en not_active Expired - Fee Related
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN107291444A (en) * | 2017-05-11 | 2017-10-24 | 广东卓信环境科技股份有限公司 | PLC instructs generation method and device and PLC programmed methods |
| CN107291444B (en) * | 2017-05-11 | 2020-08-28 | 广东卓信环境科技股份有限公司 | PLC instruction generation method and device and PLC programming method |
| CN110488738A (en) * | 2019-07-23 | 2019-11-22 | 中车青岛四方机车车辆股份有限公司 | A code generation method and device |
Also Published As
| Publication number | Publication date |
|---|---|
| JP2009245456A (en) | 2009-10-22 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US20110252062A1 (en) | Electronic device for searching for entry word in dictionary data, control method thereof and program product | |
| JP4420210B2 (en) | Program development support apparatus and processing method | |
| JP5962277B2 (en) | Document association apparatus and program | |
| JP2012128479A (en) | Retrieval device and program | |
| CN104142985B (en) | A kind of semi-automatic vertical reptile Core Generator and method | |
| JP4888534B2 (en) | Program development support apparatus and processing method | |
| JP2005300324A (en) | Measurement data analysis method, program, and measurement data analysis system for device under test | |
| CN102479219B (en) | Processing method of interactive search | |
| JP5068395B1 (en) | Screen data editing device for display | |
| JP2005173999A (en) | Electronic file search apparatus, electronic file search system, electronic file search method, program, and recording medium | |
| JP2003084813A (en) | Ladder circuit editing device and its editing method | |
| US20070073713A1 (en) | Term search and link creation from a graphical user interface associated with presentation code | |
| JP2016189128A (en) | Numerical controller having ambiguous retrieval function in program | |
| JP5127553B2 (en) | Information processing apparatus, information processing method, program, and recording medium | |
| JP6379742B2 (en) | Information display control device and program | |
| US20070226208A1 (en) | Information retrieval device | |
| JP6157166B2 (en) | Parts generation system, method and program | |
| JP2007047849A (en) | Preparation program for screen data for programmable display unit and computer-readable recording medium and screen data preparing device | |
| JPH10187762A (en) | Search formula input device | |
| JP2010157166A (en) | Device, system and method for lot tracing, and program | |
| WO2024014354A1 (en) | Control program editing device, editing method, and program | |
| JP2005141296A (en) | Document search device, document search method, and document search program | |
| JP2019523461A (en) | Semiconductor component search method using last alphabet removal algorithm | |
| Gurský et al. | Semiautomatic Annotation of E-Shops. | |
| JP2024011851A (en) | Control program editing device, editing method, and program |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20090825 |
|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20090825 |
|
| A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20110420 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20110428 |
|
| A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20110627 |
|
| TRDD | Decision of grant or rejection written | ||
| A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20111115 |
|
| A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20111128 |
|
| R150 | Certificate of patent or registration of utility model |
Ref document number: 4888534 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20141222 Year of fee payment: 3 |
|
| LAPS | Cancellation because of no payment of annual fees |