JPH0443406A - Method and device for displaying natural language for program generated by nc language - Google Patents
Method and device for displaying natural language for program generated by nc languageInfo
- Publication number
- JPH0443406A JPH0443406A JP15089190A JP15089190A JPH0443406A JP H0443406 A JPH0443406 A JP H0443406A JP 15089190 A JP15089190 A JP 15089190A JP 15089190 A JP15089190 A JP 15089190A JP H0443406 A JPH0443406 A JP H0443406A
- Authority
- JP
- Japan
- Prior art keywords
- language
- natural language
- character
- display
- program
- 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
Links
Landscapes
- Numerical Control (AREA)
Abstract
(57)【要約】本公報は電子出願前の出願データであるた
め要約のデータは記録されません。(57) [Summary] This bulletin contains application data before electronic filing, so abstract data is not recorded.
Description
【発明の詳細な説明】
〈産業上の利用分野〉
この発明はNC言語で作成されたプログラムを日本語等
の自然言語で表示するための方法およびその装置に関す
る。DETAILED DESCRIPTION OF THE INVENTION <Industrial Application Field> The present invention relates to a method and apparatus for displaying a program created in an NC language in a natural language such as Japanese.
〈従来の技術、および発明が解決しようとする課題〉
従来から数値制御装置t(以下、NC装置と略称する)
に対して動作指令を与えるためにNC言語で作成した作
業プログラムが用いられている。<Prior art and problems to be solved by the invention> Conventionally, numerical control devices (hereinafter abbreviated as NC devices) have been used.
A work program written in NC language is used to give operation commands to the machine.
したがって、作業プログラムを作成し、または作成され
た作業プログラムを修正するためにはNC言語をよく知
っていなければならない。Therefore, in order to create a work program or modify a created work program, one must be familiar with the NC language.
具体的には、例えば、
N100T060606番
N101G53GOOX25.000290.000↓
N102S6N102S6004
N103G54G01G98W−20F250番N10
4GO3W−20,0OOIOKI0.000F180
↓
N105GO4U7↓
N106GOIW−20,000F250↓N107G
OIU15.00OR5,000↓N10N108MO
5↓
N109G53GOOX50.000z130゜000
↓
N110M30↓
の作業プログラムが作成されている場合には、修正等の
ためにプログラムを表示させることが必要になれば、上
記NC言語そのものによってプログラムを表示するしか
方法がなかった。Specifically, for example, No. N100T060606 N101G53GOOX25.000290.000↓ N102S6N102S6004 N103G54G01G98W-20F250 No. N10
4GO3W-20,0OOIOKI0.000F180
↓ N105GO4U7↓ N106GOIW-20,000F250↓N107G
OIU15.00OR5,000↓N10N108MO
5↓ N109G53GOOX50.000z130゜000
↓ When a work program for N110M30↓ has been created, if it becomes necessary to display the program for modification or the like, the only way is to display the program using the NC language itself.
また、このように表示された作業プログラムを見てプロ
グラムの内容を理解するわけであり、NC言語をよく知
っていれば、Nで始まる数字がブロック番号を示し、ブ
ロック100が工具選択、101が早送り(機械座標で
絶対値指令)、102が主軸正転と切削剤吐出開始、1
03が切削送り(ワーク座標で相対値指令)、104が
左円弧(ワーク座標で相対値指令)、105が停留、1
06が切削送り(ワーク座標で相対値指令)、107が
切削送り(ワーク座標で相対値指令)、108が主軸停
止と切削剤吐出停止、109が早送り(機械座標で絶対
値指令)、110がプログラム終了をそれぞれ示してい
ることを理解できるのである。しかし、NC言語を余り
よく知らないオペレータは正確にプログラムの内容を理
解することができないので、デバッグ、修正を行なうこ
とができないという不都合がある。即ち、シンボリック
NC等により、NC言語を余りよく知らなくても作業プ
ログラムを作成できるようにしても、その後のデバッグ
、修正等に対処できない。Also, you can understand the contents of the program by looking at the work program displayed in this way, and if you are familiar with the NC language, the numbers starting with N indicate the block number, block 100 is tool selection, block 101 is Rapid traverse (absolute value command in machine coordinates), 102 starts spindle forward rotation and cutting fluid discharge, 1
03 is cutting feed (relative value command in workpiece coordinates), 104 is left arc (relative value command in workpiece coordinates), 105 is stationary, 1
06 is cutting feed (relative value command in workpiece coordinates), 107 is cutting feed (relative value command in workpiece coordinates), 108 is spindle stop and cutting fluid discharge stop, 109 is rapid feed (absolute value command in machine coordinates), 110 is You can understand that each indicates the end of the program. However, an operator who is not familiar with the NC language cannot accurately understand the contents of the program, and therefore cannot debug or modify the program. That is, even if it is possible to create a work program using symbolic NC or the like even if one does not know the NC language very well, it is not possible to deal with subsequent debugging, modification, etc.
また、NC言語はFOTRAN等のプログラミング言語
と異なり、統一されたものではないため、メーカ、機械
等が異なればNC言語も異なる可能性があり、オペレー
タはこれら種々のNC言語を知っていることが要求され
るのみならず、どのNC言語を使用すべきかを知ってい
ることも要求される。この結果、作業プログラムの作成
、修正を行ない得るオペレータが大目】に少なくなって
しまい、また、これらの要求を満足するオペレータを育
成するために長期間を必要とするという不都合がある。Also, unlike programming languages such as FOTRAN, NC languages are not standardized, so the NC languages may differ depending on the manufacturer, machine, etc., and it is important for operators to know these various NC languages. Not only is it required, but it is also required to know which NC language to use. As a result, the number of operators who can create and modify work programs is considerably reduced, and there is also the disadvantage that a long period of time is required to train operators who can meet these requirements.
〈発明の目的〉
この発明は上記の問題点に鑑みてなされたものであり、
NC言語に不慣れなオペレータにも判り易いようにプロ
グラムの内容を表示する新規な自然言語化表示方法およ
びその装置を提供することを目的としている。<Object of the invention> This invention was made in view of the above problems,
It is an object of the present invention to provide a new natural language display method and apparatus for displaying program contents in a manner that is easy to understand even for operators who are unfamiliar with NC language.
く課題を解決するための手段〉
上記の目的を達成するための、第1の発明の自然言語化
表示方法は、NC言語と自然言語との対応を示すテーブ
ルを予め作成しておき、NC言語で作成されたプログラ
ムを1文字ずつ取り込み、英文字で始まり、次の英文字
または改行マークの前までを1ワードとして複数のワー
ドに区分し、各区分毎にテーブルのNC言語と比較し、
一致したNC言語に対応する自然言語をテーブルから読
み出して表示する方法である。Means for Solving the Problem> In order to achieve the above object, the natural language display method of the first invention is such that a table showing the correspondence between the NC language and the natural language is created in advance, and the NC language Import the program created character by character, divide it into multiple words starting with an alphabetic character and ending with the next alphabetic character or before the line break mark as one word, and compare each division with the NC language in the table.
This method reads out the natural language corresponding to the matched NC language from a table and displays it.
第2の発明の自然言語化表示方法は、テーブルから読み
出した自然言語を予め定められた所定箇所に表示する方
法である。The natural language display method of the second invention is a method of displaying natural language read from a table at a predetermined location.
上記の目的を達成するための、第3の発明の自然言語化
表示装置は、NC言語と自然言語とを予め対応付けて格
納しておくテーブルと、NC言語で作成されたプログラ
ムを1文字ずつ取り込む取り込み手段と、取り込んだ文
字が英文字または改行マークか否かを判別する文字判別
手段と、英文字で始まり、次の英文字または改行マーク
の前までを1ワードとして複数のワードに区分する区分
手段と、各区分毎にテーブルのNC言語と比較し、一致
したNC言語に対応する自然言語をテーブルから読み出
す翻訳手段と、テーブルから読み出した自然言語を受け
取って表示する表示手段とを含んでいる。In order to achieve the above object, the natural language display device of the third invention includes a table in which NC language and natural language are stored in correspondence in advance, and a program created in NC language character by character. An importing means for importing, a character determining means for determining whether the imported characters are English characters or line feed marks, and a word starting with an English character and ending before the next English character or line feed mark and dividing into a plurality of words. It includes a classification means, a translation means for comparing each classification with the NC language of the table and reading from the table a natural language corresponding to the matched NC language, and a display means for receiving and displaying the natural language read from the table. There is.
第4の発明の自然言語化表示装置は、テーブルが、NC
言語と表示フォーマットをも予め対応付けて格納してお
くものであり、区分されたNC言語に基づいて表示フォ
ーマットを読み出す読み出し手段をさらに含み、表示手
段が、テーブルから読み出された自然言語を、読み出さ
れた表示フォーマットの該当箇所に表示するものである
。In the natural language display device of the fourth invention, the table is NC
Languages and display formats are also stored in association with each other in advance, and further includes a reading means for reading out the display format based on the classified NC language, and the display means reads out the natural language read from the table. It is displayed at the corresponding location in the read display format.
く作用〉
以上の自然言語化表示方法であれば、NC言語と自然言
語との対応を示すテーブルを予め作成しておく。そして
、NC言語で作成されたプログラムを1文字ずつ取り込
んで、英文字で始まり、次の英文字または改行マークの
前までを1ワードとして複数のワードに区分する。この
状態において、各区分はテーブルのNC言語の何れがと
一致するノテアルから、各区分毎にテーブルのN C言
FAと比較し、一致したNC言語に対応する自然言語を
テーブルから読み出して表示することにより、NC言語
で作成されたプログラムの全範囲を自然言語で表示でき
る。この結果、NC言語を理解できないオペレータであ
ってもプログラムの内容を正確に理解できる。また、メ
ーカ、機械等によりNC言語が異なっていても、テーブ
ルまたはテーブルの内容を変更するだけで簡単に対処で
きる。Effect> In the natural language display method described above, a table showing the correspondence between the NC language and the natural language is created in advance. Then, the program written in the NC language is taken in one character at a time and divided into a plurality of words, with each word beginning with an English character and ending with the next English character or line feed mark. In this state, each category is compared with the NC language FA in the table from the noteal that matches which of the NC languages in the table, and the natural language corresponding to the matched NC language is read out from the table and displayed. This allows the entire range of programs created in NC language to be displayed in natural language. As a result, even an operator who cannot understand the NC language can accurately understand the contents of the program. Furthermore, even if the NC language differs depending on the manufacturer, machine, etc., this can be easily handled by simply changing the table or the contents of the table.
第2の発明の自然言語化表示方法であれば、テーブルか
ら読み出した自然言語を予め定められた所定箇所に表示
するのであるから、プログラムの区分の順番に自然言語
で表示する場合と比較して著しく見品い自然言語化表示
を達成できる。In the natural language display method of the second invention, the natural language read from the table is displayed at a predetermined location, so compared to the case where the natural language is displayed in the order of the program categories. A remarkable natural language display can be achieved.
第3の発明の自然言語化表示装置であれば、先ず、NC
言語と自然言語とを予め対応付けてテーブルに格納して
おく。この状態において、NC言語で作成されたプログ
ラムを取り込み手段により1文字ずつ取り込み、取り込
んだ文字が英文字または改行マークか否かを文字判別手
段により判別する。そして、この判別結果に基づいて、
区分手段により、英文字で始まり、次の英文字または改
行マークの前までを1ワードとして複数のワードに区分
し、各区分毎に翻訳手段によりテーブルのNC言語と比
較し、一致したNC言語に対応する自然言語をテーブル
から読み出し、テーブルから読み出した自然言語を受け
取って表示手段により表示する。この結果、NC言語を
理解できないオペレータであってもプログラムの内容を
正確に理解できる。また、メーカ、機械等によりNC言
語が異なっていても、テーブルまたはテーブルの内容を
変更するだけで簡単に対処できる。In the natural language display device of the third invention, first, the NC
Languages and natural languages are associated in advance and stored in a table. In this state, the program created in the NC language is imported character by character by the importing means, and the character determining means determines whether the imported characters are English characters or line feed marks. Then, based on this discrimination result,
The classification means divides the word starting with an English character and ending with the next English character or line break mark into multiple words, and each division is compared with the NC language in the table by the translation means, and a matching NC language is selected. A corresponding natural language is read from the table, and the natural language read from the table is received and displayed by a display means. As a result, even an operator who cannot understand the NC language can accurately understand the contents of the program. Furthermore, even if the NC language differs depending on the manufacturer, machine, etc., this can be easily handled by simply changing the table or the contents of the table.
第4の発明の自然言語化表示装置であれば、テーブルが
、NC言語と表示フォーマットをも予め対応付けて格納
しておくものであるから、翻訳手段により自然言語をテ
ーブルから読み出す場合に、表示フォーマットが格納さ
れていれば、読み出し手段により該当する表示フォーマ
ットを読み出し、表示手段により、テーブルから読み出
された自然言語を、読み出された表示フォーマットの該
当箇所に表示する。したがって、プログラムの区分の順
番に自然言語で表示する場合と比較して著しく見易い自
然言語化表示を達成できる。In the natural language display device of the fourth invention, since the table stores the NC language and the display format in association with each other in advance, when the natural language is read from the table by the translation means, the display If the format is stored, the reading means reads the corresponding display format, and the display means displays the natural language read from the table at the corresponding location in the read display format. Therefore, it is possible to achieve a display in natural language that is much easier to see than when displaying in natural language in the order of the program sections.
(1,尚、これらの場合において、自然言語としては、
日本語、英詔等種々の自然言語を採用できる。(1. In these cases, the natural language is
Various natural languages such as Japanese and English can be used.
〈実施例〉 以下、実施例を示す添付図面によって詳細に説明する。<Example> Hereinafter, embodiments will be described in detail with reference to the accompanying drawings showing examples.
第8図はNC装置のフロント−パネルの一例を示す概略
図であり、画面選択、機能選択のためのメニュー、作成
された作業プログラム等を表示するC RT (1)と
、テンキー、カーソルキー ファンクションキー、デー
タ入力キー等を含むキーボード部■と、動作量設定I\
ンドル、非常停止スイッチ、電源スィッチ等を含む操作
部(3)とを含んでいる。FIG. 8 is a schematic diagram showing an example of the front panel of the NC device, which includes a CRT (1) that displays screen selection, menus for function selection, created work programs, etc., a numeric keypad, and cursor keys. Keyboard section including keys, data input keys, etc. and operation amount setting I\
The operating section (3) includes a handle, an emergency stop switch, a power switch, etc.
第1図はこの発明の自然言語化表示装置の一実施例を示
すブロック図であり、NC言語と自然言語とを予め対応
付けて格納しておくテーブル(4)と、NC言語で作成
されたプログラムを1文字ずつ取り込む取り込み部(5
)と、取り込んだ文字が英文字、改行マーク、プログラ
ム終了マーク(以下、EoFと略称する)かこれら以外
かを判別する文字判別部(6)と、判別結果に基づいて
、英文字で始まり、次の英文字または改行マークの前ま
でを1ワードとして複数のワードに区分する区分部のと
、各区分毎にテーブル(4)のNC言語と比較し、一致
したNC言語に対応する自然言語をテーブル(4)から
読み出す翻訳部[F])と、テーブル(4)から読み出
した自然言語を受け取って表示のためにCRT (1)
に供給する表示部(9)と、EOFが検出されるまで上
記各部を反復動作させる制御部00)とを含んでいる。FIG. 1 is a block diagram showing an embodiment of the natural language display device of the present invention, which includes a table (4) in which NC language and natural language are stored in association with each other in advance, and The import section that imports the program character by character (5
), a character discrimination unit (6) that discriminates whether the imported characters are English characters, line feed marks, program end marks (hereinafter abbreviated as EoF), or other than these, and based on the discrimination results, a Compare the division section that divides the word up to the next English character or line break mark into multiple words with the NC language in Table (4) for each division, and select the natural language that corresponds to the matched NC language. A translation unit [F]) reads out the table (4), and a CRT (1) receives the natural language read out from the table (4) and displays it.
and a control section 00) that repeatedly operates each of the above sections until EOF is detected.
尚、(11)はNC言語で作成されたプログラムを格納
するプログラム参メモリである。Note that (11) is a program reference memory that stores a program created in the NC language.
第2図はテーブル(4)の内容を概略的に示す図であり
、pJ (: 言Z“G00#〜“G99”および“M
O3”〜“M30°のそれぞれに対応付けて日本語表現
を予め格納しである。したがって、この実施例は、NC
言語で作成されたプログラムを自然言語の一種である日
本語に翻訳して表示する場合に対応する。FIG. 2 is a diagram schematically showing the contents of table (4).
Japanese expressions are stored in advance in association with each of degrees O3'' to M30. Therefore, this example
This corresponds to the case where a program created in a foreign language is translated into Japanese, which is a type of natural language, and displayed.
上記の構成の自然言語化・表示装置の1作は次のとおり
である。An example of a natural language conversion/display device with the above configuration is as follows.
自然言語化表示が指示された場合には、NC言語で作成
され、かつプログラム・メモリ(11)に格納されたプ
ログラムを取り込み部(5)のより1文字ずつ取り込み
、取り込んだ文字が英文字、改行マーク、プログラム終
了マーク(以下、EOFと略称する)かこれら以外かを
文字判別部(6)により判別する。即ち、順次取り込ま
れる文字の全てについて文字判別部(6)による判別が
行なわれる。したがって、順次取り込まれる全ての文字
についての判別結果に基づいて、区分部(7)により、
英文字で始まり、次の英文字または改行マークの前まで
を1ワードとして1行のプログラムを複数のワードに区
分する。そして、区分された各ワードを翻訳部(8)に
供給することにより、テーブル(4)のNC言語と比較
し、一致したNC言語に対応する自然言語をテーブル(
4)から読み出す。したがって、テーブル(4)から読
み出した自然言語を表示部(9)を介してCRT (1
)に供給することにより、NC言語で作成されたプログ
ラムのワードに対応する日本語での表示を行なうことが
できる。尚、上記一致判別に関しては、英文字の種別に
応じてワード単位の完全一致が要求され、または英文字
のみの一致が要求されるので、翻訳部(8)においてこ
れらの要求に対処している。When natural language display is instructed, the program created in the NC language and stored in the program memory (11) is imported character by character from the import unit (5), and the imported characters are English characters, A character discriminator (6) determines whether the mark is a line feed mark, a program end mark (hereinafter abbreviated as EOF), or something else. That is, the character discriminator (6) discriminates all the characters that are sequentially fetched. Therefore, based on the discrimination results for all the characters that are sequentially captured, the classification unit (7)
Divide one line of the program into multiple words, with one word beginning with an alphabetic character and ending with the next alphabetic character or line feed mark. Then, by supplying each classified word to the translation unit (8), it is compared with the NC language in the table (4), and the natural language corresponding to the matched NC language is selected in the table (4).
Read from 4). Therefore, the natural language read from the table (4) is displayed on the CRT (1
), it is possible to display the words in Japanese corresponding to the words of the program created in the NC language. Regarding the above match determination, depending on the type of English character, complete word-by-word matching or matching of only English characters is required, so these requirements are dealt with in the translation section (8). .
この場合において、取り込んだ文字が改行マークである
と判別されるまで以上の一連の処理を反復すべく制御部
00)により反復動作が制御されるので、プログラムを
1行単位で日本語化して表示でき、また、取り込んだ文
字がEOFであると判別されるまで1行単位の日本語化
表示を反復すべく制御部00)により反復動作が制御さ
れるので、プログラムの全体を日本語化して表示できる
。In this case, the repeating operation is controlled by the control unit 00) to repeat the above series of processes until the imported character is determined to be a line feed mark, so the program is translated into Japanese and displayed line by line. In addition, since the repetitive operation is controlled by the control unit 00) to repeat displaying the Japanese language on a line-by-line basis until the imported characters are determined to be EOF, the entire program can be displayed in Japanese. can.
例えば、1行分のプログラムN108M05M09を読
み出した場合には、“N108“に基づいてプログラム
・インストラクション番号が108であること、“MO
S“に基づいて主軸停止であること、“MO9°に基づ
いて切削剤吐出停止であることがそれぞれ翻訳の結果に
基づいて判る。For example, when reading one line of program N108M05M09, the program instruction number is 108 based on "N108", and the program instruction number is "MO
Based on the translation results, it is determined that the spindle is stopped based on "S" and that the cutting fluid discharge is stopped based on "MO9°."
この結果、1行分のプログラムN108MO5MO9に
対応して「(プログラム・ブロック番号)108、主軸
停止、切削剤吐出停止」の日本語表示を達成できる。As a result, a Japanese display of "(program block number) 108, spindle stop, cutting fluid discharge stop" can be achieved corresponding to one line of program N108MO5MO9.
〈実施例2〉
第3図はこの発明の自然言語化表示方法の一実施例を示
すフローチャートであり、自然言語化表示が指示された
場合に、ステップ■においてプログラム・メモリ(11
)から該当するプログラムの1文字を取り込み、ステッ
プ■■■において、取り込んだ文字が英文字か、改行マ
ークか、EOFかを順次判別する。そして、取り込んだ
文字が英文字、改行マーク、EOFの何れでもないと判
別された場合には、再びステップ■の処理を行なう。<Embodiment 2> FIG. 3 is a flowchart showing an embodiment of the natural language display method of the present invention. When natural language display is instructed, the program memory (11
), and in step ■■■, it is sequentially determined whether the imported character is an English character, a new line mark, or an EOF. Then, if it is determined that the captured character is neither an English character, a new line mark, nor an EOF, the process of step (2) is performed again.
また、ステップ■において英文字であると判別された場
合には、ステップ■において第1番目の英文字か否かを
判別し、第1番目の英文字であると判別された場合には
、ステップ■において、この英文字をワードの始めの文
字として指定し、再びステップ■の処理を行なう。逆に
、第1番目でないと判別された場合には、ステップ■に
おいて、この英文字を次のワードの始めの文字として指
定するとともに、この英文字の前の文字をワードの終り
の文字として指定し、ステップ■において、得られたワ
ードと等しいNC言語をテーブル(4)からサーチし、
ステップ■において、サーチしたNC言語に対応付けら
れた日本語をテーブル(4)から読み出して表示し、再
びステップ■の処理を行なう。上記ステップ■において
改行マークであると判別された場合には、ステップ[相
]において、改行マークの前の文字をワードの終りの文
字として指定し、ステップ■において、得られたワード
と等しいNC言語をテーブル(4)からサーチし、ステ
ップ@において、サーチしたNC言語に対応付けられた
日本語をテーブル(4)から読み出して表示し、ステッ
プ■において表示行を改行するとともに、取り込み文字
の順番をリセットし、再びステップ■の処理を行なう。Furthermore, if it is determined in step ■ that it is an English character, it is determined in step ■ whether or not it is the first English character, and if it is determined that it is the first English character, step In step (2), this alphabetic character is designated as the first character of the word, and the process in step (2) is performed again. On the other hand, if it is determined that it is not the first character, in step ■, this alphabetic character is designated as the first character of the next word, and the character before this alphabetic character is designated as the last character of the word. Then, in step (■), search the table (4) for an NC language that is equivalent to the obtained word,
In step (2), the Japanese language associated with the searched NC language is read out from the table (4) and displayed, and the process in step (2) is performed again. If the character before the line break mark is determined to be a line break mark in step ① above, in step [phase], the character before the line break mark is designated as the end character of the word, and in step is searched from the table (4), and in step @, the Japanese corresponding to the searched NC language is read out from the table (4) and displayed, and in step ■, the displayed line is line-feeded, and the order of the imported characters is changed. Reset and perform the process in step (2) again.
さらに、上記ステップ■においてEOFであると判別さ
れた場合には、ステップ[有]において、EOFの前の
文字をワードの終りの文字として指定し、ステップ■に
おいて、得られたワードと等しいNC言語をテーブル(
4)からサーチし、ステップ■において、サーチしたN
C言語に対応付けられた日本語をテーブル(4)から読
み出して表示し、ステップ■において取り込み文字の順
番をリセットし、そのまま一連の処理を終了する。Furthermore, if it is determined that it is EOF in the above step (■), in step [Yes], the character before EOF is specified as the last character of the word, and in step (2), the character in the NC language equivalent to the obtained word is table (
4), and in step ■, the searched N
The Japanese language associated with the C language is read out from the table (4) and displayed, the order of the imported characters is reset in step (2), and the series of processing is terminated.
したがって、この実施例の場合にも、NC言語で作成さ
れたプログラムを1文字ずつ取り込み、英文字を境界と
して複数のワードに区画してテーブルをサーチするので
あるから、上記実施例と同様にNC言語で作成されたプ
ログラムを日本語で表示できる。Therefore, in the case of this embodiment as well, the program written in the NC language is imported character by character, and the table is searched by dividing it into a plurality of words using English characters as boundaries. Programs created in other languages can be displayed in Japanese.
〈実施例3〉
第4図はこの発明の自然言語化表示装置の他の実施例を
示すブロック図であり、第1図の実施例と異なる点は、
テーブル(4)に代えて、特定のNC言語に対応付けて
日本語化表示フォーマット・データを予め格納したテー
ブル(4′)を用いる点、テーブル(4′)から日本語
化表示フォーマット・データを読み出す読み出し部(1
2)を設けた点、表示部θ)に代えて、テーブル(4′
)から読み出した自然言語を受け取って、読み出し部(
12)により読み出された日本語化表示フす一マット・
データの該当箇所に当てはめた状態で表示のためにCR
T (1)に供給する表示部(9′)を用いる点のみで
ある。<Embodiment 3> FIG. 4 is a block diagram showing another embodiment of the natural language display device of the present invention, and the differences from the embodiment of FIG. 1 are as follows.
Instead of table (4), table (4') is used that stores Japanese display format data in association with a specific NC language. Reading unit (1
2), instead of the display section θ), the table (4'
) receives the natural language read out from the reading unit (
12) The Japanese display matte read out by
CR for display in the state applied to the relevant part of the data
The only difference is that the display section (9') that supplies the signal to T (1) is used.
したがって、この実施例の場合には、“GOO”〜“G
99° “M03”〜“M2O“のような特定のNC
言語が含まれているプログラム・ステップに対応してテ
ーブル(4′)に日本語化表示フォーマット・データを
読み出し、表示部(9′)により、各ワードに対応する
日本語を日本語化表示フォーマットの該当箇所に当ては
めるのであるから、著しく見易い日本語化表示を達成で
きる。Therefore, in this embodiment, "GOO" to "G
99° Specific NC like “M03” ~ “M2O”
The Japanese display format data is read into the table (4') corresponding to the program step that includes the language, and the display section (9') displays the Japanese corresponding to each word in the Japanese display format. , it is possible to achieve an extremely easy-to-read Japanese display.
く具体例〉
例えば、別表1に示す作業プログラムの日本語化表示は
別表2に示す通りになり、予め定められた箇所に該当す
る日本語が表示されるので、著しく見易い日本語化表示
を達成できる。 第5図(A)はプログラムのNC言語
順の日本語化を概略的に説明する図であり、「早送り」
、[切削送リ」、「右円弧切削」、「左円弧切削」、停
留」、「原点復帰」をそれぞれ示している。そして、同
図(B)はプログラムのワードを翻訳して得られた日本
語を表示すべく割り当てられた位置を示している。Specific example> For example, the Japanese display of the work program shown in Attachment 1 will be as shown in Attachment 2, and the corresponding Japanese will be displayed in predetermined places, achieving an extremely easy-to-read Japanese display. can. Figure 5 (A) is a diagram schematically explaining the Japaneseization of the NC language order of the program, and shows the "fast forward"
, [cutting feed], [right circular arc cutting], [left circular arc cutting], [stay], and [return to origin], respectively. FIG. 3B shows the position assigned to display the Japanese words obtained by translating the words of the program.
これらの図から明らかなように、日本語化する場合のワ
ード位置を■〜■に区分しておけば、翻訳された日本語
を表示する位置■〜■のそれぞれに対して、位置■に対
しては■の日本語を、位置@に対しては■の日本語およ
び数値のうちの数値を、位MOに対しては■の日本語お
よび数値を、位it[有]に対しては■の日本語および
数値のうちの数値を、位置■に対しては■の日本語およ
び数値のうちの日本語および数値を、位置■に対しては
■の日本語を、位置■に対しては■の日本語および数値
のうちの日本語を、それぞれ割り当てて表示することに
より、上記のとおりの日本語化表示を達成できる。As is clear from these figures, if the word positions for Japanese translation are divided into ■~■, then for each position ■~■ where translated Japanese is displayed, For the position @, use the Japanese word for ■ and a numerical value, for the position MO, use the Japanese word for ■ and a numerical value, and for the position it [existence], use ■. For position ■, Japanese for ■ and Japanese for numerical value, for position ■, Japanese for ■, and for position ■, Japanese for position ■. By allocating and displaying the Japanese characters in ■ and the Japanese characters in the numerical values, it is possible to achieve the Japanese display as described above.
〈実施例4〉
第6図はこの発明の自然言語化表示方法の他の実施例を
示すフローチャートであり、第3図の実施例と異なる点
は、ステップ■■■の処理ステップに代えて、ステップ
■において、サーチしたNC言語に対応付けられた日本
語をテーブル(4′)がら読み出し、ステップ@におい
て上記NC言語に対応付けられた日本語化表示フォーマ
ット・データをテーブル(4′)から読み出し、ステッ
プ■において、テーブル(4′)から読み出された日本
語を日本語化表示フォーマットの該当箇所に当てはめて
表示する処理ステップを採用した点のみである。<Embodiment 4> FIG. 6 is a flowchart showing another embodiment of the natural language display method of the present invention, and the difference from the embodiment of FIG. 3 is that in place of the processing step In step ■, the Japanese language associated with the searched NC language is read out from the table (4'), and in step @, the Japanese display format data associated with the above NC language is read out from the table (4'). The only difference is that in step (2), a processing step is adopted in which the Japanese language read from the table (4') is applied to the corresponding part of the Japanese display format and displayed.
したがって、この実施例の場合にも、予め定められた箇
所に該当する日本語が表示されるので、著しく見易い日
本語化表示を達成できる。Therefore, in the case of this embodiment as well, since the corresponding Japanese words are displayed at predetermined locations, it is possible to achieve an extremely easy-to-read Japanese display.
〈実施例5〉
第7図はこの発明の自然言語化表示方法のさらに他の実
施例を示すフローチャートである。<Embodiment 5> FIG. 7 is a flowchart showing still another embodiment of the natural language display method of the present invention.
同図(A)に示すように、ステップ■においてワードの
取り出しを行ない、ステップ■において、取り出したワ
ードの日本語への翻′訳を行ない、ステップ■において
1ワ一ド分の日本語の表示を行ない、ステップ■におい
て、次の処理を行なうためにバッファの内容を取り出し
、ステップ■においてEOFか否かを判別し、EOFで
なければ再びステップ■の処理を行なうが、EOFであ
れば、そのまま一連の処理を終了する。As shown in the same figure (A), a word is extracted in step 2, the extracted word is translated into Japanese in step 2, and 1 word of Japanese is displayed in step 2. In step ■, the contents of the buffer are extracted for the next processing, and in step ■, it is determined whether or not it is EOF. If it is not EOF, the process in step ■ is performed again, but if it is EOF, it is Finish the series of processing.
同図(B)はステップ■の処理を詳細に説明するフロー
チャートであり、ステップ■においてプログラムを1文
字分読み出し、ステップ■においてバッファに格納し、
ステップ■■においてそれぞれEOFであるか、改行コ
ードであるかを判別し、何れでもないと判別された場合
には、ステップ[相]においてプログラムを1文字分読
み出し、ステップ■@■においてそれぞれEOFである
が、改行コードであるか、英文字であるかを判別し、何
れでもないと判別された場合には、ステップ■において
バッファに格納し、再びステップ[相]の処理を行なう
。逆に、ステップ■@■においてEOF1改行コード、
または英文字の何れかであると判別された場合には、ス
テップ■において、最新に読み出した1文字分をプログ
ラム・メモリに戻し、一連の処理を終了する。また、ス
テップ■■においてEOF、または改行コードであると
判別された場合にも、そのまま一連の処理を終了する。(B) of the same figure is a flowchart explaining in detail the process of step (■), in which one character of the program is read out, and in step (■) it is stored in a buffer,
In step ■■, it is determined whether it is EOF or a line feed code, and if it is determined that it is neither, the program is read for one character in step [phase], and in step ■@■, it is determined whether it is EOF or a line feed code. However, it is determined whether it is a line feed code or an English character, and if it is determined that it is neither, it is stored in a buffer in step (3) and the processing in step [phase] is performed again. Conversely, in step ■@■, EOF1 line feed code,
If it is determined that it is either an English character or an English character, in step (2), the most recently read character is returned to the program memory, and the series of processing is completed. Further, even if it is determined in step (■■) that the code is EOF or a line feed code, the series of processing is immediately terminated.
同図(C)はステップ■の処理を詳細に説明するフロー
チャートであり、ステップ[有]においてバッファの内
容を取り出し、ステップ■■においてそれぞれEOFで
あるか、改行コードであるかを判別し、何れでもないと
セ1別された場合には、ステップ■においてバッファか
ら取り出した内容とテーブル(4)の内容と比較し、一
致した場合には、ステップ[相]においてバッファの内
容をテーブルの該当する日本語と入れ代え、そのまま一
連の処理を終了する。また、ステップ■■においてEO
F。(C) of the same figure is a flowchart explaining in detail the processing of step ■.In step [Yes], the contents of the buffer are extracted, and in step ■■, it is determined whether it is an EOF or a line feed code, and which If not, the content retrieved from the buffer is compared with the content of table (4) in step ■, and if they match, the content of the buffer is transferred to the corresponding table in step [phase]. Replace it with Japanese and complete the series of processing. Also, in step ■■, EO
F.
または改行コードであると判別された場合、またはステ
ップ■において一致しなかった場合にも、そのまま一連
の処理を終了する。Alternatively, if it is determined that it is a line feed code, or if there is no match in step (2), the series of processing is directly terminated.
同図(D)はステップ■の処理を詳細に説明するフロー
チャートであり、ステップ■においてバッファの内容を
取り出し、ステップ@■においてそれぞれEOFか、改
行コードかを判別する。そして、何れでもないと判別さ
れた場合には、ステップ[相]においてバッファの内容
に基づく表示を行なって一連の処理を終了する。また、
改行コードであると判別された場合には、ステップ■に
おいて表示を次の行に移して一連の処理を終了する。FIG. 5(D) is a flowchart illustrating the process of step (2) in detail. In step (2), the contents of the buffer are taken out, and in step @ (2), it is determined whether it is an EOF or a line feed code. If it is determined that neither is the case, a display based on the contents of the buffer is performed in step [phase], and the series of processing ends. Also,
If it is determined that it is a line feed code, the display is moved to the next line in step (3), and the series of processing ends.
さらに、EOFであると判別された場合には、そのまま
一連の処理を終了する。Furthermore, if it is determined that it is EOF, the series of processing is immediately terminated.
したがって、この実施例の場合には、英文字、改行コー
ドまたはEOFを基準としてプログラムを1ワードずつ
取り出し、1ワードずつ日本語に翻訳して表示するので
あるから、必要回数(EOFが検出されるまで)だけ一
連の処理を反復することにより、NC言語で作成された
プログラムを日本語化して表示することができる。Therefore, in the case of this embodiment, the program is extracted word by word based on English characters, line feed codes, or EOF, translated into Japanese word by word, and displayed. By repeating the series of processes up to ), a program created in the NC language can be translated into Japanese and displayed.
尚、この発明は上記の実施例に限定されるものではなく
、例えば、日本語化表示する代わりに英語、フランス語
、スペイン語等任意の自然言語に翻訳して表示すること
が可能であるほか、第5図と異なる任意のフォーマット
で自然言語を表示することが可能であり、その他、この
発明の要旨を変更しない範囲内において種々の設計変更
を施すことが可能である。Note that the present invention is not limited to the above-mentioned embodiments; for example, instead of displaying in Japanese, it is possible to translate and display in any natural language such as English, French, Spanish, etc. Natural language can be displayed in any format different from that shown in FIG. 5, and various other design changes can be made without changing the gist of the invention.
〈発明の効果〉
以上のように第1の発明は、NC言語で作成されたプロ
グラムを1ワードずつに区分し、各ワードを自然言語に
翻訳して表示するのであるから、NC言語を理解できな
いオペレータであってもプログラムの内容を正確に理解
でき、しかも、メーカ、機械等によりNC言語が異なっ
ていても、テーブルまたはテーブルの内容を変更するだ
けで簡単に対処できるという特有の効果を奏する。<Effects of the Invention> As described above, the first invention divides a program created in the NC language into one word and displays each word by translating it into natural language, which makes it impossible to understand the NC language. Even an operator can accurately understand the contents of a program, and even if the NC language differs depending on the manufacturer, machine, etc., it has the unique effect that it can be easily handled by simply changing the table or the contents of the table.
第2の発明は、テーブルから読み出した自然言語を予め
定められた所定箇所に表示するのであるから、プログラ
ムの区分の順番に自然言語で表示する場合と比較して著
しく見易い自然官話化表示を達成できるという特有の効
果を奏する。Since the second invention displays the natural language read from the table in a predetermined location, the natural language display is much easier to read than when the natural language is displayed in the order of program divisions. It has the unique effect of being achievable.
第3の発明は、NC言語で作成されたプログラムを1ワ
ードずつに区分し、各ワードを自然言語に翻訳して表示
するのであるから、NC言語を理解できないオペレータ
であってもプログラムの内容を正確に理解でき、しかも
、メーカ、機械等によりNC言語が異なっていても、テ
ーブルまたはテーブルの内容を変更するだけで簡単に対
処できるという特有の効果を奏する。The third invention divides the program created in the NC language into one word and each word is translated into natural language and displayed, so even an operator who cannot understand the NC language can understand the contents of the program. It has the unique effect of being able to be understood accurately, and even if the NC language differs depending on the manufacturer, machine, etc., it can be easily handled by simply changing the table or the contents of the table.
第4の発明は、テーブルから読み出した自然言語を予め
定められた所定箇所に表示するのであるから、プログラ
ムの区分の順番に自然言語で表示する場合と比較して著
【7く見易い自然言語化表示を達成できるという特有の
効果を奏する。The fourth invention is that the natural language read from the table is displayed at a predetermined location, so it is easier to read the natural language than when the natural language is displayed in the order of program divisions. It has the unique effect of being able to achieve display.
第1図はこの発明の自然言語化表示装置の一実施例を示
すブロック図、
第2図はテーブルの内容を概略的に示す図、第3図はこ
の発明の自然言語化表示方法の一実施例を示すフローチ
ャート、
第4図はこの発明の自然言語化表示装置の他の実施例を
示すブロック図、
第5図(A)はプログラムのNC言語順の日本語化を概
略的に説明する図、
第5図(B)はプログラムのワードを翻訳して得られた
日本語を表示すべく割り当てられた位置を示す図、
第6図はこの発明の自然言語化表示方法の他の実施例を
示すフローチャート、
第7図はこの発明の自然言語化表示方法のさらに他の実
施例を示すフローチャート、
第8図はNC装置のフロント・パネルの一例を示す概略
図。FIG. 1 is a block diagram showing an embodiment of the natural language display device of the present invention, FIG. 2 is a diagram schematically showing the contents of a table, and FIG. 3 is an implementation of the natural language display method of the present invention. Flowchart showing an example; FIG. 4 is a block diagram showing another embodiment of the natural language display device of the present invention; FIG. , FIG. 5(B) is a diagram showing the position allocated to display the Japanese language obtained by translating the words of the program, and FIG. 6 shows another embodiment of the natural language display method of the present invention. FIG. 7 is a flowchart showing still another embodiment of the natural language display method of the present invention, and FIG. 8 is a schematic diagram showing an example of the front panel of the NC device.
Claims (1)
(4′)を予め作成しておき、NC言語で作成されたプ
ログラムを1文字ずつ取り込み、英文字で始まり、次の
英文字または改行マークの前までを1ワードとして複数
のワードに区分し、各区分毎にテーブルのNC言語と比
較し、一致したNC言語に対応する自然言語をテーブル
(4)(4′)から読み出して表示することを特徴とす
るNC言語で作成されたプログラムの自然言語化表示方
法。 2、テーブル(4′)から読み出した自然言語を予め定
められた所定箇所に表示する上記特許請求の範囲第1項
記載のNC言語で作成されたプログラムの自然言語化表
示方法。 3、NC言語と自然言語とを予め対応付けて格納してお
くテーブル(4)(4′)と、NC言語で作成されたプ
ログラムを1文字ずつ取り込む取り込み手段(5)と、
取り込んだ文字が英文字または改行マークか否かを判別
する文字判別手段(6)と、英文字で始まり、次の英文
字または改行マークの前までを1ワードとして複数のワ
ードに区分する区分手段(7)と、各区分毎にテーブル
のNC言語と比較し、一致したNC言語に対応する自然
言語をテーブルから読み出す翻訳手段(8)と、テーブ
ルから読み出した自然言語を受け取って表示する表示手
段(1)(9)(9′)とを含むことを特徴とするNC
言語で作成されたプログラムの自然言語化表示装置。 4、テーブル(4′)が、NC言語と表示フォーマット
をも予め対応付けて格納しておくものであり、区分され
たNC言語に基づいて表示フォーマットを読み出す読み
出し手段(12)をさらに含み、表示手段(9′)が、
テーブル(4′)から読み出された自然言語を、読み出
された表示フォーマットの該当箇所に表示するものであ
る上記特許請求の範囲第3項記載のNC言語で作成され
たプログラムの自然言語化表示装置。[Claims] 1. Table (4) showing correspondence between NC language and natural language
(4') is created in advance, and the program written in the NC language is imported character by character, and the words starting with an English character and ending before the next English character or line feed mark are divided into multiple words, The natural language of a program created in the NC language is characterized in that each category is compared with the NC language of the table, and the natural language corresponding to the matched NC language is read out from the table (4) (4') and displayed. display method. 2. A natural language display method for a program written in an NC language as set forth in claim 1, wherein the natural language read from the table (4') is displayed at a predetermined location. 3. Tables (4) (4') in which NC language and natural language are stored in association with each other in advance, and an importing means (5) for importing a program created in NC language one character at a time;
A character discrimination means (6) for determining whether the imported character is an English character or a line break mark; and a classification means for dividing into a plurality of words, with a word starting with an English letter and ending before the next English character or line break mark. (7), a translation means (8) that compares each category with the NC language in the table and reads out from the table a natural language corresponding to the matched NC language, and a display means that receives and displays the natural language read out from the table. (1) (9) (9')
A natural language display device for programs written in languages. 4. The table (4') stores NC languages and display formats in association with each other in advance, and further includes reading means (12) for reading display formats based on the classified NC languages. The means (9') is
Natural language conversion of a program created in the NC language according to claim 3 above, which displays the natural language read from the table (4') at a corresponding location in the read display format. Display device.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2150891A JP2643540B2 (en) | 1990-06-08 | 1990-06-08 | Natural language display method and apparatus for programs created in NC language |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2150891A JP2643540B2 (en) | 1990-06-08 | 1990-06-08 | Natural language display method and apparatus for programs created in NC language |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPH0443406A true JPH0443406A (en) | 1992-02-13 |
| JP2643540B2 JP2643540B2 (en) | 1997-08-20 |
Family
ID=15506641
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2150891A Expired - Lifetime JP2643540B2 (en) | 1990-06-08 | 1990-06-08 | Natural language display method and apparatus for programs created in NC language |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP2643540B2 (en) |
Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPS62183208U (en) * | 1986-05-12 | 1987-11-20 | ||
| JPS6312005A (en) * | 1986-07-02 | 1988-01-19 | Brother Ind Ltd | Automatic programming device |
| JPH0176607U (en) * | 1987-11-05 | 1989-05-24 | ||
| JPH01296308A (en) * | 1988-05-24 | 1989-11-29 | Sony Magnescale Inc | Nc device |
| JPH01178607U (en) * | 1988-06-02 | 1989-12-21 |
-
1990
- 1990-06-08 JP JP2150891A patent/JP2643540B2/en not_active Expired - Lifetime
Patent Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPS62183208U (en) * | 1986-05-12 | 1987-11-20 | ||
| JPS6312005A (en) * | 1986-07-02 | 1988-01-19 | Brother Ind Ltd | Automatic programming device |
| JPH0176607U (en) * | 1987-11-05 | 1989-05-24 | ||
| JPH01296308A (en) * | 1988-05-24 | 1989-11-29 | Sony Magnescale Inc | Nc device |
| JPH01178607U (en) * | 1988-06-02 | 1989-12-21 |
Also Published As
| Publication number | Publication date |
|---|---|
| JP2643540B2 (en) | 1997-08-20 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JPH08179817A (en) | Display operation device for machine tools | |
| US11372393B2 (en) | Numerical control device | |
| JPH0443406A (en) | Method and device for displaying natural language for program generated by nc language | |
| EP0148948A1 (en) | Method of setting date in numerical control apparatus | |
| JPH0117185B2 (en) | ||
| JPH04131912A (en) | Numerical controller | |
| JPH052207U (en) | Numerical control device | |
| JPH0371209A (en) | Abnormality detection device for numerical control programs | |
| JPH04148370A (en) | document processing device | |
| JPH0115906B2 (en) | ||
| JPS5814249A (en) | Display control system for ruled line | |
| JPH077839U (en) | Numerical control device | |
| JPS59229613A (en) | Numerical control device | |
| JP2024131903A (en) | Machining program editing support system | |
| JPH0317740A (en) | Program editing support method | |
| JPH08272416A (en) | NC program search method | |
| JPH05282114A (en) | Display control device | |
| JPH0362170A (en) | Comment input method in cad system | |
| JPH0314069A (en) | document processing device | |
| JP2757367B2 (en) | Character processor | |
| JP2001109508A (en) | Comment display device | |
| JPS62256069A (en) | Document processor | |
| JPH10133726A (en) | Numerical controller having working program editing function | |
| JPH04296910A (en) | Numerical controller | |
| JPH02158818A (en) | Automatic inputting spot guiding system |