JP2011123667A - Command display device of numerical control program, and command display program - Google Patents
Command display device of numerical control program, and command display program Download PDFInfo
- Publication number
- JP2011123667A JP2011123667A JP2009280815A JP2009280815A JP2011123667A JP 2011123667 A JP2011123667 A JP 2011123667A JP 2009280815 A JP2009280815 A JP 2009280815A JP 2009280815 A JP2009280815 A JP 2009280815A JP 2011123667 A JP2011123667 A JP 2011123667A
- Authority
- JP
- Japan
- Prior art keywords
- command
- pair
- commands
- program
- numerical control
- 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
Images
Landscapes
- Numerical Control (AREA)
Abstract
Description
本発明は、工作機械のための数値制御プログラムのコマンド表示装置及びコマンド表示プログラムに関する。 The present invention relates to a command display device and a command display program for a numerical control program for a machine tool.
上記工作機械として、内部記憶装置に記憶されているNC(Numerical Control;数値制御)プログラムを実行してワークを加工するNC旋盤(数値制御旋盤)が知られている。特許文献1には、複数チャンネルのNCプログラムを同時に実行するNC旋盤のためのNCプログラム入力装置が記載されている。このNCプログラム入力装置は、チャンネル毎にプログラムコードの内の設定されたプログラムコードを抽出し、該抽出したプログラムコードを各チャンネルに対応させてコード化リスト表示部としている。ここで、チャンネル間での待ち合わせ機能を持つプログラムコードは、コード化リスト表示部で同一行に表示される。従って、特許文献1のNCプログラム入力装置は、異なるチャンネルのNCプログラム同士の関係を確認し易くする装置とされている。
As the machine tool, there is known an NC lathe (numerical control lathe) for machining a workpiece by executing an NC (Numerical Control) program stored in an internal storage device.
NCプログラムを記述するための複数のコマンドには、対で使用されるペアコマンドが含まれている。例えば、エアのブローオンを指令するブロー開始コマンド、及び、このエアのブロー停止を指令するブロー終了コマンドは、対で使用されるペアコマンドとなる。上述したNCプログラム入力装置は、ペアコマンドの表示が考慮されていないため、同一チャンネルのNCプログラムで指令されているペアコマンドの相対関係を確認するのが容易ではない。 The plurality of commands for describing the NC program includes a pair command used in pairs. For example, a blow start command for commanding air blow-on and a blow end command for commanding air blow stop are pair commands used in pairs. Since the NC program input device described above does not consider the display of the pair command, it is not easy to confirm the relative relationship between the pair commands commanded by the NC program of the same channel.
以上を鑑み、本発明は、工作機械のための数値制御プログラムに記述されたペアコマンドの相対関係を容易に確認することを目的としている。 In view of the above, an object of the present invention is to easily confirm the relative relationship of pair commands described in a numerical control program for a machine tool.
上記目的を達成するため、本発明の数値制御プログラムのコマンド表示装置は、対で使用されるペアコマンドを一組以上含む複数のコマンドの中から選ばれるコマンドで記述された数値制御プログラムを記憶した記憶部と、該記憶されている数値制御プログラムに記述された前記ペアコマンドを抽出するペアコマンド抽出手段と、前記ペアコマンドの組毎に前記抽出されたペアコマンドを分けて前記数値制御プログラムに記述された順に並べて表示するペアコマンド表示手段とを備えることを特徴とする。
また、本発明の数値制御プログラムのコマンド表示プログラムは、対で使用されるペアコマンドを一組以上含む複数のコマンドの中から選ばれるコマンドで記述され記憶部に記憶されている数値制御プログラムに記述された前記ペアコマンドを抽出するペアコマンド抽出機能と、前記ペアコマンドの組毎に前記抽出されたペアコマンドを分けて前記数値制御プログラムに記述された順に並べて表示するペアコマンド表示機能とをコンピュータに実現させることを特徴とする。
To achieve the above object, a numerical control program command display device according to the present invention stores a numerical control program described by a command selected from a plurality of commands including one or more pair commands used in pairs. A storage unit, pair command extraction means for extracting the pair command described in the stored numerical control program, and the extracted pair command for each pair of the pair commands are described in the numerical control program. And a pair command display means for arranging and displaying in order.
The command display program of the numerical control program of the present invention is described in a numerical control program described by a command selected from a plurality of commands including one or more pair commands used in pairs and stored in a storage unit. A pair command extraction function for extracting the pair command, and a pair command display function for dividing the extracted pair command for each pair of the pair commands and displaying them in the order described in the numerical control program. It is characterized by realizing.
すなわち、記憶部に記憶されている数値制御プログラムに記述されたペアコマンドが抽出され、ペアコマンドの組毎に前記抽出されたペアコマンドが分けられて数値制御プログラムに記述された順に並べられて表示される。従って、数値制御プログラムに記述されたペアコマンドの相対関係の確認が容易である。 That is, the pair commands described in the numerical control program stored in the storage unit are extracted, and the extracted pair commands are divided for each pair of pair commands and displayed in the order described in the numerical control program. Is done. Therefore, it is easy to confirm the relative relationship between the pair commands described in the numerical control program.
ここで、ペアコマンドは、コマンドの一種であり、先に記述される開始コマンド、及び、該開始コマンドの後に記述される終了コマンドが含まれる。ペアコマンドの組は、対応する開始コマンド及び終了コマンドを総括した概念とする。
組毎にペアコマンドを分けてプログラム順に並べて表示することには、抽出されたペアコマンドを所定方向へ数値制御プログラムに記述された順とし、かつ、前記所定方向とは異なる方向へペアコマンドの組に応じた位置として並べて表示することが含まれる。
Here, the pair command is a kind of command, and includes a start command described earlier and an end command described after the start command. The pair command pair is a concept that summarizes the corresponding start command and end command.
In order to divide the pair commands for each group and display them in the order of the programs, the pair commands extracted are set in the order described in the numerical control program in a predetermined direction and in a direction different from the predetermined direction. It is included that they are displayed side by side as positions according to the above.
請求項1、請求項5に係る発明によれば、工作機械のための数値制御プログラムに記述されたペアコマンドの相対関係を容易に確認することができる。
請求項2に係る発明では、ペアコマンドの組同士の相対関係を容易に確認することができる。
請求項3に係る発明では、ペアコマンドの相対関係をさらに容易に確認することができる。
請求項4に係る発明では、数値制御プログラムに含まれる正しい位置でないペアコマンドを容易に把握することができる。
According to the first and fifth aspects of the invention, it is possible to easily confirm the relative relationship of the pair commands described in the numerical control program for the machine tool.
In the invention according to
In the invention according to
In the invention which concerns on
(1)数値制御プログラム入力システムの構成:
図1に示すように、本実施形態のNC(数値制御)プログラムP1は、コンピュータ(コマンド表示装置)PC1で作成され、NC旋盤(工作機械)2に読み込まれて実行される。NCプログラムP1は、図5(b)に例示するように複数の所定のコマンドA1の中から選ばれるコマンドA1で記述され、NC旋盤2にワークW1を加工させる機能を実現させる。NCプログラムP1に記述可能な複数のコマンドA1には、対で使用されるペアコマンドA2が一組以上含まれる。このようなNCプログラムP1を実行するNC旋盤2と、NCプログラムP1を入力可能なコンピュータPC1とは、NCプログラム入力システムを構成する。
NC旋盤2は、NC装置50、操作パネル60、機械機構部70、を備えている。
(1) Configuration of numerical control program input system:
As shown in FIG. 1, an NC (numerical control) program P1 of the present embodiment is created by a computer (command display device) PC1 and is read and executed by an NC lathe (machine tool) 2. The NC program P1 is described by a command A1 selected from a plurality of predetermined commands A1 as illustrated in FIG. 5B, and realizes the function of causing the
The
NC装置50は、CPU(Central Processing Unit)51、ROM(Read Only Memory)52、RAM(Random Access Memory)53、操作パネル用のインターフェイス(I/F)54、機械機構部用のI/F55,56、通信I/F57、メモリカードスロット58、等が互いに接続されたコンピュータとされている。NCプログラムP1は、RAM53に記憶される。ROM52には、図示しない解釈実行プログラムが書き込まれている。CPU51は、この解釈実行プログラム及びNCプログラムP1に従って機械機構部70を数値制御する。
通信I/F57は、RS−232C(Recommended Standard 232 version C)やUSB(Universal Serial Bus)といったシリアル通信I/F等とされ、コンピュータPC1に接続される。USBI/Fの場合、書き換え可能な不揮発性半導体メモリを有するUSBメモリをUSBI/Fに装着可能である。メモリカードスロット58は、書き換え可能な不揮発性半導体メモリを有する規格化されたメモリカードM1を装着可能である。
The NC device 50 includes a CPU (Central Processing Unit) 51, a ROM (Read Only Memory) 52, a RAM (Random Access Memory) 53, an interface (I / F) 54 for an operation panel, an I /
The communication I / F 57 is a serial communication I / F such as RS-232C (Recommended Standard 232 version C) or USB (Universal Serial Bus), and is connected to the computer PC1. In the case of the USB I / F, a USB memory having a rewritable nonvolatile semiconductor memory can be attached to the USB I / F. The memory card slot 58 can be loaded with a standardized memory card M1 having a rewritable nonvolatile semiconductor memory.
操作パネル60には、例えば、オペレータから操作入力を受け付けるためのボタンやタッチパネルを有する操作部と、操作入力を受け付けた各種設定の内容やNC旋盤2に関する各種情報の表示部とが設けられる。
機械機構部70には、例えば、ワークW1を解放可能に把持する主軸、この主軸を回転させる主軸モータ、この主軸回転モータを駆動させる主軸アンプ、工具T1を保持する刃物台、この刃物台を移動させるサーボモータ、このサーボモータを駆動させるサーボアンプ、等が設けられる。機械機構部70は、NCプログラムP1のコマンドに従って工具T1によりワークW1を加工する。
The
The mechanical mechanism unit 70 includes, for example, a main shaft that releasably holds the workpiece W1, a main shaft motor that rotates the main shaft, a main shaft amplifier that drives the main shaft rotation motor, a tool post that holds the tool T1, and the tool post that moves. And a servo amplifier for driving the servo motor. The mechanical mechanism unit 70 processes the workpiece W1 with the tool T1 according to the command of the NC program P1.
コンピュータPC1は、CPU10、不揮発性メモリ20、RAM30、通信I/F45、メモリカードスロット48、等が互いに接続されている。コンピュータPC1には、パーソナルコンピュータ等が用いられる。NCプログラムP1は、RAM30、不揮発性メモリ20、等に記憶される。通信I/F45は、図2に示すRS−232CI/F46やUSBI/F47等とされ、規格化された信号ケーブルを介してNC装置50の通信I/F57に接続される。USBI/Fの場合、USBメモリをUSBI/Fに装着可能である。メモリカードスロット48は、NC装置50のメモリカードスロット58に装着可能なメモリカードM1を装着可能である。
In the computer PC1, a
以上より、コンピュータPC1に記憶されているNCプログラムP1は、例えば、通信I/F45から通信I/F57へ送信されてNC装置50に読み込まれる。むろん、コンピュータPC1に記憶されているNCプログラムP1は、コンピュータPC1のUSBI/FからUSBメモリに書き込まれた後、NC装置50のUSBI/FにUSBメモリが装着されてUSBメモリからNC装置50に読み込まれてもよい。また、NCプログラムP1は、メモリカードスロット48からメモリカードM1に書き込まれた後、メモリカードスロット58にメモリカードM1が装着されてメモリカードM1からNC装置50に読み込まれてもよい。
From the above, the NC program P1 stored in the computer PC1 is transmitted from the communication I /
(2)数値制御プログラムのコマンド表示装置の構成:
NCプログラムP1は、図5(b)に例示するように、多数のコマンドA1が記述された長大なものになることが多い。一方、NCプログラムP1に記述されるコマンドA1の中には、対で使用されるペアコマンドA2が含まれる。ペアコマンドA2には、図5(a)に例示されるように、先に記述される開始コマンドA3、及び、開始コマンドA3の後に記述される終了コマンドA4が含まれる。NCプログラムP1において開始コマンドA3を記述した後に終了コマンドA4を記述し忘れていないか、ペアコマンドA2が正しい場所に記述されているか、等の確認は、重要である。コンピュータPC1に実現される本実施形態のコマンド表示装置は、NCプログラムP1に記述されたペアコマンドA2の相対関係の確認を容易にするため、図2に示す構成を有し、図4に示すペアコマンドチェック処理を行う。
(2) Configuration of command display device for numerical control program:
As illustrated in FIG. 5B, the NC program P1 is often a long program in which a large number of commands A1 are described. On the other hand, the command A1 described in the NC program P1 includes a pair command A2 used in pairs. As illustrated in FIG. 5A, the pair command A2 includes a start command A3 described earlier and an end command A4 described after the start command A3. It is important to confirm whether the end command A4 is not forgotten after the start command A3 is described in the NC program P1, or whether the pair command A2 is described in the correct place. The command display device of the present embodiment realized in the computer PC1 has the configuration shown in FIG. 2 to facilitate confirmation of the relative relationship of the pair command A2 described in the NC program P1, and the pair shown in FIG. Perform command check processing.
図2に示すように、コンピュータPC1のCPU10は、不揮発性メモリ20、RAM30、入力装置用のI/F41、表示装置用のI/F43、RS232CI/F46、USBI/F47、メモリカードスロット48、等に対してデータを入出力可能とされている。CPU10は、不揮発性メモリ20に格納されているプログラムに従ってコンピュータPC1全体を制御する。
As shown in FIG. 2, the
不揮発性メモリ20は、ROMやハードディスク等とされ、NCプログラムのコマンド表示プログラムP2等を記憶している。本実施形態のコマンド表示プログラムP2は、コマンド検索モジュール21、コマンドリスト構築モジュール22、コマンドエラー解析モジュール23、を備え、RAM30に読み出されて実行される。コマンド検索モジュール21は、ペアコマンド抽出手段U1に対応したペアコマンド抽出機能をコンピュータPC1に実現させる。コマンドリスト構築モジュール22及びコマンドエラー解析モジュール23は、ペアコマンド表示手段U2に対応したペアコマンド表示機能をコンピュータPC1に実現させる。
The
RAM30には、NCプログラム保存領域(記憶部)31、ペアコマンド設定保存領域32、コマンド検索用の一時バッファ領域33、コマンド検索用パラメータ34、コマンドリスト構築用パラメータ35、コマンドエラー解析用パラメータ36、ペアコマンドリスト格納領域37、等が設けられている。NCプログラム保存領域31には、図5(b)に例示するNCプログラムP1が格納される。ペアコマンド設定保存領域32には、図5(a)に例示されるペアコマンド設定リストL1が格納される。一時バッファ領域33には、図5(c)に例示されるように、NCプログラムP1から抽出されたペアコマンドA2が格納される。ペアコマンドリスト格納領域37には、図6に例示されるペアコマンドリストL2が格納される。
The
入力装置42は、キーボードやマウス(ポインティングデバイス)等の操作入力デバイスとされ、I/F41に接続されている。表示装置44は、ディスプレイ等の出力デバイスとされ、I/F43に接続されている。
The
コンピュータPC1は、NCプログラムのコマンド表示プログラムP2を起動させる所定の操作入力を入力装置42から受け付けると、図3に例示するペアコマンドチェック画面90を表示装置44に表示する。このペアコマンドチェック画面90は、NCプログラム編集用のエディタとは異なるダイアログであり、この意味でNCプログラム編集用のエディタと一緒に表示装置44に表示可能である。ペアコマンドチェック画面90は、上段にペアコマンドA2の設定領域91が設けられ、下段にチェック結果表示領域94が設けられている。コンピュータPC1は、図5(a)に示すペアコマンド設定リストL1をペアコマンド設定保存領域32から参照し、このペアコマンド設定リストL1に対応したペアコマンド表示領域93を有する設定領域91を表示する。初期段階では、チェック結果表示領域94のペアコマンドリスト表示領域96が例えば空白(背景色)とされる。
When the computer PC1 receives a predetermined operation input for starting the command display program P2 of the NC program from the
設定領域91には、複数の操作ボタン92、ペアコマンド表示領域93、設定名称入力領域97等が設けられている。リスト追加ボタンは、新しい設定リストを追加するための操作ボタンである。リスト削除ボタンは、表示されている設定リストを削除するためのボタンである。追加ボタンは、新しいペアコマンドA2を追加するための操作ボタンである。上位コマンドボタンは、上位コマンドNo.(上位コマンド番号)を設定するための操作ボタンである。この上位コマンドNo.が設定された場合、上位コマンドNo.を設定した開始コマンド及び終了コマンドの組合せが上位コマンドNo.の開始コマンドと終了コマンドとの間に指令されていないときにエラーとなる。削除ボタンは、選択されたペアコマンドA2を削除するための操作ボタンである。設定名称入力領域97は、任意の文字列を入力することが可能である。設定リストの組み合わせは入力された名称毎に不揮発性メモリ20に保存される。
ペアコマンド表示領域93では、開始コマンドA3がONコマンド、終了コマンドA4がOFFコマンドと表示され、M6,M10,M14,M66,M68がONコマンド、M7,M11,M15,M67,M69がOFFコマンドとして設定されていることが示されている。ここで、ペアコマンドA2の組PA1は、開始コマンドA3及び終了コマンドA4を含む概念とする。また、ペアコマンドM68,M69には、上位のペアコマンドとして番号3のペアコマンドM14,M15が設定されていることが示されている。
In the
In the pair
ペアコマンドA2は、対で使用されることが前提とされたコマンドであり、NC旋盤の種類に応じて設けられる。以下に例示する組のコマンドは、ペアコマンドA2となる。
(例1)エアのブローオンを指令するブロー開始コマンドと、このエアのブロー停止を指令するブロー終了コマンド。
(例2)クーラント液の吐出オンを指令するクーラント液開始コマンドと、このクーラント液の吐出停止を指令するクーラント液終了コマンド。
(例3)正面主軸のZ軸方向への移動と背面主軸(対向主軸)のZB軸方向(Z方向と同じ方向)への移動とを同期させるZ−ZB軸同期開始コマンドと、該同期を解除させるZ−ZB軸同期終了コマンド。
(例4)正面主軸のC1方向への回転と背面主軸のC2方向への回転とを同期させるC1−C2同期開始コマンドと、該同期を解除させるC1−C2同期終了コマンド。
ペアコマンドA2の性格上、開始コマンド及び終了コマンドがペアコマンドA2となることが多い。むろん、チェックするペアコマンドA2は、対となるコマンドであればどのような種類のコマンドでもよい。
The pair command A2 is a command that is assumed to be used in pairs, and is provided according to the type of the NC lathe. A set of commands exemplified below is a pair command A2.
(Example 1) A blow start command for instructing air blow-on and a blow end command for instructing air blow stop.
(Example 2) A coolant start command for instructing discharge on of the coolant, and a coolant end command for instructing stop of discharge of the coolant.
(Example 3) A Z-ZB axis synchronization start command for synchronizing the movement of the front spindle in the Z-axis direction and the movement of the back spindle (opposite spindle) in the ZB-axis direction (the same direction as the Z direction) and the synchronization Z-ZB axis synchronization end command to be released.
(Example 4) A C1-C2 synchronization start command for synchronizing the rotation of the front spindle in the C1 direction and the rotation of the back spindle in the C2 direction, and a C1-C2 synchronization end command for releasing the synchronization.
Due to the nature of the pair command A2, the start command and the end command are often the pair command A2. Of course, the pair command A2 to be checked may be any type of command as long as it is a pair of commands.
ここで、各主軸のZ,ZB軸方向への移動を同期させるために各主軸のC1,C2方向への回転を同期させておく必要があるものとし、両主軸の回転の同期を解除させるために両主軸の軸方向への移動同期を解除させる必要があるものとする。この場合、NCプログラムP1には、「C1−C2同期開始コマンド」、「Z−ZB軸同期開始コマンド」、「Z−ZB軸同期終了コマンド」、「C1−C2同期終了コマンド」の順に記述される必要がある。すなわち、C1−C2同期開始/終了コマンドは、Z−ZB軸同期開始/終了コマンドよりも上位のペアコマンドとなっている。図3の例では、Z−ZB軸同期開始/終了コマンドのような下位のペアコマンドが「M68,M69」と設定され、C1−C2同期開始/終了コマンドのような上位のペアコマンドが「M14,M15」と設定されている。 Here, in order to synchronize the movement of each spindle in the Z and ZB axis directions, it is necessary to synchronize the rotation of each spindle in the C1 and C2 directions, and to cancel the synchronization of the rotation of both spindles. It is necessary to cancel the movement synchronization in the axial direction of both spindles. In this case, the NC program P1 is described in the order of “C1-C2 synchronization start command”, “Z-ZB axis synchronization start command”, “Z-ZB axis synchronization end command”, “C1-C2 synchronization end command”. It is necessary to That is, the C1-C2 synchronization start / end command is a pair command higher than the Z-ZB axis synchronization start / end command. In the example of FIG. 3, the lower pair command such as the Z-ZB axis synchronization start / end command is set to “M68, M69”, and the upper pair command such as the C1-C2 synchronization start / end command is “M14”. , M15 ".
チェック結果表示領域94には、チェック開始ボタン95等の複数の操作ボタン、ペアコマンドリスト表示領域96、等が設けられている。チェック開始ボタン95は、現在NCプログラムP1の編集を行っている系統のエディタから指定されたペアコマンドA2を検索して当該検索結果をペアコマンドリスト表示領域96に表示させるための操作ボタンである。コンピュータPC1は、ペアコマンドチェック画面90を表示しているとき、入力装置42からチェック開始ボタン95の操作を受け付けると、図4に例示するペアコマンドチェック処理を行い、ペアコマンドリスト表示領域96にペアコマンドA2を並べて表示する。ジャンプボタンは、ペアコマンドリスト表示領域96で選択されているコマンドのエディタの行へ移動するための操作ボタンである。
In the check
ペアコマンドリスト表示領域96には、NCプログラムP1に含まれるペアコマンドA2がペアコマンドの組PA1毎に分けられてNCプログラムP1に記述された順に並べられる。本実施形態のチェック結果表示領域94に表示されるペアコマンドA2は、縦方向(所定方向)D1へNCプログラムP1に記述された順とされ、かつ、縦方向D1とは異なる横方向D2へペアコマンドの組PA1に応じた位置として並べられている。図3の例では、NCプログラムP1の中で最初に現れたペアコマンドM14が1行目の「M14/M15」列に表示され、2番目に現れたペアコマンドM68が2行目の「M68/M69」列に表示されている。1行目における「M14/M15」列以外の列は空白とされ、2行目における「M68/M69」列以外の列は空白とされている。すなわち、横方向D2に対しては、NCプログラムP1中のペアコマンドA2が重ならないように配置される。一方、縦方向D1に対しては、同じ組PA1のペアコマンドA2が同じ列となり、異なる組PA1のペアコマンドA2が異なる列となるように配置される。
In the pair command
また、NCプログラムP1中で正しい順に記述されたペアコマンドA2の組PA1の表示箇所は、背景色(例えば白色)とは異なる同一のペアコマンドエリア色(例えば青色や黄色)とされる。一方、NCプログラムP1中で正しい位置でないペアコマンドA2の表示箇所は、前記背景色や前記ペアコマンドエリア色とは異なるエラー色(例えば赤色)とされ、他の箇所とは異なる態様の表示とされる。例えば、開始コマンドA3のみ抽出されたり、終了コマンドA4のみ抽出されたりすると、これらのペアコマンドA2がエラー色で表示される。NCプログラムP1中で終了コマンドA4の次に開始コマンドA3が指令されている場合等も、これらのペアコマンドA2がエラー色で表示されてもよい。
さらに、NCプログラムP1中で正しい位置でない下位のペアコマンドの組の表示箇所は、前記背景色や前記ペアコマンドエリア色とは異なるエラーコマンドエリア色(例えば赤紫色)とされ、他の箇所とは異なる態様の表示とされる。例えば、上位のペアコマンドの開始コマンドA3の後に下位のペアコマンドの開始コマンドA3が存在し、その後に上位のペアコマンドの終了コマンドA4が存在している場合、その下位のペアコマンドがエラーコマンドエリア色で表示される。上位のペアコマンドも、エラーコマンドエリア色で表示されてもよい。
The display location of the set PA1 of the pair command A2 described in the correct order in the NC program P1 is the same pair command area color (for example, blue or yellow) different from the background color (for example, white). On the other hand, the display location of the pair command A2 that is not in the correct position in the NC program P1 is an error color (for example, red) different from the background color or the pair command area color, and is displayed in a different manner from the other locations. The For example, when only the start command A3 is extracted or only the end command A4 is extracted, these pair commands A2 are displayed in an error color. The pair command A2 may be displayed in an error color even when the start command A3 is instructed next to the end command A4 in the NC program P1.
Further, the display position of the lower pair command pair that is not in the correct position in the NC program P1 is an error command area color (for example, magenta) different from the background color or the pair command area color. The display is different. For example, when the start command A3 of the lower pair command exists after the start command A3 of the upper pair command and the end command A4 of the upper pair command exists thereafter, the lower pair command is displayed in the error command area. Displayed in color. The upper pair command may also be displayed in the error command area color.
コンピュータPC1は、ペアコマンドチェック画面90を表示しているとき、NCプログラムP1から抽出するペアコマンドの組を設定する操作入力を入力装置42から受け付ける。コンピュータPC1は、ペアコマンド表示領域93の表示内容を受け付けた内容とし、図5(a)に例示するペアコマンド設定リストL1の内容を受け付けた内容とする。例えば、ペアコマンド表示領域93の上から5行目で開始コマンド「M68」、終了コマンド「M69」、上位コマンドNo.「3」が操作入力されると、コンピュータPC1は、ペアコマンド設定リストL1の設定No.5の箇所に開始コマンド「M68」、終了コマンド「M69」、上位コマンドNo.「3」を格納して、このペアコマンド設定リストL1をペアコマンド設定保存領域32に記憶する。
When the pair
(3)数値制御プログラムのコマンド表示装置の動作、作用、効果:
次に、本実施形態のコマンド表示装置の動作、作用、効果を説明する。
図4は、ペアコマンドチェック画面90上でチェック開始ボタン95が操作されたときに行われるペアコマンドチェック処理をフローチャートにより例示している。このペアコマンドチェック処理は、CPU10を中心としてコマンド表示プログラムP2に従って行われ、マルチタスクにより他の処理と並列して行われる。ここで、ステップS102〜S112(以下、「ステップ」の記載を省略)の処理がコマンド検索モジュール21により実行され、S114〜S120の処理がコマンドリスト構築モジュール22により実行され、S122〜S126の処理がコマンドエラー解析モジュール23により実行される。
(3) Operation, action and effect of command display device of numerical control program:
Next, the operation, action, and effect of the command display device of this embodiment will be described.
FIG. 4 illustrates a pair command check process performed when the
まず、コンピュータPC1は、NCプログラムP1中の解釈対象の行番号を表すパラメータprg_nに初期値1を代入し、一時バッファ領域33のペアコマンド格納位置を表すパラメータdata_iに初期値0を代入する、パラメータ初期化処理を行う(S102)。S104では、NCプログラム保存領域31からNCプログラムP1のprg_n行目を読み出し、prg_n行目にペアコマンドA2が含まれているか否かを解析する。該ペアコマンドA2は、図3で示した設定領域91に入力され、図5(a)で示したペアコマンド設定リストL1に格納された開始コマンドA3及び終了コマンドA4である。S106では、prg_n行目にペアコマンドA2が発見されたか否かに応じて処理を分岐する。ペアコマンドA2が発見されなかった場合、コンピュータPC1は、S110に進む。ペアコマンドA2が発見された場合、コンピュータPC1は、prg_n行目からペアコマンドA2を抽出し、抽出したペアコマンドA2を一時バッファ領域33のdata_i番目に格納し(S108)、S110に進む。
First, the computer PC1 substitutes an
S110では、NCプログラムP1の最終行まで解析を完了したか否かを判断する。NCプログラムP1に未解析の行が残っている場合、コンピュータPC1は、パラメータprg_nに1を加算し(S112)、S104に戻る。最終行まで解析が完了した場合、コンピュータPC1は、S114に進む。
以上の処理により、図5(b)で示したNCプログラムP1からペアコマンド設定リストL1にあるペアコマンドA2が順に抽出され、一時バッファ領域33に対してプログラム順に蓄積される。
In S110, it is determined whether or not the analysis is completed up to the last line of the NC program P1. If an unanalyzed line remains in the NC program P1, the computer PC1 adds 1 to the parameter prg_n (S112), and returns to S104. When the analysis is completed up to the last line, the computer PC1 proceeds to S114.
Through the above processing, the pair commands A2 in the pair command setting list L1 are sequentially extracted from the NC program P1 shown in FIG. 5B and stored in the
S114では、ペアコマンドリスト格納領域37のペアコマンドリストL2の全データを消去し、ペアコマンドリストL2を初期化する。S116では、一時バッファ領域33のdata_i番のペアコマンドA2をペアコマンドリストL2の最終行(data_i番)の該当する組PA1の列に格納する。図6の例では、一時バッファ領域33の0番のペアコマンドM14がペアコマンドリストL2の0行の「M14/M15」列に格納され、一時バッファ領域33の1番のペアコマンドM68がペアコマンドリストL2の1行の「M68/M69」列に格納されることが示されている。S118では、一時バッファ領域33のペアコマンドA2の最後までペアコマンドリストL2に登録したか否かを判断する。一時バッファ領域33に未登録のペアコマンドA2が残っている場合、コンピュータPC1は、パラメータdata_iに1を加算し(S120)、S116に戻る。最後まで登録した場合、コンピュータPC1は、S122に進む。
In S114, all data in the pair command list L2 in the pair command
一時バッファ領域33に格納されるペアコマンドをCj(i)とする。ここで、iは一時バッファ領域33に格納されている何番(data_iに相当)のペアコマンドであるかを示す引数、jはペアコマンドリストL2のどの列番に相当(図6のrow_iに相当)する組PA1であるかを示す記号であるとする。以上の処理により、図6に例示するように、各ペアコマンドCj(i)がi行j列に格納されたペアコマンドリストL2が作成される。このペアコマンドリストL2は、NCプログラムP1から抽出されたペアコマンドA2が縦方向D1へNCプログラムに記述された順とされ、かつ、横方向D2へペアコマンドの組PA1に応じた位置とされた二次元データテーブルとされている。
A pair command stored in the
S122では、ペアコマンドリストL2に従ってペアコマンドリスト表示領域96にペアコマンドA2を並べる。上述したように、ペアコマンドリスト表示領域96に表示されるペアコマンドA2は、縦方向D1へNCプログラムP1に記述された順とされ、かつ、横方向D2へペアコマンドの組PA1に応じた位置として並べられる。従って、NCプログラムP1に記述されたペアコマンドA2の組PA1同士の相対関係が判り易い。
なお、ペアコマンドリスト表示領域96の背景色は、ペアコマンドエリア色やエラー色とは異なる色とされている。
In S122, the pair commands A2 are arranged in the pair command
The background color of the pair command
S124では、図7に例示するペアコマンドエラー解析処理を行う。まず、コンピュータPC1は、ペアコマンドリストL2のコマンド取得対象の列位置を表すパラメータrow_iに0を代入し、ペアコマンドリストL2のコマンド取得対象の行位置を表すパラメータlist_iに0を代入し、ペアコマンドエリアの開始行を表すパラメータlist_bgn_iに0を代入する、パラメータ初期化処理を行う(S202)。S204では、ペアコマンドリストL2におけるrow_i列及びlist_i行のデータを取得する。図6の例では、row_i=list_i=0の場合に空白を表す空白データが取得され、row_i=0,list_i=4の場合にペアコマンド「M11」が取得される。
In S124, a pair command error analysis process illustrated in FIG. 7 is performed. First, the computer PC1 assigns 0 to the parameter row_i representing the command acquisition target column position of the pair command list L2, and
S206では、取得されたデータが空白データであるか否かを判断する。空白データが取得された場合、コンピュータPC1は、S220に進む。その結果、行インデックスlist_iがペアコマンドリストL2の最終行の値でなければlist_iに1が加算され、行インデックスlist_iがペアコマンドリストL2の最終行の値であって列インデックスrow_iがペアコマンドリストL2の最終列の値でなければrow_iに1が加算される。 In S206, it is determined whether or not the acquired data is blank data. When the blank data is acquired, the computer PC1 proceeds to S220. As a result, if the row index list_i is not the value of the last row of the pair command list L2, 1 is added to list_i, the row index list_i is the value of the last row of the pair command list L2, and the column index row_i is the pair command list L2. If it is not the value of the last column, 1 is added to row_i.
一方、ペアコマンドA2が取得された場合、コンピュータPC1は、取得されたペアコマンドA2が開始コマンドであるか否かを判断する(S208)。 On the other hand, when the pair command A2 is acquired, the computer PC1 determines whether or not the acquired pair command A2 is a start command (S208).
開始コマンドでなければ、ある組PA1において開始コマンド無しに終了コマンドがNCプログラムP1に記述されていることになるため、コンピュータPC1は、エラー表示を行い(S210)、S220に進む。本実施形態では、取得されたペアコマンドA2の表示箇所を所定のエラー色(例えば赤色)に変更し、当該ペアコマンドA2の組PA1の名称の前にチェック印を付すことにしている。図3の例では、「M10/M11」列で最初となるペアコマンドM11の表示箇所が赤色とされ、「M10/M11」の名称の前にチェック印が付されていることが示されている。 If it is not the start command, the end command is described in the NC program P1 without a start command in a certain set PA1, so the computer PC1 displays an error (S210) and proceeds to S220. In the present embodiment, the display location of the acquired pair command A2 is changed to a predetermined error color (for example, red), and a check mark is added before the name of the set PA1 of the pair command A2. In the example of FIG. 3, the display location of the first pair command M11 in the “M10 / M11” column is red, and a check mark is added in front of the name “M10 / M11”. .
一方、取得されたペアコマンドA2が開始コマンドである場合、コンピュータPC1は、現在の行インデックスlist_iを開始インデックスlist_bgn_iとして保存する(S212)。S214では、行インデックスlist_iを1ずつ増やしながらrow_i列のペアコマンドA2を検索し、ペアコマンドA2が検索されたら該ペアコマンドA2を取得し、row_i列の最終行までペアコマンドA2が見つからなかったら検索を終了する。S216では、S214で取得したコマンドが終了コマンドか否かを判断する。 On the other hand, when the acquired pair command A2 is a start command, the computer PC1 stores the current row index list_i as the start index list_bgn_i (S212). In S214, the row index list_i is incremented by 1, and the pair command A2 in the row_i column is searched. When the pair command A2 is searched, the pair command A2 is acquired. Exit. In S216, it is determined whether or not the command acquired in S214 is an end command.
終了コマンドが取得されなかった場合は、ある組PA1において、開始コマンドの次に開始コマンドがNCプログラムP1に記述されているか、開始コマンドが最後の記述となっている。そこで、コンピュータPC1は、S204で取得したコマンドの表示箇所にエラー表示を行い、S214で取得したコマンドが終了コマンドでないと判断した場合にはそのコマンドの表示箇所にもエラー表示を行った(S210)上でS220に進む。
以上説明したようにして、コンピュータPC1は、組PA1毎に並べられたペアコマンドA2の順番に基づいてペアコマンドA2のそれぞれがNCプログラムP1の中で正しい位置であるか否かを判断する。そして、正しい位置でないと判断したペアコマンドA2の表示箇所を他の箇所とは異なる態様で表示する。
When the end command is not acquired, in a certain set PA1, the start command is described in the NC program P1 next to the start command, or the start command is the last description. Accordingly, the computer PC1 displays an error at the display location of the command acquired at S204, and when it determines that the command acquired at S214 is not an end command, it also displays an error at the display location of the command (S210). Above, it progresses to S220.
As described above, the computer PC1 determines whether each of the pair commands A2 is in the correct position in the NC program P1 based on the order of the pair commands A2 arranged for each set PA1. Then, the display location of the pair command A2 determined not to be the correct position is displayed in a manner different from other locations.
一方、終了コマンドが取得された場合、コンピュータPC1は、row_i列のlist_bgn_i行からlist_i行までの表示箇所を所定のペアコマンドエリア色(例えば青色や黄色)に変更する(S218)。図3の例では、「M14/M15」列で最初の開始コマンドM14から次の終了コマンドM15までのペアコマンドエリアが青色とされていることが示されている。図3の例では列インデックスrow_iが奇数の場合にペアコマンドが青色とされ、列インデックスrow_iが偶数の場合にペアコマンドが黄色とされていることが示されている。むろん、ペアコマンドエリア色は、列に応じて交互に色分けされる以外にも、3色以上で色分けされてもよいし、全ペアコマンドエリアで同一色とされてもよいし、同じ列でも色分けされてもよい。 On the other hand, when the end command is acquired, the computer PC1 changes the display location from the list_bgn_i row to the list_i row in the row_i column to a predetermined pair command area color (for example, blue or yellow) (S218). In the example of FIG. 3, the pair command area from the first start command M14 to the next end command M15 in the “M14 / M15” column is blue. The example of FIG. 3 shows that the pair command is blue when the column index row_i is an odd number, and the pair command is yellow when the column index row_i is an even number. Of course, the pair command area colors may be color-coded by three or more colors in addition to being alternately color-coded according to the columns, may be the same color in all pair command areas, or may be color-coded in the same column. May be.
S220では、行インデックスlist_iが最終行の値となったか否かを判断する。list_iが最終行の値でない場合、コンピュータPC1は、list_iに1を加算し(S222)、S204に戻る。list_iが最終行の値である場合、コンピュータPC1は、列インデックスrow_iが最終列の値となったか否かを判断する(S224)。row_iが最終列の値でない場合、コンピュータPC1は、row_iに1を加算し(S226)、行インデックスlist_iに0を代入して(S228)、S204に戻る。row_iが最終列の値である場合、コンピュータPC1は、ペアコマンドエラー解析処理を終了して、図4のS126に進む。 In S220, it is determined whether or not the row index list_i is the value of the last row. If list_i is not the value of the last line, the computer PC1 adds 1 to list_i (S222), and returns to S204. When list_i is the value of the last row, the computer PC1 determines whether or not the column index row_i is the value of the last column (S224). If row_i is not the value of the last column, the computer PC1 adds 1 to row_i (S226), assigns 0 to the row index list_i (S228), and returns to S204. If row_i is the value of the last row, the computer PC1 ends the pair command error analysis process and proceeds to S126 of FIG.
以上の処理により、ペアコマンドの組PA1毎にNCプログラムP1に記述された順に並べられたペアコマンドA2の中で開始コマンドA3の次に終了コマンドA4が配置されているときに該配置の開始コマンドA3及び終了コマンドA4が同一色で表示される。従って、NCプログラムP1に記述されたペアコマンドA2の相対関係の確認が容易である。また、開始コマンドA3から終了コマンドA4までのペアコマンドエリア全体が同一色で表示されるので、ペアコマンドA2の組PA1同士の相対関係が判り易い。
さらに、正しい位置でないと判断されたペアコマンドA2の表示箇所が他の箇所とは異なる態様で表示されるので、NCプログラムP1に含まれる正しい位置でないペアコマンドA2の把握が容易である。
By the above processing, when the end command A4 is arranged next to the start command A3 in the pair command A2 arranged in the order described in the NC program P1 for each pair of the pair commands PA1, the arrangement start command is arranged. A3 and end command A4 are displayed in the same color. Therefore, it is easy to confirm the relative relationship of the pair command A2 described in the NC program P1. Further, since the entire pair command area from the start command A3 to the end command A4 is displayed in the same color, the relative relationship between the pair PA1 of the pair command A2 is easy to understand.
Furthermore, since the display location of the pair command A2 determined not to be in the correct position is displayed in a different form from the other locations, it is easy to grasp the pair command A2 that is not in the correct position included in the NC program P1.
S126では、図8に例示する上位コマンドエラー解析処理を行う。まず、コンピュータPC1は、上記S202と同様、パラメータrow_i,list_i,list_bgn_iに0を代入する、パラメータ初期化処理を行う(S302)。S304では、ペアコマンドリストL2におけるrow_i列及びlist_i行のデータを取得する。S306では、開始コマンドが取得され、かつ、該開始コマンドに上位のペアコマンドが設定されているか否かを判断する。図5,6の例では、ペアコマンドM68,M69に上位のペアコマンドM14,M15が設定されているため、開始コマンドM68が取得されると条件成立となる。
条件不成立時、コンピュータPC1は、処理をS320に進める。
In S126, the upper command error analysis process illustrated in FIG. 8 is performed. First, the computer PC1 performs parameter initialization processing in which 0 is substituted for the parameters row_i, list_i, and list_bgn_i as in S202 (S302). In S304, the row_i column and list_i row data in the pair command list L2 are acquired. In S306, it is determined whether a start command is acquired and a higher pair command is set in the start command. In the examples of FIGS. 5 and 6, since the upper pair commands M14 and M15 are set in the pair commands M68 and M69, the condition is satisfied when the start command M68 is acquired.
When the condition is not satisfied, the computer PC1 advances the process to S320.
S306で条件成立時、コンピュータPC1は、現在の行インデックスlist_iを開始インデックスlist_bgn_iとして保存する(S308)。S310では、行インデックスlist_iを1ずつ増やしながらrow_i列のペアコマンドA2を検索して取得する処理を行い、row_i列の最終行までペアコマンドA2が見つからなかったらS320に進み、ペアコマンドA2があればS312に進む。S312では、S310で取得されたコマンドが終了コマンドか否かを判断する。終了コマンドでは無い場合、つまり開始コマンドである場合にはS304に戻り、その開始コマンドを対象としてS304以降の処理を行う。 When the condition is satisfied in S306, the computer PC1 stores the current row index list_i as the start index list_bgn_i (S308). In S310, the row index list_i is incremented by 1 to search and acquire the pair command A2 in the row_i column. If the pair command A2 is not found up to the last row in the row_i column, the process proceeds to S320, and if there is a pair command A2 The process proceeds to S312. In S312, it is determined whether or not the command acquired in S310 is an end command. If it is not an end command, that is, if it is a start command, the process returns to S304, and the processing from S304 onward is performed for that start command.
一方、終了コマンドが取得された場合、コンピュータPC1は、list_bgn_i行よりも前に上位の開始コマンドが有るか否かを判断する(S314)。図5,6の例では、開始コマンドM68の前に「M14/M15」列で上位の開始コマンドM14があるか否かが判断されることになる。
list_bgn_i行よりも前に上位の開始コマンドが無ければ、コンピュータPC1は、エラー表示を行い(S316)、S320に進む。本実施形態では、row_i列のlist_bgn_i行からlist_i行までの表示箇所を所定のエラーコマンドエリア色(例えば赤紫色)に変更し、row_i列の組PA1の名称の前にチェック印を付すことにしている。
On the other hand, when the end command is acquired, the computer PC1 determines whether there is a higher start command before the list_bgn_i line (S314). In the example of FIGS. 5 and 6, it is determined whether or not there is a higher start command M14 in the “M14 / M15” column before the start command M68.
If there is no upper start command before the list_bgn_i line, the computer PC1 displays an error (S316) and proceeds to S320. In this embodiment, the display location from the list_bgn_i row to the list_i row in the row_i column is changed to a predetermined error command area color (for example, magenta), and a check mark is added in front of the name of the set PA1 in the row_i column. Yes.
list_bgn_i行よりも前に上位の開始コマンドが有る場合、コンピュータPC1は、その上位の開始コマンドであってlist_bgn_i行に最も近い位置にあるコマンドに対応する上位の終了コマンドがlist_i行よりも後に有るか否かを判断する(S318)。図5,6の例では、「M14/M15」列でlist_bgn_i行の前であって最も近い位置にある上位の開始コマンドM14に対応する上位の終了コマンドM15が終了コマンドM69の後にあるか否かが判断されることになる。 If there is an upper start command before the list_bgn_i line, the computer PC1 determines whether there is an upper end command corresponding to the upper start command that is closest to the list_bgn_i line after the list_i line. It is determined whether or not (S318). In the example of FIGS. 5 and 6, whether or not the upper end command M15 corresponding to the upper start command M14 in the “M14 / M15” column before the list_bgn_i row and located at the nearest position is after the end command M69. Will be judged.
条件不成立時、コンピュータPC1は、エラー表示を行い(S316)、S320に進む。本実施形態では、row_i列のlist_bgn_i行からlist_i行までの表示箇所を所定のエラーコマンドエリア色に変更し、row_i列の組PA1の名称の前にチェック印を付すことにしている。図3の例では、「M68/M69」列の一番下の終了コマンドM69よりも前に上位の終了コマンドM15が配置されているため、下位の開始コマンドM68から下位の終了コマンドM69までのエラーコマンドエリアが赤紫色とされ、「M68/M69」の名称の前にチェック印が付されていることが示されている。むろん、エラーコマンドエリア色は、図7で示したペアコマンドエラー解析処理で表示されるエラー色と同じ色とされてもよい。 When the condition is not satisfied, the computer PC1 displays an error (S316), and proceeds to S320. In the present embodiment, the display locations from the list_bgn_i row to the list_i row in the row_i column are changed to a predetermined error command area color, and a check mark is added before the name of the set PA1 in the row_i column. In the example of FIG. 3, since the upper end command M15 is arranged before the lowest end command M69 in the “M68 / M69” column, errors from the lower start command M68 to the lower end command M69 are detected. The command area is magenta, indicating that a check mark is added in front of the name “M68 / M69”. Of course, the error command area color may be the same as the error color displayed in the pair command error analysis processing shown in FIG.
以上説明したようにして、コンピュータPC1は、組PA1毎に並べられたペアコマンドA2の順番に基づいて階層を有するペアコマンドA2のそれぞれがNCプログラムP1の中で正しい階層位置であるか否かを判断する。そして、正しい階層位置でないと判断したペアコマンドA2の表示箇所を他の箇所とは異なる態様で表示する。上位のペアコマンドと下位のペアコマンドとが入れ子になっていない等、正しい階層位置でないと判断されたペアコマンドA2の表示箇所は、他の箇所とは異なる態様で表示される。従って、NCプログラムP1に含まれる正しい階層位置でないペアコマンドA2の把握が容易である。 As described above, the computer PC1 determines whether or not each of the pair commands A2 having a hierarchy is the correct hierarchy position in the NC program P1 based on the order of the pair commands A2 arranged for each set PA1. to decide. Then, the display location of the pair command A2 that is determined not to be in the correct hierarchy position is displayed in a manner different from other locations. The display location of the pair command A2 that is determined not to be in the correct hierarchical position, such as when the upper pair command and the lower pair command are not nested, is displayed in a different manner from the other locations. Therefore, it is easy to grasp the pair command A2 that is not in the correct hierarchical position included in the NC program P1.
S320では、行インデックスlist_iが最終行の値となったか否かを判断する。list_iが最終行の値でない場合、コンピュータPC1は、list_iに1を加算し(S322)、S304に戻る。list_iが最終行の値である場合、コンピュータPC1は、列インデックスrow_iが最終列の値となったか否かを判断する(S324)。row_iが最終列の値でない場合、コンピュータPC1は、row_iに1を加算し(S326)、行インデックスlist_iに0を代入して(S328)、S304に戻る。row_iが最終列の値である場合、コンピュータPC1は、上位コマンドエラー解析処理を終了し、図4のペアコマンドチェック処理を終了する。 In S320, it is determined whether or not the row index list_i has reached the value of the last row. If list_i is not the value of the last row, the computer PC1 adds 1 to list_i (S322), and returns to S304. When list_i is the value of the last row, the computer PC1 determines whether or not the column index row_i is the value of the last column (S324). If row_i is not the value of the last column, the computer PC1 adds 1 to row_i (S326), substitutes 0 for the row index list_i (S328), and returns to S304. When row_i is the value of the last row, the computer PC1 ends the upper command error analysis process and ends the pair command check process of FIG.
以上説明したように、本コマンド表示装置によると、NCプログラムP1に記述されたペアコマンドA2の組PA1毎に、NCプログラムP1に含まれるペアコマンドA2が分けられてプログラム順に並べられて表示される。従って、本コマンド表示装置は、NC旋盤2のためのNCプログラムP1に記述されたペアコマンドA2の相対関係を容易に確認することができ、NCプログラムP1のチェックを容易にすることができる。
As described above, according to this command display device, for each pair PA1 of the pair command A2 described in the NC program P1, the pair command A2 included in the NC program P1 is divided and displayed in the program order. . Therefore, this command display device can easily confirm the relative relationship of the pair command A2 described in the NC program P1 for the
(4)変形例:
本発明は、様々な変形例が考えられる。
例えば、NCプログラムを実行する工作機械は、NC旋盤以外の数値制御工作機械でもよい。
NCプログラムのコマンド表示装置は、工作機械自体に設けられてもよい。例えば、NCプログラムのコマンド表示プログラムP2をNC装置50に記憶させ、NC装置50でコマンド表示プログラムP2を実行すると、NC旋盤(工作機械)2がNCプログラムのコマンド表示装置となる。
上述した各ステップの順番は、適宜、変更可能である。例えば、S114のペアコマンドリスト初期化処理は、S104又はS102の処理の前に行われてもよい。
一時バッファ領域33に格納されるペアコマンドA2は、NCプログラムP1に記述された順とされなくてもよい。例えば、各ペアコマンドA2を表す情報と、NCプログラムP1に記述された順番とを対応付ける情報テーブルを作成すれば、この情報テーブルに基づいてペアコマンドリストL2を作成することができる。
(4) Modification:
Various modifications of the present invention are conceivable.
For example, the machine tool that executes the NC program may be a numerically controlled machine tool other than the NC lathe.
The NC program command display device may be provided in the machine tool itself. For example, when the NC program command display program P2 is stored in the NC device 50 and the NC device 50 executes the command display program P2, the NC lathe (machine tool) 2 becomes the NC program command display device.
The order of the steps described above can be changed as appropriate. For example, the pair command list initialization process in S114 may be performed before the process in S104 or S102.
The pair command A2 stored in the
ペアコマンドA2の階層は、3階層以上とされてもよい。例えば、図3で示した設定領域91でペアコマンドM14,M15の上位コマンドNo.が「2」とされると、ペアコマンドM68,M69の上位のペアコマンドM14,M15のさらに上位のペアコマンドが「M10,M11」に設定される。この場合も、上位コマンドエラー解析処理が行われることにより、NCプログラムP1中で最上位のペアコマンドM10,M11に対して正しい位置でないペアコマンドM14,M15の表示箇所も他の箇所とは異なる態様で表示される。
また、上位のペアコマンドに対して複数組の下位のペアコマンドが設定されてもよい。例えば、図3で示した設定領域91でペアコマンドM66,M67の上位コマンドNo.が「3」とされると、ペアコマンドM14,M15の下位のペアコマンドは「M66,M67」及び「M68,M69」となる。この場合も、上位コマンドエラー解析処理が行われることにより、NCプログラムP1中でペアコマンドM14,M15に対して正しい位置でない下位のペアコマンドM66,M67の表示箇所も他の箇所とは異なる態様で表示される。
The hierarchy of the pair command A2 may be three or more. For example, the upper command No. of the pair commands M14 and M15 in the setting
A plurality of lower pair commands may be set for the upper pair commands. For example, the upper command No. of the pair commands M66 and M67 in the setting
なお、NCプログラムP1中で正しい階層位置でない開始コマンドと終了コマンドとの間の空白は、直接対応するペアコマンドの組合せを判り易くする点からは開始コマンド及び終了コマンドと同じエラーコマンドエリア色とされるのが好ましいものの、エラーコマンドエリア色とされなくてもよい。 In the NC program P1, the space between the start command and the end command that is not in the correct hierarchy position is the same error command area color as the start command and the end command in order to make it easy to understand the combination of the corresponding pair commands. However, the error command area color may not be used.
また、NCプログラムP1中で正しい位置の開始コマンドと終了コマンドとの間の空白も、直接対応するペアコマンドの組合せを判り易くする点からは開始コマンド及び終了コマンドと同じペアコマンドエリア色とされるのが好ましいものの、ペアコマンドエリア色とされなくてもよい。図9(a)は、開始コマンドと終了コマンドとの間の空白をペアコマンドエリア色としない変形例のチェック結果表示領域94を示している。この場合でも、直接対応するペアコマンドの組合せが同一色で表示されるので、ペアコマンドA2の相対関係の確認が容易である。
Further, the space between the start command and the end command at the correct position in the NC program P1 is also set to the same pair command area color as the start command and the end command in order to make it easy to understand the combination of the corresponding pair commands. However, the pair command area color may not be used. FIG. 9A shows a check
さらに、図9(b)に例示するように、ペアコマンドA2の組PA1同士の位置関係がプログラム順となっていなくてもよい。本変形例のチェック結果表示領域94には、ペアコマンドA2が各組PA1においてプログラム順とされたペアコマンドリスト表示領域96が表示されている。従って、NCプログラムP1から抽出されたペアコマンドA2が組PA1毎に分けられてプログラム順に並べて表示されているといえる。この場合も、各組PA1においてペアコマンドA2の相対関係の確認が容易である。
本変形例の場合、一時バッファ領域33に対して組PA1別にペアコマンドA2をプログラム順に蓄積すれば、組PA1別とされたペアコマンドA2を一時バッファ領域33から読み出してペアコマンドリストを表示することができる。
Furthermore, as illustrated in FIG. 9B, the positional relationship between the pair PA1 of the pair command A2 may not be in the program order. In the check
In the case of this modification, if the pair command A2 is stored in the program order in the
ところで、図4のS126の上位コマンドエラー解析処理やS124のペアコマンドエラー解析処理が行われなくても、NCプログラムP1に記述されたペアコマンドA2の相対関係を容易に確認することができる。
むろん、従属請求項に係る構成要件を有しておらず独立請求項に係る構成要件のみからなる装置及びプログラムでも、上述した基本的な作用、効果が得られる。
また、本発明は、上述した実施形態や変形例に限られず、上述した実施形態及び変形例の中で開示した各構成を相互に置換したり組み合わせを変更したりした構成、公知技術並びに上述した実施形態及び変形例の中で開示した各構成を相互に置換したり組み合わせを変更したりした構成、等も含まれる。
Incidentally, the relative relationship of the pair command A2 described in the NC program P1 can be easily confirmed without performing the upper command error analysis process of S126 of FIG. 4 or the pair command error analysis process of S124.
Of course, the above-described basic operations and effects can be obtained even with an apparatus and a program that do not have the configuration requirements according to the dependent claims but only the configuration requirements according to the independent claims.
In addition, the present invention is not limited to the above-described embodiments and modifications, and the configurations disclosed in the above-described embodiments and modifications are mutually replaced or the combination is changed, the known technology, and the above-described configurations. Configurations in which the respective configurations disclosed in the embodiment and the modified examples are mutually replaced or combinations are changed are also included.
2…数値制御旋盤(工作機械)、
31…数値制御プログラム保存領域(記憶部)、
90…ペアコマンドチェック画面、91…設定領域、94…チェック結果表示領域、
A1…コマンド、A2…ペアコマンド、A3…開始コマンド、A4…終了コマンド、
D1…縦方向(所定方向)、D2…横方向、
L1…ペアコマンド設定リスト、L2…ペアコマンドリスト、
P1…数値制御プログラム、P2…コマンド表示プログラム、
PA1…ペアコマンドの組、
PC1…コンピュータ(コマンド表示装置)、
U1…ペアコマンド抽出手段、U2…ペアコマンド表示手段。
2 ... Numerically controlled lathe (machine tool),
31 ... Numerical control program storage area (storage unit),
90 ... Pair command check screen, 91 ... Setting area, 94 ... Check result display area,
A1 ... command, A2 ... pair command, A3 ... start command, A4 ... end command,
D1 ... vertical direction (predetermined direction), D2 ... horizontal direction,
L1 ... Pair command setting list, L2 ... Pair command list,
P1 ... Numerical control program, P2 ... Command display program,
PA1 ... Pair command set,
PC1 computer (command display device),
U1 ... Pair command extraction means, U2 ... Pair command display means.
Claims (5)
該記憶されている数値制御プログラムに記述された前記ペアコマンドを抽出するペアコマンド抽出手段と、
前記ペアコマンドの組毎に前記抽出されたペアコマンドを分けて前記数値制御プログラムに記述された順に並べて表示するペアコマンド表示手段とを備えることを特徴とする数値制御プログラムのコマンド表示装置。 A storage unit storing a numerical control program described by a command selected from a plurality of commands including at least one pair command used in a pair;
Pair command extraction means for extracting the pair command described in the stored numerical control program;
A command display device for a numerical control program, comprising: a pair command display unit that divides the extracted pair commands for each pair of the pair commands and displays them in the order described in the numerical control program.
前記ペアコマンド表示手段は、前記ペアコマンドの組毎に前記数値制御プログラムに記述された順に並べられたペアコマンドの中で前記開始コマンドの次に前記終了コマンドが配置されているときに該配置の前記開始コマンド及び前記終了コマンドを同一色で表示することを特徴とする請求項1又は請求項2に記載の数値制御プログラムのコマンド表示装置。 The pair command pair includes a start command described earlier and an end command described after the start command,
The pair command display means is arranged when the end command is arranged next to the start command in the pair commands arranged in the order described in the numerical control program for each pair of the pair commands. The command display device for a numerical control program according to claim 1 or 2, wherein the start command and the end command are displayed in the same color.
前記ペアコマンドの組毎に前記抽出されたペアコマンドを分けて前記数値制御プログラムに記述された順に並べて表示するペアコマンド表示機能とをコンピュータに実現させることを特徴とする数値制御プログラムのコマンド表示プログラム。 A pair command extraction function for extracting the pair command described in a numerical control program described by a command selected from a plurality of commands including one or more pair commands used in pairs and stored in a storage unit;
A command display program for a numerical control program, which causes a computer to realize a pair command display function for dividing the extracted pair commands for each pair of the pair commands and displaying them in the order described in the numerical control program. .
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009280815A JP5356203B2 (en) | 2009-12-10 | 2009-12-10 | Command display device and command display program for numerical control program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009280815A JP5356203B2 (en) | 2009-12-10 | 2009-12-10 | Command display device and command display program for numerical control program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2011123667A true JP2011123667A (en) | 2011-06-23 |
JP5356203B2 JP5356203B2 (en) | 2013-12-04 |
Family
ID=44287500
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2009280815A Active JP5356203B2 (en) | 2009-12-10 | 2009-12-10 | Command display device and command display program for numerical control program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5356203B2 (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2017097474A (en) * | 2015-11-19 | 2017-06-01 | ファナック株式会社 | Numerical control device in which external signal input/output in servo control unit is speeded up |
WO2019064915A1 (en) * | 2017-09-26 | 2019-04-04 | 日本電産株式会社 | Robot teaching device |
WO2023112772A1 (en) * | 2021-12-13 | 2023-06-22 | 川崎重工業株式会社 | Robot programming assistance device, robot programming assistance program, and robot programming assistance method |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH05113817A (en) * | 1991-10-23 | 1993-05-07 | Nec Corp | Numerical controller |
-
2009
- 2009-12-10 JP JP2009280815A patent/JP5356203B2/en active Active
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH05113817A (en) * | 1991-10-23 | 1993-05-07 | Nec Corp | Numerical controller |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2017097474A (en) * | 2015-11-19 | 2017-06-01 | ファナック株式会社 | Numerical control device in which external signal input/output in servo control unit is speeded up |
US10114359B2 (en) | 2015-11-19 | 2018-10-30 | Fanuc Corporation | Numerical control device for realizing high-speed input and output of external signal in servo controller |
WO2019064915A1 (en) * | 2017-09-26 | 2019-04-04 | 日本電産株式会社 | Robot teaching device |
JPWO2019064915A1 (en) * | 2017-09-26 | 2020-10-15 | 日本電産株式会社 | Robot teaching device |
JP7167925B2 (en) | 2017-09-26 | 2022-11-09 | 日本電産株式会社 | Robot teaching device |
WO2023112772A1 (en) * | 2021-12-13 | 2023-06-22 | 川崎重工業株式会社 | Robot programming assistance device, robot programming assistance program, and robot programming assistance method |
Also Published As
Publication number | Publication date |
---|---|
JP5356203B2 (en) | 2013-12-04 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105103065B (en) | Bias numbering setting device | |
CN102854831B (en) | Block execution sequence display device | |
CN1648807A (en) | Numerical control apparatus | |
JP5356203B2 (en) | Command display device and command display program for numerical control program | |
CN106471430B (en) | Procedure editor's servicing unit | |
CN1349141A (en) | Device and method for industrial control based on distributable technology target | |
EP3203334B1 (en) | Control device for machine tool | |
KR20110102499A (en) | Ladder program edition device | |
WO2012102472A1 (en) | Apparatus and method for inputting cutting shape using interactive program in computer numerical control machine tool | |
JP2007109200A (en) | Display, display method, and display program | |
CN105144004B (en) | Program map display device and programme diagram display methods | |
KR101260275B1 (en) | Plant control system and program relocate method | |
CN101158861A (en) | Controller for machine tool | |
KR101447846B1 (en) | Motion sfc program component creation device | |
JP4456526B2 (en) | NC program display and editing method | |
CN112147949A (en) | Parameter management device and management system thereof | |
JP5542300B2 (en) | Program editing device | |
EP2339417A1 (en) | Apparatus and method for controlling machine tool | |
JP2006243841A (en) | Plc tool device | |
US20160292237A1 (en) | Numerical controller with ambiguous search function in program | |
JP2010244110A (en) | Software design support device and computer program | |
US20040215364A1 (en) | Method for generating and visualizing a task-oriented step representation | |
JP5376034B2 (en) | Program editing device | |
JP5008520B2 (en) | How to display data entry status in the display screen | |
WO2024014355A1 (en) | Control program editing device, editing method, and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20120823 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20130815 |
|
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: 20130827 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20130828 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5356203 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |