|

楼主 |
发表于 2007-4-12 13:23:50
|
显示全部楼层
来自: 中国四川阿坝藏族羌族自治州
基于MasterCAM平台的数控编程后处理程序应用开发2
(1)圆弧输出设置
+ @2 Z4 f5 u4 x) c, l- b2 O) @ 用于对圆弧插补的输出进行控制,如圆心的表达(R或IJK)、圆弧打断、整圆输出等。
( L- M" @2 ]8 \0 L9 J& J' _ #Arc output settings" ]2 V$ Q8 R ?8 X9 B5 |
breakarcs: 0 #Break arcs, 0 = no, 1 = quadrants, 2 = 180 arcs
/ R* p" i0 w4 ~* O% g7 {2 B arcoutput: 0 #0 = IJK, 1 = R no sign, 2 = R signed neg. over 1805 I( Z! D1 l& o$ f5 Z# t5 f- C
arctype : 2 #Arc center 1=abs, 2=St-Ctr, 3=Ctr-St, 4=unsigned inc.9 S0 x4 I, U5 K: u- @! ], U
do_full_arc : 1 #Allow full circle output? 0=no, 1=yes3 B" X1 P# J+ Q
helix_arc: 1 #Support helix arc output, 0=no, 1=all planes, 2=XY plane only5 r e8 ?! g+ N
arccheck : 1 #Check for small arcs, convert to linear
6 |, F3 N9 m9 J1 A8 U atol : .01#Angularity tolerance for arccheck = 2: C8 H# J9 E0 m" F$ G# \7 b
(2)五轴机床构造及运动设置
* j* ~# I) J7 x, p2 h; L 用于对典型的五轴机床运动方式进行配置,可对工作台双摆动、主轴头双摆动、主轴摆动及工作台摆动、工作台复合摆动(回转)、主轴复合摆动(回转)等典型五轴机床进行设置。主轴回转或摆动对应于相应机床,可处于主动轴或从动轴的形式。针对KR214机床的配置Mtype设为2。" u9 a% o* r& s
#Machine rotary routine settings
$ T" l4 K+ q; d6 ^4 `' Y5 \; h mtype : 2 #Machine type (Define base and rotation plane below) ) @, @5 b, p/ ^2 C$ N
#0 = Table/Table4 G/ @# [, v8 S! X) B/ ~3 S( R2 j
#1 = Tilt Head/Table' s) q& ?2 n# \! x$ c3 R
#2 = Head/Head
* f* A! W* ?0 H$ C #3 = Nutator Table/Table
' ]2 l3 }% U& s! m' n' [ #4 = Nutator Tilt Head/Table
3 @ @8 D [4 \ #5 = Nutator Head/Head
' E8 j! M' z, b' e head_is_sec : 2 #Set with mtype 1 and 4 to indicate head is on secondary
8 v, C* k! e$ W+ f+ v3 B" S5 _* z8 l (3)旋转轴矢量平面设置
2 k; A Z/ a$ s0 v6 H+ f5 ?% g7 i+ O* U 用于设置主动轴及从动旋转轴矢量方向,设置主轴或工作台复合摆动轴矢量方向。根据KR214(KR211)的C、A轴的运动配置,其C轴在XY平面内旋转,A轴在YZ平面内摆动,因而设置如下:
& E( W; R1 ~& j z8 R( c #Primary planeXY XZ YZ& t! y% w' b/ V9 M& N
#Secondary or XZ XY XY; u+ O/ z& w0 O Q: _* ]' \, |
#Secondary YZ YZ XZ
" O% a0 A* ^$ c8 e0 s/ ~ rotaxis1 = vecy #Zero # }' ?0 ~, J8 S: ?9 {
rotdir1 = vecx #Direction 3 O' U% Z) B! z- P
rotaxis2 = vecz #Zero
0 ~* d- H, W7 {9 }! D rotdir2 = vecy #Direction! y- H7 I% [2 V" g {/ B( j" v
p_nut_restore #Postblock, restores original axis settings ! t: G+ @& l8 G: ~4 z. F9 j
result = updgbl(rotaxis1, vecy) #Zero* Z- ^$ [2 d! J6 @, N
result = updgbl(rotdir1, vecx) #Direction. A. D- G& e+ V* [
result = updgbl(rotaxis2, vecz) #Zero
' O2 C$ `$ j% q% k( h9 v+ Z; Q/ X; E result = updgbl(rotdir2, vecx) #Direction
8 j7 ]! Y2 N C' c( |+ ^ nut_ang_pri : -45) i- Z0 z2 q* \- U
对于旋转平面不在坐标平面的特殊主轴复合摆动或工作台复合摆动的五轴机床,且Mtype设置为3~5的特殊类型时,如DMU125P和DMU50P的机床需要正确设置Nut_ang_pri参数。只有当Mtype设置为3~5时,该参数才起作用。0 t9 D. N. Y/ ]) }6 _) p5 U
(4)旋转轴中心、偏心设置及刀具轴输出设置
! R$ L$ }1 e8 n* |3 T3 H- N 根据KR214(或KR211)机床运动轴配置特点,其g7_tilt参数应设为2。
/ c; `! |* L) n saxisx: 0 #The axis offset direction?& R+ y9 v5 F/ Y- i& N4 C
saxisy: 0 #The axis offset direction?
) c) D. t) U3 v; t saxisz: 0 #The axis offset direction?) A% T. H9 j8 T. s
r_intersect : 1 #Rotary axis intersect on their center of ratations
. f! ^& ?/ h5 C4 E g7_tilt : 2 #With mill_plus and nutating, select toolplane output1 l6 S! d. ~! b6 G
#0 = Post selects G7 rotation axis
$ s1 y4 J/ j. [/ g+ b0 d( F #1 to 4, user selected G7 rotation axis
) h6 C3 A9 }5 Y" I6 c$ r* ? #1 = Primary C : X zero, Secondary B2 l$ M$ `. |( `) q( ]8 ]: Q1 Q
#2 = Primary C : Y zero, Secondary A
" u, r: Y" b+ J #3 = Primary C : -X zero, Secondary B! g4 O( `8 K, Y N: C* A
#4 = Primary C : -Y zero, Secondary A3 J1 e1 ^. K( Q6 E1 U
shift_90_s : 1 #Shift pos.=1, neg.=-19 a, j' k0 Q3 U
(5)机床行程及转角限位设置
5 J% K6 R8 w# V$ \$ q' t 坐标运动轴的行程及软件限位设置的正确性,直接影响五轴机床数控程序输出的正确性,下述分别为KR214的各坐标轴的行程及A/C轴的转角行程设置。
$ c/ ~3 ]5 \, V8 ]( ] 1)X、Y、Z线性轴行程设置$ D# S, d, r/ o* `+ Z
adj2sec : 1 + W; m, I3 W, w5 Y8 o/ E, a$ u+ S8 p
use_stck_typ : 2 #0=Off, 1=Stock def., 2=Limits) f/ ]/ C# K# `0 M: f
up_x_lin_lim : 1350#X axis limit in positive direction
* j; @' {: F1 V, f0 h- w/ z! k up_y_lin_lim : 900#Y axis limit in positive direction
! X0 m2 I% w" C8 {6 S' e5 Y% j up_z_lin_lim : 1400#Z axis limit in positive direction
2 W5 o" @6 `5 H& M lw_x_lin_lim : -1350 #X axis limit in negative direction
4 m7 }) `4 B3 z" H0 t; g lw_y_lin_lim : -200 #Y axis limit in negative direction
0 ~, W! z8 N$ f8 J8 a8 z lw_z_lin_lim : 200#Z axis limit in negative direction
1 [' f* R8 Q F" J/ B) e 2)主动轴C和从动轴A的转角设置' u+ w& k# g- i% ]8 e
auto_set_lim : 1 #Set the type from the angle limit settings (ignore these)
& f9 f5 c9 P# m- Z1 f( f5 |" G pri_limtyp : 19 O4 Z/ w1 d5 L; ]
sec_limtyp : 1
4 x; Y: H! F# d' C; i: e" q2 } #Set the absolute angles for axis travel on primary6 b: X) T, K5 x" X. v0 Z0 v" b
pri_limlo: -200) s6 ?: `; B! }. e: W' B
pri_limhi: +200
8 b* h" S+ R% o* Y2 w( q #Set intermediate angle, in limits, for post to reposition machine
6 s6 x! a9 A3 ?$ r2 v1 Y pri_intlo: -2001 Y6 }0 M. C+ w6 ~; |, |
pri_inthi: +200
/ R0 m0 Q8 o3 I- e #Set the absolute angles for axis travel on secondary% G. `8 S+ _ W& L7 s7 a
sec_limlo: -115 ( A" X% C" r2 M0 K; l. t9 q
sec_limhi: +90
1 t. | O- X5 z #Set intermediate angle, in limits,for post to reposition machine
% |# l3 R9 A w: c sec_intlo: -200 $ s8 f" y4 h+ p6 ?
sec_inthi: +200 y; H( V% G6 N" L8 V4 H% M
五坐标机床后处理程序的验证可通过下面的测试进行。例如,我们根据KR214的需求进行了多种测试,如X/W轴联动、固定A轴、变A轴、旋转C轴、五轴底刃、五轴侧刃等典型的五轴加工程序测试。其测试的刀具轨迹与部分程序代码如图3~图5所示。
L2 U1 p7 ]( i: Oa)五轴底刃刀具轨迹及其模拟 b)五轴侧刃刀具轨迹及其模拟 图3 五轴铣削加工功能测试示意图 |
|