JPH0210405A - Method for monitoring number of worked parts - Google Patents

Method for monitoring number of worked parts

Info

Publication number
JPH0210405A
JPH0210405A JP15933888A JP15933888A JPH0210405A JP H0210405 A JPH0210405 A JP H0210405A JP 15933888 A JP15933888 A JP 15933888A JP 15933888 A JP15933888 A JP 15933888A JP H0210405 A JPH0210405 A JP H0210405A
Authority
JP
Japan
Prior art keywords
parts
program
command
worked
total number
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP15933888A
Other languages
Japanese (ja)
Inventor
Keiichiro Miyajima
敬一郎 宮嶋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fanuc Corp
Original Assignee
Fanuc Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fanuc Corp filed Critical Fanuc Corp
Priority to JP15933888A priority Critical patent/JPH0210405A/en
Publication of JPH0210405A publication Critical patent/JPH0210405A/en
Pending legal-status Critical Current

Links

Landscapes

  • Numerical Control (AREA)

Abstract

PURPOSE:To accurately output the total number of worked parts by discriminating whether a number command to specify a number N of worked parts exists in an NC program or not and adding this number to the total number of worked parts obtained till then. CONSTITUTION:A NC device consists of an NC tape 11, an NC data reading part 12, an NC main body part 13, and a display part 14 like a CRT on which a total number NT of worked parts is displayed. The NC main body part 13 is provided with a discriminating part 13a which discriminates the number command, the program end, and the other commands, registers 13b-13e, an adding part 13f, and a numerical control part 13g. It is discriminated by the discriminating part 13a whether NC data read from the NC tape 11 is the number command which specifies the number N of parts to be worked by the NC program or not, and the adding part 13f adds the number N of parts to be worked to the number NT of parts worked till then by the program end and outputs the addition result to display it on the display part 14. Thus, the correct total number of worked parts is always outputted.

Description

【発明の詳細な説明】 〈産業上の利用分野〉 本発明は加工部品数監視方法に係り、特に1つのNCプ
ログラムにより多数の部品が加工される場合に好適な加
工部品数監視方法に関する。
DETAILED DESCRIPTION OF THE INVENTION <Industrial Application Field> The present invention relates to a method for monitoring the number of machined parts, and particularly to a method for monitoring the number of machined parts suitable when a large number of parts are machined by one NC program.

〈従来技術〉 NC装置には加工部品数を表示する機能があり、適宜総
加工数をCRTに表示できるようになっている。すなわ
ち、従来は1つのNCプログラムによる加工が終了する
と、総加工部品数を1カウントアツプして表示するよう
にしている。
<Prior Art> The NC device has a function of displaying the number of machined parts, and the total number of machined parts can be displayed on the CRT as appropriate. That is, conventionally, when machining by one NC program is completed, the total number of machined parts is incremented by one and displayed.

〈発明が解決しようとしている課題〉 ところで、加工によっては1つのNCプログラムを実行
すると2以上の部品が得られる場合がある。たとえば、
打ち抜き加工等において多数個取り指令やカスタムマク
ロ等でそれ相当のNCプログラムを作成し1枚の素材か
ら多数の加工製品を得る場合である。
<Problems to be Solved by the Invention> Incidentally, depending on the processing, two or more parts may be obtained by executing one NC program. for example,
This is the case when a corresponding NC program is created using a multi-piece cutting command or a custom macro to obtain a large number of processed products from one sheet of material, such as in punching processing.

かかる多数個取りのNCプログラムに従来の加工部品数
監視方式を適用すると、CRTに表示される総加工部品
数と実際の総加工部品数が異なるという問題が生じる。
If the conventional method for monitoring the number of machined parts is applied to such a multi-piece NC program, a problem arises in that the total number of machined parts displayed on the CRT is different from the actual total number of machined parts.

以上から、本発明の目的は加工部品数に関係なく常に正
しい総加工部品数を出力できる加工部品数監視方法を提
供することである。
From the above, an object of the present invention is to provide a method for monitoring the number of machined parts that can always output the correct total number of machined parts regardless of the number of machined parts.

く課題を解決するための手段〉 第1図は本発明を実現するNC装置のブロック図である
Means for Solving the Problems> FIG. 1 is a block diagram of an NC device that implements the present invention.

11はNCテープ、13はNC本体部、13aは枚数指
令/プログラムエンド/その他の指令の判別をする判別
部、13cは加工部品数Nが設定されるレジスタ、13
 e If総加工部品数N工を記憶するレジスタ、13
fは加算部、14は表示部である。
11 is an NC tape, 13 is an NC main unit, 13a is a determination unit for determining the number of sheets/program end/other commands, 13c is a register in which the number N of processed parts is set, 13
e If a register for storing the total number of machined parts N, 13
f is an addition section, and 14 is a display section.

く作用〉 NCテープ11から読み取られたNCデータが、NCプ
ログラムにより加工される部品数Nを特定する枚数指令
であるか判別部13aで判別し、NCプログラム内に枚
数指令がある場合には加算部13fばプログラムエンド
によりそれ迄の総加工部品数87に加工部品数Nを加算
して加算結果を表示部14に出力して表示する。
Function> The determination unit 13a determines whether the NC data read from the NC tape 11 is a number command that specifies the number N of parts to be machined by the NC program, and if there is a number command in the NC program, it is added. The section 13f adds the number N of machined parts to the total number of parts machined up to that point 87 at the end of the program, and outputs the addition result to the display section 14 for display.

〈実施例〉 第1図は本発明を実現するNC装置のブロック図である
<Embodiment> FIG. 1 is a block diagram of an NC device that implements the present invention.

11はNCテープ、12はNCテープから1ブロツクづ
つNCデータを読み取るNCデータ読取部、13はNC
本体部、14は総加工部品数N工を表示するCRT等の
表示部である。
11 is an NC tape, 12 is an NC data reading unit that reads NC data one block at a time from the NC tape, and 13 is an NC
The main body part 14 is a display part such as a CRT that displays the total number of parts to be machined.

NC本体部13において、13aは1ブロツクのNCデ
ータを入力され、枚数指令/プログラムエンド/その他
の指令の判別をする判別部、13bは数値1が設定され
るレジスタ、13CはNCプログラムにより加工されろ
加工部品数Nが設定されるレジスタ、13dは枚数指令
があった時にセットされ、プログラムエンドによりリセ
ットされるフラグレジスタ、13eは総加工部品数NT
を記憶するレジスタ、13fは枚数指令がある場合には
プログラムエンドにより N+N−N      ・・・・(1)の演算を行い、
枚数指令がない場合にはN+1→N     ・・・・
(2) の演算を行う加算部、13gはNCデータに従って所定
の数値制御処理を行う数値制御部である。
In the NC main unit 13, 13a is a discrimination unit that receives one block of NC data and discriminates whether it is a number of sheets command/program end/other command, 13b is a register to which the numerical value 1 is set, and 13C is a register that is processed by the NC program. 13d is a flag register that is set when the number of parts is commanded and reset at the end of the program; 13e is the total number of parts to be machined NT
The register 13f that stores the number of sheets performs the calculation of N+N-N (1) at the end of the program when there is a number of sheets command.
If there is no number of sheets command, N+1→N...
(2) An addition section 13g that performs the calculation is a numerical control section that performs predetermined numerical control processing in accordance with NC data.

図示しない操作盤上の起動スイッチが操作されると数値
制御処理部13gはNCデータ読取部12に読取イネー
ブル信号REWを入力しNCテープ11から1ブロツク
のNCデータを読み取らせて判別部13aに入力させる
When a start switch on the operation panel (not shown) is operated, the numerical control processing section 13g inputs a read enable signal REW to the NC data reading section 12, reads one block of NC data from the NC tape 11, and inputs it to the discriminating section 13a. let

判別部13aは入力されたNCデータが枚数指令である
か、プログラムエンドであるか、その他の指令であるか
を判別し、枚数指令であれば、NCプログラムによる加
工部品数Nをレジスタ13Cにセットすると共に、へイ
レベル(=’rlJ)のフラグFをフラグ部13dにセ
ットし、枚数指令でもなく、プログラムエンドでもなけ
れば、入力されたNCデータを数値制御処理部13gに
入力して周知の数値制御処理を行わせろ。
The determining unit 13a determines whether the input NC data is a number of sheets command, a program end, or another command, and if it is a number of sheets command, sets the number N of parts processed by the NC program in the register 13C. At the same time, the flag F of the high level (='rlJ) is set in the flag section 13d, and if it is not a sheet quantity command or a program end, the input NC data is input to the numerical control processing section 13g and a known numerical value is set. Let the control process take place.

枚数指令に対する処理あるいは所定の数値制御処理が終
了すれば、数値制御処理部13g1.tNCデータ読取
部12に読取イネーブル信号RENを出力して次の1ブ
ロツク分のNCデータをNCテープ11から読み取らせ
て判別部13aに入力させる。
When the processing for the number of sheets command or the predetermined numerical control processing is completed, the numerical control processing section 13g1. A read enable signal REN is output to the tNC data reading section 12 to cause the next block of NC data to be read from the NC tape 11 and input to the discriminating section 13a.

判別部13aは同様に入力されたNCデータが枚数指令
か、プログラムエンドか、その他の指令かを判別し、プ
ログラムエンドであればその旨を数値制御処理部13g
に入力して数値制御処理を完了させると共に、加算部1
3fに加算イネーブル指令AENを出力する。
The determining unit 13a similarly determines whether the input NC data is a number of sheets command, program end, or other command, and if it is the program end, the numerical control processing unit 13g notifies the user of the fact.
to complete the numerical control process, and adder 1
Addition enable command AEN is output to 3f.

加算部13fは加算指令AENが入力されると、フラグ
が71」かチエツクし、「1」であれば枚数指令により
7NCプログラムによる加工部品数N」がレジスタ13
cにセットされているから、(1)式により総加工部品
数NTを計算し、計算結果をレジスタ13eに記憶する
と共に表示部(CRT)14に出力して表示する。尚、
フラグF1.tOにリセットされる。
When the addition command AEN is input, the addition unit 13f checks whether the flag is "71", and if it is "1", the number N of parts processed by the 7NC program is set in the register 13 according to the number of pieces command.
c, the total number of machined parts NT is calculated using equation (1), and the calculation result is stored in the register 13e and output to the display unit (CRT) 14 for display. still,
Flag F1. It is reset to tO.

一方、フラグが「0」であれば枚数指令がないから、従
来と同様に(2)式により総加工部品数NTを計算し、
計算結果をレジスタ13eに記憶すると共に表示部(C
RT)14に出力して表示する。
On the other hand, if the flag is "0", there is no number of parts command, so the total number of machined parts NT is calculated using equation (2) as before,
The calculation result is stored in the register 13e and displayed on the display section (C
RT) 14 for display.

第2図はコンピュータ構成のNC装置のブロック図、第
3図は第2図のNC装置による本発明の処理の流れ図で
ある。
FIG. 2 is a block diagram of an NC device having a computer configuration, and FIG. 3 is a flow chart of the processing of the present invention by the NC device of FIG.

第2図において、101はプロセッサ、102は制御プ
ログラムを記憶するプログラムメモリ(ROM)   
103は処理結果や実行中のNCプログラム等を記憶す
るRAM、104はパラメータや複数のNCプログラム
を記憶するバッテリーバックアップRAM (不揮発性
メモリ)  105はCRT105aとキーボード10
5 b9!備えたCRT&MD!装置、106はNCデ
ータ入力装置、107はパルス補間晋と各軸サーボユニ
ットを有する軸制御部、108はプロセッサから指令さ
れたM −S −T−機能命令等を工作機械に出力し、
工作機械からの各種信号をプロセッサに入力するインタ
フェース、109は操作盤、201は工作機械である。
In FIG. 2, 101 is a processor, and 102 is a program memory (ROM) that stores a control program.
103 is a RAM that stores processing results and NC programs being executed; 104 is a battery backup RAM (nonvolatile memory) that stores parameters and multiple NC programs; 105 is a CRT 105a and a keyboard 10
5 b9! Equipped with CRT & MD! 106 is an NC data input device, 107 is an axis control unit having a pulse interpolation unit and a servo unit for each axis, and 108 is for outputting M-S-T-function commands and the like issued from the processor to the machine tool;
An interface for inputting various signals from the machine tool to the processor, 109 is an operation panel, and 201 is the machine tool.

尚、NCプログラムにより加工される部品数を設定する
枚数指令用のNCデータは、たとえば以下のフォーマッ
ト G10L5ONロロロロROOi を有している。ただし、「G10」はパラメータ及びオ
フセット量設定用のGコード、「L50」はパラメータ
入力指定、「R」はパラメータ(加工部品数O・・O)
を指定するワードアドレス語、rNJはパラメータ(加
工部品数)が設定される場所(パラメータ番号)口・・
口を指定するワードアドレス語である。
Incidentally, the NC data for the number command for setting the number of parts to be machined by the NC program has, for example, the following format G10L5ONROROROROROOi. However, "G10" is the G code for setting the parameter and offset amount, "L50" is the parameter input specification, and "R" is the parameter (number of machined parts O...O)
The word address word that specifies, rNJ is the location (parameter number) where the parameter (number of processed parts) is set...
It is a word address word that specifies the mouth.

以下、第3図に従って第2図の処理を説明する。The process shown in FIG. 2 will be explained below with reference to FIG.

操作盤109上の起動スイッチが操作されろとプロセッ
サ101は予めRAM103に読出しである所定のNC
プログラムの1ブロック分のNCデータを読み取る(ス
テップ301)。
When the start switch on the operation panel 109 is operated, the processor 101 reads out a predetermined NC value in the RAM 103 in advance.
One block of NC data of the program is read (step 301).

ついで、プロセッサ101はNCデータが枚数指令であ
るかチエツクしくステップ302)、枚数指令であれば
、枚数指令のアルファベット「R」に続く数値O・・○
(Nとする)をRAM103の所定記憶域(パラメータ
番号口・・口に応じた記憶域)に記憶すると共に、フラ
グFを「1」にセットしくステップ303)、以後ステ
ップ301以降の処理を繰り返す。
Next, the processor 101 checks whether the NC data is a number-of-sheets command (step 302), and if it is a number-of-sheets command, the number O...○ following the alphabet "R" of the number of sheets command is determined by the processor 101.
(N) is stored in a predetermined storage area of the RAM 103 (storage area corresponding to the parameter number . .

一方、ステップ302において、NCデータが枚数指令
でなければ、プログラムエンドかチエツクしくステップ
304)、プログラムエンドでなければNCデータに基
づいて周知の数値制御処理を実行しくステップ305)
、Jd後スステップ301息降処理を繰り返す。
On the other hand, in step 302, if the NC data is not a sheet quantity command, check whether the program is at the end (step 304), and if the program is not at the end, execute well-known numerical control processing based on the NC data (step 305).
, Jd, the step 301 breath-down process is repeated.

ステップ304において、プログラムエンドであれば数
値制御処理を終了すると共に、フラグがセットされてい
るかチエツクしくステップ306)、セットされていれ
ば枚数指令によりrNCプログラムによる加工部品数N
」が指定されているから、プロセッサ101は(1)式
により総加工部品数NTを計算し、計算結果を記憶する
と共に(ステップ307)  CRT105aに出力し
て表示する(ステップ308)。尚、フラグFは0にリ
セットされろ。
In step 304, if the program is at the end, the numerical control process is terminated and the flag is checked (step 306).
'' is specified, the processor 101 calculates the total number of machined parts NT using equation (1), stores the calculation result (step 307), and outputs it to the CRT 105a for display (step 308). Note that flag F should be reset to 0.

一方、フラグがリセットされていれば枚数指令がないか
ら、従来と同様に(2)式により総加工部品数N工を計
算しくステップ309)、計算結果を記憶すると共にC
RT105aに出力して表示する(ステップ308)。
On the other hand, if the flag is reset, there is no number command, so the total number of parts to be machined N is calculated using equation (2) as in the past (step 309), the calculation result is stored, and the
It is output to the RT 105a and displayed (step 308).

〈発明の効果〉 以上本発明によれば、NCプログラム中に該NCプログ
ラムにより加工されろ部品数Nを特定する枚数指令があ
るか判別し、枚数指令がある場合にはプログラムエンド
によりそれ迄の総加工部品数N工に加工部品数Nを加算
して加算結果を出力するように構成したから、加工部品
数に関係なく常に正しい総加工部品数を出力できろ。
<Effects of the Invention> According to the present invention, it is determined whether there is a number command specifying the number N of parts to be machined by the NC program in an NC program, and if there is a number command, the number of parts up to that point is determined by the program end. Since the configuration is configured to add the number N of machined parts to the total number N of machined parts and output the addition result, the correct total number of machined parts can always be output regardless of the number of machined parts.

又、本発明によれば、枚数指令がない場合には、プログ
ラムエンド毎に1づつ累積して出力するように構成した
から、従来と同様な表示も可能である。
Further, according to the present invention, when there is no number of sheets command, the system is configured to accumulate and output one at a time at each program end, so that the same display as the conventional one is also possible.

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

第1図は本発明を実現するNC装置のブロック図、 第2図は本発明のNC装置の別のブロック図、第3図は
本発明の処理の流れ図である。 11・・NCテープ、 13・・NC本体部、 13a・・判別部、 13c・・加工部品数レジスタ、 13e・・総加工部品数レジス、 13f・・加算部、 14・・表示部
FIG. 1 is a block diagram of an NC device that implements the present invention, FIG. 2 is another block diagram of the NC device of the present invention, and FIG. 3 is a flowchart of the processing of the present invention. 11...NC tape, 13...NC main unit, 13a...discrimination section, 13c...number of machined parts register, 13e...total number of machined parts register, 13f...addition section, 14...display section

Claims (2)

【特許請求の範囲】[Claims] (1)NCプログラム中に該NCプログラムにより加工
される部品数Nを特定する枚数指令があるか判別し、 枚数指令がある場合にはプログラムエンドによりそれ迄
の総加工部品数N_Tに加工部品数Nを加算して加算結
果を出力することを特徴とする加工部品数監視方法。
(1) Determine whether there is a number command that specifies the number N of parts to be machined by the NC program in the NC program, and if there is a number command, the total number of parts machined N_T up to that point is determined by the program end. A method for monitoring the number of processed parts, characterized by adding N and outputting the addition result.
(2)枚数指令がない場合には、プログラムエンド毎に
1づつ累積して出力することを特徴とする特許請求の範
囲第1項記載の加工部品数監視方法。
(2) The method for monitoring the number of machined parts according to claim 1, characterized in that when there is no number of parts command, one is accumulated and outputted at each program end.
JP15933888A 1988-06-29 1988-06-29 Method for monitoring number of worked parts Pending JPH0210405A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP15933888A JPH0210405A (en) 1988-06-29 1988-06-29 Method for monitoring number of worked parts

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP15933888A JPH0210405A (en) 1988-06-29 1988-06-29 Method for monitoring number of worked parts

Publications (1)

Publication Number Publication Date
JPH0210405A true JPH0210405A (en) 1990-01-16

Family

ID=15691651

Family Applications (1)

Application Number Title Priority Date Filing Date
JP15933888A Pending JPH0210405A (en) 1988-06-29 1988-06-29 Method for monitoring number of worked parts

Country Status (1)

Country Link
JP (1) JPH0210405A (en)

Similar Documents

Publication Publication Date Title
JP2641797B2 (en) Interactive numerical controller
EP0150217B1 (en) Numerical control apparatus with function for checking stored stroke limit of drawing
US5619734A (en) Programmable controller and method of operation thereof
JPS6115205A (en) Drawing method of graphic display for numerical controller
US4924403A (en) Numerical control method and system therefor having override playback function
US5041985A (en) Tool changing method
US6829518B2 (en) Numerical control apparatus
JPH0573125A (en) Work monitoring system for nc machine tool
JPH0210405A (en) Method for monitoring number of worked parts
JP3251639B2 (en) Pointing device
JP2667563B2 (en) Tool axis direction calculation method
JPS60186906A (en) Automatic programming method
JPH0194404A (en) Nc data generation system
JPS60217448A (en) Data input system
JP2943177B2 (en) Drawing device for XY coordinate axes with scale numerical value
JPH10161724A (en) Numerical controller
JPH06208403A (en) Control device
JP2670088B2 (en) Design support device and design support method
JP2504551B2 (en) Error detection processing method for input data
JPH0546220A (en) Numerical controller
JPS63292304A (en) Display method for locus of tool movement in numerical controller
JP2623392B2 (en) Sensing device and output correction method thereof
JPH0728517A (en) Display control system for cnc
JP3000986B2 (en) Machining program creating device and machining program creating method
JPH06332520A (en) Display system for motor waveform of cnc