Background technology
In digital control processing, correctly positioning workpiece, set up workpiece numerical-controlled Cutter coordinate system, is the prerequisite that nc program correctly performs.Therefore, how to carry out Workpiece fixing accurately and rapidly, set up the committed step that workpiece numerical-controlled Cutter coordinate system becomes digital control processing.
For Digit Control Machine Tool, coordinate system is the basis that Digit Control Machine Tool performs numerical control programmed instruction.It is the frame of reference set up when numerical programming programmed instruction that workpiece numerical-controlled journey compiles coordinate system.Workpiece numerical-controlled Cutter coordinate system is the reference coordinate system that Digit Control Machine Tool performs that numerical control program carries out adding man-hour, and it must be compiled coordinate system with workpiece numerical-controlled journey and match.The benchmark setting up workpiece numerical-controlled Cutter coordinate system is generally the positioning datum of workpiece.Holes one side location is modal Workpiece fixing form, as shown in Figure 1.
Traditional Workpiece fixing method is manually carried out by means of instruments such as amesdials: be fixed on by amesdial on machine tool chief axis, manual rotation main shaft also checks beats, continuous adjustment lathe main spindle's, makes machine tool chief axis center aim at locating hole center, determining hole center position coordinates; Locate two locating holes successively; When the not timing of workpiece putting position, also need to finely tune workpiece; Finally, using the initial point of one of them center, hole as workpiece numerical-controlled Cutter coordinate system, workpiece numerical-controlled Cutter coordinate system is set up.This traditional workpiece numerical-controlled machining coordinate system, method shortcoming of setting up is that process is very loaded down with trivial details, and efficiency is low, and precision is also subject to the impact of operating personnel's technical ability simultaneously.
Along with the raising of Digit Control Machine Tool automaticity, traditional artificial location, set up workpiece numerical-controlled machining coordinate system, method and more and more embody significant limitation.Such as, under the environment such as closed processing environment, automatically switching plane horizontal Machining centers, workpiece is clamping in advance, when workpiece putting position not just, very difficult when needing fine setting; Meanwhile, manual operation amesdial is located, is set up all very inconvenience of workpiece numerical-controlled Cutter coordinate system.
Object of the present invention is intended to the limitation overcome because manually locating, setting up workpiece numerical-controlled Cutter coordinate system, realizes efficiently, automation accurately sets up workpiece numerical-controlled machining coordinate system, method.
Summary of the invention
The method of workpiece numerical-controlled Cutter coordinate system and adaptive equalization is set up in the automation that the invention provides a holes positioning workpieces on a kind of Digit Control Machine Tool.Pass through the present invention, the automation quick position of two positions, locating hole hole to place work piece free on Digit Control Machine Tool can be realized, set up workpiece numerical-controlled Cutter coordinate system, and carry out the adaptive equalization of workpiece numerical-controlled Cutter coordinate system according to workpiece laying state, realize automation process.The present invention is made up of jointly following content:
A kind of method setting up workpiece numerical-controlled Cutter coordinate system, the NC Programming Coordinate System of known workpiece, workpiece is provided with main locating hole and auxiliary locating hole, it is characterized in that: 1) have a numerical control trace routine, the main locating hole of workpiece, auxiliary locating hole is defined at the theoretical position coordinate of NC Programming Coordinate System in this program, and locating hole diameter information; 2) workpiece is placed on numerically controlled machining platform, gauge head is measured in the numerical control that main shaft of numerical control machine tool loads measuring workpieces position coordinates, this gauge head is moved to workpiece surface, any measurement point of contact workpiece surface, and this measurement point is set to the Z-direction initial baseline of workpiece numerical-controlled Cutter coordinate system, gauge head is moved to the top position of the main locating hole of workpiece, and the locating hole current location that gauge head points to is set to the X of workpiece numerical-controlled Cutter coordinate system, the initial baseline of Y-direction, set up the workpiece numerical-controlled processing initial coordinate system of lathe; 3) be reference system with initial workpiece digital control processing coordinate, NC inspecting program prepared in advance on actual figure controlled machine, carry out hole measurement recursion instruction, measure the centre coordinate of main locating hole and auxiliary locating hole respectively, the surving coordinate value of main locating hole and auxiliary locating hole is stored in the system variable of trace routine; 4) by writing the main locating hole of NC inspecting program computation of lathe and the theoretical coordinate value of auxiliary locating hole and the X of surving coordinate value in advance to, Y-direction position offset and offset; 5) X of main locating hole and auxiliary locating hole is write the current initial workpiece digital control processing coordinate system of lathe as the X of digital control processing coordinate system to the compensation of, Y-direction position offset and Z-direction rotational offset respectively to, Y-direction position offset and offset, form the digital control processing coordinate system of workpiece.
The invention has the advantages that: the automation quick position that can realize two positions, locating hole hole to place work piece free on Digit Control Machine Tool, set up workpiece numerical-controlled Cutter coordinate system, and carry out the adaptive equalization of workpiece numerical-controlled Cutter coordinate system according to workpiece laying state, realize automation process, improve the efficiency of digital control processing.
Below in conjunction with embodiment accompanying drawing, the application is elaborated.
Specific embodiment
The present embodiment is located for the automation of a kind of workpiece on Digit Control Machine Tool, is set up workpiece numerical-controlled Cutter coordinate system process, further illustrates scheme of the invention.
As shown in Figure 1, workpiece 4 is rectangle, prefabricated two locating holes, compile coordinate system 3 times in workpiece numerical-controlled journey, the theoretical coordinate of main locating hole 1 is (XE1, YE1), aperture Ф 20mm, the theoretical coordinate of auxiliary locating hole 2 is (XE2, YE2), aperture Ф 20mm, the process equipment digital control system of workpiece is Sinumerik840D.
The first step, sets up initial workpiece digital control processing coordinate system.
As shown in Figure 2, be placed in by workpiece 4 on platform of machine tool 7, workpiece surface is Z-direction datum plane.Main shaft of numerical control machine tool loads gauge head 5, and gauge head is that one can be arranged on main shaft of numerical control machine tool, for the numerical control survey tool of measuring workpieces position coordinates.
Gauge head is moved to workpiece surface, any measurement point of contact workpiece surface, and this measurement point is set to the Z-direction initial baseline of workpiece numerical-controlled Cutter coordinate system 6.Gauge head 5 is moved to the top approximate location of main locating hole 1 on workpiece, and current location corresponding for gauge head is set to X, the Y-direction benchmark of workpiece numerical-controlled Cutter coordinate system 6.Set up the workpiece numerical-controlled processing initial coordinate system of lathe, in numerically-controlled machine tool system, memory location is G54.
Second step, carries out the automation quick position of two positions, locating hole hole.
As shown in Figure 3, with initial workpiece digital control processing coordinate system 6 for reference system, Digit Control Machine Tool performs NC inspecting program prepared in advance.In NC inspecting program, define the theoretical position coordinate (XE1, YE1) of main locating hole 1, the theoretical position coordinate (XE2, YE2) of auxiliary locating hole 2, the information such as the diameter Ф 20mm of locating hole, and the instruction such as gauge head motion, measurement.First make gauge head 5 move to the top position of main locating hole 1, perform hole measurement recursion instruction CYCLE977, the surving coordinate (XM1, YM1) measuring the main locating hole center obtained is stored in the system variable of NC inspecting program; Make gauge head move to the top position of auxiliary locating hole 2 again, perform hole measurement recursion instruction CYCLE977, the surving coordinate (XM2, YM2) measuring the auxiliary locating hole center obtained is stored in the system variable of NC inspecting program.
3rd step, by writing the instruction in the numerical control program of lathe in advance, calculates position offset and the offset of locating hole.As shown in Figure 3.
The position offset of main locating hole 1:
X is to side-play amount: XFI=XM1-XE1;
Y-direction side-play amount: YFI=YM1-YE1;
Workpiece numerical-controlled journey compiles coordinate system 3 times, the angle that two locating hole lines are:
A1=atan((YE2-YE1)/(XE2-XE1));
After actual measurement, workpiece numerical-controlled Cutter coordinate system 6 times, the angle that two locating hole lines are:
A2=atan((YM2-YM1)/(XM2-XM1));
The offset of workpiece:
A3=A2-A1。
4th step, by writing the instruction in numerical control program in advance, position offset and the offset of carrying out workpiece numerical-controlled Cutter coordinate system 6 compensate.
First, the position offset carrying out workpiece numerical-controlled Cutter coordinate system 6 compensates, by X to the X of, the Y-direction side-play amount current workpiece numerical-controlled Cutter coordinate system of writing machine bed system respectively in, Y-direction position offset offset, programmed instruction is as follows:
$P_UIFR[WK_OFFSET_NO,X,FI]=XFI
$P_UIFR[WK_OFFSET_NO,Y,FI]=YFI
To carry out in the Z-direction rotational offset offset of the current workpiece numerical-controlled Cutter coordinate system of the offset writing machine bed system of workpiece numerical-controlled Cutter coordinate system 6, programmed instruction is as follows again:
$P_UIFR[WK_OFFSET_NO,Z,RT]=A3
In Sinumerik840D system automation fast aligning and workpiece numerical-controlled Cutter coordinate system adaptive equalization program realization example as follows:
DEF REAL_PosX1, _ PosX2, _ PosY1, _ PosY2, _ PosZ1, _ PosZ2; / variable-definition/
DEF REAL_dia1,_dia2,_ANGLE
DEF INT_Gcode
DEF REAL_XE1,_YE1,_XE2,_YE2,_XM1,_YM1,_XM2,_YM2,WK_OFFSET_NO
DEF REAL_XFI,_YFI,_A3
_ PosX1=0; / main locating hole theoretical coordinate definition/
_PosY1=0
_PosZ1=0
_ PosX2=0; / auxiliary locating hole theoretical coordinate definition/
_PosY2=1355
_PosZ2=0
_ dia1=20; / main locating hole aperture definition/
_dia2=20
_Gcode=$P_GG[8];
_XE1=_PosX1
_YE1=_PosY1
_XE2=_PosX2
_YE2=_PosY2
FFWOF
COMPOF
IF $AA_IM[Z]<=-300
SUPA G0Z=-300
ENDIF
SUPA G0C0A0
PROBON;
G0 X=_PosX1Y=_PosY1; / gauge head move to main locating hole/
G0 Z=_PosZ1+100
G1 Z=_PosZ1+10F5000
G1 Z=_PosZ1-5F500
SPOS=0; / definition hole measurement parameter/
_MVAR=101
_SETVAL=_dia1
_PRNUM=1
_KNUM=0
_FA=10
_TSA=10
_CPA=_PosX1
_CPO=_PosY1
_STA1=0
_VMS=500
_NMSP=2
_CHBIT[10]=0
_CHBIT[11]=0
_CHBIT[21]=1
CYCLE977; / perform the measurement of main locating hole to circulate/
_ XM1=_OVR [5]; The absolute fix storage of center ,/main locating hole hole/
_YM1=_OVR[6]
STOPRE
G1 Z=_PosZ1+20F500; / gauge head leave main locating hole/
G1 Z=_PosZ1+100F5000
G0 SUPA Z0
G0 X=_PosX2Y=_PosY2; / gauge head move to auxiliary locating hole/
G0 Z=_PosZ2+100
G1 Z=_PosZ2+10F5000
G1 Z=_PosZ2-5F500
_ MVAR=1; / definition hole measurement parameter/
_KNUM=0
_SETVAL=_dia2
_CPA=_PosX2
_CPO=_PosY2
SPOS=0
CYCLE977; / perform the measurement of auxiliary locating hole to circulate/
_ XM2=_OVR [5]; The absolute fix storage of center ,/auxiliary locating hole hole/
_YM2=_OVR[6]
STOPRE
R08=_Gcode-1
WK_OFFSET_NO=R08
STOPRE
R201=ATAN2 (_ YE2-_YE1, _ XE2-_XE1); The point of theory that/two locating hole lines are/
R202=ATAN2 (_ YM2-_YM1, _ XM2-_XM1); The actual measurement angle that/two locating hole lines are/
_ A3=R202-R201; The offset of/workpiece/
_ XFI=_XM1-_XE1; The position offset of/main locating hole/
_YFI=_YM1-_XE1
$ P_UIFR [WK_OFFSET_NO, X, FI]=_ XFI; / carry out workpiece numerical-controlled Cutter coordinate system position offset compensate/
$P_UIFR[WK_OFFSET_NO,Y,FI]=_YFI
$ P_UIFR [WK_OFFSET_NO, Z, RT]=_ A3; / carry out workpiece numerical-controlled Cutter coordinate system offset compensate/
STOPRE
G0 SUPA Z0;
PROBOF
M2
So far, the workpiece automation quick position on Digit Control Machine Tool, the foundation of workpiece numerical-controlled Cutter coordinate system, and position offset and offset adaptive equalization all complete, and can carry out follow-up digital control processing.