首页 PowerMILL后处理制作教程

PowerMILL后处理制作教程

举报
开通vip

PowerMILL后处理制作教程PowerMILL后处理制作教程 definewordTN addressletter="TOOLTYPE:-" addresswidth=13 fieldwidth=25 enddefine 具体解释: definewordTN——————————————定义字段; addressletter="TOOLTYPE:-...

PowerMILL后处理制作教程
PowerMILL后处理制作教程 definewordTN addressletter="TOOLTYPE:-" addresswidth=13 fieldwidth=25 enddefine 具体解释: definewordTN——————————————定义字段; addressletter="TOOLTYPE:-"—————定义字段的返回值,比如在后处理文件里有“MS=C;TNToolType;EM=C”,而在写程式的时候选用的是端铣刀,那么在CNC程式里就会有(TOOLTYPE:-ENDMILL); addresswidth=13———————————定义字符宽度,如上"TOOLTYPE:-",从T开始算起一共13位,包括空格; fieldwidth=25———————————定义返回字的宽度,如上"ENDMILL",如果fieldwidth=2,那"TOOLTYPE:-"就返回EN;如果fieldwidth=25,那"TOOLTYPE:-"就返回ENDMILL。 enddefine ==========================第二段是定义字符的 格式 pdf格式笔记格式下载页码格式下载公文格式下载简报格式下载 ============================= defineformat(/G6STM1M2LPDEHO) addresswidth=1 fieldwidth=2 exponentwidth=0 scalefactor=1 scaledivisor=1 tapeposition=0 printposition=1 sign=none notpermanent notmodal metricformats leadingzeros=false trailingzeros=true decimalpoint=false控制公制尺寸的前导零、后导零,小数点 decimalplaces=0 imperialformats leadingzeros=false trailingzeros=true decimalpoint=false控制英制尺寸的前导零、后导零,小数点 decimalplaces=0 enddefine wordorder=(OPNG1G2G3G4G5) wordorder=(+G6G7XYZBC) wordorder=(+IJKRDST) wordorder=(+HM1M2MSmsgEMQ)注册字符 wordorder=(+Q1Z2R2IDF) wordorder=(+TNTDTRDYMTYRPM) ==========================第三段是定义键值=================================== definekeys blocknumber=N——————定义程序段号 preparatoryfunction=G1———————定义准备功能指令 auxfunction=M1——————定义辅助功能指令 xfeedratenotused—————定义X进给率指令 yfeedratenotused—————定义Y进给率指令 zfeedratenotused—————定义Z进给率指令 circleanglenotused—————圆周角度 xcoordinate=X——————定义X坐标轴 ycoordinate=Y——————定义Y坐标轴 zcoordinate=Z——————定义Z坐标轴 keyi=I——————定义X轴矢量I键 keyj=J——————定义Y轴矢量J键 keyk=K——————定义Z轴矢量K键 feedrate=F——————定义进给率指令 feedrateperrevolution=F———————定义每转进给率指令 spindle=S——————定义主轴指令 toolnumber=T——————定义刀具指令 cycledwellnotused dwell=X—————定义暂停时间键值 toollength=H——————定义刀具长度补偿指令 toolradius=D——————定义刀具半径补偿指令 drillpeckdepth=Q1——————钻孔的啄钻深度 drillholedepth=Z2——————定义钻孔深度 clearplane=R2—————定义安全平面高度 messagestart=MS—————定义注释的开始符 messageend=EM————定义注释的结束符 opskip=OP————定义跳段符号 radius=R—————定义半径R键 programid=ID—————定义程序号 azimuthaxis=B—————在多轴加工中,定义方位轴 elevationaxis=C—————在多轴加工中,定义仰角轴 3rdrotationaxis=null—————在多轴加工中,定义第三旋转轴 leadernotused xvectornotused yvectornotused zvectornotused errornotused enddefine ==========================定义指令值======================================== definecodes rapid=G10==========快速点定位 linear=G11===========直线插补 circlecw=G12===========顺圆插补 circleccw=G13==========逆圆插补 dwell=G64=========暂停、准确停止 xyplane=G317=========XY平面 zyplane=G319=========YZ平面 xzplane=G318=========ZX平面 compensationoff=G240==========取消刀具半径补偿 compensationonleft=G241===========刀具半径左补偿 compensationonright=G242===========刀具半径右补偿 imperialdata=G420============英寸输入 metricdata=G421============毫米输入 absolutedata=G590============指定绝对坐标编程 incrementaldata=G591============指定增量坐标编程 from=G354==========制定工作坐标系 feedrateperminutenotused================每分钟进给 feedrateperrevolutionnotused=================每转进给 spindlerpmnotused constantsurfacespeednotused drill=G481===========钻孔循环锪镗循环 breakchip=G482===========钻孔循环或反镗循环 deepdrill=G483============深孔钻循环 tap=G484==========攻丝循环 bore1=G485==========镗孔循环 bore2=G486==========镗孔循环 bore3=G487==========背镗循环 bore4=G488==========镗孔循环 bore5=G489==========镗孔循环 endofdrill=G480=============固定循环取消 macrostartnotused============宏程序模态调用 macroendnotused===========宏程序模态调用取消 macrocallnotused============宏程序调用 cycleretract=G699==========固定循环返回到R点 toollengthoffset=G343===========正向刀具长度补偿 splinenotused========spline插补方式 stop=M10====程序停止 optstop=M11=====选择停止 spindleoncw=M13=====主轴正转 spindleonccw=M14=====主轴逆转 spindleoff=M15=====主轴停止 spincoolantoncw=M113 spincoolantonccw=M114 spincoolantoff=M15======冷却液关 changetool=M16======自动换刀 coolantonmist=M17=====雾状冷却液 coolanton=M18====冷却液开 coolantonflood=M18=====冷却液开(喷出) coolantoff=M19=====冷却液关 clamponnotused clampoffnotused endoftape=M12=====程序结束 endofprog=M130=====程序结束 gearrange1notused gearrange2notused gearrange3notused constantcontourspeednotused constantcontourspeed2notused worddrillnotused wordbreakchipnotused worddeepnotused wordtapnotused wordbore1notused wordbore2notused wordbore3notused wordbore4notused wordbore5notused coolantontapnotused rigidtapnotused======刚性攻丝 helicaldrillnotused helicalretractdrillnotused enddefine ================================定义变量====================================== printheader="DelcamPostprocessor"==================定义打印标题 machinename="Fanuc6mversion1.2"=========机器名 point="."================================小数点 zero="0"===============================零 tapeheaders=1==============================纸带标题 (integer6、integer7):定义coolantoutput(冷却液输出) integer6=2==============定义冷却液开(M07、M08)的输出方式, 此变量共有三个选项——0:在后处理时遇到相关指令时输出;1:在下一段中单独输出;2、在下一段中和坐标移动一起输出。 integer7=1==============定义冷却液关(M09)的输出方式,此变量共有三个选项——0:在后处理时遇到相关指令时输出;1:在下一段中单独输出;2、在下一段中和坐标移动一起输出。 (integer10、integer11、integer12、integer13):定义spindleoutput(主轴输出) integer10=2==============定义主轴开(M03、M04)的输出方式, 此变量共有三个选项——0:在后处理时遇到主轴开指令时输出;1:在下一段中单独输出;2、在下一段中和坐标移动一起输出。 integer11=1=============定义主轴关(M05)的输出方式,此变量共有二个选项——0:在遇到主轴关指令时不输出S;1:在遇到主轴关指令时输出S0。 integer12=1=============定义M代码的输出方式,此变量共有二个选项——0:在遇到主轴相关指令时不输出M;1:在遇到主轴相关指令时输出M。 toolresetcoordinates=2===============定义刀具复位后(M06后)的坐标处理方式,有1、2、3、4四个选项,请注意这四个选项的刀具补偿的区别: cycleoutput=1================定义循环指令(G80~G89)的输出方式,此变量共有两个选项——0:不输出循环移动指令;1、输出循环指令(默认值为G81)。 (integer20、integer26、fullcircle):定义circleoutput(圆弧输出) integer20=1=============定义圆弧(M02、M03)的输出坐标,此变量共有两个选项——0:不输出圆弧的X、Y坐标;1:输出圆弧的X、Y坐标。 blockstart=1===============定义程序段的开始段号 blockincrement=1===============定义程序段号的增量 splitmove=0 integer26=1==============定义圆弧(M02、M03)的输出,此变量共有两个选项——0:不输出圆弧指令;1、输出圆弧指令,如果选择0,那么在后处理时遇到有圆弧的地方,系统将这个圆弧打断成若干条直线段输出。 programidstart=100===============定义程序起始号 integer34=3 integer35=1 integer36=1 integer37=2 rapidfeedcode=0===============共有两个选项——0:在快速移动时不输出进给率;1:在快速移动时输出进给率(需要在快速移动中定义F)。 maximumblocknumber=0 maximumtapeblocks=0 minimumtapeblocks=0 segmenttype=0 counterstart=0 counterincrement=0 tapesplitretractdistance=-999 multiaxiscoordinatetransform=true======定义机床是否支持多轴联动,true:支持;false:不支持 messageoutput=false blockorder=true tlooutput=true========是否正常输出刀具长度(半径)补偿,true:输出;false:不输出。 tapesplitontoolchange=false fullcircle=true=========true:整圆输出;false:不做整圆输出。 incrementalcentre=true gohomeoutput=false usepartid=true========是否使用自定义partid,true:使用;false:不使用 useprogid=true========是否使用自定义progid,true:使用;false:不使用 spindlexmotion=false========定义主轴运动方向,true:X方向;false:NOX方向。 spindleymotion=false========定义主轴运动方向,true:Y方向;false:NOY方向。 spindlezmotion=true========定义主轴运动方向,true:Z方向;false:NOZ方向。 spindlewmotion=false========定义主轴运动方向,true:W方向;false:NOW方向。 spindleazimuthrotation=false==========定义方位轴方式,true:为主轴头式;false:为工作台式。 spindleelevationrotation=false==========定义仰角轴方式,true:为主轴头式;false:为工作台式。 linearisemultiaxismoves=true==========定义机床是否支持线性多轴联动,true:支持;false:不支持。 useholetopincycles=false retractatangularlimit=false unwindattoolchange=false suppressxyarc=false suppressxzarc=false suppressyzarc=false transformworkplaneorigin=false previousmultaxrapidstyle=false knotvectortype=none units=input=======定义单位,input=ouput;metric;imperial coordinates=absolute======定义坐标单位,absolute;incremental azimuthaxisunits=degrees=======定义方位轴单位 azimuthaxisdirection=positive=======定义方位轴用法,相对还是绝对 elevationaxisunits=degrees========定义仰角轴单位 elevationaxisdirection=positive========定义仰角轴用法,相对还是绝对 splinetype=none workplaneangles=none optionfileunits=none maximumfeedrate=9999.0000 minimumfeedrate=1.0000 rapidfeedrate=9999.0000 maximumtapelength=0.0000 plungethresholdangle=0.0000 maximumsegment=0.0000 diameter=1.0000 withdrawalamount=50.0000 arcradiuslimit=10000.0000 retractionthreshholdangle=360.0000 arcminimumradius=0.0000 azimuthaxisparameters=(000000)=========定义方位轴参数,前三个零为分别定义每个轴的旋转中心;后三个零为定义方位轴的坐标,依次为X、Y、Z。 azimuthcentre=(000)==========================定义方位轴圆心参数 elevationaxisparameters=(000000)==========定义仰角轴参数,前三个零为分别定义每个轴的旋转中心;后三个零为定义仰角轴的坐标,依次为X、Y、Z。 elevationcentre=(000)===========================定义仰角轴圆心参数 pcsorigin=(000000)========定义旋转轴圆心 linearaxislimits=(-99999999999-99999999999-99999999999)==============定义线性轴范围 rotaryaxislimits=(-99999999999-999999999999991)============定义旋转轴范围,前两个零为定义方位轴的旋转范围;中间两个零为定义仰角轴的旋转范围;第五个零定义公差;第六个零定义分辨率。 movesafeangles=(0000)====================定义起始角度 defineblocktapestart "%" #IDProgID N;G291;G628;Z0;Z=C N;MS=C;PMJobName;EM=C N;MS=C;MTMonth;DYDay;YRYear;EM=C N;MS=C;TNToolType;EM=C N;MS=C;TDToolRadius[ToolNum];EM=C N;MS=C;TRToolRadius[ToolNum];EM=C N;compensationoff;G649;xyplane;G480;G354 #N;G291;G628;X0;Y0;X=C;Y=C enddefine defineblocktapeend N;G591;G628;ZZcoord;Z=C N;H0;G649 #N;G628;X0;Y0;X=C;Y=C N;M130 enddefine defineblockgohomepreamble enddefine defineblocktoolchangefirst #N;OP;changetool;TToolNum G354;G590;G3=C;G5=C;#TNextTool; enddefine defineblocktoolchange N;G591;G628;Z0;Z=C N;H0;G649 N;G628;X0;Y0;X=C;Y=C N;TToolNumber;changetool G590;G354;G5=C;G3=C;#TNextTool; enddefine defineblocktoolchangeclear enddefine defineblockgohomezmove enddefine defineblockgohomexymove enddefine defineblockmovefrom enddefine defineblockmovecircle N;G1;G2;G3;X;Y;Z;I;J;K;F;D enddefine defineblockmovelinear enddefine defineblockmoverapid N;G1;G2;G3;G5;G6;X;Y;Z;T;H;S; M1;M2 enddefine defineblockmovecycle N;G4;G6;X;Y;Z2;R2;Q;Q1;F;M2 enddefine defineblockmovetap N;G6;G4;X;Y;Z2;R2;F;M1;M2 enddefine defineblocktapesegment enddefine defineblocktapesplitstart "%" IDProgID enddefine defineblocktapesplitend N;G128;G691;Z0;Z=C N;H0;G649 #N;G628;X0;Y0;X=C;Y=C N;M130 enddefine defineblockcyclestart N;S;M1 N;G3;G5;M2 F=C;G4=C;Z2;R2;Q;Q1;G6; enddefine defineblockcycleend N;G480 enddefine defineblocktapesplitmove enddefine defineblockmovespline enddefine End
本文档为【PowerMILL后处理制作教程】,请使用软件OFFICE或WPS软件打开。作品中的文字与图均可以修改和编辑, 图片更改请在作品中右键图片并更换,文字修改请直接点击文字进行修改,也可以新增和删除文档中的内容。
该文档来自用户分享,如有侵权行为请发邮件ishare@vip.sina.com联系网站客服,我们会及时删除。
[版权声明] 本站所有资料为用户分享产生,若发现您的权利被侵害,请联系客服邮件isharekefu@iask.cn,我们尽快处理。
本作品所展示的图片、画像、字体、音乐的版权可能需版权方额外授权,请谨慎使用。
网站提供的党政主题相关内容(国旗、国徽、党徽..)目的在于配合国家政策宣传,仅限个人学习分享使用,禁止用于任何广告和商用目的。
下载需要: ¥18.0 已有0 人下载
最新资料
资料动态
专题动态
个人认证用户
飞哥
暂无简介~
格式:doc
大小:45KB
软件:Word
页数:9
分类:企业经营
上传时间:2018-05-11
浏览量:44