JP4059734B2 - Numerical controller - Google Patents

Numerical controller Download PDF

Info

Publication number
JP4059734B2
JP4059734B2 JP2002251597A JP2002251597A JP4059734B2 JP 4059734 B2 JP4059734 B2 JP 4059734B2 JP 2002251597 A JP2002251597 A JP 2002251597A JP 2002251597 A JP2002251597 A JP 2002251597A JP 4059734 B2 JP4059734 B2 JP 4059734B2
Authority
JP
Japan
Prior art keywords
axis
movement
corner
vector
block
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2002251597A
Other languages
Japanese (ja)
Other versions
JP2004094372A (en
Inventor
辰文 荒木
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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric 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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP2002251597A priority Critical patent/JP4059734B2/en
Publication of JP2004094372A publication Critical patent/JP2004094372A/en
Application granted granted Critical
Publication of JP4059734B2 publication Critical patent/JP4059734B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Description

【0001】
【発明の属する技術分野】
この発明は、回転軸を含む加工制御を行う数値制御装置に関し、進行方向の変化角度が大きな指令ブロックの継目における加工時に発生する切削工具の振動や指令値と実際の移動軌跡の差異を抑制した数値制御装置に関するものである。
【0002】
【従来の技術】
数値制御装置(NC装置)によって、例えばワークの切削加工を行う場合、指令に基づいてワークと工具とが相対移動されワークを加工するのであるが、例えば工具の進行方向が変化する場合(換言すればコーナ形状の加工の場合)、工具の移動につき進行方向の変化の程度を判定し(換言すればコーナ判別を行い)、変化の程度によっては指令された速度よりも減速した移動処理(減速処理)を行い、指令どおりの加工を行う必要がある。すなわち、指令どおりのコーナ形状となるように高精度加工を保証するためには、コーナ部において減速処理を行う必要がある場合が存在し、この減速処理で使われる技術にコーナ判別がある。例えば、NC指令をG91(ワークと工具の相対移動指令)、G01(切削直線移動)とした場合、
G91 G01 X10.0 F10000.0 ・・・増分値でX方向に10mmを10m/分で直線補間
G01 X10.0 Y0.1 ・・・X方向に10mm、Y方向に0.1mmを直線補間
G01 X-10.0 ・・・X方向に−10mmを直線補間
という加工プログラムは、図9に示すような軌跡を描く。この図9において、第1ブロックと第2ブロックの変化する角度θ1は小さい(コーナが緩い)ので、減速することなくF10000.0にて指定された送り速度を維持して加工しても、加工面を滑らかに保つことができるが、第2ブロックと第3ブロックのなす角度θ2は大きい(コーナがきつい)ので、F10000.0より小さな速度に減速してコーナに近づき、加速しながらコーナを出て行くという処理を行わないと、加工されたコーナの形状がだれてしまう。このため第1ブロックと第2ブロックとの角度変化及び第2ブロックと第3ブロックとの角度変化についてコーナ判別という判断を行う処理が必要となる。
【0003】
図10は、このコーナ判別処理を搭載する数値制御装置の概略構成を示すブロック図である。図10において、1は加工プログラムを格納している記憶装置、2は記憶装置1内に格納されている加工プログラムを読み込んで各ブロックの移動開始点と移動終了点の算出およびコーナ判別などを行うプログラム解析部、3はプログラム解析部2により解析された移動開始点と移動終了点に基づいて補間処理を実行し、各軸方向の移動量に分配する補間部、4は各軸方向の移動量とコーナ判別部が付加した加減速情報から移動サンプリング周期当たりの移動量を計算し、移動指令パルスを出力する移動指令パルス分配部、5は移動指令パルス分配部4からの指令を入力して、移動指令に移動があった場合に指令パルスに対して加減速処理を実行する加減速部、6は加減速部5からの信号を入力して、指令パルスを出力する指令パルス出力部、7は指令パルス出力部6からの指令パルスを入力して制御対象であるモータ8を制御する駆動部である。
【0004】
ここにおいて、プログラム解析部2は以下の3つの部分から構成されている。すなわち、21は加工プログラムを取り込み、数値制御装置が計算しやすい情報へと変換するプログラム読込部、22は各ブロックの移動開始点と移動終了点を算出するパス生成部、23はブロック間における移動ベクトルの変化量からコーナの角度変化を評価し、コーナが閾値より大きな角度変化を有する場合、コーナ付近での速度を十分小さな値にクランプするという情報を付加するコーナ判別部である。
【0005】
ここで従来のコーナ判別部23でのコーナ判別処理を、図11及び図12を参照して述べる。図11は、第1ブロックから第2ブロックへの移動に際し、移動ベクトルrn-1から移動ベクトルrnへ変化した場合の様子を示しており、加工プログラムの指令としては、G91 G01 X20 Y10 Z10からG01 X10 Y20 Z30への変更を示している。そして、従来のコーナ判別処理は、cosθ=rn・rn-1/(|rn|*|rn-1|)という余弦定理(ここではベクトルの内積を表す公式)に当てはめて、コーナ角度θを算出する。なお、図11において、cosθの式中、上式はいわゆる第2余弦定理、下式は内積の公式であるが、角度θを求める式であることは、代わりがない。また、式において|rn|は移動ベクトルrnの大きさ、"・"はベクトルの内積、rnの添え字"n"はn番目のブロックであることを意味する。
【0006】
具体的には、「G91; G01 X20 Y10 Z10; G01 X10 Y20 Z30;」というプログラム指令にあって、移動ベクトルrn-1、rnを成分で表すと、rn-1=(20,10,10)、rn=(10,20,30)となり、コーナ角度は成分表示の公式からcosθ=rn・rn-1/(|rn|*|rn-1)=(20*10+10*20+10*30)/(sqrt(202+102+102)*sqrt(102+202+302))=0.7637・・・として求めることができる。ここで、sqrt(X)はXの平方根を表す。
【0007】
この結果、コーナ判別処理としては、図12に示すようにブロック継目直前の移動ベクトルrn-1の取得を行い(ステップS301)、ついでブロック継目直後の移動ベクトルrn の取得を行う(ステップS302)。この後、余弦定理によってコーナの角θを算出する(ステップS303)。
【0008】
【発明が解決しようとする課題】
以上の説明は、直線移動のみの加工を前提にして説明したものである。すなわち、ある軸の直線移動プログラム指令が急激に変化するブロックでは、その軸のモータ出力が指令についていけないので、減速しなければいけないという判断を、コーナ角度の大小を使って判断している。しかし、加工にあたっては、移動軸として回転軸を有する場合がある。この場合、従来の数値制御装置では、直線軸のみでコーナ判別を行う場合と回転軸を含む直線軸の場合とで、コーナ判別の方法を分けることなく、同一のコーナ判別処理を行っている。
【0009】
しかし、ワークと工具の刃先のなす相対軌跡という面から考えた場合、従来の判別処理にて算出されるコーナ角度は、移動軸に回転軸が含まれる場合には、以下の様な問題のある角度計算を行ってしまう。
【0010】
すなわち、例えばC軸を回転軸としZ軸を直線軸である移動軸とした場合、「G91; G01 Z100 C90; G01 Z100 C-90;」というプログラム指令では、計算されるコーナ角度はcosθ=rn・rn-1/(|rn|*|rn-1)=(100*100+90*-90)/(sqrt(1002+902)*sqrt(1002+902))=0.10497・・・と計算される。従って、従来のコーナ判別処理によって算出されるコーナ角度は、工具やワークの形状に拘らず、軸の移動量が同じ場合には、常に同じコーナ判別を行ってしまうことになる。
【0011】
ところが、図13のように、半径の大きさが極端に異なる2種類のワークA、Bを想定してみれば明らかであるが、ワークAもワークBも「G91; G01 Z100 C90; G01 Z100 C-90;」というブロックを実行しており、刃先とワークの相対軌跡、つまり切削が行われていく軌跡は、“G01 Z100 C90;”のブロックが矢印▲1▼、“G01 Z100 C-90;”のブロックが矢印▲2▼で表されているにも拘らず、矢印▲1▼と矢印▲2▼のなす角度θは、軸回転にかかわる周速度の違いから半径が小さいワークBよりも半径の大きいワークAの方が鋭くなっている。このように、従来のコーナ判別では、回転軸が含まれる場合に正しいコーナ判別を行うことができない。
【0012】
なお、回転軸制御の従来例として特開平4−340604号公報記載の技術があるが、この技術(特開平4−340604)は速度制御の判断を行うのが目的であり、ブロック間のコーナ角度を算出するものでなく、更には、回転軸が直交3軸上で任意の方向にある場合(例えば、本発明にて後述する(x,y,z)=(1,2,3)という斜めの方向ベクトルをもつ軸の回りに旋回する場合)などを含めた、一般的なベクトル変換を扱うものでもない。
【0013】
さらに、上述のコーナ判別処理が正しくできたと仮定して、隣接するブロックの移動ベクトルのなす角度に基づいて加減速処理を行う場合、従来では軸構成と軸動作に応じた加減速処理を適切に切替える機能を持っていないという点も問題である。つまり、どの回転軸がどの直線軸の周りを回転するかという軸構成の把握と、現在どの軸を動かしているかという動作状態の把握とに基づく切替え作業が、回転軸の影響を加減速処理に効率よく反映させるために必要不可欠となる。
【0014】
例えば、X,Y,Z,B,Cの5軸(図4参照)を有するNC工作機械において、XとBの2軸を同時に動かしている状態ではB軸が旋回することにより、X,Z平面での移動が行われるので、B軸旋回によるXの移動と、最初から存在するX軸の指令による移動とが干渉してしまい、3次元のベクトル演算による換算が必要である。他方、ZとCの2軸を動かしている状態では、このような干渉はおこらず、C軸旋回によるX,Y平面上の移動と、Z軸の指令による移動は独立した平面で行われることになり、1次元のスカラー演算による換算で十分である。ここで、干渉とは、例えばC軸が移動する場合、C軸はZ軸を旋回中心として回転するので、Z軸の座標値はC軸回転による影響を受けないが、X軸とY軸の座標値はC軸が回転することで変化してしまうことをいい、このようにある軸の回転が他の軸の座標値に影響を及ぼしてしまう場合、“干渉する”と判断される。
【0015】
こうして、上述のように直線軸と回転軸が同時に動いていると言っても、回転軸移動の換算を3次元ベクトルで演算しなければいけない場合と、1次元の演算で済ませることが可能な場合の2種類が存在する。そして、スカラー演算を行うだけで回転軸の影響を正しく換算することができるという1次元の演算で済ませることが可能な場合には、ベクトル演算を用いたコーナ判別処理を行うことは計算ステップ数の無駄をもたらし、また実際上、3次元のベクトル演算でも、1次元のスカラー演算でも、求まるコーナ角度としては同一となっている。
【0016】
更に、回転軸を搭載している機械でも、直線軸だけで加工を行っている状態の時は、回転軸移動量の換算自体が全く不必要となる。
【0017】
こうして、計算の無駄を防ぐという目的からすれば、軸構成と軸動作に応じた加減速処理にあって、1次元のスカラー演算で回転軸移動量の換算を行う処理機構、及び、どの加減速処理を選択するのが適切かを判断する処理機構(ベクトル演算が必要かスカラー演算で十分か、或いは換算自体が必要ないかといったことを判断する処理機構)が必要である。
【0018】
この発明は上記に鑑みてなされたもので、移動軸に回転軸を含む場合でも正しいコーナ判別を行い、また制御する軸が直線軸のみの場合、回転軸が含まれる場合、それぞれの場合に応じて、適切なコーナ加減速を行う数値制御装置を提供することを目的とする。
【0019】
【課題を解決するための手段】
上記目的を達成するため、この発明にかかる数値制御装置は、直線軸と回転軸の両方を含む工作機械を制御する数値制御装置において、2つの連続するブロック間のコーナ加減速処理を行う際に、この連続するブロックの回転軸の移動ベクトルを直交3軸座標系における移動ベクトルに換算する手段と、この換算されたベクトルを角度算出演算に当てはめてコーナ角度を求める手段と、を含むコーナ加減速処理機能を有することを特徴とする。
【0020】
また、この発明は、上記の発明において、連続するブロックの回転軸の移動ベクトルを直交3軸座標系における移動ベクトルに換算することなく前記連続するブロックの移動ベクトルを直接前記角度算出演算に当てはめてコーナ角度を求める第2の手段と、移動ベクトルが回転軸の移動を伴うか否かを判断する判断手段と、この判断手段にて移動ベクトルが回転軸の移動を伴うと判断されたとき、前記コーナ加減速処理を行う処理に切替え、前記判断手段にて移動ベクトルが回転軸の移動を伴わないと判断されたとき、前記第2の手段で求めたコーナ角度に基づくコーナ加減速処理を行う処理に切替える切換手段とを備えてなることを特徴とする。
【0027】
【発明の実施の形態】
以下に添付図面を参照して、この発明にかかる好適な実施の形態を詳細に説明する。まず、正しいコーナの判別処理を行うにあたって、図13に示すようなワークAとBにおける角度θの大きさが違う処理をNC装置に行わせるに当たっては、発明者は次のように着眼した。ワークAとBの切削軌跡を見た人が測定する角度θは、切削軌跡を直行3軸空間上での移動として観測した角度である。この場合の測定作業では、直線軸と回転軸がどのように動いたかを考えるのではなく、このそれぞれの軸が動いた結果として、切削軌跡は直行3軸空間上でどう変化していったのかということを測定している。従来のコーナ判別処理は、回転軸と直線軸が動いたときに、「結果として直行3軸空間上でどう動いたか」という置き換えをする手段を持たないので、図13の説明にて述べたようにワークAとBにおけるワークと刃物の相対軌跡が描く角度を正しく算出することができない。つまり、コーナ角度θを正しく求めるためには、回転軸の回転による移動量を直交3軸上での移動量に変換するという前処理をすればよい。従って、回転軸の回転による移動の影響を直交3軸上の移動に換算してしまえば、その換算された移動ベクトルを従来のコーナ判別処理(移動ベクトルを余弦定理に代入しコーナ角度を求める処理)に当てはめることができる。このために発明者は、ブロックの継目での加工点の位置ベクトルである刃先点位置ベクトルrtと角移動ベクトルΔθiとの外積という概念を導入し回転軸の回転による移動の影響を直交3軸上の移動に換算した。
【0028】
実施の形態1.
図1は、この発明の実施の形態1である数値制御装置におけるフローチャートである。このフローチャートの実行に当たり、具体例として、半径100[mm]、長さ300[mm]の円柱状ワークに対して、プログラム指令「G91; G01 Z100. C90.; G01 Z100. C-90.;」を実行した場合を図2を用いて説明する。図2において、まずコーナ加減速の要否を判定するために求める角度θとは、プログラムの第2ブロックと第3ブロックの継目のなす角度のことで、接線tn-1とtnのなす角度のことである。
【0029】
この場合、ブロックの継目での加工点の位置ベクトルである刃先点位置ベクトルrtは、図2における原点からブロック継目の点Ptに向かうベクトルに対応する。ここでは、このブロックを動かす前に刃先が(X, Y, Z, C)=(0, 100, 0, 0)にあったと仮定して、ブロック継目での刃先点の位置はrt=(0, 100, 100, 90)となる。
【0030】
他方、回転軸(今回のプログラム例ではC軸)に対応する旋回中心軸(プログラム例ではC軸の旋回中心軸、つまりZ軸)の方向をベクトルの方向に持ち、回転速度の大きさ(プログラム例では90[deg/min] = π/2[rad/min])をスカラー量に持つベクトルを角移動ベクトルΔθiとした。ここで、Δθi についてインデックス番号iをA軸について1、B軸について2、C軸について3とすると、今回のプログラムの第2ブロック(G01 Z100. C90.)ではΔθ3は(0, 0, π/2)となり、A軸とB軸は指令していないので、Δθ1とΔθ2は(0, 0, 0)となる。同様に、第3ブロック(G01 Z100. C-90.)では、Δθ1とΔθ2は(0, 0, 0)となり、Δθ3は(0, 0, -π/2)となる。
【0031】
図1において、ステップS101にて刃先点位置ベクトルrtをまず取得する。ついで、ステップS102にて角移動ベクトルΔθiを求める。そして、ステップS103にて外積rd=Δθi×rtiを求める。ここで、rtiは図2での回転軸の旋回中心軸上(Z軸上)の1点Pi0からrtで示す刃先点へと向かうベクトルである。ここでPi0は旋回中心軸上であれば、どの点でも構わず、今回の例ではP30を(0, 0, 0)にとる。この場合、rt3=(0, 100, 100)となる。
【0032】
Δθi、rtiの外積(Δθi×rti)によって、回転軸iの回転による移動量を(X, Y, Z)の直交3軸空間での移動量に換算することができる。今回の例では第2ブロックでのΔθ3=(0, 0, π/2)、rt3=(0, 100, 100)なので、外積による成分計算式から、Δθ3×rt3=(−100π/2, 0, 0)となる。
【0033】
そして、A軸、B軸、C軸については、換算した移動量をi=1〜3に関して足し合わせれば、つまりrd=Σ(Δθi×rti)を計算すれば、回転軸全体の移動量を直交3軸空間上のベクトルに換算できることとなる。今回の図2の例ではΔθ1=Δθ2=(0, 0, 0)なので、rd=Δθ3×rt3となる。
【0034】
そして、ステップS104に示すように換算ベクトルrdとプログラムの軸アドレスから直接求められる(X, Y, Z)の移動ベクトルrlの和rn=rl+rdを得ることで、移動に回転軸が含まれる場合でも、刃先点とワークの相対軌跡が、(X, Y, Z)の直交3軸空間において、どう変化するかを正確に求めることができる。図3はこのベクトル合成の様子を表しており、図2のPt近傍で第2ブロックの描くベクトルrnは直線軸移動によるrlと回転軸移動による換算ベクトルrdの和で表されることになる。
【0035】
このプログラムの第2ブロックではrl=(0, 0, 100)であるので、第2ブロックと第3ブロックの継目において第2ブロックの移動が作る刃先点とワークの相対軌跡はrn=(−100π/2, 0, 100)となる。同様に第3ブロック側の相対軌跡はrn=(100π/2, 0, 100)となる。なお、識別を分かりやすくするため、以後は第2ブロックの相対軌跡をrn-1、第3ブロックの相対軌跡をrnとする。
【0036】
この結果、ステップS105では、コーナ角度の式cosθ=rn・rn-1/(|rn|*|rn-1)からコーナ角度を算出する。このプログラム例では、cosθ=−0.3355・・・となり、所望のコーナ角度が算出される。
【0037】
図1のフローチャートによるコーナ角度算出の例として、上述の如くZ軸とC軸のみが動くという最も簡単な場合を用いて説明したが、このフローチャートは回転軸2軸以上を含む5軸以上を同時に動かす場合にも適用することができる。例えば図4に示す座標軸構成のように5軸X,Y, Z,B,Cの移動についてプログラム指令「G90 G01 X0. Y0. Z0. B0. C0.; G01 X100. Y100. Z100. B-45. C90.; G01 X-100. Y200. Z200. B30. C-90.;」という場合も、図1のフローチャートを用いれば、(X, Y, Z)の直交3軸空間での移動ベクトルに換算できる。
【0038】
以下にこのプログラム指令に基づき第2ブロックと第3ブロックの継目におけるコーナ角度の算出方法を説明する。この図4の座標系の特徴として、B軸とC軸がそれぞれY軸、Z軸を旋回中心にしていることがあげられる。つまり、回転軸の旋回中心が、原点を通る軸であるということが特徴である。
【0039】
まず、ステップS101の刃先点位置ベクトルrtは、(X, Y, Z)=(100, 100, 100)となる。また、ステップS102において、第2ブロック側の角移動ベクトルΔθiはΔθ1=(0, 0, 0)、Δθ2=(0, −π/4, 0)、Δθ3=(0, 0, π/2)となる。同様に第3ブロック側のΔθiはΔθ1=(0, 0, 0)、Δθ2=(0, π/6, 0)、Δθ3=(0, 0, −π/2)となる。更に、ステップS103において、旋回中心軸から刃先点に向かうベクトルrtiはP20を(0, 100, 0)にとってrt2=(100, 0, 100)、P30を(0, 0, 100)にとってrt3=(100, 100, 0)となる。rt1については第2ブロックも第3ブロックもΔθ1=0なので考え得る必要はない。このとき第2ブロック側の外積rdは外積による成分計算式からrd=Σ(Δθi×rti)=(Δθ2×rt2 + Δθ3×rt3)=(−300π/4, 100π/2, 100π/4)となる。同様に第3ブロック側の外積rdはrd=(500π/6, −100π/2, 100π/6)となる。ステップS104にて、第2ブロックのベクトルrl は、rl=(100, 100, 100)、第3ブロックでは(−100, 200, 200)である。これ以後の処理は加工プログラムによらず同じであり、和rn=rl+rdを求め、ステップS105にてコーナ角度を求める。こうして、5軸同時制御の場合にも適用可能である。
【0040】
更に、一般的な場合として、回転するワークの旋回中心軸(x,y,z)=(10,20,30)を通り、(x,y,z)=(1,2,3)の方向にある任意の回転軸を考える。この回転軸をW軸と呼ぶとして、プログラム指令「G90 G01 X0. Y0. Z50. W0.; G01 X100. Y100. Z150. W-180.; G01 X-100. Y200. Z250. W180.;」を実行した時の第2ブロックと第3ブロックのなす角度を計算する。ここで、使用している工具がZ方向に50の長さを持つとすると、刃先点位置ベクトルrt=(rtx, rty, rtz)=(0, 100, 100)となる。
【0041】
この場合、図1のステップS102における角移動ベクトルΔθiは、W軸に対するインデックス番号iを1とすると、W軸方向にて第2ブロックではΔθ1=(−π/sqrt(14), −2π/sqrt(14), −3π/sqrt(14))、Δθ2=Δθ3=Δθ4=Δθ…=(0, 0, 0)となる。同様に第3ブロックではΔθ1=(π/sqrt(14), 2π/sqrt(14), 3π/sqrt(14))、Δθ2=Δθ3=Δθ4=Δθ…=(0, 0, 0)となる。
【0042】
また、P10を(10, 20, 30)にとると、旋回中心軸から刃先点に向かうベクトルは、rt1=(90, 80, 70)となる。このとき第2ブロック側の外積rdはrd=Σ(Δθi×rti)=(Δθ1×rt1)=(100π/sqrt(14), −200π/sqrt(14), 300π/sqrt(14))となる。同様に第3ブロック側の外積rdはrd=(−100π/sqrt(14), 200π/sqrt(14), −300π/sqrt(14))となる。
【0043】
ステップS104において、第2ブロックのrl=(100, 100, 100)、第3ブロックはrl= (−200, 100, 100)であり、和rn=rl+rdを求める。そして、ステップS105にてコーナ角度を求める。こうして、任意の軸構成に対応可能なコーナ角度算出手段を提供することができる。
【0044】
実施の形態2.
次に、実施の形態2にて回転軸の移動量に倍率を乗ずるコーナ加減速処理を有する数値制御装置について説明する。実施の形態1(ベクトル換算を用いたコーナ加減速処理を行う数値制御装置)では、ワークと刃物の相対軌跡の変化に対して、回転軸が及ぼす影響を3次元のベクトルで計算し、この結果どんな軸構成のNC装置に対しても、一般的に相対軌跡を算出することができる。しかし例えば、回転軸1軸(C軸)と直線軸2軸(X,Z軸)からなるようなNCにおいて、ZとCのみで動かすときに、ワークの大きさ(半径)が既知の場合では、1次元の掛算を回転軸の移動量に対して行うだけで、回転軸の及ぼす影響を適切に計算することができる場合もある。この場合、回転軸(C軸)を移動させることによって生じるワークと刃物の相対軌跡の変化と、Z軸を移動させることによって生じる相対軌跡の変化は、それぞれXY平面での変化と、Z軸上での変化に分離されている。従って、回転軸の移動量にワークの半径を乗じた移動量は、XY平面での実際の相対軌跡の変化量と一致する。つまり、回転軸の移動量に倍率をかけるというスカラー演算を行うだけで回転軸の影響を正しく換算することができるために、この半径を乗じた移動量とZ軸の移動量を従来の余弦定理の計算式に代入することにより、実施の形態1(ベクトル換算を用いたコーナ加減速処理を行う数値制御装置)を用いた場合の結果と同一の角度を算出することができる。
【0045】
図5はこの実施の形態2(回転軸の移動量に倍率を乗ずるコーナ加減速処理を有する数値制御装置)を実現するフローチャートである。プログラム指令「G91; G01 Z100. C90.; G01 Z100. C-90.;」を例に説明する。図5において、S1001に従い、回転軸(このプログラムではC軸)の移動量にある倍率をかける。この倍率は通常、ワークの半径に比例した値を用いるのが適切であり、ここでは予めワークを計測した結果、倍率が3に設定されているとする。このとき第2ブロックの移動ベクトルはrn-1=(Z, C)=(100, 270)、第3ブロックはrn= (Z, C)=(100, -270)となる。
【0046】
次いでステップS1002では、cosθ=rn・rn-1/(|rn|*|rn-1)からコーナ角度を算出する。この例では、cosθ=−0.7587となる。
【0047】
実施の形態3.
つぎに、この発明の実施の形態3(回転軸移動量の倍率を切替える数値制御装置)について説明する。実施の形態2においては、回転軸の移動に乗ずる倍率の選び方として、ワークの半径に比例させたのであるが、モータ出力の遅れや、ワークの方向による硬度の違いが及ぼす影響などを経験的に把握している場合、ある特定の倍率を使用したほうが高精度の加工ができる。このため、パラメータまたはプログラムによって、倍率を任意に設定することも必要となる。図6は実施の形態3の倍率算出部分を搭載した場合のコーナ加減速処理、図7はその倍率算出部分のフローチャートである。以下に図7を説明する。
【0048】
ステップS1201では、倍率の計算をNC装置に自動で行わせるモード(倍率自動計算モードと呼ぶことにする)にあるか否かを判断し、その後の処理を分ける。このモードのON/OFFは、NCの内部変数にフラグとして持たせればよく、例えば増分値/絶対値切替のような機能をつければ実現できる。ここではプログラムによってON/OFFを制御することとする。
【0049】
ステップS1201で倍率自動計算モードONの場合は、ステップS1202で示す倍率計算を行う。ここでは、刃先点と各回転軸の距離を計算し、(距離×π/180)を倍率とする。例えば、X、Y、Z、B、Cの5軸を有し、B軸回りに工具が回転するNC工作機を例に挙げると、B軸に対応する距離は工具長、C軸に対応する距離はsqrt(X2+Y2)となる(但し、X、Y、Zはそれぞれ刃先のX、Y、Z座標である)。このNC工作機において、プログラム指令「G91; G01 Z100. C90.; G01 Z100. C-90.;」を実行した場合について述べれば、ここで、プログラム開始時に刃先が(X, Y, Z, B, C)=(30, 40, 0, 90, 0)にあるものとする。プログラムの第2ブロックと第3ブロックの継目において、移動する回転軸はC軸のみであり、C軸と刃先点との距離はsqrt(302+402)=50となる。従って、C軸に対応する倍率は(距離×π/180)=(50×π/180)となる。
【0050】
ステップS1201にて、倍率自動計算モードOFFの場合は、ステップS1203で示す条件判断を行う。例えば倍率の指定をするコードが「M2001 P_ Q_ R_;」であるとし、P、Q、RはそれぞれA、B、C軸に対応する倍率であるとするとき、ステップS1203においてM2001のモード中はステップS1204に示す倍率設定を行う。そして、ステップS1204はP、Q、Rのアドレスで指定した数値を各回転軸の倍率としてセットする。
【0051】
ステップS1203でプログラム指定でない場合は、ステップS1205で示す倍率設定を行う。この処理は予めパラメータとしてNCに登録しておいた倍率を各回転軸の倍率にセットする。
【0052】
以上に説明したステップS1201〜S1205の処理によって、回転軸の移動量に対する倍率を求めることができる。
【0053】
実施の形態4.
次に実施の形態4である制御対象軸の軸構成に応じて使用する加減速処理を変更できる数値制御装置について説明する。図8は実施の形態4を実現するフローチャートの一つである。図8において、まずステップS1301で制御軸に関する情報を取得する。ここでの情報とはどの軸が回転軸で、回転軸に対応する旋回中心軸はどれか(例えばC軸に対応する軸はZ軸)といった情報である。
【0054】
ステップS1302ではステップS1301で得た制御軸の情報と、読み込んだ加工プログラムの移動軸に関する情報を照合し、加工プログラムのブロック継目の前後で回転軸が移動するか否かを判断し、以後の処理を振り分ける。このステップS1302にて、移動軸に回転軸が無い場合は、回転軸の影響を計算するという無駄な処理を省き、ステップS1306のコーナ加減速処理▲3▼を呼び出す。この加減速処理▲3▼は軸の種類を考慮しない従来型のコーナ加減速処理であり、例えば従来の技術で紹介した余弦定理を用いる方法が該当する。他方、回転軸が移動する場合はステップS1303の判断処理ルーチンを呼び出す。
【0055】
ステップS1303では回転軸の移動指令と直線軸の移動指令が干渉するか否かを判断する。干渉する軸の組み合わせとしては、1:A軸とY、Z軸 2:B軸とZ、X軸 3:C軸とX、Y軸 といった組み合わせがある。従って、「G01 X100. C200.」のように同一ブロック中に干渉する軸が指令されている場合は、移動指令が“干渉する”と判断される。
【0056】
ステップS1303にて軸移動の干渉が起こる場合は、回転軸移動の影響を直行3軸上の移動ベクトルに換算してからでなければ、正しいコーナ加減速を行うことが出来ないので、ステップS1304に示すコーナ加減速処理▲1▼を呼び出す。このコーナ加減速処理▲1▼はベクトル換算を用いたコーナ加減速処理である。干渉が起こらない場合は、回転軸の移動は独立した直線軸と見なした扱いが可能で、ステップS1305に示すコーナ加減速処理▲2▼を呼び出す。このコーナ加減速処理▲2▼は回転軸の移動量に倍率を乗ずるコーナ加減速処理である。
【0057】
こうして、ステップS1304〜S1306に示すコーナ加減速処理を経て、コーナ付近で減速が必要か否かが判断される。その判断結果を元にステップS1307でモータに指令する移動速度を決定する。
【0058】
【発明の効果】
以上説明したように、この発明によれば、移動制御軸に回転軸を含む数値制御装置において、回転軸の移動を含むコーナ加減速を行う際に、隣接するブロックにおける回転軸の移動ベクトルを直交3軸における移動ベクトルに換算する手段と、この換算されたベクトルを角度算出演算に当てはめてコーナ角度を求める手段とを含むコーナ加減速処理機能を有することにより、移動軸に回転軸を含む場合でもワークと刃物の相対軌跡、つまり加工点が実際に描くコーナ角度を計算することができ正しいコーナ判別を行うことができる。
【図面の簡単な説明】
【図1】 この発明の実施の形態1の処理手順を表すフローチャートである。
【図2】 回転軸の移動ベクトルを直交3軸における移動ベクトルに換算する際の変数の取扱いを説明する図である。
【図3】 ベクトルの合成の様子を説明する図である。
【図4】 具体例における座標軸のとり方を説明する図である。
【図5】 この発明の実施の形態2の処理手順を表すフローチャートである。
【図6】 図5のフローチャートに実施の形態3を搭載した場合の処理手順を表すフローチャートである。
【図7】 実施の形態3の処理手順を表すフローチャートである。
【図8】 実施の形態4を実現する処理手順を表すフローチャートである。
【図9】 コーナ角度の説明をする図である。
【図10】 コーナ加減速機能を搭載する数値制御装置(CNC)の概略構成を示すブロック図である。
【図11】 従来のコーナ加減速方式における余弦定理の使用の仕方を補足する図である。
【図12】 従来の余弦定理を使ったコーナ加減速方式のフローチャートである。
【図13】 従来のコーナ加減速方式が抱える問題を説明する図である。
【符号の説明】
2 プログラム解析部、21 プログラム読み込み部、22 パス生成部、23 コーナ判別部、rn、rn-1 移動ベクトル、rt 刃先点位置ベクトル、Δθi 角移動ベクトル、rd 外積。
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a numerical control device that performs machining control including a rotation axis, and suppresses a difference between a cutting tool vibration and a command value that occur during machining at a joint of a command block having a large change angle in a traveling direction and an actual movement locus. The present invention relates to a numerical control device.
[0002]
[Prior art]
For example, when a workpiece is cut by a numerical control device (NC device), the workpiece and the tool are moved relative to each other based on the command to process the workpiece. For example, when the traveling direction of the tool changes (in other words, For example, in the case of corner-shaped machining), the degree of change in the advancing direction is determined as the tool moves (in other words, corner discrimination is performed). ) And processing as directed. That is, there is a case where it is necessary to perform a deceleration process in the corner portion in order to ensure high-precision machining so as to obtain a corner shape as instructed, and there is corner discrimination as a technique used in this deceleration process. For example, if the NC command is G91 (relative movement command of workpiece and tool), G01 (cutting linear movement),
G91 G01 X10.0 F10000.0 ・ ・ ・ Linear interpolation at 10m / min for 10mm in X direction with increment value
G01 X10.0 Y0.1 ・ ・ ・ Linear interpolation 10mm in X direction and 0.1mm in Y direction
G01 X-10.0 ・ ・ ・ Linear interpolation of −10mm in the X direction
That is, the machining program draws a locus as shown in FIG. In FIG. 9, the changing angle θ between the first block and the second block1Is small (the corners are loose), so that the machined surface can be kept smooth even when machining with the feed rate specified in F10000.0 maintained without deceleration. The angle θ2Is large (the corner is tight), so if you do not perform the process of decelerating to a speed smaller than F10000.0, approaching the corner, and exiting the corner while accelerating, the shape of the processed corner will bend. For this reason, it is necessary to perform a process of determining corner determination for the change in angle between the first block and the second block and the change in angle between the second block and the third block.
[0003]
FIG. 10 is a block diagram showing a schematic configuration of a numerical control device equipped with this corner discrimination processing. In FIG. 10, 1 is a storage device storing a machining program, 2 is reading a machining program stored in the storage device 1, and calculates the movement start point and movement end point of each block, corner determination, etc. The program analysis unit 3 performs interpolation processing based on the movement start point and the movement end point analyzed by the program analysis unit 2, and distributes the movement amount in each axis direction. And a movement command pulse distribution unit that calculates a movement amount per movement sampling period from the acceleration / deceleration information added by the corner determination unit and outputs a movement command pulse, 5 receives a command from the movement command pulse distribution unit 4, An acceleration / deceleration unit that executes acceleration / deceleration processing on the command pulse when the movement command is moved, and 6 is a command pulse output unit that inputs a signal from the acceleration / deceleration unit 5 and outputs a command pulse. 7 is a driving unit that controls the motor 8 to be controlled by entering the command pulses from the command pulse output section 6.
[0004]
Here, the program analysis unit 2 is composed of the following three parts. That is, 21 is a program reading unit that takes a machining program and converts it into information that can be easily calculated by the numerical control device, 22 is a path generation unit that calculates the movement start point and movement end point of each block, and 23 is a movement between blocks. It is a corner discriminating unit that adds information that clamps the speed near the corner to a sufficiently small value when the corner angle change is evaluated from the vector change amount and the corner has an angle change larger than a threshold value.
[0005]
Here, a corner discrimination process in the conventional corner discrimination unit 23 will be described with reference to FIGS. FIG. 11 shows a movement vector r when moving from the first block to the second block.n-1Move vector rnThe machining program command indicates a change from G91 G01 X20 Y10 Z10 to G01 X10 Y20 Z30. Then, the conventional corner discrimination processing is performed by cos θ = rn・ Rn-1/ (| Rn| * | rn-1The corner angle θ is calculated by applying the cosine theorem (here, a formula representing the inner product of vectors). In FIG. 11, in the equation of cos θ, the upper equation is a so-called second cosine theorem, and the lower equation is an inner product formula, but there is no substitute for calculating the angle θ. Also, in the expressionn| Is the movement vector rn, "·" Is the inner product of vectors, rnThe subscript "n" means the nth block.
[0006]
Specifically, in the program command “G91; G01 X20 Y10 Z10; G01 X10 Y20 Z30;”, the movement vector rn-1, RnIs expressed as a component, rn-1= (20,10,10), rn= (10, 20, 30), and the corner angle is cos θ = r from the component display formulan・ Rn-1/ (| Rn| * | rn-1) = (20 * 10 + 10 * 20 + 10 * 30) / (sqrt (202+102+102) * Sqrt (102+202+302)) = 0.7637... Here, sqrt (X) represents the square root of X.
[0007]
As a result, the corner discrimination process includes a movement vector r immediately before the block joint as shown in FIG.n-1Is acquired (step S301), and then the movement vector r immediately after the block joint is obtained.n Is acquired (step S302). Thereafter, the corner angle θ is calculated by the cosine theorem (step S303).
[0008]
[Problems to be solved by the invention]
The above description is based on the premise of processing only with linear movement. That is, in a block in which a linear movement program command for a certain axis changes abruptly, the motor output of that shaft cannot follow the command, so the determination that the vehicle must decelerate is determined using the size of the corner angle. However, in processing, there is a case where a rotation axis is provided as a movement axis. In this case, in the conventional numerical control device, the same corner determination processing is performed without dividing the corner determination method between the case where the corner determination is performed only with the linear axis and the case where the linear axis includes the rotation axis.
[0009]
However, considering the relative trajectory between the workpiece and the cutting edge of the tool, the corner angle calculated in the conventional discrimination process has the following problems when the rotation axis is included in the movement axis: The angle is calculated.
[0010]
That is, for example, when the C axis is a rotation axis and the Z axis is a moving axis that is a linear axis, the calculated corner angle is cos θ = r in the program command “G91; G01 Z100 C90; G01 Z100 C-90;”n・ Rn-1/ (| Rn| * | rn-1) = (100 * 100 + 90 * -90) / (sqrt (1002+902) * Sqrt (1002+902)) = 0.10497... Therefore, the corner angle calculated by the conventional corner discrimination process always performs the same corner discrimination regardless of the shape of the tool or workpiece when the movement amount of the shaft is the same.
[0011]
However, as shown in FIG. 13, it is obvious if two types of workpieces A and B having extremely different radii are assumed, but both workpiece A and workpiece B are “G91; G01 Z100 C90; G01 Z100 C”. -90; "is executed, and the relative trajectory between the cutting edge and the workpiece, that is, the trajectory in which cutting is performed, is indicated by the arrow" 1 ▼ "," G01 Z100 C-90; " The angle θ formed by the arrows (1) and (2) is larger than that of the work B having a smaller radius due to the difference in the peripheral speed related to the shaft rotation. The larger work A is sharper. As described above, in the conventional corner discrimination, correct corner discrimination cannot be performed when the rotation axis is included.
[0012]
As a conventional example of rotating shaft control, there is a technique described in Japanese Patent Laid-Open No. 4-340604. This technique (Japanese Patent Laid-Open No. 4-340604) is intended to determine speed control, and a corner angle between blocks. Further, when the rotation axis is in an arbitrary direction on three orthogonal axes (for example, (x, y, z) = (1,2,3) described later in the present invention) It does not deal with general vector conversion, including the case of turning around an axis having a directional vector.
[0013]
Furthermore, assuming that the above-described corner determination processing has been correctly performed, when performing acceleration / deceleration processing based on the angle formed by the movement vectors of adjacent blocks, conventionally, acceleration / deceleration processing according to the shaft configuration and the shaft operation is appropriately performed. Another problem is that it does not have a switching function. In other words, the switching work based on the understanding of the axis configuration of which rotating shaft rotates around which linear axis and the operating state of which axis is currently being moved can be used for acceleration / deceleration processing. It is indispensable to reflect efficiently.
[0014]
For example, in an NC machine tool having 5 axes of X, Y, Z, B, and C (see Fig. 4), the X axis and Z axis are swung while the X axis and B axis are moving simultaneously. Since the movement in the plane is performed, the movement of X by the B-axis rotation interferes with the movement of the X-axis command that exists from the beginning, and conversion by three-dimensional vector calculation is necessary. On the other hand, when the two axes of Z and C are moving, such interference does not occur, and movement on the X and Y planes by turning the C axis and movement by command of the Z axis are performed on independent planes. Therefore, conversion by a one-dimensional scalar calculation is sufficient. Here, the interference is, for example, when the C axis moves, the C axis rotates around the Z axis, so that the coordinate value of the Z axis is not affected by the rotation of the C axis, but the X axis and the Y axis The coordinate value is said to change due to the rotation of the C axis. When the rotation of one axis affects the coordinate value of another axis as described above, it is determined that the interference occurs.
[0015]
Thus, even if the linear axis and the rotary axis are moving simultaneously as described above, the conversion of the rotary axis movement must be calculated with a three-dimensional vector, and the one-dimensional calculation can be performed. There are two types. Then, if it is possible to perform a one-dimensional calculation that can correctly convert the influence of the rotation axis only by performing a scalar calculation, performing a corner determination process using a vector calculation is the number of calculation steps. This is wasteful, and in fact, the obtained corner angle is the same whether it is a three-dimensional vector operation or a one-dimensional scalar operation.
[0016]
Further, even in a machine equipped with a rotary shaft, when the machining is performed only with the linear shaft, conversion of the rotary shaft moving amount itself is completely unnecessary.
[0017]
Thus, for the purpose of preventing calculation waste, in the acceleration / deceleration processing according to the axis configuration and the axis operation, a processing mechanism for converting the rotational axis movement amount by one-dimensional scalar calculation, and which acceleration / deceleration A processing mechanism that determines whether it is appropriate to select a process (a processing mechanism that determines whether vector calculation is necessary, scalar calculation is sufficient, or conversion itself is not necessary) is required.
[0018]
The present invention has been made in view of the above. Even when the moving shaft includes a rotating shaft, correct corner discrimination is performed, and when the controlled shaft is only a linear shaft, the rotating shaft is included. An object of the present invention is to provide a numerical control device that performs appropriate corner acceleration / deceleration.
[0019]
[Means for Solving the Problems]
  In order to achieve the above object, a numerical control device according to the present invention is a numerical control device for controlling a machine tool including both a linear shaft and a rotary shaft.AndWhen corner acceleration / deceleration processing between two consecutive blocks is performed, means for converting the movement vector of the rotation axis of the continuous block into a movement vector in an orthogonal three-axis coordinate system, and an angle calculation operation for the converted vector And a corner acceleration / deceleration processing function including a means for obtaining a corner angle.
[0020]
  Further, according to the present invention, in the above invention, the movement vector of the continuous block is directly applied to the angle calculation calculation without converting the movement vector of the rotation axis of the continuous block into the movement vector in the orthogonal triaxial coordinate system. A second means for obtaining a corner angle; a judging means for judging whether or not the movement vector is accompanied by a movement of the rotation axis; and when the judgment means judges that the movement vector is accompanied by a movement of the rotation axis, Switching to processing for performing corner acceleration / deceleration processing, and processing for performing corner acceleration / deceleration processing based on the corner angle obtained by the second means when the determination means determines that the movement vector does not involve movement of the rotating shaft And a switching means for switching to.
[0027]
DETAILED DESCRIPTION OF THE INVENTION
Exemplary embodiments of the present invention will be described below in detail with reference to the accompanying drawings. First, when performing correct corner determination processing, the inventor has focused on the following when the NC apparatus performs processing in which the angle θ of the workpieces A and B is different as shown in FIG. An angle θ measured by a person who sees the cutting trajectories of the workpieces A and B is an angle obtained by observing the cutting trajectory as a movement in an orthogonal three-axis space. The measurement work in this case does not consider how the linear axis and the rotary axis moved, but how the cutting locus changed in the orthogonal 3-axis space as a result of the movement of each axis. It measures that. Since the conventional corner discrimination process does not have a means for replacing "how it moves in the orthogonal 3-axis space" when the rotation axis and the linear axis move, as described in the explanation of FIG. In addition, the angle drawn by the relative trajectory of the workpiece and the blade in the workpieces A and B cannot be calculated correctly. In other words, in order to correctly obtain the corner angle θ, a pre-process for converting the movement amount due to the rotation of the rotation shaft into the movement amount on the three orthogonal axes may be performed. Therefore, if the influence of the movement due to the rotation of the rotation axis is converted into a movement on three orthogonal axes, the converted movement vector is converted into a conventional corner discrimination process (a process for obtaining a corner angle by substituting the movement vector into the cosine theorem). ). To this end, the inventor has determined that the cutting edge point position vector r, which is the position vector of the machining point at the block seam.tAnd angular movement vector ΔθiThe concept of the outer product is introduced, and the effect of movement due to rotation of the rotating shaft is converted to movement on three orthogonal axes.
[0028]
Embodiment 1 FIG.
FIG. 1 is a flowchart in the numerical control apparatus according to the first embodiment of the present invention. In executing this flowchart, as a specific example, a program command “G91; G01 Z100. C90 .; G01 Z100. C-90 .;” is applied to a cylindrical workpiece having a radius of 100 [mm] and a length of 300 [mm]. The case of executing is described with reference to FIG. In FIG. 2, the angle θ obtained for determining whether or not corner acceleration / deceleration is necessary is an angle formed by the joint between the second block and the third block of the program.n-1And tnIt is the angle formed by
[0029]
In this case, the cutting edge point position vector r, which is the position vector of the machining point at the block seamtIs the point P at the block seam from the origin in FIG.tCorresponds to the vector going to. Here, assuming that the cutting edge was at (X, Y, Z, C) = (0, 100, 0, 0) before moving this block, the position of the cutting edge point at the block seam is rt= (0, 100, 100, 90)
[0030]
On the other hand, the direction of the rotation axis (C axis in this program example) (the C rotation center axis, that is, the Z axis in the example program) has the direction of the vector, and the magnitude of the rotation speed (program In the example, 90 [deg / min] = π / 2 [rad / min])iIt was. Where Δθi Assuming that the index number i is 1 for the A axis, 2 for the B axis, and 3 for the C axis, Δθ in the second block (G01 Z100. C90.) Of this programThreeBecomes (0, 0, π / 2), and the A and B axes are not commanded.1And Δθ2Becomes (0, 0, 0). Similarly, in the third block (G01 Z100. C-90.), Δθ1And Δθ2Becomes (0, 0, 0) and ΔθThreeBecomes (0, 0, -π / 2).
[0031]
In FIG. 1, the cutting edge point position vector r in step S101.tGet first. Next, in step S102, the angular movement vector ΔθiAsk for. In step S103, the outer product rd= ΔθiXrtiAsk for. Where rtiIs one point P on the turning center axis (Z axis) of the rotation axis in FIG.i0To rtIt is a vector which goes to the blade point shown by. Where Pi0Can be any point as long as it is on the turning center axis.30To (0, 0, 0). In this case, rt3= (0, 100, 100)
[0032]
Δθi, RtiProduct (ΔθiXrti), The amount of movement due to the rotation of the rotation axis i can be converted into the amount of movement in the orthogonal three-axis space of (X, Y, Z). In this example, Δθ in the second blockThree= (0, 0, π / 2), rt3= (0, 100, 100), so ΔθThreeXrt3= (− 100π / 2, 0, 0).
[0033]
For the A-axis, B-axis, and C-axis, the converted movement amount is added for i = 1 to 3, that is, rd= Σ (ΔθiXrti) Can be converted into a vector in the orthogonal three-axis space. In this example of FIG. 2, Δθ1= Δθ2= (0, 0, 0), so rd= ΔθThreeXrt3It becomes.
[0034]
Then, as shown in step S104, the conversion vector rdAnd (X, Y, Z) translation vector r obtained directly from the program axis addresslSum of rn= Rl+ RdThus, even when the movement includes the rotation axis, it is possible to accurately determine how the relative locus of the cutting edge point and the workpiece changes in the (X, Y, Z) orthogonal three-axis space. FIG. 3 shows the state of this vector composition.tVector r drawn by the second block in the vicinitynIs r by linear axis movementlAnd conversion vector r by rotation axis movementdIt will be expressed as the sum of
[0035]
In the second block of this program, rl= (0, 0, 100), so the relative trajectory of the cutting edge point created by the movement of the second block and the workpiece at the joint between the second block and the third block is rn= (− 100π / 2, 0, 100). Similarly, the relative trajectory on the third block side is rn= (100π / 2, 0, 100). In order to make the identification easy to understand, the relative trajectory of the second block will be expressed as r.n-1, The relative trajectory of the third block is rnAnd
[0036]
As a result, in step S105, the corner angle equation cos θ = rn・ Rn-1/ (| Rn| * | rn-1) To calculate the corner angle. In this program example, cos θ = −0.3355... And a desired corner angle is calculated.
[0037]
As an example of calculating the corner angle according to the flowchart of FIG. 1, the simplest case where only the Z axis and the C axis move as described above has been described. However, this flowchart simultaneously includes five or more axes including two or more rotation axes. It can also be applied when moving. For example, as in the coordinate axis configuration shown in FIG. 4, the program command “G90 G01 X0. Y0. Z0. B0. C0 .; G01 X100. Y100. Z100. B-45” C90 .; G01 X-100. Y200. Z200. B30. C-90 .; ”, the movement vector in the orthogonal three-axis space of (X, Y, Z) Can be converted.
[0038]
A method for calculating the corner angle at the joint between the second block and the third block will be described below based on this program command. A feature of the coordinate system of FIG. 4 is that the B axis and the C axis are centered on the Y axis and the Z axis, respectively. That is, the feature is that the turning center of the rotation axis is an axis passing through the origin.
[0039]
First, the cutting edge point position vector r in step S101tIs (X, Y, Z) = (100, 100, 100). In step S102, the angular movement vector Δθ on the second block sideiIs Δθ1= (0, 0, 0), Δθ2= (0, −π / 4, 0), ΔθThree= (0, 0, π / 2). Similarly, Δθ on the third block sideiIs Δθ1= (0, 0, 0), Δθ2= (0, π / 6, 0), ΔθThree= (0, 0, -π / 2). Further, in step S103, the vector r from the turning center axis toward the cutting edge pointtiIs P20For (0, 100, 0)t2= (100, 0, 100), P30To (0, 0, 100)t3= (100, 100, 0) rt1For the second and third blocks, Δθ1= 0 so there is no need to think about it. At this time, the outer product r on the second block sidedIs r from the component calculation formula by outer productd= Σ (ΔθiXrti) = (Δθ2Xrt2 + ΔθThreeXrt3) = (− 300π / 4, 100π / 2, 100π / 4). Similarly, outer product r on the third block sidedIs rd= (500π / 6, −100π / 2, 100π / 6). In step S104, the second block vector rl Rl= (100, 100, 100), (−100, 200, 200) in the third block. The subsequent processing is the same regardless of the machining program.n= Rl+ RdIn step S105, a corner angle is obtained. Thus, the present invention can also be applied to the case of simultaneous 5-axis control.
[0040]
Furthermore, as a general case, it passes through the turning center axis (x, y, z) = (10,20,30) of the rotating workpiece, and the direction of (x, y, z) = (1,2,3) Consider any axis of rotation. Assuming that this rotation axis is called the W axis, the program command "G90 G01 X0. Y0. Z50. W0 .; G01 X100. Y100. Z150. W-180 .; G01 X-100. Y200. Z250. W180 .;" The angle formed by the second block and the third block when executed is calculated. Here, if the tool being used has a length of 50 in the Z direction, the cutting edge point position vector rt= (rtx, rty, rtz) = (0, 100, 100).
[0041]
In this case, the angular movement vector Δθ in step S102 of FIG.iIf the index number i for the W-axis is 1, Δθ in the second block in the W-axis direction1= (− Π / sqrt (14), −2π / sqrt (14), −3π / sqrt (14)), Δθ2= ΔθThree= ΔθFour= Δθ... = (0, 0, 0). Similarly, in the third block, Δθ1= (π / sqrt (14), 2π / sqrt (14), 3π / sqrt (14)), Δθ2= ΔθThree= ΔθFour= Δθ... = (0, 0, 0).
[0042]
PTenIs (10, 20, 30), the vector from the swivel center axis to the cutting edge is rt1= (90, 80, 70) At this time, the outer product r on the second block sidedIs rd= Σ (ΔθiXrti) = (Δθ1Xrt1) = (100π / sqrt (14), −200π / sqrt (14), 300π / sqrt (14)). Similarly, outer product r on the third block sidedIs rd= (− 100π / sqrt (14), 200π / sqrt (14), −300π / sqrt (14)).
[0043]
In step S104, the second block rl= (100, 100, 100), the third block is rl= (−200, 100, 100) and sum rn= Rl+ RdAsk for. In step S105, a corner angle is obtained. Thus, it is possible to provide a corner angle calculation means that can correspond to an arbitrary axis configuration.
[0044]
Embodiment 2. FIG.
Next, a numerical controller having a corner acceleration / deceleration process for multiplying the moving amount of the rotary shaft by a magnification in the second embodiment will be described. In the first embodiment (numerical control device that performs corner acceleration / deceleration processing using vector conversion), the influence of the rotation axis on the change in the relative trajectory of the workpiece and the cutter is calculated using a three-dimensional vector. In general, a relative trajectory can be calculated for an NC device having any axis configuration. However, for example, in an NC consisting of one rotation axis (C axis) and two linear axes (X, Z axes), when the workpiece size (radius) is known when moving only with Z and C, In some cases, it is possible to appropriately calculate the influence of the rotation axis only by performing one-dimensional multiplication on the movement amount of the rotation axis. In this case, the change in the relative trajectory between the workpiece and the tool caused by moving the rotation axis (C axis) and the change in the relative trajectory caused by moving the Z axis are the change in the XY plane and the change in the Z axis. Separated into changes in Therefore, the amount of movement obtained by multiplying the amount of movement of the rotation axis by the radius of the workpiece matches the actual amount of change in the relative trajectory on the XY plane. In other words, since the influence of the rotation axis can be correctly converted simply by performing a scalar calculation of multiplying the movement amount of the rotation axis, the conventional cosine theorem can be used to calculate the movement amount multiplied by this radius and the Z-axis movement amount. By substituting in the calculation formula, it is possible to calculate the same angle as the result in the case of using the first embodiment (a numerical control device that performs corner acceleration / deceleration processing using vector conversion).
[0045]
FIG. 5 is a flowchart for realizing the second embodiment (a numerical control apparatus having a corner acceleration / deceleration process for multiplying the moving amount of the rotary shaft by a magnification). The program command “G91; G01 Z100. C90 .; G01 Z100. C-90 .;” will be described as an example. In FIG. 5, according to S1001, a certain magnification is applied to the movement amount of the rotation axis (C-axis in this program). In general, it is appropriate to use a value proportional to the radius of the workpiece. Here, it is assumed that the magnification is set to 3 as a result of measuring the workpiece in advance. At this time, the movement vector of the second block is rn-1= (Z, C) = (100, 270), the third block is rn= (Z, C) = (100, -270).
[0046]
Next, in step S1002, cos θ = rn・ Rn-1/ (| Rn| * | rn-1) To calculate the corner angle. In this example, cos θ = −0.7587.
[0047]
Embodiment 3 FIG.
Next, a third embodiment of the present invention (numerical control device that switches the magnification of the rotational axis movement amount) will be described. In the second embodiment, the method of selecting the magnification to be multiplied by the movement of the rotating shaft is proportional to the radius of the workpiece. However, the influence of the delay in motor output and the difference in hardness depending on the workpiece direction is empirically determined. When grasping, it is possible to process with higher accuracy by using a specific magnification. For this reason, it is necessary to arbitrarily set the magnification by a parameter or a program. FIG. 6 is a corner acceleration / deceleration process when the magnification calculation part of the third embodiment is installed, and FIG. 7 is a flowchart of the magnification calculation part. Hereinafter, FIG. 7 will be described.
[0048]
In step S1201, it is determined whether or not it is in a mode in which the NC apparatus automatically calculates the magnification (referred to as a magnification automatic calculation mode), and the subsequent processing is divided. This mode ON / OFF can be realized by providing an NC internal variable as a flag, and for example, by adding a function such as incremental value / absolute value switching. Here, ON / OFF is controlled by a program.
[0049]
If the automatic magnification calculation mode is ON in step S1201, the magnification calculation shown in step S1202 is performed. Here, the distance between the cutting edge point and each rotation axis is calculated, and (distance × π / 180) is set as the magnification. For example, in the case of an NC machine tool that has 5 axes of X, Y, Z, B, and C and the tool rotates around the B axis, the distance corresponding to the B axis corresponds to the tool length and the C axis. The distance is sqrt (X2+ Y2(However, X, Y, and Z are the X, Y, and Z coordinates of the cutting edge, respectively). In this NC machine tool, when the program command “G91; G01 Z100. C90 .; G01 Z100. C-90 .;” is described, the cutting edge is set to (X, Y, Z, B at the start of the program. , C) = (30, 40, 0, 90, 0). At the joint between the second block and the third block of the program, the rotation axis that moves is only the C axis, and the distance between the C axis and the cutting edge is sqrt (302+402) = 50. Therefore, the magnification corresponding to the C axis is (distance × π / 180) = (50 × π / 180).
[0050]
If the automatic magnification calculation mode is OFF in step S1201, the condition judgment shown in step S1203 is performed. For example, when the code for designating the magnification is “M2001 P_Q_R_;”, and P, Q, and R are the magnifications corresponding to the A, B, and C axes, respectively, in the mode of M2001 in step S1203, The magnification setting shown in step S1204 is performed. In step S1204, the numerical values designated by the P, Q, and R addresses are set as the magnification of each rotation axis.
[0051]
If the program is not designated in step S1203, the magnification setting shown in step S1205 is performed. In this process, the magnification previously registered in the NC as a parameter is set as the magnification of each rotation axis.
[0052]
By the processes in steps S1201 to S1205 described above, the magnification with respect to the movement amount of the rotating shaft can be obtained.
[0053]
Embodiment 4 FIG.
Next, a numerical controller that can change the acceleration / deceleration processing used according to the axis configuration of the control target axis according to the fourth embodiment will be described. FIG. 8 is one of flowcharts for realizing the fourth embodiment. In FIG. 8, first, in step S1301, information regarding the control axis is acquired. The information here is information such as which axis is the rotation axis and which is the turning center axis corresponding to the rotation axis (for example, the axis corresponding to the C axis is the Z axis).
[0054]
In step S1302, the control axis information obtained in step S1301 is collated with information relating to the movement axis of the read machining program, and it is determined whether or not the rotary axis moves before and after the block joint of the machining program. Sort out. If there is no rotation axis in step S1302, the useless process of calculating the influence of the rotation axis is omitted, and the corner acceleration / deceleration process (3) in step S1306 is called. This acceleration / deceleration process {circle around (3)} is a conventional corner acceleration / deceleration process that does not consider the type of shaft, and for example, a method using the cosine theorem introduced in the prior art is applicable. On the other hand, when the rotation axis moves, the determination processing routine of step S1303 is called.
[0055]
In step S1303, it is determined whether or not the rotation axis movement command and the linear axis movement command interfere. As the combinations of the interfering axes, there are a combination of 1: A axis and Y, Z axis 2: B axis and Z, X axis 3: C axis and X, Y axis. Therefore, when an interfering axis is commanded in the same block, such as “G01 X100. C200.”, It is determined that the movement command is “interfering”.
[0056]
If the interference of the axis movement occurs in step S1303, the correct corner acceleration / deceleration cannot be performed unless the influence of the rotation axis movement is converted into the movement vector on the three orthogonal axes. Call the indicated corner acceleration / deceleration process (1). This corner acceleration / deceleration process (1) is a corner acceleration / deceleration process using vector conversion. If no interference occurs, the movement of the rotation axis can be treated as an independent linear axis, and the corner acceleration / deceleration process (2) shown in step S1305 is called. This corner acceleration / deceleration process {circle around (2)} is a corner acceleration / deceleration process for multiplying the moving amount of the rotary shaft by a magnification.
[0057]
In this way, through the corner acceleration / deceleration processing shown in steps S1304 to S1306, it is determined whether deceleration is necessary near the corner. Based on the determination result, the moving speed commanded to the motor is determined in step S1307.
[0058]
【The invention's effect】
As described above, according to the present invention, in a numerical control apparatus including a rotation axis as a movement control axis, when corner acceleration including movement of the rotation axis is performed, the movement vector of the rotation axis in the adjacent block is orthogonal. Even if the moving axis includes a rotation axis by having a corner acceleration / deceleration processing function including means for converting to a movement vector in three axes and means for obtaining a corner angle by applying the converted vector to an angle calculation calculation. The relative trajectory of the workpiece and the cutter, that is, the corner angle actually drawn by the machining point can be calculated, and correct corner discrimination can be performed.
[Brief description of the drawings]
FIG. 1 is a flowchart illustrating a processing procedure according to a first embodiment of the present invention.
FIG. 2 is a diagram for explaining handling of variables when converting a movement vector of a rotation axis into a movement vector of three orthogonal axes.
FIG. 3 is a diagram for explaining a state of vector synthesis;
FIG. 4 is a diagram for explaining how to take coordinate axes in a specific example;
FIG. 5 is a flowchart showing a processing procedure according to the second embodiment of the present invention.
6 is a flowchart showing a processing procedure when the third embodiment is installed in the flowchart of FIG. 5. FIG.
FIG. 7 is a flowchart illustrating a processing procedure according to the third embodiment.
FIG. 8 is a flowchart showing a processing procedure for realizing the fourth embodiment.
FIG. 9 is a diagram illustrating corner angles.
FIG. 10 is a block diagram showing a schematic configuration of a numerical controller (CNC) equipped with a corner acceleration / deceleration function.
FIG. 11 is a diagram for supplementing how to use the cosine theorem in a conventional corner acceleration / deceleration method.
FIG. 12 is a flowchart of a corner acceleration / deceleration method using a conventional cosine theorem.
FIG. 13 is a diagram for explaining a problem of a conventional corner acceleration / deceleration method.
[Explanation of symbols]
2 program analysis unit, 21 program reading unit, 22 path generation unit, 23 corner discrimination unit, rn, Rn-1  Moving vector, rt  Cutting edge point position vector, Δθi  Angular movement vector, rd  Outer product.

Claims (2)

直線軸と回転軸の両方を含む工作機械を制御する数値制御装置において、
つの連続するブロック間のコーナ加減速処理を行う際に、この連続するブロックの回転軸の移動ベクトルを直交3軸座標系における移動ベクトルに換算する手段と、この換算されたベクトルを角度算出演算に当てはめてコーナ角度を求める手段と、を含むコーナ加減速処理機能を有することを特徴とする数値制御装置。
In a numerical control device for controlling a machine tool including both a linear axis and a rotary axis,
When corner acceleration / deceleration processing between two consecutive blocks is performed, means for converting the movement vector of the rotation axis of the continuous block into a movement vector in an orthogonal three-axis coordinate system, and an angle calculation operation for the converted vector And a corner acceleration / deceleration processing function including means for obtaining a corner angle by applying to the above.
連続するブロックの回転軸の移動ベクトルを直交3軸座標系における移動ベクトルに換算することなく前記連続するブロックの移動ベクトルを直接前記角度算出演算に当てはめてコーナ角度を求める第2の手段と、
移動ベクトルが回転軸の移動を伴うか否かを判断する判断手段と、
この判断手段にて移動ベクトルが回転軸の移動を伴うと判断されたとき、前記コーナ加減速処理を行う処理に切替え、前記判断手段にて移動ベクトルが回転軸の移動を伴わないと判断されたとき、前記第2の手段で求めたコーナ角度に基づくコーナ加減速処理を行う処理に切り換える切換手段と、
を備えてなる請求項1に記載の数値制御装置。
Second means for obtaining a corner angle by directly applying the movement vector of the continuous block to the angle calculation calculation without converting the movement vector of the rotation axis of the continuous block into a movement vector in an orthogonal three-axis coordinate system;
Determining means for determining whether or not the movement vector is accompanied by movement of the rotation axis;
When it is determined by the determination means that the movement vector is accompanied by the movement of the rotation axis, the processing is switched to the processing for performing the corner acceleration / deceleration processing, and the determination means is determined not to be accompanied by the movement of the rotation axis. Switching means for switching to processing for performing corner acceleration / deceleration processing based on the corner angle obtained by the second means;
The numerical control device according to claim 1, comprising:
JP2002251597A 2002-08-29 2002-08-29 Numerical controller Expired - Fee Related JP4059734B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002251597A JP4059734B2 (en) 2002-08-29 2002-08-29 Numerical controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002251597A JP4059734B2 (en) 2002-08-29 2002-08-29 Numerical controller

Publications (2)

Publication Number Publication Date
JP2004094372A JP2004094372A (en) 2004-03-25
JP4059734B2 true JP4059734B2 (en) 2008-03-12

Family

ID=32058147

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002251597A Expired - Fee Related JP4059734B2 (en) 2002-08-29 2002-08-29 Numerical controller

Country Status (1)

Country Link
JP (1) JP4059734B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8576013B2 (en) * 2011-12-29 2013-11-05 Mks Instruments, Inc. Power distortion-based servo control systems for frequency tuning RF power sources

Also Published As

Publication number Publication date
JP2004094372A (en) 2004-03-25

Similar Documents

Publication Publication Date Title
JP6140130B2 (en) Numerical control device for protecting tools and workpieces
US9507337B2 (en) Numerical control device
US7058473B2 (en) Method and device for generation of machining program
US4503373A (en) Numerical control system
EP0129092B2 (en) Numerical control device for use with a machine tool
JP2012032848A (en) Numerical control device for multi-spindle machine for machining slope face
JP4847428B2 (en) Machining simulation apparatus and program thereof
JP2018005480A (en) Numerical control device performing skiving processing control
KR0180953B1 (en) Method of controlling the normal direction of the main shaft of the numerical machine tool
EP0323517A1 (en) Profiling method
Otsuki et al. Method to evaluate speed and accuracy performance of CNC machine tools by speed-error 2-D representation
JP4995976B1 (en) Numerical control device that performs in-position check of rotating shaft
JP2002182716A (en) Incorner cutting method and numerical controller
JP2008117032A (en) Working control device and its program
JPH02178711A (en) Numerical controller
JP4059734B2 (en) Numerical controller
US10261500B2 (en) Numerical controller controlling machining tool based on skiving instruction
CN110586960A (en) Method for machining a workpiece, numerical control device and machine tool
JPH08106311A (en) Numerical controller
JP2686293B2 (en) Three-dimensional laser processing method
JP4770076B2 (en) Numerical controller
JP4873082B2 (en) Numerical controller
JPH0218602A (en) Play-back system
CN111045395A (en) Numerical controller
JP2001034318A (en) Method for preparing working pass, method for automatically preparing nc program, cad/cam system, nc working system, and storage medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20041217

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20060804

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20060808

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20061010

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20070403

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20070530

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: 20071218

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20071218

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20101228

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20111228

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20111228

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20121228

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20121228

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20131228

Year of fee payment: 6

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees