JP2012150848A - Numerical control device - Google Patents

Numerical control device Download PDF

Info

Publication number
JP2012150848A
JP2012150848A JP2012114768A JP2012114768A JP2012150848A JP 2012150848 A JP2012150848 A JP 2012150848A JP 2012114768 A JP2012114768 A JP 2012114768A JP 2012114768 A JP2012114768 A JP 2012114768A JP 2012150848 A JP2012150848 A JP 2012150848A
Authority
JP
Japan
Prior art keywords
coordinate system
coordinate
viewed
orientation
origin position
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
Application number
JP2012114768A
Other languages
Japanese (ja)
Other versions
JP5321712B2 (en
Inventor
Kotaro Nagaoka
弘太朗 長岡
Tomonori Sato
智典 佐藤
Toshiro Ono
俊郎 小野
Daisuke Fujino
大助 藤野
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 JP2012114768A priority Critical patent/JP5321712B2/en
Publication of JP2012150848A publication Critical patent/JP2012150848A/en
Application granted granted Critical
Publication of JP5321712B2 publication Critical patent/JP5321712B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

PROBLEM TO BE SOLVED: To provide a numerical control device for performing program creation and working in a short time by simplifying a method of designating an inclined plane.SOLUTION: A numerical control device includes: means of acquiring the origin position and attitude of a current second coordinate system viewed from a first coordinate system; means of setting a coordinate system rotation central axis and an angle of rotation around the coordinate system rotation central axis; and means of setting the origin position and attitude of the coordinate system obtained by rotating the second coordinate system designated on the current inclined plane only by the angle of rotation around the coordinate system rotation central axis as the origin position and attitude of the new second coordinate system viewed from the first coordinate system, and performing coordinate conversion including the conversion of the attitude to a position commanded in the second coordinate system by using the origin position and attitude of the new second coordinate system viewed from the first coordinate system to obtain the position in the first coordinate system.

Description

この発明は、傾斜した座標系において指令を行うことができる数値制御装置に関するものである。   The present invention relates to a numerical control apparatus capable of giving a command in an inclined coordinate system.

従来の回転軸を有する機械の数値制御装置では、機械のXY平面に対してある角度だけ傾いた面、すなわち傾斜面をXY平面とみなして加工プログラムを作成し、加工実行時には、プログラム上で指令された位置を傾斜面上の座標系から機械の座標系に座標変換して得られた位置をもとに機械可動部の位置を制御することにより、加工するワークの面に沿った座標系で加工プログラムを作成できるようにしている(例えば、特許文献1参照)。
また、傾斜面に沿った座標系を指定する際には、傾斜面の座標系を指定した回転中心ベクトルまわりに指定した角度だけ回転させ、平行移動を行う操作を複数回組み合わせて行うと機械の座標系と一致するとした場合の回転軸方向とその軸周りの回転角度および平行移動量を用いて指定するようにしている(例えば、特許文献2参照)。
In a conventional numerical control device for a machine having a rotating shaft, a machining program is created by regarding a plane inclined by a certain angle with respect to the XY plane of the machine, that is, the inclined plane is regarded as the XY plane. By controlling the position of the machine moving part based on the position obtained by converting the coordinated position from the coordinate system on the inclined surface to the coordinate system of the machine, the coordinate system along the surface of the workpiece to be machined A machining program can be created (for example, see Patent Document 1).
In addition, when specifying a coordinate system along an inclined surface, the coordinate system of the inclined surface is rotated by a specified angle around the specified rotation center vector, and the operation of performing parallel movement is performed multiple times in combination. Designation is performed using the rotation axis direction, the rotation angle around the axis, and the amount of translation when the coordinate system is matched (see, for example, Patent Document 2).

特開昭60−126709号公報JP 60-126709 A 特開平3−269604号公報JP-A-3-269604

このような数値制御装置では、傾斜面の指定は機械の座標系を基準に行われる。すなわち、傾斜面を指定するためのパラメータ、すなわち回転中心ベクトルとその軸周りの回転軸角度および平行移動量は、機械の座標系における値を設定する必要があった。工作機械のテーブル側に回転機構を有する構成である場合、テーブル上に置かれたワークの位置および姿勢は、テーブルが回転することにより変化する。したがって、ワーク上の傾斜面に沿って座標系を定義するときには、傾斜面を指定するパラメータを現在の機械の座標系と傾斜面の姿勢の位置関係から算出する第一の方法、または、テーブル回転軸の回転角度が傾斜面を指定したパラメータを算出したときに想定していたテーブル回転軸の回転角度と一致するようにテーブルを回転させる第二の方法を採用する必要があった。   In such a numerical control device, the designation of the inclined surface is performed based on the coordinate system of the machine. That is, the parameters for designating the inclined surface, that is, the rotation center vector, the rotation axis angle around the axis, and the amount of translation need to be set in the machine coordinate system. In the case of a configuration having a rotation mechanism on the table side of the machine tool, the position and posture of the workpiece placed on the table change as the table rotates. Therefore, when defining the coordinate system along the inclined surface on the workpiece, the first method to calculate the parameter for specifying the inclined surface from the positional relationship between the coordinate system of the current machine and the posture of the inclined surface, or table rotation It was necessary to adopt the second method of rotating the table so that the rotation angle of the shaft coincides with the rotation angle of the table rotation shaft assumed when the parameter specifying the inclined surface was calculated.

第一の方法を採用する場合、テーブルの回転軸角度が変化するたびに傾斜面を指定するパラメータを計算し直さねばならず、加工プログラムの作成が非常に煩雑かつ困難である。
また、第二の方法を採用する場合、傾斜面を指定するたびに、加工する上では本来移動させる必要のない位置にテーブルの回転軸角度を移動させなければならず、加工時間が余計に掛かったり、移動中のワークと機械や工具の干渉を回避する必要があったりするなどの問題がある。
When the first method is adopted, it is necessary to recalculate the parameter for designating the inclined surface every time the rotation axis angle of the table changes, and the creation of the machining program is very complicated and difficult.
In addition, when the second method is adopted, each time an inclined surface is specified, the rotation axis angle of the table must be moved to a position that does not need to be moved for machining, which requires additional machining time. And there is a problem that it is necessary to avoid interference between a moving workpiece and a machine or a tool.

また、このような数値制御装置では、傾斜面を指定する際に、図面上に記載されたワークの寸法や加工形状間の位置関係を直接用いることができず、これらの図面情報から回転軸まわりの回転角度などの傾斜面を指定するためのパラメータを求めることが必要であるが、複雑な形状のワークで傾斜面を多数設定しなければならない場合や、傾斜面を指定するための回転中心ベクトルが機械の座標系の座標軸に対して斜めに傾いている場合などでは、傾斜面を指定するためのパラメータを求めることが非常に困難であるという問題がある。   In addition, in such a numerical control device, when specifying an inclined surface, it is not possible to directly use the workpiece dimensions and the positional relationship between the machining shapes described on the drawing. It is necessary to obtain parameters for specifying the inclined surface such as the rotation angle of the workpiece, but if a large number of inclined surfaces need to be set for a complex shaped workpiece, or the rotation center vector for specifying the inclined surface Is inclined at an angle with respect to the coordinate axis of the machine coordinate system, there is a problem that it is very difficult to obtain a parameter for designating the inclined surface.

この発明の目的は、傾斜面を指定する方法が簡潔となり、短時間でプログラム作成および加工が可能となるような数値制御装置を提供することである。   An object of the present invention is to provide a numerical control device that can simplify a method of designating an inclined surface and can create and process a program in a short time.

この発明に係わる数値制御装置は、機械の駆動軸方向と座標軸方向が異なる第2の座標系において指令された位置を、座標変換して、機械の駆動軸方向と座標軸方向が一致するように設定された第1の座標系における位置を得るとともに該位置に機械を移動させる数値制御装置において、上記第1の座標系からみた現在の第2の座標系の原点位置および姿勢を取得する手段と、座標系回転中心軸および該座標系回転中心軸まわりの回転角度を設定する手段と、上記現在の傾斜面に指定された第2の座標系を上記座標系回転中心軸まわりに上記回転角度だけ回転させた座標系の原点位置および姿勢を上記第1の座標系からみた新しい第2の座標系の原点位置および姿勢として設定し、上記第1の座標系からみた新しい第2の座標系の原点位置および姿勢を用いて、上記第2の座標系において指令された位置に対して姿勢の変換を含む座標変換を行って上記第1の座標系における位置を得る手段と、を備える。   The numerical control device according to the present invention performs coordinate conversion on the commanded position in the second coordinate system in which the drive axis direction of the machine is different from the coordinate axis direction, and is set so that the drive axis direction of the machine matches the coordinate axis direction. In the numerical control apparatus for obtaining the position in the first coordinate system and moving the machine to the position, means for acquiring the origin position and orientation of the current second coordinate system viewed from the first coordinate system; A coordinate system rotation center axis and means for setting a rotation angle around the coordinate system rotation center axis; and the second coordinate system specified for the current inclined surface is rotated around the coordinate system rotation center axis by the rotation angle. The origin position and orientation of the coordinate system thus set are set as the origin position and orientation of the new second coordinate system viewed from the first coordinate system, and the origin position of the new second coordinate system viewed from the first coordinate system is set. Oh With fine orientation, and means for obtaining a position in said first coordinate system by performing a coordinate transformation which includes a transformation of the position with respect to the commanded position in the second coordinate system.

この発明に係わる数値制御装置の効果は、現在ワークが置かれている位置や姿勢に関係なく、ワーク上の加工したい形状の位置関係の情報のみを用いて傾斜面を定義するためのパラメータを決定することができるので、現在ワークが置かれている位置や姿勢をもとに傾斜面を定義するためのパラメータを求め直したり、ワークが置かれている位置や姿勢を傾斜面を定義するためのパラメータを定めたときに想定したワークの位置および姿勢に変更したりする作業が不要となり、加工を簡単に早く行うことができる。   The effect of the numerical control device according to the present invention is that a parameter for defining an inclined surface is determined using only the positional relationship information of the shape to be machined on the workpiece, regardless of the position and posture where the workpiece is currently placed. So that the parameters for defining the inclined surface can be re-determined based on the position and posture where the workpiece is currently placed, and the position and posture where the workpiece is placed are used to define the inclined surface. The work of changing to the workpiece position and posture assumed when the parameters are determined is not required, and the machining can be performed easily and quickly.

実施の形態1.
図1は、この発明の実施の形態1に係わる数値制御装置の構成を示すブロック図である。
この発明の実施の形態1に係わる数値制御装置40は、加工プログラム50を読み込み、解析し、座標変換し、機械移動量を算出し、機械駆動部54を制御してワークを加工する。
そして、実施の形態1に係わる数値制御装置40は、図1に示すように、傾斜面のパラメータ設定手段1、回転中心軸・基準角度設定手段2、回転角度取得手段3、傾斜面の位置および姿勢設定手段4、基準座標系設定手段5、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6、プログラム解析部51、座標変換部52、機械移動指令計算部53、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6、第1の座標系からみた第2の座標系の原点位置および姿勢取得手段7、姿勢パラメータ演算手段8および原点位置および姿勢パラメータ出力手段9を有する。
Embodiment 1 FIG.
FIG. 1 is a block diagram showing a configuration of a numerical control apparatus according to Embodiment 1 of the present invention.
The numerical controller 40 according to the first embodiment of the present invention reads a machining program 50, analyzes it, converts coordinates, calculates a machine movement amount, and controls the machine drive unit 54 to machine a workpiece.
As shown in FIG. 1, the numerical control device 40 according to the first embodiment includes an inclined surface parameter setting unit 1, a rotation center axis / reference angle setting unit 2, a rotation angle acquisition unit 3, a position of the inclined surface, and Posture setting means 4, reference coordinate system setting means 5, origin position and posture setting means 6 of the second coordinate system viewed from the first coordinate system, program analysis unit 51, coordinate conversion unit 52, machine movement command calculation unit 53, Origin position and orientation setting means 6 of the second coordinate system viewed from the first coordinate system, origin position and orientation acquisition means 7 of the second coordinate system viewed from the first coordinate system, attitude parameter calculation means 8 and origin position And posture parameter output means 9.

回転中心軸・基準角度設定手段2は、入力された回転中心軸の位置および回転軸方向と基準角度を基準座標系設定手段5に設定する。
回転角度取得手段3は、入力された現在のワークの姿勢における回転中心軸まわりの回転角度を基準座標系設定手段5に設定する。
基準座標系設定手段5は、回転中心軸の位置および回転軸方向、基準角度および現在の回転角度から、回転角度が基準角度と一致するとき第1の座標系と一致するとともに、ワークに固定された座標系である基準座標系を求め、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6に設定する。
基準座標系は、機械の各駆動軸の方向に基づいて定められた第1の座標系からみた基準座標系の原点位置および姿勢として表現される。
The rotation center axis / reference angle setting unit 2 sets the input position of the rotation center axis, the rotation axis direction, and the reference angle in the reference coordinate system setting unit 5.
The rotation angle acquisition unit 3 sets the rotation angle around the rotation center axis in the input current workpiece posture in the reference coordinate system setting unit 5.
The reference coordinate system setting means 5 matches the first coordinate system and is fixed to the workpiece when the rotation angle matches the reference angle from the position of the rotation center axis, the rotation axis direction, the reference angle and the current rotation angle. A reference coordinate system, which is a coordinate system, is obtained and set in the origin position and orientation setting means 6 of the second coordinate system viewed from the first coordinate system.
The reference coordinate system is expressed as the origin position and orientation of the reference coordinate system viewed from the first coordinate system determined based on the direction of each drive axis of the machine.

また、傾斜面のパラメータ設定手段1は、入力された傾斜面のパラメータを傾斜面の位置および姿勢設定手段4に設定する。
傾斜面の位置および姿勢設定手段4は、傾斜面のパラメータから傾斜面の位置および姿勢を求め、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6に設定する。
第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6は、傾斜面の位置および姿勢と、第1の座標系からみた基準座標系の原点位置および姿勢とから、第1の座標系からみた第2の座標系の原点位置および姿勢を求め、この第1の座標系からみた第2の座標系の原点位置および姿勢を座標変換部52に設定する。
The inclined surface parameter setting means 1 sets the input inclined surface parameters in the inclined surface position and orientation setting means 4.
The position and orientation setting unit 4 of the inclined surface obtains the position and orientation of the inclined surface from the parameters of the inclined surface, and sets them in the origin position and orientation setting unit 6 of the second coordinate system as viewed from the first coordinate system.
The origin position and orientation setting means 6 of the second coordinate system viewed from the first coordinate system is based on the position and orientation of the inclined surface and the origin position and orientation of the reference coordinate system viewed from the first coordinate system. The origin position and orientation of the second coordinate system as seen from the coordinate system are obtained, and the origin position and orientation of the second coordinate system as seen from the first coordinate system are set in the coordinate conversion unit 52.

プログラム解析部51は、加工プログラム50を読み込んで、補間周期ごとの第2の座標系における位置指令を求め、座標変換部52に出力する。
座標変換部52は、設定されている第1の座標系からみた第2の座標系の原点位置および姿勢に基づき、入力された第2の座標系における位置指令を第1の座標系における位置指令に変換して、機械移動指令計算部53に出力する。
機械移動指令計算部53は、第1の座標系での位置指令から、機械の各駆動軸の位置指令を求め、機械駆動部54に出力する。
機械駆動部54は、機械の各駆動軸の位置指令に機械各軸が追従するように機械の駆動部を駆動させる。
The program analysis unit 51 reads the machining program 50, obtains a position command in the second coordinate system for each interpolation period, and outputs the position command to the coordinate conversion unit 52.
The coordinate conversion unit 52 converts the input position command in the second coordinate system to the position command in the first coordinate system based on the origin position and orientation of the second coordinate system viewed from the set first coordinate system. And output to the machine movement command calculation unit 53.
The machine movement command calculation unit 53 obtains a position command for each drive shaft of the machine from the position command in the first coordinate system, and outputs it to the machine drive unit 54.
The machine drive unit 54 drives the drive unit of the machine such that each axis of the machine follows the position command of each drive axis of the machine.

また、第1の座標系からみた第2の座標系の原点位置および姿勢取得手段7は、座標変換部52より、第1の座標系からみた第2の座標系の原点位置および姿勢を取得して、姿勢パラメータ演算手段8に出力する。
姿勢パラメータ演算手段8は、姿勢を表す座標変換行列から所定の形式の姿勢パラメータを求め、さらに第1の座標系からみた第2の座標系の原点位置とともに、原点位置および姿勢パラメータ出力手段9に出力する。
原点位置および姿勢パラメータ出力手段9は、第1の座標系からみた第2の座標系の原点位置と姿勢パラメータを数値制御装置40の図示しない操作画面に表示する。
The origin position and orientation acquisition unit 7 of the second coordinate system viewed from the first coordinate system acquires the origin position and orientation of the second coordinate system viewed from the first coordinate system from the coordinate conversion unit 52. And output to the attitude parameter calculation means 8.
The attitude parameter calculation means 8 obtains an attitude parameter in a predetermined format from the coordinate transformation matrix representing the attitude, and further sends the origin position and attitude parameter output means 9 together with the origin position of the second coordinate system as viewed from the first coordinate system. Output.
The origin position and orientation parameter output means 9 displays the origin position and orientation parameters of the second coordinate system viewed from the first coordinate system on an operation screen (not shown) of the numerical controller 40.

次に、この実施の形態1に係わる数値制御装置40の動作について説明する。図2は、この実施の形態1における機械とワークの位置関係を表した図である。
加工プログラム50を作成するとき、図2の実線で表すようにワーク10が置かれ、第1の座標系12からみた傾斜面21の原点位置および傾斜面21上の第2の座標系13が作成される。
ワーク10の基準面に第1の座標系12が、機械の駆動軸方向と座標軸方向が一致するように設定されている。この第1の座標系12は、工作機械の数値制御の分野ではワーク座標系と呼ばれる。加工プログラム作成時には、ワーク10の基準面が第1の座標系12のZ軸に垂直になるようなワーク10の姿勢を想定していたが、実際の加工時には回転中心軸まわりに回転角度θrotだけ回転したワーク11の姿勢(図2の点線で示す)で加工するものとする。加工プログラム作成時の回転中心軸まわりの回転角度を0°と定義する。このときの回転角度が基準角度となるので、基準角度は0°となる。第1の座標系12における回転中心軸16の位置をprotとし、回転軸方向の単位ベクトルをrrotとする。加工プログラムでは、XY平面が加工したい傾斜面21と一致するように定義された第2の座標系(加工プログラムを作成したときの第2の座標系13)上の位置を指令するものとする。
Next, the operation of the numerical controller 40 according to the first embodiment will be described. FIG. 2 is a diagram showing the positional relationship between the machine and the workpiece in the first embodiment.
When the machining program 50 is created, the workpiece 10 is placed as represented by the solid line in FIG. 2, and the origin position of the inclined surface 21 viewed from the first coordinate system 12 and the second coordinate system 13 on the inclined surface 21 are created. Is done.
The first coordinate system 12 is set on the reference plane of the workpiece 10 so that the drive axis direction of the machine and the coordinate axis direction coincide with each other. The first coordinate system 12 is called a workpiece coordinate system in the field of numerical control of machine tools. At the time of creating the machining program, the posture of the workpiece 10 is assumed such that the reference plane of the workpiece 10 is perpendicular to the Z axis of the first coordinate system 12. However, in actual machining, the rotation angle θ rot around the rotation center axis. It is assumed that machining is performed with the posture of the workpiece 11 rotated by only the position (indicated by a dotted line in FIG. 2). The rotation angle around the rotation center axis when creating a machining program is defined as 0 °. Since the rotation angle at this time becomes the reference angle, the reference angle is 0 °. The position of the rotation center axis 16 in the first coordinate system 12 is set to prot, and the unit vector in the direction of the rotation axis is set to rrot . In the machining program, a position on the second coordinate system (second coordinate system 13 when the machining program is created) defined so that the XY plane coincides with the inclined surface 21 to be machined is commanded.

ここで、傾斜面のパラメータ設定手段1と傾斜面の位置および姿勢設定手段4の動作を説明する。
第1の座標系12からみた加工プログラムを作成したときの第2の座標系13の原点位置をpofs、姿勢を表す座標変換行列をRとする。ここで、座標変換行列Rは、もとの座標系からみた、姿勢を表したい座標系のX軸、Y軸、Z軸の座標軸方向単位ベクトルを列ベクトルとする3行3列の行列と定義する。すなわち、座標変換行列Rは第1の座標系12からみた、加工プログラムを作成したときの第2の座標系13のX軸、Y軸、Z軸の座標軸方向単位ベクトルを列ベクトルとする3行3列の行列となる。通常、傾斜面21の姿勢は座標変換行列よりも簡便な形式で指定される。この指定方式には多数の形式があるが、ここでは一例としてロール角、ピッチ角およびヨー角を用いる。これは、第1の座標系12をX軸まわりにロール角θ回転させ、回転させた後の座標系のY軸まわりにピッチ角θ回転させ、さらに回転させた後の座標系のZ軸まわりにヨー角θ回転させたときの座標系の座標軸方向が第2の座標系13の座標軸方向と一致するようなロール角θ、ピッチ角θおよびヨー角θで姿勢を表すものである。ロール角θ、ピッチ角θ、ヨー角θを用いると座標変換行列Rは式(1)のように表される。
Here, the operation of the parameter setting unit 1 of the inclined surface and the position and posture setting unit 4 of the inclined surface will be described.
Let p ofs be the origin position of the second coordinate system 13 when the machining program viewed from the first coordinate system 12 is created, and R be the coordinate transformation matrix representing the orientation. Here, the coordinate transformation matrix R is defined as a matrix of 3 rows and 3 columns with column vectors representing the X-axis, Y-axis, and Z-axis coordinate axis direction unit vectors of the coordinate system in which the posture is to be expressed as viewed from the original coordinate system. To do. In other words, the coordinate transformation matrix R has three rows as viewed from the first coordinate system 12, with the X-axis, Y-axis, and Z-axis coordinate axis direction unit vectors of the second coordinate system 13 when the machining program is created as column vectors. It becomes a three-column matrix. Usually, the posture of the inclined surface 21 is specified in a simpler form than the coordinate transformation matrix. There are many types of this designation method. Here, a roll angle, a pitch angle, and a yaw angle are used as an example. This is because the first coordinate system 12 is rotated by the roll angle θ R about the X axis, the pitch angle θ P is rotated about the Y axis of the coordinate system after rotation, and the Z of the coordinate system after further rotation is rotated. The posture is represented by a roll angle θ R , a pitch angle θ P and a yaw angle θ Y such that the coordinate axis direction of the coordinate system when the yaw angle θ Y is rotated about the axis coincides with the coordinate axis direction of the second coordinate system 13. Is. When the roll angle θ R , the pitch angle θ P , and the yaw angle θ Y are used, the coordinate transformation matrix R is expressed as shown in Equation (1).

図2に示した例の傾斜面21の姿勢を表すパラメータは、ロール角0°、ピッチ角45°、ヨー角0°である。この座標変換行列Rと第2の座標系13の原点位置pofsが、傾斜面21を指定するパラメータとなる。この傾斜面21を指定するパラメータは、通常は加工プログラムに記述される。傾斜面のパラメータ設定手段1では、第1の座標系12からみた加工プログラムを作成したときの第2の座標系13の原点位置pofsと姿勢を指定するパラメータ、すなわちロール角θ、ピッチ角θ、ヨー角θを加工プログラムなどから取得して、傾斜面の位置および姿勢設定手段4に設定する。
そして、傾斜面の位置および姿勢設定手段4では、第1の座標系12からみた加工プログラムを作成したときの第2の座標系13の原点位置pofsと姿勢を表す座標変換行列Rを、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6に設定する。
The parameters representing the posture of the inclined surface 21 in the example shown in FIG. 2 are a roll angle of 0 °, a pitch angle of 45 °, and a yaw angle of 0 °. The coordinate transformation matrix R and the origin position p ofs of the second coordinate system 13 are parameters for designating the inclined surface 21. The parameters for designating the inclined surface 21 are usually described in a machining program. In the parameter setting means 1 for the inclined surface, parameters for designating the origin position p ofs and the posture of the second coordinate system 13 when the machining program viewed from the first coordinate system 12 is created, that is, the roll angle θ R and the pitch angle. θ P and yaw angle θ Y are acquired from a machining program or the like, and set to the position and orientation setting means 4 of the inclined surface.
Then, the position and orientation setting means 4 of the inclined surface obtains the coordinate transformation matrix R representing the origin position p ofs and orientation of the second coordinate system 13 when the machining program viewed from the first coordinate system 12 is created. The origin position and orientation setting means 6 of the second coordinate system viewed from the coordinate system of 1 is set.

次に、回転中心軸・基準角度設定手段2、回転角度取得手段3および基準座標系設定手段5の動作について説明する。
機械に設置したときのワークの姿勢が加工プログラムを作成したときのワークの姿勢と異なる場合、図2から明らかなように、加工プログラムを作成したときの傾斜面21のパラメータをそのまま用いると、加工したい傾斜面とは異なる位置・姿勢の傾斜面を指定してしまうことになる。
すなわち、機械に設置したとき、第2の座標系15を第2の座標系に設定しなければならないが、そのままでは加工プログラムを作成したときの第2の座標系13を第2の座標系に設定してしまい、この座標系上においてプログラムで指令された形状を加工する。
したがって、従来の数値制御装置においてこの問題から回避するには、第1の座標系12からみた、機械に設置したときの第2の座標系15の原点位置およびロール角、ピッチ角およびヨー角などの姿勢パラメータを求め直したり、ワークを加工プログラムを作成したときのワークの姿勢と同じ姿勢に置き直したりしてから加工を行う必要があった。
Next, operations of the rotation center axis / reference angle setting means 2, the rotation angle acquisition means 3, and the reference coordinate system setting means 5 will be described.
When the workpiece posture when installed in the machine is different from the workpiece posture when the machining program is created, as is apparent from FIG. 2, if the parameters of the inclined surface 21 when the machining program is created are used as they are, the machining is performed. This means that an inclined surface having a position / posture different from the desired inclined surface is designated.
That is, when installed on the machine, the second coordinate system 15 must be set to the second coordinate system, but the second coordinate system 13 when the machining program is created is used as the second coordinate system. Then, the shape commanded by the program is processed on this coordinate system.
Therefore, in order to avoid this problem in the conventional numerical control apparatus, the origin position and roll angle, pitch angle, yaw angle, etc. of the second coordinate system 15 when installed in the machine as seen from the first coordinate system 12. It was necessary to perform machining after re-determining the posture parameters of the workpiece or repositioning the workpiece to the same posture as the workpiece when the machining program was created.

一方、この実施の形態1では、次のように基準座標系を導入することでこのようなワークの姿勢においても同じ傾斜面のパラメータで加工を行うことができるようにしている。 すなわち、回転中心軸まわりの回転角度が基準角度のときに第1の座標系12と一致し、ワークに固定された座標系を基準座標系14とし、第1の座標系12からみた基準座標系14の原点位置と姿勢を求める。
この実施の形態1では、第1の座標系12を回転中心軸16まわりに、機械に設置したときの回転角度θrotだけ回転させた座標系が基準座標系14となる。第1の座標系12からみた基準座標系14の原点位置をpofsstd、座標変換行列をRstdとする。このとき、基準座標系14の原点位置pofsstdと座標変換行列Rstdは、それぞれ式(2)と式(3)で表される。なお、関数Rot(r,θ)は、単位方向ベクトルr=(r,r,r)のまわりにベクトルをθだけ回転させるための行列であり、式(4)で表される。
On the other hand, in the first embodiment, by introducing a reference coordinate system as follows, machining can be performed with the parameters of the same inclined surface even in the posture of such a workpiece. That is, when the rotation angle around the rotation center axis is the reference angle, the coordinate system coincides with the first coordinate system 12 and the coordinate system fixed to the workpiece is the reference coordinate system 14, and the reference coordinate system viewed from the first coordinate system 12. 14 origin positions and postures are obtained.
In the first embodiment, the reference coordinate system 14 is a coordinate system obtained by rotating the first coordinate system 12 around the rotation center axis 16 by the rotation angle θ rot when installed on the machine. The origin position of the reference coordinate system 14 viewed from the first coordinate system 12 is p ofsstd and the coordinate transformation matrix is R std . At this time, the origin position p ofsstd and the coordinate transformation matrix R std of the reference coordinate system 14 are expressed by Expression (2) and Expression (3), respectively. Note that the function Rot (r, θ) is a matrix for rotating the vector by θ around the unit direction vector r = (r 1 , r 2 , r 3 ), and is expressed by Expression (4).

回転中心軸・基準角度設定手段2と回転角度取得手段3は、それぞれ回転中心軸、基準角度と回転角度を作業者があらかじめパラメータとして入力しておいた値を取得して、基準座標系設定手段5に設定する。
次に、基準座標系設定手段5では、第1の座標系12からみた基準座標系14の原点位置pofsstdと、姿勢を表す座標変換行列Rstdを式(2)および式(3)から求めて、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6に設定する。
The rotation center axis / reference angle setting means 2 and the rotation angle acquisition means 3 acquire values that the operator has previously input as parameters for the rotation center axis, reference angle and rotation angle, respectively, and reference coordinate system setting means Set to 5.
Next, the reference coordinate system setting means 5 obtains the origin position p ofsstd of the reference coordinate system 14 viewed from the first coordinate system 12 and the coordinate transformation matrix R std representing the attitude from the equations (2) and (3). Thus, the origin position and orientation setting means 6 of the second coordinate system as viewed from the first coordinate system is set.

次に、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6の動作について説明する。
第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6では、第1の座標系12からみた第2の座標系13の原点位置pofs12と姿勢を表す座標変換行列R12を次のようにして求める。まず、第1の座標系12から基準座標系14への変換を同次変換行列Tstdで表す。なお、同次変換行列については、R.P.ポール著、「ロボット・マニピュレータ数学的基礎、プログラミングおよび制御」、コロナ社、1989年9月に詳細な記述がある。
Next, the operation of the origin position and orientation setting means 6 in the second coordinate system as viewed from the first coordinate system will be described.
The origin position and orientation setting means 6 of the second coordinate system viewed from the first coordinate system 6 has a coordinate transformation matrix R 12 representing the origin position p ofs12 and orientation of the second coordinate system 13 viewed from the first coordinate system 12. Is obtained as follows. First, the transformation from the first coordinate system 12 to the reference coordinate system 14 is represented by a homogeneous transformation matrix T std . For the homogeneous transformation matrix, R.I. P. There is a detailed description in Paul, "Robot Manipulator Mathematical Foundations, Programming and Control", Corona, September 1989.

同次変換行列Tstdは、第1の座標系12からみた基準座標系14の原点位置pofsstdと、姿勢を表す座標変換行列Rstdを用いて式(5)のように表される。ただし、同次変換行列Tstdの0要素は1行3列のゼロベクトルを表す。 The homogeneous transformation matrix T std is expressed as in Equation (5) using the origin position p ofsstd of the reference coordinate system 14 viewed from the first coordinate system 12 and the coordinate transformation matrix R std representing the posture. However, the 0 element of the homogeneous transformation matrix T std represents a 1-by-3 zero vector.

次に、基準座標系14から第2の座標系15への変換を同次変換行列Tで表す。基準座標系14からみた第2の座標系15の原点位置および姿勢は、第1の座標系12からみた、加工プログラムを作成した時の第2の座標系13の原点位置および姿勢と等しいので、同次変換行列Tは第1の座標系12からみた加工プログラムを作成したときの第2の座標系13の原点位置pofsと姿勢を表す座標変換行列Rを用いて式(6)のように表される。
第1の座標系12から第2の座標系15への変換を表す同次変換行列T12は、同次変換行列Tstdと同次変換行列Tの積であり、式(7)のように表される。
したがって、第1の座標系12からみた第2の座標系15の原点位置pofs12と姿勢を表す座標変換行列R12は式(8)および式(9)で表される。
Then, it describes the transformation from the reference coordinate system 14 to the second coordinate system 15 with homogeneous transformation matrix T 2. Since the origin position and orientation of the second coordinate system 15 viewed from the reference coordinate system 14 are equal to the origin position and orientation of the second coordinate system 13 when the machining program is created viewed from the first coordinate system 12, The homogeneous transformation matrix T 2 is expressed by the following equation (6) using a coordinate transformation matrix R representing the origin position p ofs and the posture of the second coordinate system 13 when the machining program viewed from the first coordinate system 12 is created. It is expressed in
A homogeneous transformation matrix T 12 representing transformation from the first coordinate system 12 to the second coordinate system 15 is a product of the homogeneous transformation matrix T std and the homogeneous transformation matrix T 2 , as shown in Equation (7). It is expressed in
Therefore, the coordinate transformation matrix R 12 representing a home position p Ofs12 and orientation of the second coordinate system 15 viewed from a first coordinate system 12 is expressed by Equation (8) and (9).

第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6では、式(8)および式(9)の演算により求められた、第1の座標系12からみた第2の座標系15の原点位置pofs12と姿勢を表す座標変換行列R12を座標変換部52に設定する。
次に、プログラム解析部51、座標変換部52、機械移動指令計算部53および機械駆動部54の動作について説明する。
プログラム解析部51では、加工プログラム50を読み込んで、プログラムの指令内容を読みとり、移動区間毎の始点と終点を計算する。加工プログラムにおける位置指令は、第2の座標系13上の座標値で指令されている。
さらに、移動区間毎の始点と終点の間を、直線補間や円弧補間などのプログラム上に指令された方法で補間し、各補間点での位置指令を計算する。
In the origin position and orientation setting means 6 of the second coordinate system as viewed from the first coordinate system, the second coordinates as viewed from the first coordinate system 12 obtained by the calculations of the equations (8) and (9). A coordinate transformation matrix R 12 representing the origin position p ofs 12 and the posture of the system 15 is set in the coordinate transformation unit 52.
Next, operations of the program analysis unit 51, the coordinate conversion unit 52, the machine movement command calculation unit 53, and the machine drive unit 54 will be described.
The program analysis unit 51 reads the machining program 50, reads the command contents of the program, and calculates the start point and end point for each movement section. A position command in the machining program is commanded by a coordinate value on the second coordinate system 13.
Further, the start point and end point of each movement section are interpolated by a method commanded on a program such as linear interpolation or circular interpolation, and a position command at each interpolation point is calculated.

次に、座標変換部52では、各補間点での位置指令について第2の座標系15から第1の座標系12への座標変換を行う。補間点での位置指令の第2の座標系15上での座標値をpref2で表すと、その点の第1の座標系12上での座標値pref1は式(10)のように表される。 Next, the coordinate conversion unit 52 performs coordinate conversion from the second coordinate system 15 to the first coordinate system 12 for the position command at each interpolation point. When the coordinate value on the second coordinate system 15 of the position command at the interpolation point is represented by p ref2 , the coordinate value p ref1 on the first coordinate system 12 of the point is expressed as in Expression (10). Is done.

機械移動指令計算部53では、各補間点での第1の座標系12における位置指令の各軸の値に対して加減速処理を行い、機械各軸の移動指令を求める。
機械駆動部54では、機械各軸の位置が機械各軸の移動指令に追従するように機械各軸を駆動させる。
なお、この実施の形態1では、補間後の位置指令について座標変換を行ったが、各移動区間の始点と終点の位置指令について座標変換を行い、座標変換後の位置指令について補間を行って、補間点での位置指令を求めてもよい。
The machine movement command calculation unit 53 performs acceleration / deceleration processing on the value of each axis of the position command in the first coordinate system 12 at each interpolation point to obtain a movement command of each axis of the machine.
The machine drive unit 54 drives each machine axis so that the position of each machine axis follows the movement command of each machine axis.
In the first embodiment, the coordinate conversion is performed for the position command after the interpolation. However, the coordinate conversion is performed for the position command of the start point and the end point of each moving section, and the position command after the coordinate conversion is interpolated. A position command at the interpolation point may be obtained.

次に、第2の座標系の原点位置および姿勢取得手段7、姿勢パラメータ演算手段8および原点位置および姿勢パラメータ出力手段9の動作について説明する。
第2の座標系の原点位置および姿勢取得手段7は、現在設定されている第2の座標系15について、第1の座標系12からみた第2の座標系15の原点位置pofs12と姿勢を表す座標変換行列R12を座標変換部52から取得し、姿勢パラメータ演算手段8に送る。
Next, the operations of the origin position and orientation acquisition means 7, the orientation parameter calculation means 8 and the origin position and orientation parameter output means 9 in the second coordinate system will be described.
The origin position and orientation acquisition unit 7 of the second coordinate system obtains the orientation and the origin position p ofs12 of the second coordinate system 15 as viewed from the first coordinate system 12 with respect to the currently set second coordinate system 15. A coordinate transformation matrix R 12 to be represented is acquired from the coordinate transformation unit 52 and sent to the posture parameter calculation means 8.

姿勢パラメータ演算手段8では、送られてきた第1の座標系12からみた第2の座標系15の原点位置pofs12と姿勢を表す座標変換行列R12のうち、第1の座標系12からみた第2の座標系15の座標変換行列R12から、所定の形式の姿勢パラメータを求める。姿勢パラメータの形式は多く存在するが、ここでは一例としてロール角、ピッチ角およびヨー角の場合について説明する。
ロール角θR1、ピッチ角θP1、ヨー角θY1を第1の座標系12からみた第2の座標系15の座標変換行列R12から求めるためには、式(1)からロール角θ、ピッチ角θ、ヨー角θについて解けばよく、その計算式はそれぞれ式(11)、式(12)、式(13)である。ここで、rijはR12のi行j列の成分を表す。
In posture parameter calculating means 8, of the coordinate transformation matrix R 12 representing a home position p Ofs12 and orientation of the second coordinate system 15 viewed from a first coordinate system 12 that has been sent, viewed from a first coordinate system 12 from the coordinate transformation matrix R 12 in the second coordinate system 15 determines a posture parameter of the predetermined format. There are many types of posture parameters, but here, a case of a roll angle, a pitch angle, and a yaw angle will be described as an example.
In order to obtain the roll angle θ R1 , the pitch angle θ P1 , and the yaw angle θ Y1 from the coordinate transformation matrix R 12 of the second coordinate system 15 viewed from the first coordinate system 12, the roll angle θ R is obtained from the equation (1). The pitch angle θ P and the yaw angle θ Y may be solved, and the calculation formulas thereof are the formula (11), the formula (12), and the formula (13), respectively. Here, r ij represents the component of i row and j column of R 12 .

原点位置および姿勢パラメータ出力手段9は、姿勢パラメータ演算手段8で求めた姿勢パラメータすなわちロール角θR1、ピッチ角θP1、ヨー角θY1と、第2の座標系の原点位置および姿勢取得手段7で取得した第1の座標系12からみた第2の座標系15の原点位置pofs12を数値制御装置40の操作画面に出力する。 The origin position and orientation parameter output means 9 is the orientation parameters obtained by the orientation parameter calculation means 8, that is, the roll angle θ R1 , the pitch angle θ P1 , the yaw angle θ Y1, and the origin position and orientation acquisition means 7 of the second coordinate system. The origin position p ofs12 of the second coordinate system 15 as viewed from the first coordinate system 12 obtained in step S3 is output to the operation screen of the numerical controller 40.

このように実施の形態1に係わる数値制御装置40は、現在ワークが置かれている位置や姿勢に関係なく、ワーク上の加工したい形状の位置関係の情報のみを用いて、傾斜面を定義するためのパラメータを決定することができるので、ワークが置かれている位置や姿勢が変化したとき傾斜面を定義するためのパラメータを求め直したり、ワークが置かれている位置や姿勢を、傾斜面を定義するためのパラメータを定めたときに想定したワークの位置および姿勢に合わせたりする作業が不要となり、加工を簡単に早く行うことができる。   As described above, the numerical controller 40 according to the first embodiment defines the inclined surface by using only the positional relationship information of the shape to be machined on the workpiece, regardless of the position and posture where the workpiece is currently placed. Parameters can be determined, so when the position or posture where the workpiece is placed changes, the parameters for defining the inclined surface can be obtained again, or the position or posture where the workpiece is placed can be The work for adjusting the position and posture of the workpiece assumed when the parameters for defining the workpiece are determined is not required, and the machining can be performed easily and quickly.

また、実施の形態1に係わる数値制御装置40は、現在設定されている傾斜面の位置と姿勢の情報を操作画面等に出力することにより、次の加工プログラム指令によって工具がどのように移動するかを作業者が把握できるようになり、作成した加工プログラムの動作確認を行う際にプログラム作成ミスによるワークと工具や機械との干渉を未然に検知することができる。   Further, the numerical controller 40 according to the first embodiment outputs information on the position and orientation of the currently set inclined surface to the operation screen and the like, so that the tool moves according to the next machining program command. This makes it possible for the operator to grasp the above, and when checking the operation of the created machining program, it is possible to detect in advance the interference between the workpiece and the tool or machine due to a program creation error.

実施の形態2.
図3は、この発明の実施の形態2に係わる数値制御装置の構成を示すブロック図である。
この発明の実施の形態2に係わる数値制御装置40Bは、図3に示すように、実施の形態1に係わる数値制御装置40の回転中心軸・基準角度設定手段2と回転角度取得手段3の代わりにテーブル回転軸の回転中心軸・基準角度設定手段18とテーブル回転角度取得手段19を有することが異なっており、それ以外は同様であるので、同様な部分に同じ符号を付記して説明は省略する。
テーブル回転角度取得手段19は、プログラム解析部51から機械のテーブル回転軸の角度を取得する。
Embodiment 2. FIG.
FIG. 3 is a block diagram showing the configuration of the numerical control apparatus according to the second embodiment of the present invention.
As shown in FIG. 3, a numerical control device 40B according to the second embodiment of the present invention replaces the rotation center axis / reference angle setting means 2 and the rotation angle acquisition means 3 of the numerical control device 40 according to the first embodiment. The table rotation axis / reference angle setting means 18 and the table rotation angle acquisition means 19 are different from each other, and the other parts are the same. To do.
The table rotation angle acquisition unit 19 acquires the angle of the table rotation axis of the machine from the program analysis unit 51.

次に、この実施の形態2に係わる数値制御装置40Bの動作について説明する。図4は、この実施の形態2における傾斜面のパラメータを設定した時の機械とワークの位置関係を表した図である。
第1の座標系12は、実施の形態1と同様に、機械の駆動軸方向と座標軸方向が一致するように設定されている。しかし、実施の形態1と異なり、機械のテーブルが回転機構を有し、X軸まわりに回転する第1回転テーブル26の上に、Z軸まわりに回転する第2回転テーブル27が載る構造となっている。以下の説明においては、第1回転テーブル26の回転軸をA軸24、第2回転テーブル27の回転軸をC軸25と呼ぶ。傾斜面21のパラメータを設定する時のA軸24とC軸25の回転角度はともに0°であったとする。このときのA軸24とC軸25の回転角度を基準角度とする。
Next, the operation of the numerical controller 40B according to the second embodiment will be described. FIG. 4 is a diagram showing the positional relationship between the machine and the workpiece when the parameters of the inclined surface in the second embodiment are set.
As in the first embodiment, the first coordinate system 12 is set so that the drive axis direction of the machine matches the coordinate axis direction. However, unlike the first embodiment, the machine table has a rotation mechanism, and the second rotation table 27 rotating around the Z axis is mounted on the first rotation table 26 rotating around the X axis. ing. In the following description, the rotation axis of the first rotation table 26 is referred to as an A axis 24, and the rotation axis of the second rotation table 27 is referred to as a C axis 25. It is assumed that both the rotation angles of the A axis 24 and the C axis 25 when setting the parameters of the inclined surface 21 are 0 °. The rotation angle of the A axis 24 and the C axis 25 at this time is set as a reference angle.

傾斜面のパラメータ設定手段1と傾斜面の位置および姿勢設定手段4の動作は、実施の形態1と同様であり、第1の座標系12からみた加工プログラムを作成したときの第2の座標系13の原点位置pofsと姿勢を表す座標変換行列Rが、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6に設定される。 The operations of the parameter setting means 1 of the inclined surface and the position and posture setting means 4 of the inclined surface are the same as those in the first embodiment, and the second coordinate system when the machining program viewed from the first coordinate system 12 is created. 13 origin position p ofs and a coordinate transformation matrix R representing the attitude are set in the origin position and attitude setting means 6 of the second coordinate system viewed from the first coordinate system.

次に、テーブル回転軸の回転中心軸・基準角度設定手段18、テーブル回転角度取得手段19および基準座標系設定手段5の動作について説明する。図5は、この実施の形態2における、加工を開始するときの機械とワークの位置関係を表した図である。
加工を開始するときには、A軸24とC軸25が基準角度と異なる角度に移動し、ワーク30の姿勢が傾斜面21のパラメータを設定したときとは異なった姿勢となっている。このような場合、第1の座標系12から、本来加工したい傾斜面に沿った座標系(加工を開始するときの第2の座標系32)を設定するための傾斜面のパラメータは、最初に設定した傾斜面のパラメータとは異なる値となる。したがって、従来の数値制御装置においてこの問題を回避するには、第1の座標系12からみた、加工を開始するときの第2の座標系32の原点位置およびロール角、ピッチ角およびヨー角などの姿勢パラメータを求め直したり、A軸24とC軸25をそれぞれ基準角度に割り出したりしてから加工を開始する必要があった。
Next, the operations of the rotation center axis / reference angle setting means 18 of the table rotation axis, the table rotation angle acquisition means 19 and the reference coordinate system setting means 5 will be described. FIG. 5 is a diagram showing the positional relationship between the machine and the workpiece when machining is started in the second embodiment.
When machining is started, the A-axis 24 and the C-axis 25 are moved to an angle different from the reference angle, and the posture of the workpiece 30 is different from that when the parameters of the inclined surface 21 are set. In such a case, the parameters of the inclined surface for setting the coordinate system along the inclined surface to be originally processed (the second coordinate system 32 when processing is started) from the first coordinate system 12 are first set as follows. The value is different from the set slope parameter. Therefore, in order to avoid this problem in the conventional numerical control apparatus, the origin position and roll angle, pitch angle, yaw angle, etc. of the second coordinate system 32 when starting machining, as viewed from the first coordinate system 12, etc. It is necessary to start machining after re-determining the posture parameters of the first axis and indexing the A-axis 24 and the C-axis 25 to the respective reference angles.

一方、この実施の形態2では、次のように基準座標系を導入することで加工開始時のA軸24とC軸25の回転角度が基準角度と異なるような場合においても同じ傾斜面21のパラメータで加工を行うことができるようにしている。
A軸24とC軸25が基準角度のときに第1の座標系12と一致し、ワーク30に固定された座標系を基準座標系31とし、第1の座標系12からみた基準座標系31の原点位置と姿勢を求める。
この実施の形態2では、第1の座標系12を、X軸まわりに現在のA軸24の角度だけ回転させ、さらに回転後の座標系のZ軸まわりに現在のC軸25の角度だけ回転させた座標系を基準座標系31とする。第1の座標系12からみた基準座標系31の原点位置および姿勢を表す座標変換行列は、実施の形態1と同様の演算を行うことにより求めることができる。但し、この実施の形態2では、実施の形態1と異なり、回転の操作をA軸24とC軸25に関して2回連続して行うこととなる。
テーブル回転軸の回転中心軸・基準角度設定手段18は、テーブル回転中心軸の位置と回転軸方向ならびに基準角度を作業者があらかじめパラメータとして入力しておいた値を取得して、基準座標系設定手段5に設定する。
On the other hand, in the second embodiment, by introducing the reference coordinate system as follows, even when the rotation angle of the A axis 24 and the C axis 25 at the start of machining is different from the reference angle, Processing can be performed with parameters.
When the A axis 24 and the C axis 25 are at the reference angle, the coordinate system coincides with the first coordinate system 12 and is fixed to the work 30 as a reference coordinate system 31, and the reference coordinate system 31 viewed from the first coordinate system 12. Find the origin position and orientation of.
In the second embodiment, the first coordinate system 12 is rotated about the X axis by the current angle of the A axis 24, and further rotated about the Z axis of the rotated coordinate system by the current angle of the C axis 25. This coordinate system is defined as a reference coordinate system 31. A coordinate transformation matrix representing the origin position and orientation of the reference coordinate system 31 viewed from the first coordinate system 12 can be obtained by performing the same calculation as in the first embodiment. However, in the second embodiment, unlike the first embodiment, the rotation operation is performed twice with respect to the A axis 24 and the C axis 25 continuously.
The rotation center axis / reference angle setting means 18 of the table rotation axis obtains values that the operator has previously input as parameters, the position, rotation axis direction and reference angle of the table rotation center axis, and sets the reference coordinate system. Set to means 5.

また、テーブル回転角度取得手段19は、加工を開始するときのテーブル回転軸の回転角度をプログラム解析部51から取得して、基準座標系設定手段5に設定する。テーブル回転角度取得手段19から取得できるのはプログラムで指令された回転角度であるが、機械駆動部54においてテーブル回転軸の回転角度は指令された回転角度に追従されるように駆動されるため、指令された回転角度を現在のテーブル回転軸の回転角度として用いることができる。
なお、加工を開始するときのテーブル回転軸の回転角度を、機械駆動部54に角度検出器をとりつけて取得するようにしてもよい。
Further, the table rotation angle acquisition unit 19 acquires the rotation angle of the table rotation axis when starting machining from the program analysis unit 51 and sets it in the reference coordinate system setting unit 5. What can be acquired from the table rotation angle acquisition means 19 is the rotation angle commanded by the program, but since the rotation angle of the table rotation axis is driven by the machine drive unit 54 so as to follow the commanded rotation angle, The commanded rotation angle can be used as the rotation angle of the current table rotation axis.
Note that the rotation angle of the table rotation shaft when processing is started may be obtained by attaching an angle detector to the mechanical drive unit 54.

次に、基準座標系設定手段5では、第1の座標系12からみた基準座標系31の位置と、姿勢を表す座標変換行列を上記の演算により求めて、第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6に設定する。
第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6における動作は、実施の形態1の場合と同様であり、実施の形態1の場合と同様の演算により第1の座標系12からみた第2の座標系32の原点位置と姿勢を表す座標変換行列を求めて座標変換部52に設定する。
Next, the reference coordinate system setting means 5 obtains the coordinate transformation matrix representing the position and orientation of the reference coordinate system 31 as seen from the first coordinate system 12 by the above calculation, and the second as seen from the first coordinate system. The origin position and orientation setting means 6 of the coordinate system is set.
The operation of the origin position and orientation setting means 6 in the second coordinate system as viewed from the first coordinate system is the same as that in the first embodiment, and the first coordinate is calculated by the same calculation as in the first embodiment. A coordinate transformation matrix representing the origin position and orientation of the second coordinate system 32 viewed from the system 12 is obtained and set in the coordinate transformation unit 52.

プログラム解析部51、座標変換部52、機械移動指令計算部53、機械駆動部54、第1の座標系からみた第2の座標系の原点位置および姿勢取得手段7、姿勢パラメータ演算手段8、原点位置および姿勢パラメータ出力手段9の動作は、実施の形態1における動作とまったく同様である。   Program analysis unit 51, coordinate conversion unit 52, machine movement command calculation unit 53, machine drive unit 54, origin position and orientation acquisition unit 7 in the second coordinate system viewed from the first coordinate system, orientation parameter calculation unit 8, origin The operation of the position and orientation parameter output means 9 is exactly the same as the operation in the first embodiment.

このように実施の形態2に係わる数値制御装置40Bは、テーブルの回転軸の回転角度の値に関係なく、ワーク上の加工したい形状の位置関係の情報のみを用いて傾斜面を定義するためのパラメータを決定することができるので、現在のテーブルの回転軸の回転角度をもとに傾斜面を定義するためのパラメータを求め直したり、テーブルの回転軸の回転角度を傾斜面のパラメータを定めたときに想定した回転角度に変更したりする作業が不要となり、傾斜面の指定をより簡単に早く設定できるようになって、加工を簡単に早く行うことができる。
また、第1の座標系から基準座標系に至るまでの回転操作を異なる回転中心軸周りにそれぞれ指定した基準角度分回転させる操作とすることにより、第1の座標系と基準座標系との間の関係について、より自由度の高い設定が可能となるため、傾斜面を定義するためのパラメータの定義を作業者にとってよりわかりやすいワークの姿勢において行うことができるようになり、傾斜面の指定をより簡単に早く設定できるようになるという効果がある。
また、回転軸を有するテーブルを備える機械の場合でも、傾斜面を指定するためのパラメータを、テーブルの回転軸の回転角度がどのような角度であっても、常に決まった角度におけるパラメータで定義することができるようになり、傾斜面の指定をより簡単に早く設定できる。
As described above, the numerical control device 40B according to the second embodiment defines the inclined surface using only the positional relationship information of the shape to be machined on the workpiece regardless of the rotation angle value of the rotation axis of the table. Since the parameters can be determined, the parameters for defining the inclined surface can be recalculated based on the current rotation angle of the table rotation axis, or the rotation angle of the table rotation axis can be determined There is no need to change the rotation angle that is assumed at times, and the designation of the inclined surface can be set easily and quickly, so that the machining can be performed easily and quickly.
In addition, the rotation operation from the first coordinate system to the reference coordinate system is made to rotate by a specified reference angle around different rotation center axes, so that the first coordinate system and the reference coordinate system are Since it is possible to set a higher degree of freedom in relation to the above, it is possible to define parameters for defining the inclined surface in a work posture that is easier to understand for the worker, and to specify the inclined surface more There is an effect that it can be set easily and quickly.
Even in the case of a machine having a table having a rotation axis, the parameter for designating the inclined surface is always defined by a parameter at a fixed angle regardless of the rotation angle of the rotation axis of the table. It becomes possible to set the inclined surface more easily and quickly.

なお、この実施の形態2では、テーブルの回転軸の軸数が2であり、回転軸がX軸まわりとZ軸まわりである場合について説明したが、軸数が2以外であってもよく、また回転軸はいずれの方向であってもよい。   In the second embodiment, the number of rotation axes of the table is 2 and the rotation axes are around the X axis and the Z axis. However, the number of axes may be other than 2, The rotation axis may be in any direction.

実施の形態3.
図6は、この発明の実施の形態3に係わる数値制御装置の構成を示すブロック図である。
この発明の実施の形態3に係わる数値制御装置40Cは、図6に示すように、実施の形態1に係わる数値制御装置40の傾斜面のパラメータ設定手段1、回転中心軸・基準角度設定手段2、回転角度取得手段3、傾斜面の位置および姿勢設定手段4、基準座標系設定手段5および第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6の代わりに座標系回転中心軸・回転角度設定手段55、第1の座標系から見た現在の第2の座標系の原点位置および姿勢取得手段56および第1の座標系から見た新しい第2の座標系の原点位置および姿勢設定手段57を有することが異なっており、それ以外は同様であるので、同様な部分に同じ符号を付記して説明は省略する。
Embodiment 3 FIG.
FIG. 6 is a block diagram showing the configuration of the numerical control apparatus according to Embodiment 3 of the present invention.
As shown in FIG. 6, the numerical control device 40C according to the third embodiment of the present invention includes an inclined surface parameter setting means 1, a rotation center axis / reference angle setting means 2 of the numerical control device 40 according to the first embodiment. , Rotation angle acquisition means 3, inclined surface position and orientation setting means 4, reference coordinate system setting means 5, and coordinate system rotation instead of the origin position and orientation setting means 6 of the second coordinate system as viewed from the first coordinate system Center axis / rotation angle setting means 55, current origin position of second coordinate system as seen from first coordinate system and attitude acquisition means 56 and origin position of new second coordinate system as seen from first coordinate system And the posture setting means 57 are different, and the rest is the same, and the same parts are denoted by the same reference numerals and the description thereof is omitted.

座標系回転中心軸・回転角度設定手段55は、入力された座標系回転中心軸の位置と軸方向ベクトルとそのベクトルまわりの回転角度を、第1の座標系からみた新しい第2の座標系の原点位置および姿勢設定手段57に設定する。
第1の座標系から見た現在の第2の座標系の原点位置および姿勢取得手段56は、座標変換部52から第1の座標系から見た現在の第2の座標系の原点位置および姿勢を取得して、第1の座標系からみた新しい第2の座標系の原点位置および姿勢設定手段57に設定する。
The coordinate system rotation center axis / rotation angle setting means 55 indicates the input position of the coordinate system rotation center axis, the axial direction vector, and the rotation angle around the vector in the new second coordinate system as viewed from the first coordinate system. The origin position and orientation setting means 57 is set.
The origin position and orientation acquisition unit 56 of the current second coordinate system viewed from the first coordinate system is the origin position and orientation of the current second coordinate system viewed from the coordinate system 52 from the first coordinate system. Is set in the origin position and orientation setting means 57 of the new second coordinate system viewed from the first coordinate system.

第1の座標系から見た新しい第2の座標系の原点位置および姿勢設定手段57は、座標系回転中心軸の位置と軸方向ベクトルとそのベクトルまわりの回転角度と、第1の座標系から見た現在の第2の座標系の原点位置および姿勢から、第1の座標系からみた新しい第2の座標系の原点位置および姿勢を求めて座標変換部52に設定する。   The origin position and orientation setting means 57 of the new second coordinate system viewed from the first coordinate system includes the position of the coordinate system rotation center axis, the axial direction vector, the rotation angle around the vector, and the first coordinate system. The origin position and orientation of the new second coordinate system viewed from the first coordinate system are obtained from the viewed origin position and orientation of the current second coordinate system and set in the coordinate conversion unit 52.

次に、この実施の形態3に係わる数値制御装置40Cの動作について説明する。図7は、この実施の形態3における加工ワークの形状を表した図である。
実施の形態3に係わる加工ワーク70は、円柱であり、外周に沿って同一形状の6つの面に加工する。各面には、面に沿った座標軸72、73、74、75、76、77が設定されている。また、第1の座標系12が、機械の駆動軸方向と座標系回転中心軸78が一致するように設定されている。
この場合、最初にひとつの面に沿った座標系を第2の座標系に設定して、異なる面に対しては、座標系回転中心軸78まわりに所定の回転角度だけ回転させて別の新しい第2の座標系として設定することを順次行えば、簡単にすべての面を同一の加工プログラムで加工することができる。
Next, the operation of the numerical controller 40C according to the third embodiment will be described. FIG. 7 is a diagram showing the shape of the workpiece in the third embodiment.
The workpiece 70 according to the third embodiment is a cylinder and is processed into six surfaces having the same shape along the outer periphery. On each surface, coordinate axes 72, 73, 74, 75, 76, 77 along the surface are set. The first coordinate system 12 is set so that the drive axis direction of the machine and the coordinate system rotation center axis 78 coincide.
In this case, the coordinate system along one surface is first set as the second coordinate system, and a different surface is rotated by a predetermined rotation angle around the coordinate system rotation center axis 78 to obtain another new one. By sequentially setting the second coordinate system, all surfaces can be easily machined with the same machining program.

第1の座標系12における座標系回転中心軸78の位置をpcrot、座標系回転中心軸78の軸方向ベクトルをrcrotとおく。また、最初の時点で、第2の座標系として、1番目に第2の座標系72が設定されているものとする。
第1の座標系から見た現在の第2の座標系の原点位置および姿勢取得手段56は、座標変換部52に設定されている、第1の座標系12から見た現在の第2の座標系72の原点位置pofsprevおよび姿勢を表す座標変換行列Rprevを取得して、第1の座標系からみた新しい第2の座標系の原点位置および姿勢設定手段57に設定する。
The position of the coordinate system rotation center axis 78 in the first coordinate system 12 is set as p crot , and the axial direction vector of the coordinate system rotation center axis 78 is set as r crot . Further, it is assumed that the second coordinate system 72 is set first as the second coordinate system at the first time point.
The origin position and orientation acquisition unit 56 of the current second coordinate system viewed from the first coordinate system is set in the coordinate conversion unit 52, and the current second coordinate viewed from the first coordinate system 12 The origin position p ofsprev and the coordinate transformation matrix R prev representing the attitude of the system 72 are acquired and set in the origin position and attitude setting means 57 of the new second coordinate system viewed from the first coordinate system.

座標系回転中心軸・回転角度設定手段55は、入力された座標系回転中心軸78の位置pcrot、軸方向ベクトルrcrotおよびそのベクトルまわりの回転角度θcrotを、第1の座標系からみた新しい第2の座標系の原点位置および姿勢設定手段57に設定する。座標系回転中心軸78の位置pcrot、軸方向ベクトルrcrotおよびそのベクトルまわりの回転角度θcrotは、通常は加工プログラムに記述される。
第1の座標系から見た新しい第2の座標系の原点位置および姿勢設定手段57は、座標系回転中心軸78の位置と軸方向ベクトルとそのベクトルまわりの回転角度と、第1の座標系12から見た現在の第2の座標系72の原点位置および姿勢を表す座標変換行列から、第1の座標系12からみた新しい第2の座標系73の原点位置pofsnewおよび姿勢Rnewを求める。第1の座標系12からみた新しい第2の座標系73の原点位置pofsnewおよび姿勢を表す座標変換行列Rnewは、式(14)、式(15)により求める。
The coordinate system rotation center axis / rotation angle setting means 55 viewed the input position p rot of the coordinate system rotation center axis 78, the axial direction vector r crot and the rotation angle θ rot around the vector from the first coordinate system. The origin position and orientation setting means 57 of the new second coordinate system is set. The position p crot of the coordinate system rotation center axis 78, the axial vector r crot and the rotation angle θ crot about the vector are usually described in the machining program.
The origin position and orientation setting means 57 of the new second coordinate system viewed from the first coordinate system includes the position of the coordinate system rotation center axis 78, the axial direction vector, the rotation angle around the vector, the first coordinate system. From the coordinate transformation matrix representing the origin position and orientation of the current second coordinate system 72 viewed from 12, a new origin position p ofsnew and orientation R new of the second coordinate system 73 viewed from the first coordinate system 12 are obtained. . An origin position p ofsnew of the new second coordinate system 73 viewed from the first coordinate system 12 and a coordinate transformation matrix R new representing an attitude are obtained by Expressions (14) and (15).

そして、第1の座標系から見た新しい第2の座標系の原点位置および姿勢設定手段57は、式(14)、式(15)の演算により求めた第1の座標系12からみた新しい第2の座標系73の原点位置pofsnewおよび姿勢を表す座標変換行列Rnewを座標変換部52に設定する。このようにして現在の第2の座標系72の原点位置および姿勢から、新しい第2の座標系73の原点位置および姿勢を求めることができ、これを繰り返すことにより、他の第2の座標系74〜77の原点位置および姿勢を求めることができる。 Then, the origin position and orientation setting means 57 of the new second coordinate system as seen from the first coordinate system is the new second coordinate system as seen from the first coordinate system 12 obtained by the calculations of the equations (14) and (15). The coordinate conversion unit 52 sets the origin position p ofsnew of the coordinate system 73 of 2 and the coordinate conversion matrix R new representing the posture. In this way, the origin position and orientation of the new second coordinate system 73 can be obtained from the origin position and orientation of the current second coordinate system 72, and by repeating this, another second coordinate system can be obtained. 74 to 77 origin positions and postures can be obtained.

プログラム解析部51、座標変換部52、機械移動指令計算部53、機械駆動部54、第1の座標系からみた第2の座標系の原点位置および姿勢取得手段7、姿勢パラメータ演算手段8、原点位置および姿勢パラメータ出力手段9の動作は、実施の形態1における動作とまったく同様であるので、説明は省略する。   Program analysis unit 51, coordinate conversion unit 52, machine movement command calculation unit 53, machine drive unit 54, origin position and orientation acquisition unit 7 in the second coordinate system viewed from the first coordinate system, orientation parameter calculation unit 8, origin Since the operation of the position and orientation parameter output means 9 is exactly the same as the operation in the first embodiment, description thereof is omitted.

この実施の形態3によれば、丸物ワークの外周上の複数の場所に同一形状を加工するような場合や、円周上の複数の場所に同一形状を加工するような場合は、複数の加工する場所のうちのある場所を基準としたときに、それぞれの加工する場所がある円の座標系回転中心軸78と、それぞれの場所の基準とした場所からの回転角度は、図面から容易に読み取ることができ、この座標系回転中心軸78と回転角度を指定するだけで、それぞれの場所を加工するための傾斜面加工のパラメータを求めることなしに、所望の加工を行うことができるようになり、加工を簡単に早く行うことができるようになるという効果がある。   According to the third embodiment, when processing the same shape at a plurality of locations on the outer periphery of a round workpiece, or when processing the same shape at a plurality of locations on the circumference, a plurality of When a certain place among the places to be processed is used as a reference, the coordinate system rotation center axis 78 of the circle in which each place to be processed is present, and the rotation angle from the reference place of each place can be easily determined from the drawings. It can be read, and by simply designating the coordinate system rotation center axis 78 and the rotation angle, the desired machining can be performed without obtaining the parameters of the inclined surface machining for machining each location. Therefore, there is an effect that processing can be performed easily and quickly.

実施の形態4.
図8は、この発明の実施の形態4に係わる数値制御装置の構成を示すブロック図である。
この発明の実施の形態4に係わる数値制御装置40Dは、図8に示すように、実施の形態1に係わる数値制御装置40の傾斜面のパラメータ設定手段1、回転中心軸・基準角度設定手段2、回転角度取得手段3、傾斜面の位置および姿勢設定手段4および基準座標系設定手段5の代わりに第1の基準座標値設定手段58および第2の基準座標値設定手段59を有することが異なっており、それ以外は同様であるので、同様な部分に同じ符号を付記して説明は省略する。
Embodiment 4 FIG.
FIG. 8 is a block diagram showing a configuration of a numerical control apparatus according to Embodiment 4 of the present invention.
As shown in FIG. 8, the numerical control device 40D according to the fourth embodiment of the present invention includes an inclined surface parameter setting means 1, a rotation center axis / reference angle setting means 2 of the numerical control device 40 according to the first embodiment. The rotation angle acquisition unit 3, the position and orientation setting unit 4 of the inclined surface, and the reference coordinate system setting unit 5 are replaced with a first reference coordinate value setting unit 58 and a second reference coordinate value setting unit 59. Since the rest is the same, the same reference numerals are given to the same parts and the description is omitted.

第1の基準座標値設定手段58は、入力された第1の基準座標値を第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6に設定する。
第2の基準座標値設定手段59は、入力された第2の基準座標値を第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6に設定する。
第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6は、第1の基準座標値と第2の基準座標値から第1の座標系からみた第2の座標系の原点位置および姿勢を求めて座標変換部52に設定する。
The first reference coordinate value setting means 58 sets the input first reference coordinate value in the origin position and orientation setting means 6 of the second coordinate system as viewed from the first coordinate system.
The second reference coordinate value setting means 59 sets the input second reference coordinate value in the origin position and orientation setting means 6 of the second coordinate system as viewed from the first coordinate system.
The origin position and orientation setting means 6 of the second coordinate system viewed from the first coordinate system is the origin of the second coordinate system viewed from the first coordinate system from the first reference coordinate value and the second reference coordinate value. The position and orientation are obtained and set in the coordinate conversion unit 52.

次に、この実施の形態4に係わる数値制御装置の動作について説明する。図9は、この実施の形態4における第2の座標系の設定方法を示した図である。図9(a)には、機械テーブル17に設置したワーク80が表されている。そして、傾斜面21の同一直線上に並ばない3点の座標系指定用基準点を第1の座標系82からみた位置ベクトル85、86、87を図示してある。また、傾斜面21には第2の座標系83が指定されている。
また、図9(b)には、図面に記載された傾斜面の加工形状81が表されている。そして、加工プログラムにおける指令位置が属する座標系84と加工プログラムにおける指令位置が属する座標系84からみた座標系指定用基準点の位置ベクトル88、89、90が図示されている。
Next, the operation of the numerical control apparatus according to the fourth embodiment will be described. FIG. 9 is a diagram showing a second coordinate system setting method in the fourth embodiment. FIG. 9A shows a work 80 installed on the machine table 17. Further, position vectors 85, 86, and 87 are shown in which three coordinate system designating reference points that are not aligned on the same straight line of the inclined surface 21 are viewed from the first coordinate system 82. A second coordinate system 83 is designated for the inclined surface 21.
Further, FIG. 9B shows a machining shape 81 of the inclined surface described in the drawing. In addition, position vectors 88, 89, and 90 of the coordinate system designating reference point viewed from the coordinate system 84 to which the command position in the machining program belongs and the coordinate system 84 to which the command position in the machining program belongs are shown.

まず、作業者は図面に記載された加工形状81のうち、同一直線上にない3点をえらんで座標系指定用基準点とし、加工プログラムにおける指令値が属する座標系84からみた各座標系指定用基準点の位置を図面から読み取って、第1の基準座標値とする。
次に、ワーク80を機械に設置し、機械の第1の座標系82からみた各座標系指定用基準点の位置を、タッチプローブ等を用いて測定し、第2の基準座標値とする。なお、第1の座標系82は、機械の駆動軸方向と座標軸方向が一致するように設定されている。
First, the operator selects three points that are not on the same straight line among the machining shapes 81 described in the drawing as coordinate system designation reference points, and designates each coordinate system as seen from the coordinate system 84 to which the command value in the machining program belongs. The position of the reference point for use is read from the drawing and set as the first reference coordinate value.
Next, the workpiece 80 is placed on the machine, and the position of each coordinate system designating reference point as viewed from the first coordinate system 82 of the machine is measured using a touch probe or the like to obtain a second reference coordinate value. The first coordinate system 82 is set so that the drive axis direction of the machine coincides with the coordinate axis direction.

第1の基準座標値をp11、p12、p13、第2の基準座標値をp21、p22、p23とする。第1の座標系82からみた第1の基準座標値における位置と、第2の座標系83が設定されたと仮定したときのその座標系からみた第2の基準座標値における位置が一致するように、第1の座標系82からみた第2の座標系83の原点位置および姿勢を表す座標変換行列を定めることにより、指定した傾斜面での指定した形状の加工を行うことができる。 The first reference coordinate values are p 11 , p 12 , p 13 , and the second reference coordinate values are p 21 , p 22 , p 23 . The position in the first reference coordinate value viewed from the first coordinate system 82 and the position in the second reference coordinate value viewed from the coordinate system when the second coordinate system 83 is assumed to be set coincide with each other. By defining a coordinate transformation matrix representing the origin position and orientation of the second coordinate system 83 as viewed from the first coordinate system 82, it is possible to process the specified shape on the specified inclined surface.

第1の基準座標値p11、p12、p13、第2の基準座標値p21、p22、p23を用いて第1の座標系82からみた第2の座標系の原点位置pofs3および姿勢を表す座標変換行列Rを求める手順を以下で説明する。
第1の基準座標値p11、p12、p13は、第2の基準座標値p21、p22、p23、第1の座標系からみた第2の座標系の原点位置pofs3および姿勢を表す座標変換行列Rから式(16)、式(17)、式(18)に従って求める。
The origin position p ofs3 of the second coordinate system viewed from the first coordinate system 82 using the first reference coordinate values p 11 , p 12 , p 13 and the second reference coordinate values p 21 , p 22 , p 23. A procedure for obtaining the coordinate transformation matrix R 3 representing the posture and the posture will be described below.
The first reference coordinate values p 11 , p 12 , and p 13 are the second reference coordinate values p 21 , p 22 , p 23 , the origin position p ofs3 and the posture of the second coordinate system as viewed from the first coordinate system. equation (16) from the coordinate transformation matrix R 3 representing the formula (17), determined in accordance with equation (18).

これらの式から式(19)、式(20)の関係式を得る。   From these equations, the relational expressions of the equations (19) and (20) are obtained.

したがって、r11、r12、r13、r21、r22、r23をそれぞれ式(21)、式(22)、式(23)、式(24)、式(25)、式(26)とすると、式(27)の関係式が得られる。なお、記号×はベクトルの外積を表す。 Therefore, r 11 , r 12 , r 13 , r 21 , r 22 , and r 23 are respectively expressed by formula (21), formula (22), formula (23), formula (24), formula (25), and formula (26). Then, the relational expression of Expression (27) is obtained. The symbol x represents the outer product of vectors.

そして、式(27)の右辺の右側の行列から、3点の座標系指定用基準点が同一直線上にない場合には逆行列を求めることができ、座標変換行列Rは式(28)により求めることができる。この式(28)と式(16)を用いて、pofs3を式(29)により求めることができる。 Then, from the matrix on the right side of the right side of Expression (27), if the three coordinate system designating reference points are not on the same straight line, an inverse matrix can be obtained, and the coordinate transformation matrix R 3 is expressed by Expression (28). It can ask for. Using this equation (28) and equation (16), p ofs3 can be obtained from equation (29).

第1の基準座標値および第2の基準座標値は通常は加工プログラムに記述されて入力される。
第1の基準座標値設定手段58および第2の基準座標値設定手段59は、入力された第1の基準座標値と第2の基準座標値を第2の座標系の原点位置および姿勢設定手段6に設定する。
第1の座標系からみた第2の座標系の原点位置および姿勢設定手段6は、第1の基準座標値と第2の基準座標値から、上記の演算により第1の座標系からみた第2の座標系の原点位置および姿勢を求めて座標変換部52に設定する。
The first reference coordinate value and the second reference coordinate value are normally described and input in a machining program.
The first reference coordinate value setting means 58 and the second reference coordinate value setting means 59 use the input first reference coordinate value and second reference coordinate value as the origin position and orientation setting means of the second coordinate system. Set to 6.
The origin position and orientation setting means 6 of the second coordinate system viewed from the first coordinate system is the second position viewed from the first coordinate system by the above calculation from the first reference coordinate value and the second reference coordinate value. The origin position and orientation of the coordinate system are obtained and set in the coordinate conversion unit 52.

なお、プログラム解析部51、座標変換部52、機械移動指令計算部53、機械駆動部54、第1の座標系からみた第2の座標系の原点位置および姿勢取得手段7、姿勢パラメータ演算手段8および原点位置および姿勢パラメータ出力手段9の動作は、実施の形態1における動作とまったく同様であるので、説明は省略する。   Note that the program analysis unit 51, the coordinate conversion unit 52, the machine movement command calculation unit 53, the machine drive unit 54, the origin position and posture acquisition unit 7 of the second coordinate system viewed from the first coordinate system, and the posture parameter calculation unit 8 Since the operation of the origin position and orientation parameter output means 9 is exactly the same as the operation in the first embodiment, description thereof is omitted.

このように実施の形態4に係わる数値制御装置は、図面上に記載された形状における各基準点の位置情報と、ワークを機械に設置したときの各基準点の位置を測定して得られた位置情報を設定するだけで、図面上の情報から複雑な計算を行って傾斜面を指定するためのパラメータを求めることなしに、指定した傾斜面での指定した形状の加工を行うことができ、加工を簡単に早く行うことができるようになるという効果がある。   As described above, the numerical control device according to the fourth embodiment is obtained by measuring the position information of each reference point in the shape described on the drawing and the position of each reference point when the workpiece is installed in the machine. By simply setting the position information, it is possible to perform the processing of the specified shape on the specified inclined surface without calculating the parameters for specifying the inclined surface by performing complex calculations from the information on the drawing, There is an effect that processing can be performed easily and quickly.

この発明の実施の形態1に係わる数値制御装置の構成を示すブロック図である。It is a block diagram which shows the structure of the numerical control apparatus concerning Embodiment 1 of this invention. この実施の形態1における機械とワークの位置関係を表した図である。It is a figure showing the positional relationship of the machine in this Embodiment 1, and a workpiece | work. この発明の実施の形態2に係わる数値制御装置の構成を示すブロック図である。It is a block diagram which shows the structure of the numerical control apparatus concerning Embodiment 2 of this invention. この実施の形態2における傾斜面のパラメータを設定した時の機械とワークの位置関係を表した図である。It is a figure showing the positional relationship of a machine and a workpiece | work when the parameter of the inclined surface in this Embodiment 2 is set. この実施の形態2における加工を開始するときの機械とワークの位置関係を表した図である。It is a figure showing the positional relationship of a machine and a workpiece | work when the process in this Embodiment 2 is started. この発明の実施の形態3に係わる数値制御装置の構成を示すブロック図である。It is a block diagram which shows the structure of the numerical control apparatus concerning Embodiment 3 of this invention. この実施の形態3における加工ワークの形状を表した図である。It is a figure showing the shape of the workpiece in this Embodiment 3. この発明の実施の形態4に係わる数値制御装置の構成を示すブロック図である。It is a block diagram which shows the structure of the numerical control apparatus concerning Embodiment 4 of this invention. この実施の形態4における第2の座標系の設定方法を示した図である。It is the figure which showed the setting method of the 2nd coordinate system in this Embodiment 4. FIG.

1 傾斜面のパラメータ設定手段、2 回転中心軸・基準角度設定手段、3 回転角度取得手段、4 傾斜面の位置および姿勢設定手段、5 基準座標系設定手段、6 第1の座標系からみた第2の座標系の原点位置および姿勢設定手段、7 第1の座標系からみた第2の座標系の原点位置および姿勢取得手段、8 姿勢パラメータ演算手段、9 原点位置および姿勢パラメータ出力手段、10、20 加工プログラムを作成した時のワーク、11 機械に設置したときのワーク、12 第1の座標系、13 加工プログラムを作成したときの第2の座標系、14 基準座標系、15 機械に設置したときの第2の座標系、16 回転中心軸、17 機械テーブル、18 テーブル回転軸の回転中心軸・基準角度設定手段、19 テーブル回転角度取得手段、21 傾斜面、24 第1回転テーブルの回転中心軸(A軸)、25 第2回転テーブルの回転中心軸(B軸)、26 第1回転テーブル、27 第2回転テーブル、30 加工を開始するときのワーク、31 基準座標系、32 加工を開始するときの第2の座標系、40 数値制御装置、50 加工プログラム、51 プログラム解析部、52 座標変換部、53 機械移動指令計算部、54 機械駆動部、55 座標系回転中心軸・回転角度設定手段、56 第1の座標系からみた現在の第2の座標系の原点位置および姿勢取得手段、57 第1の座標系からみた新しい第2の座標系の原点位置および姿勢設定手段、58 第1の基準座標値設定手段、59 第2の基準座標値設定手段、70 加工ワーク、72〜77 機械に設置したときの第2の座標系、78 座標系回転中心軸、80 機械に設置したワーク、81 図面に記載された加工形状、82 第1の座標系、83 第2の座標系、84 加工プログラムにおける指令位置が属する座標系、85〜87 第1の座標系からみた座標系指定用基準点の位置ベクトル、88〜90 加工プログラムにおける指令位置が属する座標系からみた座標系指定用基準点の位置ベクトル。   DESCRIPTION OF SYMBOLS 1 Parameter setting means of inclined surface, 2 Rotation center axis and reference angle setting means, 3 Rotation angle acquisition means, 4 Position and orientation setting means of inclined surface, 5 Reference coordinate system setting means, 6 1st coordinate system seen from 1st coordinate system 2 coordinate system origin position and orientation setting means, 7 second coordinate system origin position and orientation acquisition means viewed from the first coordinate system, 8 orientation parameter calculation means, 9 origin position and orientation parameter output means, 10, 20 Workpiece when creating machining program, 11 Workpiece when installed on machine, 12 First coordinate system, 13 Second coordinate system when creating machining program, 14 Reference coordinate system, 15 Installed on machine Second coordinate system, 16 rotation center axis, 17 machine table, 18 table rotation axis rotation center axis / reference angle setting means, 19 table rotation angle acquisition hand , 21 Inclined surface, 24 Rotation center axis (A axis) of the first turntable, 25 Rotation center axis (B axis) of the second turntable, 26 First turntable, 27 Second turntable, 30 Start processing Workpiece when, 31 reference coordinate system, 32 second coordinate system when starting machining, 40 numerical control device, 50 machining program, 51 program analysis unit, 52 coordinate conversion unit, 53 machine movement command calculation unit, 54 machine Driving unit, 55 coordinate system rotation center axis / rotation angle setting means, 56 origin position and orientation acquisition means of the current second coordinate system viewed from the first coordinate system, 57 new second view viewed from the first coordinate system Origin position and orientation setting means of the coordinate system, 58 first reference coordinate value setting means, 59 second reference coordinate value setting means, 70 machining workpiece, 72-77 second when installed in the machine Coordinate system, 78 coordinate system rotation center axis, 80 workpiece set on machine, 81 machining shape described in drawing, 82 first coordinate system, 83 second coordinate system, 84 coordinate to which command position in machining program belongs System, 85-87 Position vector of a coordinate system designating reference point viewed from the first coordinate system, 88-90 Position vector of a coordinate system designating reference point viewed from the coordinate system to which the command position in the machining program belongs.

Claims (3)

機械の駆動軸方向と座標軸方向が異なる第2の座標系において指令された位置を、座標変換して、機械の駆動軸方向と座標軸方向が一致するように設定された第1の座標系における位置を得るとともに該位置に機械を移動させる数値制御装置において、
上記第1の座標系からみた現在の第2の座標系の原点位置および姿勢を取得する手段と、
座標系回転中心軸および該座標系回転中心軸まわりの回転角度を設定する手段と、
上記現在の傾斜面に指定された第2の座標系を上記座標系回転中心軸まわりに上記回転角度だけ回転させた座標系の原点位置および姿勢を上記第1の座標系からみた新しい第2の座標系の原点位置および姿勢として設定し、上記第1の座標系からみた新しい第2の座標系の原点位置および姿勢を用いて、上記第2の座標系において指令された位置に対して姿勢の変換を含む座標変換を行って上記第1の座標系における位置を得る手段と、
を備えることを特徴とする数値制御装置。
The position in the first coordinate system set so that the drive axis direction of the machine and the coordinate axis direction coincide with each other by performing coordinate conversion on the position commanded in the second coordinate system in which the drive axis direction of the machine is different from the coordinate axis direction. In a numerical control device that obtains and moves the machine to the position,
Means for obtaining the origin position and orientation of the current second coordinate system viewed from the first coordinate system;
Means for setting a coordinate system rotation center axis and a rotation angle around the coordinate system rotation center axis;
A new second view of the origin position and orientation of the coordinate system obtained by rotating the second coordinate system designated for the current inclined plane by the rotation angle around the coordinate system rotation center axis, as viewed from the first coordinate system. Set as the origin position and orientation of the coordinate system, and use the origin position and orientation of the new second coordinate system as seen from the first coordinate system, and change the orientation relative to the commanded position in the second coordinate system. Means for performing coordinate transformation including transformation to obtain a position in the first coordinate system;
A numerical control device comprising:
機械の駆動軸方向と座標軸方向が異なる第2の座標系において指令された位置を、座標変換して、機械の駆動軸方向と座標軸方向が一致するように設定された第1の座標系における位置を得るとともに該位置に機械を移動させる数値制御装置において、
空間内の同一直線上にない3点を座標系指定用基準点としたときに、第1の座標系からみた各上記座標系指定用基準点の座標を第1の基準座標値として設定する手段と、
加工プログラムにおける指令位置が属する座標系からみた各上記座標系指定用基準点の座標を第2の基準座標値として設定する手段と、
上記第1の基準座標値と上記第2の基準座標値に基づいて上記第1の座標系からみた第2の座標系の原点位置および姿勢を設定し、上記第1の座標系からみた第2の座標系の原点位置および姿勢を用いて、上記第2の座標系において指令された位置に対して姿勢の変換を含む座標変換を行って上記第1の座標系における位置を得る手段と、
を備えることを特徴とする数値制御装置。
The position in the first coordinate system set so that the drive axis direction of the machine and the coordinate axis direction coincide with each other by performing coordinate conversion on the position commanded in the second coordinate system in which the drive axis direction of the machine is different from the coordinate axis direction. In a numerical control device that obtains and moves the machine to the position,
Means for setting the coordinates of each of the coordinate system designating reference points as viewed from the first coordinate system as first reference coordinate values when three points that are not on the same straight line in space are used as coordinate system designating reference points. When,
Means for setting the coordinates of each of the coordinate system designating reference points as seen from the coordinate system to which the command position in the machining program belongs, as a second reference coordinate value;
Based on the first reference coordinate value and the second reference coordinate value, the origin position and orientation of the second coordinate system viewed from the first coordinate system are set, and the second position viewed from the first coordinate system is set. Means for obtaining a position in the first coordinate system by performing a coordinate transformation including a transformation of the posture with respect to a position commanded in the second coordinate system using the origin position and the posture of the coordinate system;
A numerical control device comprising:
上記第1の座標系からみたワークの現在の傾斜面に指定された第2の座標系の原点位置および姿勢を取得する手段と、
取得した姿勢の情報から所定の形式の姿勢パラメータを所定の
演算により求める手段と、
上記原点位置と上記姿勢パラメータを出力する手段と、
を備えることを特徴とする請求項1または2に記載の数値制御装置。
Means for obtaining the origin position and orientation of the second coordinate system designated on the current inclined surface of the workpiece as viewed from the first coordinate system;
Means for obtaining posture parameters in a predetermined format from the acquired posture information by a predetermined calculation;
Means for outputting the origin position and the attitude parameters;
The numerical control apparatus according to claim 1, further comprising:
JP2012114768A 2012-05-18 2012-05-18 Numerical controller Expired - Fee Related JP5321712B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012114768A JP5321712B2 (en) 2012-05-18 2012-05-18 Numerical controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012114768A JP5321712B2 (en) 2012-05-18 2012-05-18 Numerical controller

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2006254875A Division JP5020579B2 (en) 2006-09-20 2006-09-20 Numerical controller

Publications (2)

Publication Number Publication Date
JP2012150848A true JP2012150848A (en) 2012-08-09
JP5321712B2 JP5321712B2 (en) 2013-10-23

Family

ID=46792967

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012114768A Expired - Fee Related JP5321712B2 (en) 2012-05-18 2012-05-18 Numerical controller

Country Status (1)

Country Link
JP (1) JP5321712B2 (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS564883A (en) * 1979-06-26 1981-01-19 Toshiba Corp Control unit for real coordinate display
JPS60126709A (en) * 1983-12-14 1985-07-06 Fanuc Ltd Position controlling method
JPH0218602A (en) * 1988-07-07 1990-01-22 Fanuc Ltd Play-back system
JPH03269604A (en) * 1990-03-19 1991-12-02 Okuma Mach Works Ltd Numerical controller
JPH05341829A (en) * 1992-06-08 1993-12-24 Yamazaki Mazak Corp Controller for pentahedral processing machine
JPH0895626A (en) * 1994-09-21 1996-04-12 Kumamoto Techno Porisu Zaidan Off-line teaching device for three-dimensional measuring instrument
JP2003195917A (en) * 2001-10-16 2003-07-11 Fanuc Ltd Numerical control device
JP2006190048A (en) * 2005-01-05 2006-07-20 Yaskawa Siemens Nc Kk Numerical control device for composite working machine
JP2008077352A (en) * 2006-09-20 2008-04-03 Mitsubishi Electric Corp Numerical control device

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS564883A (en) * 1979-06-26 1981-01-19 Toshiba Corp Control unit for real coordinate display
JPS60126709A (en) * 1983-12-14 1985-07-06 Fanuc Ltd Position controlling method
JPH0218602A (en) * 1988-07-07 1990-01-22 Fanuc Ltd Play-back system
JPH03269604A (en) * 1990-03-19 1991-12-02 Okuma Mach Works Ltd Numerical controller
JPH05341829A (en) * 1992-06-08 1993-12-24 Yamazaki Mazak Corp Controller for pentahedral processing machine
JPH0895626A (en) * 1994-09-21 1996-04-12 Kumamoto Techno Porisu Zaidan Off-line teaching device for three-dimensional measuring instrument
JP2003195917A (en) * 2001-10-16 2003-07-11 Fanuc Ltd Numerical control device
JP2006190048A (en) * 2005-01-05 2006-07-20 Yaskawa Siemens Nc Kk Numerical control device for composite working machine
JP2008077352A (en) * 2006-09-20 2008-04-03 Mitsubishi Electric Corp Numerical control device

Also Published As

Publication number Publication date
JP5321712B2 (en) 2013-10-23

Similar Documents

Publication Publication Date Title
KR101126808B1 (en) Error estimation method and device for multi-axis controlled machines
JP5266373B2 (en) Numerical control device with tool trajectory display function
US7848851B2 (en) Controller of work piece-conveying robot
US8155789B2 (en) Device, method, program and recording medium for robot offline programming
JP5220183B2 (en) Numerical control device and control method of the numerical control device
CN105643369A (en) Cooperation system having machine tool and robot
JP6145130B2 (en) Trajectory display device that displays the trajectory of the tool axis
JP5374616B1 (en) Tool path display device for displaying tool vectors of machine tools
JP6496338B2 (en) Machine tool control system
JP5792251B2 (en) Error correction amount creation device
JP5715215B2 (en) Tool trajectory display device having trajectory data display section
JP2008269316A (en) Numerical control machine tool and numerical control device
JP2017027360A (en) Error compensation system for machine, error compensation method, and error compensation program
JP2011165066A (en) Error display device of machine tool
JP2008126327A (en) Moving locus display device
JP5187436B2 (en) Numerical control device, control method of numerical control device, and system program
JP2009015464A (en) Numerical control device
JP5020579B2 (en) Numerical controller
JP6474450B2 (en) Machine tool control system
JP5956952B2 (en) Numerically controlled machine tool
WO2016027355A1 (en) Numerical control device
TWI684841B (en) Program code generating method and device of multi-axis machine tool for machining inclined plane the same
JP5321712B2 (en) Numerical controller
JP2003044109A (en) Numerical controller for multiaxial machine tool with work coordinate system setting means
JP2012220999A (en) Correction value operation method and program of machine tool

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20120518

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20130531

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20130701

R151 Written notification of patent or utility model registration

Ref document number: 5321712

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

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

LAPS Cancellation because of no payment of annual fees