powermill后处理修改参考

合集下载

powermill后处理修改方法...

powermill后处理修改方法...

powermill后处理修改方法(PowerMILL post-processingmodification method)Machine fanucom -- -- post-processing file headerDefine word TN ---------------------------- defined fields;Address letter = "TOOL TYPE:-" - defines the return value of the fieldAddress width = 13 defines character widthField width = 25 defines the width of the word returned End define end definitionThe define format (/ G6, S, T, M2, L, P, D, E, H, O) M1 is defined in the form of theAddress width = 1------------ defines character width Address width = 1------------ defines character widthField width = 2 - definition of return word widthExponent width = 0 - width indexScale factor = 1 - scale factor: value multiplied by 1 Scale divisor = 1 - scale factor: value divided by 1Leave a space before the word "tape position = 1-----------"Print position = 1 - print positionSign = none----- is used without the need for G code and feed rateSign = if negative only identifies negative coordinatesSign = always, if needed + / -Not permanent - does not require line numberNot modal - only when changes need to repeat the word for modal. (modal).Typically, the G code is X, Y, and Z are coordinates of modal,But the I, J, and K codes that are usually used by the center are usually not, so they are not modalMetric formats - MetricLeading zeros = false - leading 0Trailing zeros = true - Guide 0Decimal point = false --- does not need a decimal pointDecimal places = 2 - 2 decimal pointsImperial formats - InchWord order===================== word orderWord order = (OP, N, G1, G2, G5, G3, G4, etc)Word order = (+, G6, G7, X, Y, Z, B, C)Word order = (+, I, J, K, R, D, S, T)Word order = (+, H, M1, M2, MS, MSG, EM, Q)Word order = (+ Q1, Z2, R2, ID, F)Word order = (+, TN, TD, TR, DY, MT, YR, PM)The third paragraph of define keys is the definition keyBlocknumber = N - defined programPreparatory function = G1 - defines the ready function instructionsAux function = M1 - definition of auxiliary function instructionX feedrate not used X -- definition of feed rate instructionY feedrate not used Y -- definition of feed rate instructionZ, feedrate, not, used -- define the Z feed rate instructionsCircle, angle, not, used -- circumferential angleX coordinate = X -- -- -- defines the X coordinate axis Y coordinate = Y -- -- -- defines the Y coordinate axis Z coordinate = Z -- -- -- defines the Z coordinate axis Key i = I - X - I bond axis vector definitionKey J = J - - Y axis vector JKey K = K - Z - K bond axis vector definitionFeedrate = F - - - defines feed rate instructionsFeedrate per revolution = F--- defines the feed rate instruction per turnSpindle = S -- -- -- defining spindle instructions chair number = t - - 定义刀具指令 ------ translated dwell not used ----------- 不使用循环停留 cycle--------------- 定义暂停时间键值 dwell = xlength = h ------------ 定义刀具长度补偿指令 chairthe chair ------------ 定义刀具半径补偿指令 radius = ddrill peck depth = q1 - - - - 钻孔的啄钻深度drill hole depth = z2 定义钻孔深度...----------- 定义安全平面高度 clearplane = r2.--------- 定义注释的开始符 message start = msmessage itself ----------- 定义注释的结束符 = emopskip = op - - - - --------- 定义跳段符号radius... -------- 键定义半径 r = rprogram id = id... - - - 定义程序号azimuth axis = b - - - - --------- 在多轴加工中, 定义方位轴elevation axis = c --------- 在多轴加工中, 定义仰角轴3rd rotation axis = zero... 在多轴加工中, 定义第三旋转轴not used (% 领导不使用 leaderthe x vector not used x矢量不使用 meddra system organ class y vector not used y矢量不使用 meddra system organ classz vector not used z矢量不使用 meddra system organ classerror 错误不使用 not used "define yourselfdefine ------------- --------- 定义指令值 codesrapid = 0 = = = = = g1 ---------- -------- 快速点定位linear = g1 = = = = = "1 直线插补circle cw = = = = = = g1 2 ------------- 顺圆插补circle ccw = = = = = = g1 3 ------------ 逆圆插补dwell = = = = ------------------- 暂停、准确停止 g6 4.the g3 xy plane = = = = = = = 17 平面 ------------- xyzy plane = = = = = = g3 19 --------- - - - - 平面 plastic tray xz plane = 18 = = = = = g3 平面 ------------- zxcompensation off = 40 = = ------ translated 取消刀具半径补偿g2compensation is left = = = = = 刀具半径左补偿 g2 41 compensation is right = g2 42 = = = 刀具半径右补偿imperial data = 20 = = = = = g4 --------- 英寸输入metric data 21 = = = = = g4 ---------- 毫米输入 = = =absolute data = = = = = ----------- g5 90 指定绝对坐标编程incremental data = = = = = -------- g5 91 指定增量坐标编程from = = = = = = g3 54 ------------------- 制定工作坐标系feedrate per minute not used = = = = = = 每分钟进给feedrate per revoluti not used = = = = = 每转进给spindle rpm not used 每分钟转速 meddra system organ classconstant surface speed not used 恒定的表面速度 ------ translateddrill = = = = = ------------------- g4 81 钻孔循环锪镗循环break the g4 chip = = = = --------------- 钻孔循环或反镗循环82deep drill = = = = = = g4 83 = ----------- 深孔钻循环tap = = = = = = g4 84 = = ------------------ 攻丝循环bore 85 = = = 1 = g4 --------------- 镗孔循环 = = = =the g4 bore 2 = = = = = = = 86 --------------- 镗孔循环the g4 bore 3 = = = = = = = 87 (% 背镗循环孔4 = 88 ====== ----------------镗孔循环G4孔5 = 89 ====== ----------------镗孔循环G4端钻= G4 80 ====== ----------固定循环取消宏开始不习惯======= ---------宏程序模态调用不使用===== -------------宏程序模态调用取消宏结束宏调用不使用======== ---------宏程序调用周期收回= G6 99 = = ------------固定循环返回到R点刀具长度偏置= = = = = ----- G3 43正向刀具长度补偿不使用========插补方式-------------花键花键停止0 = = = = = M1 ---------------------程序停止选择停止= M1 1 ===== ----------------选择停止在CW = M1 3 ===== -----------主轴正转主轴在CCW = M1 4 ===== ----------主轴逆转主轴主轴停止= M1 5 ===== -------------主轴停止自旋对CW = ----------------- M1 13冷却液旋转逆时针= ---------------- M1 14冷却液旋转冷却液= M1 5 = = = = --------冷却液关换刀= M1 6 ===== ------------自动换刀冷却液雾= = = = ----------雾状冷却液M1 7冷却液对M1 8 = = = = = ---------------冷却液开洪水= M1 8 = ------------冷却液开冷却剂(喷出)冷却液= M1 9 ===== -------------冷却液关夹在不使用------ -------------主轴锁紧不要用--------------------主轴锁紧不使用夹磁带结束= M1 2 ===== -------------程序结束结束程序= M1 30 ===== ------------程序结束1不使用----------------变速范围1不使用档2不使用----------------变速范围2不使用档3不使用----------------变速范围3不使用档恒定的速度不-----持续的轮廓速度不使用轮廓2不使用恒定轮廓速度----持续的轮廓速度2不使用字钻不------------------钻孔指令不使用字断屑不使用------------不使用断屑深不------------------孔深不使用字字不------------------冷却水不使用水龙头字孔1不使用---------------孔1不使用字孔2未使用字孔3未使用字孔4未使用字孔5未使用自来水不习惯-------------冷却液不使用冷却剂不使用====== -----------刚性攻丝刚性攻丝螺旋钻不------------螺旋钻孔螺旋收缩不------螺旋钻孔不使用钻最后定义===========================定义变量打印头=“Delcam后处理器”= = = =定义打印标题机器名称=“fanuc6m 1.2版”= = =机器名点==================================小数点零=“0”=============================零磁带头= 1 =======================纸带标题整数6 = 2 ====================== = = =定义冷却液开(M07、M08)的输出方式,此变量共有三个选项--0:在后处理时遇到相关指令时输出;1:在下一段中单独输出;2:在下一段中和坐标移动一起输出。

PowerMILL后处理的分析说明

PowerMILL后处理的分析说明

PowerMILL 後處理對於後處理格式,一般的用戶有三個層次的需求:一、powermill自帶的後處理中有適合自己機床要求的,不過要修改、增刪些代碼。

二、沒有適合的,需要改寫後處理。

三、機床的代碼格式完全與普通G代碼格式不同,需建全新的後處理。

本文只針對1、2種需求來進行講解,至於第三種則是高級篇的範疇了(哈哈,其實我也不知道,還沒做過呢)現在開始準備工作:1、以不同的控制器試著處理幾個G代碼檔出來,然後和自己機床的代碼進行比較,選一個最接近自己的。

2、打開ductpost\dp-index.html,準備有問題就看幫助。

3、運行:ductpost -w [控制器類型] > [控制器類型].opt ,從而生成OPT檔,這個選最接近你機床的控制器。

如:ductpost -w hurco > hurco.opt 。

這時就可以用文本編輯器來打開這個opt檔了:1、程式頭、程式尾的改寫:這個在以下的定義裏面:define block tape start********************end definedefine block tape end*******************end define你可以根據自己的需要添加,如:define block tape start"%"N ; "G17G90G80G40G49"end definedefine block tape endN ; "M05"N ; "M30"end define不過注意這種引號方法優點是簡單明瞭,但控制器只是把它當字元處理,而不能以模態存在,具體可參見其他說明。

2、是否需要N行號?%:0001N10G28G91X0Y0Z0N30T1M6N40G0G90X-25.Y-40.S800 M3如這上面的N10、N30、N40,另外行號的起始、增量、最大都可以定義。

PM后处理修改方法教程

PM后处理修改方法教程
N100( MSG, TOOL COORDINATES: TIP ET)
N110( MSG, LOAD TOOL ET)
上面的信息,可修改为你需要的,具体参见帮助。也可选择不输出,如:
message output = false
4、圆弧的输出格式:
这个需要讲一下,输出R的就不讲了,专讲I、J、K的输出。大致有三大类:
"%"
N ; "G17G90G80G40G49"
end define
define block tape end
N ; "M05"
N ; "M30"
end define
不过注意这种引号方法优点是简单明了,但控制器只是把它当字符处理,而不能以模态存在,具体可参见其它说明
一、powermill自带的后处理中有适合自己机床要求的,不过要修改、增删些代码。
二、没有适合的,需要改写后处理。
三、机床的代码格式完全与普通G代码格式不同,需建全新的后处理。
本文只针对1、2种需求来进行讲解,至于第三种则是高级篇的范畴了(哈哈,其实我也不知道,还没做过呢)
现在开始准备工作:
1、以不同的控制器试着处理几个G代码文件出来,然后和自己机床的代码进行比较,选一个最接近自己的。
2、打开ductpost\dp-index.html,准备有问题就看帮助。
3、运行:ductpost -w [控制器类型] > [控制器类型].opt ,从而生成OPT文件,这个选最接近你机床的控制器。如:ductpost -w hurco > hurco.opt 。 这时就可以用文本编辑器来打开这个opt文件了:

powermill后处理修改方法[整理]

powermill后处理修改方法[整理]

powermill 后办理改正方法[ 整理 ]powermill后办理改正方法machine fanucom ——————后办理文件头define word TN ---------------------------- 定义字段 ;address letter = "TOOL TYPE :- " ----- 定义字段的返回值address width = 13 定义字符宽度field width = 25 定义返回字的宽度end define结束定义define format ( / G6 S T M1 M2 L P D E H O ) 第二段是定义字符的格式address width = 1------------ 定义字符宽度address width = 1------------定义字符宽度field width = 2 ------------- 定义返回字的宽度exponent width = 0 ---------- 指数的宽度scale factor = 1 -------------比率因子: 值乘以 1scale divisor = 1 ------------ 比率因子 : 值被 1 除tape position = 1----------- 字前留一个空格print position = 1 ----------- 打印地点sign = none----- 用于不需要G 代码和进给率sign = if negative 仅表记负坐标sign = always 假如需要+ / - 号not permanent -------- 不需要行号not modal ------------ 仅当改变时需要重复的字为modal 。

( 模态 )。

往常 G 代码和 X, Y和Z为坐标为modal,但圆心往常使用的I, J, K代码往常不是,所以它们为not modal .metric formats --------------- 公制leading zeros = false ---------前导0 trailing zeros = true ---------- 后导0 decimal point = false ------不需要小数点decimal places = 2 -------- 小数点后 2 imperial formats------------- 英制word order=====================语序 word order = ( OP N G1 G2 G3 G4G5 ) word order = ( + G6 G7 X Y Z B C ) word order = ( + I J K R D S T )word order = ( + H M1 M2 MS msg EM Q ) word order = ( + Q1 Z2 R2 ID F )word order = ( + TN TD TR DY MT YR PM )define keys第三段是定义键值blocknumber = N—————定义程序段号preparatory function = G1——定义准备功能指令aux function = M1 ------------- 定义协助功能指令x feedrate not used ---------- 定义X 进给率指令y feedrate not used ---------- 定义Y 进给率指令z feedrate not used —— ------ 定义Z 进给率指令circle angle not used ————圆周角度x coordinate = X —————- --- 定义X 坐标轴y coordinate = Y —————---- 定义Y 坐标轴z coordinate = Z —————--- 定义Z 坐标轴key i = I —————--------- -定义X 轴矢量I 键key j = J —————---------- 定义Y 轴矢量Jkey k = K —————---------- 定义Z 轴矢量K 键feedrate = F —————------- 定义进给率指令feedrate perrevolution = F--- 定义每转进给率指令spindle = S ——————----- 定义主轴指令tool number = T ——————-- 定义刀具指令cycle dwell not used----------- 不使用循环逗留dwell = X —————---------- 定义暂停时间键值tool length = H —— ---------- 定义刀具长度赔偿指令tool radius = D —— ---------- 定义刀具半径赔偿指令drill peck depth = Q1 ————钻孔的啄钻深度 drill hole depth =Z2 ———— - 定义钻孔深度 clearplane = R2———-------- 定义安全平面高度message start = MS —— ------- 定义说明的开始符message end = EM —— --------- 定义说明的结束符opskip = OP ———— --------- 定义跳段符号 radius = R ————— -- ------ 定义半径R 键program id = ID —————--- 定义程序号azimuth axis = B ---- --------- 在多轴加工中,定义方向轴elevation axis = C —— ------- 在多轴加工中,定义仰角轴3rd rotation axis = null ----- 在多轴加工中,定义第三旋转轴leader not used---------------- 领导不使用x vector not used--------------X 矢量不使用y vector not used--------------Y 矢量不使用z vectornot used--------------Z 矢量不使用error not used----------------- 错误不使用end definedefine codes ------------- --------- 定义指令值rapid = G1 0 =====---------- -------- 迅速点定位linear = G1 1 ===== ----------------- 直线插补circle cw = G1 2=====------------- 顺圆插补circle ccw = G1 3 =====------------ 逆圆插补dwell = G6 4 === ------------------- 暂停、正确停止xy plane = G3 17 ======------------- XY 平面zy plane = G3 19 =====--------- ---- YZ 平面xz plane = G3 18 =====------------- ZX 平面compensation off = G2 40 == ------ 撤消刀具半径赔偿compensation on left = G2 41 ==== 刀具半径左赔偿compensation on right = G2 42 === 刀具半径右赔偿imperial data = G4 20 ===== --------- 英寸输入 metric data = G4 21=======---------- 毫米输入 absolute data = G5 90 ====----------- 指定绝对坐标编程incremental data = G5 91 ====-------- 指定增量坐标编程from = G3 54 ===== ------------------- 拟订工作坐标系feedrate per minute not used ====== 每分钟进给feedrate per revoluti not used ===== 每转进给 spindle rpm not used -------------- 每分钟转速constant surface speed not used------ 恒定的表面速度drill = G4 81 ==== ------------------- 钻孔循环锪镗循环break chip = G4 82 === --------------- 钻孔循环或反镗循环deep drill = G4 83 ======----------- 深孔钻循环tap = G4 84 ======= ------------------ 攻丝循环 bore 1 = G4 85=======--------------- 镗孔循环 bore 2 = G4 86 ======--------------- 镗孔循环 bore 3 = G4 87 ======---------------- 背镗循环bore 4 = G4 88 ======---------------- 镗孔循环 bore 5 = G4 89 ====== ---------------- 镗孔循环 end of drill = G4 80 ======---------- 固定循环撤消macro start not used ======= --------- 宏程序模态调用macro end not used =====------------- 宏程序模态调用撤消macro call not used ========--------- 宏程序调用cycle retract = G6 99 ==------------ 固定循环返回到 R 点tool length offset = G3 43 ====----- 正向刀具长度赔偿spline not used ========------------- spline 插补方式stop = M1 0 ====--------------------- 程序停止opt stop = M1 1=====---------------- 选择停止spindle on cw = M1 3 =====----------- 主轴正转spindle on ccw = M1 4 =====---------- 主轴逆转spindle off = M1 5=====------------- 主轴停止 spin coolant on cw =----------------- M1 13 spincoolant on ccw =---------------- M1 14 spin coolant off = M1 5====-------- 冷却液关change tool = M1 6 ===== ------------ 自动换刀coolant on mist = M1 7 === ---------- 雾状冷却液coolant on = M1 8 ====--------------- 冷却液开coolant on flood = M18 =------------ 冷却液开 ( 喷出 )coolant off = M1 9 ===== ------------- 冷却液关clamp on not used ------ ------------- 主轴锁紧clamp off not used-------------------- 主轴锁紧不使用end of tape = M1 2 =====------------- 程序结束end of prog = M1 30===== ------------ 程序结束gear range 1 not used---------------- 变速范围1不使用gear range 2 not used---------------- 变速范围 2 不使用gear range 3 not used---------------- 变速范围 3 不使用constant contour speed not used----- 连续的轮廓速度不使用constant contour speed 2 not used---- 连续的轮廓速度 2 不使用word drill not used------------------ 钻孔指令不使用word break chip not used------------ 不使用断屑word deep not used------------------ 孔深不使用word tap not used------------------ 冷却水不使用word bore 1 not used--------------- 孔1不使用word bore 2 not usedword bore 3 not usedword bore 4 not usedword bore 5 not usedcoolant on tap not used------------- 冷却液不使用rigid tap not used ======----------- 刚性攻丝helical drill not used------------ 螺旋钻孔helical retract drill not used------ 螺旋钻孔不使用end define===========================定义变量 Print header ="Delcam Post processor"====定义打印标题machine name = "Fanuc6m version 1.2" ===机器名point ==================================小数点zero = "0" ============================= 零 tape headers = 1=======================纸带标题integer 6 = 2====================== ===定义冷却液开(M07、M08 )的输出方式,此变量共有三个选项——0 :在后办理时碰到有关指令时输出; 1 :在下一段中独自输出;2 : 在下一段中和坐标挪动一同输出。

powermill后处理修改精华帖修订版

powermill后处理修改精华帖修订版

p o w e r m i l l后处理修改精华帖修订版IBMT standardization office【IBMT5AB-IBMT08-IBMT2C-ZZT18】m a c h i n e f a n u c o m——————后处理文件头define word TN ---------------------------- 定义字段;address letter = "TOOL TYPE :- " ----- 定义字段的返回值address width = 13 定义字符宽度field width = 25 定义返回字的宽度end define 结束定义define format ( / G6 S T M1 M2 L P D E H O ) 第二段是定义字符的格式address width = 1------------ 定义字符宽度address width = 1------------ 定义字符宽度field width = 2 ------------- 定义返回字的宽度exponent width = 0 ---------- 指数的宽度scale factor = 1 ------------- 比例因子:值乘以 1scale divisor = 1 ------------ 比例因子:值被 1 除tape position = 1----------- 字前留一个空格print position = 1 -----------打印位置sign = none----- 用于不需要 G代码和进给率sign = if negative 仅标识负坐标sign = always 如果需要 + / - 号not permanent -------- 不需要行号not modal ------------ 仅当改变时需要重复的字为 modal 。

(模态)。

通常 G 代码和 X, Y 和 Z 为坐标为 modal,但圆心通常使用的 I, J, K 代码通常不是,因此它们为 not modal .metric formats --------------- 公制leading zeros = false --------- 前导 0trailing zeros = true ----------后导 0decimal point = false ------ 不需要小数点decimal places = 2 -------- 小数点后 2imperial formats ------------- 英制word order=====================语序word order = ( OP N G1 G2 G3 G4 G5 )word order = ( + G6 G7 X Y Z B C )word order = ( + I J K R D S T )word order = ( + H M1 M2 MS msg EM Q )word order = ( + Q1 Z2 R2 ID F )word order = ( + TN TD TR DY MT YR PM )define keys 第三段是定义键值blocknumber = N —————定义程序段号preparatory function = G1 ——定义准备功能指令aux function = M1 -------------定义辅助功能指令x feedrate not used ---------- 定义 X 进给率指令y feedrate not used ---------- 定义 Y 进给率指令z feedrate not used ——------ 定义 Z 进给率指令circle angle not used ————圆周角度x coordinate = X —————----定义 X 坐标轴y coordinate = Y —————----定义 Y 坐标轴z coordinate = Z —————--- 定义 Z 坐标轴key i = I —————---------- 定义 X 轴矢量 I 键key j = J ————— ----------定义 Y 轴矢量 J key k = K —————---------- 定义 Z 轴矢量 K 键feedrate = F —————------- 定义进给率指令feedrate per revolution = F--- 定义每转进给率指令spindle = S ——————----- 定义主轴指令tool number = T —————— --定义刀具指令cycle dwell not used-----------不使用循环停留dwell = X —————---------- 定义暂停时间键值tool length = H ——---------- 定义刀具长度补偿指令tool radius = D ——---------- 定义刀具半径补偿指令drill peck depth = Q1 ————钻孔的啄钻深度drill hole depth = Z2 ————-定义钻孔深度clearplane = R2 ———-------- 定义安全平面高度message start = MS ——------- 定义注释的开始符message end = EM ——--------- 定义注释的结束符opskip = OP ———— --------- 定义跳段符号radius = R ————— -------- 定义半径 R 键program id = ID ————— --- 定义程序号azimuth axis = B ---- ---------在多轴加工中,定义方位轴elevation axis = C ——------- 在多轴加工中,定义仰角轴3rd rotation axis = null ----- 在多轴加工中,定义第三旋转轴leader not used----------------领导不使用x vector not used--------------X矢量不使用y vector not used--------------Y矢量不使用z vector not used--------------Z矢量不使用error not used-----------------错误不使用end definedefine codes ------------- --------- 定义指令值rapid = G1 0 =====---------- -------- 快速点定位linear = G1 1 ===== ----------------- 直线插补circle cw = G1 2 =====------------- 顺圆插补circle ccw = G1 3 =====------------ 逆圆插补dwell = G6 4 === ------------------- 暂停、准确停止xy plane = G3 17 ======------------- XY 平面zy plane = G3 19 =====--------- ---- YZ 平面xz plane = G3 18 =====------------- ZX 平面compensation off = G2 40 == ------ 取消刀具半径补偿compensation on left = G2 41 ==== 刀具半径左补偿compensation on right = G2 42 === 刀具半径右补偿imperial data = G4 20 ===== --------- 英寸输入metric data = G4 21 =======---------- 毫米输入absolute data = G5 90 ====----------- 指定绝对坐标编程incremental data = G5 91 ====-------- 指定增量坐标编程from = G3 54 ===== -------------------制定工作坐标系feedrate per minute not used ====== 每分钟进给feedrate per revoluti not used ===== 每转进给spindle rpm not used -------------- 每分钟转速constant surface speed not used------ 恒定的表面速度drill = G4 81 ==== -------------------钻孔循环锪镗循环break chip = G4 82 === ---------------钻孔循环或反镗循环deep drill = G4 83 ======----------- 深孔钻循环tap = G4 84 ======= ------------------攻丝循环bore 1 = G4 85 =======--------------- 镗孔循环bore 2 = G4 86 ======--------------- 镗孔循环bore 3 = G4 87 ======---------------- 背镗循环bore 4 = G4 88 ======---------------- 镗孔循环bore 5 = G4 89 ====== ----------------镗孔循环end of drill = G4 80 ======---------- 固定循环取消macro start not used ======= ---------宏程序模态调用macro end not used =====------------- 宏程序模态调用取消macro call not used ========--------- 宏程序调用cycle retract = G6 99 ==------------ 固定循环返回到 R 点tool length offset = G3 43 ====----- 正向刀具长度补偿spline not used ========------------- spline 插补方式stop = M1 0 ====--------------------- 程序停止opt stop = M1 1 =====---------------- 选择停止spindle on cw = M1 3 =====----------- 主轴正转spindle on ccw = M1 4 =====---------- 主轴逆转spindle off = M1 5 =====------------- 主轴停止spin coolant on cw =----------------- M1 13spin coolant on ccw =---------------- M1 14spin coolant off = M1 5 ====-------- 冷却液关change tool = M1 6 ===== ------------ 自动换刀coolant on mist = M1 7 === ---------- 雾状冷却液coolant on = M1 8 ====--------------- 冷却液开coolant on flood = M1 8 =------------ 冷却液开(喷出)coolant off = M1 9 ===== -------------冷却液关clamp on not used ------ -------------主轴锁紧clamp off not used--------------------主轴锁紧不使用end of tape = M1 2 =====------------- 程序结束end of prog = M1 30 ===== ------------程序结束gear range 1 not used---------------- 变速范围1不使用gear range 2 not used---------------- 变速范围2不使用gear range 3 not used---------------- 变速范围3不使用constant contour speed not used----- 持续的轮廓速度不使用constant contour speed 2 not used----持续的轮廓速度2不使用word drill not used------------------钻孔指令不使用word break chip not used------------不使用断屑word deep not used------------------孔深不使用word tap not used------------------冷却水不使用word bore 1 not used---------------孔1不使用word bore 2 not usedword bore 3 not usedword bore 4 not usedword bore 5 not usedcoolant on tap not used-------------冷却液不使用rigid tap not used ======----------- 刚性攻丝helical drill not used ------------ 螺旋钻孔helical retract drill not used------螺旋钻孔不使用end define=========================== 定义变量Print header ="Delcam Post processor"==== 定义打印标题machine name = "Fanuc6m version 1.2" === 机器名point ================================== 小数点zero = "0" ============================= 零tape headers = 1 ======================= 纸带标题integer 6 = 2====================== === 定义冷却液开(M07 、M08 )的输出方式,此变量共有三个选项——0 :在后处理时遇到相关指令时输出;1 :在下一段中单独输出;2 :在下一段中和坐标移动一起输出。

[新版]powermill后处理

[新版]powermill后处理

[新版]powermill后处理PowerMILL后处理修改本教程是偶在实际使用中的PowerMILL后处理文件修改知识的积累,其中有部分修改案例来源于帮助文件,在此仅以文字和图片的形式把他记录下来与初学者共同分享。

一、完整的后处理文件介绍一个完整的后处理文件通常有:定义字符段、定义字符格式段、定义键值段、定义指令值段、变量定义、程序格式段等部分组成。

下面我们先来看一个比较完整的后处理文件,并把它分为数段,把需要修改的地方做个必要的解释:machine fanucom ——————后处理文件头=========================== 第一部分是定义字符段==============================define word TNaddress letter = "TOOL TYPE:- "address width = 13field width = 25end define具体解释:define word TN ——————————————定义字段;address letter = "TOOL TYPE:- " —————定义字段的返回值,比如在后处理文件里有“MS=C ; TN ToolType ; EM =C”,而在写程式的时候选用的是端铣刀,那么在CNC程式里就会有(TOOL TYPE:- ENDMILL);address width = 13 ———————————定义字符宽度,如上"TOOL TYPE:- ",从T开始算起一共13位,包括空格;field width = 25 ———————————定义返回字的宽度,如上"ENDMILL",如果fieldwidth = 2,那"TOOL TYPE:- "就返回EN;如果field width = 25,那"TOOL TYPE:- "就返回ENDMILL。

powermill后处理修改精华帖

powermill后处理修改精华帖

p o w e r m i l l后处理修改精华帖内部编号:(YUUT-TBBY-MMUT-URRUY-UOOY-DBUYI-0128)m a c h i n e f a n u c o m——————后处理文件头define word TN ---------------------------- 定义字段;address letter = "TOOL TYPE :- " ----- 定义字段的返回值address width = 13 定义字符宽度field width = 25 定义返回字的宽度end define 结束定义define format ( / G6 S T M1 M2 L P D E H O ) 第二段是定义字符的格式address width = 定义字符宽度address width = 定义字符宽度field width = 2 ------------- 定义返回字的宽度exponent width = 0 ---------- 指数的宽度scale factor = 1 ------------- 比例因子:值乘以 1scale divisor = 1 ------------ 比例因子:值被 1 除tape position = 字前留一个空格print position = 1 -----------打印位置sign = none----- 用于不需要 G代码和进给率sign = if negative 仅标识负坐标sign = always 如果需要 + / - 号not permanent -------- 不需要行号not modal ------------ 仅当改变时需要重复的字为 modal 。

(模态)。

通常 G 代码和 X, Y 和 Z 为坐标为 modal,但圆心通常使用的 I, J, K 代码通常不是,因此它们为 not modal . metric formats --------------- 公制leading zeros = false --------- 前导 0trailing zeros = true ----------后导 0decimal point = false ------ 不需要小数点decimal places = 2 -------- 小数点后 2imperial formats ------------- 英制word order=====================语序word order = ( OP N G1 G2 G3 G4 G5 )word order = ( + G6 G7 X Y Z B C )word order = ( + I J K R D S T )word order = ( + H M1 M2 MS msg EM Q )word order = ( + Q1 Z2 R2 ID F )word order = ( + TN TD TR DY MT YR PM )define keys 第三段是定义键值blocknumber = N —————定义程序段号preparatory function = G1 ——定义准备功能指令aux function = M1 -------------定义辅助功能指令x feedrate not used ---------- 定义 X 进给率指令y feedrate not used ---------- 定义 Y 进给率指令z feedrate not used ——------ 定义 Z 进给率指令circle angle not used ————圆周角度x coordinate = X —————----定义 X 坐标轴y coordinate = Y —————----定义 Y 坐标轴z coordinate = Z —————--- 定义 Z 坐标轴key i = I —————---------- 定义 X 轴矢量 I 键key j = J ————— ----------定义 Y 轴矢量 Jkey k = K —————---------- 定义 Z 轴矢量 K 键feedrate = F —————------- 定义进给率指令feedrate per revolution = F--- 定义每转进给率指令spindle = S ——————----- 定义主轴指令tool number = T —————— --定义刀具指令cycle dwell not used-----------不使用循环停留dwell = X —————---------- 定义暂停时间键值tool length = H ——---------- 定义刀具长度补偿指令tool radius = D ——---------- 定义刀具半径补偿指令drill peck depth = Q1 ————钻孔的啄钻深度drill hole depth = Z2 ————-定义钻孔深度clearplane = R2 ———-------- 定义安全平面高度message start = MS ——------- 定义注释的开始符message end = EM ——--------- 定义注释的结束符opskip = OP ———— --------- 定义跳段符号radius = R ————— -------- 定义半径 R 键program id = ID ————— --- 定义程序号azimuth axis = B ---- ---------在多轴加工中,定义方位轴elevation axis = C ——------- 在多轴加工中,定义仰角轴3rd rotation axis = null ----- 在多轴加工中,定义第三旋转轴leader not used----------------领导不使用x vector not used--------------X矢量不使用y vector not used--------------Y矢量不使用z vector not used--------------Z矢量不使用error not used-----------------错误不使用end definedefine codes ------------- --------- 定义指令值rapid = G1 0 =====---------- -------- 快速点定位linear = G1 1 ===== ----------------- 直线插补circle cw = G1 2 =====------------- 顺圆插补circle ccw = G1 3 =====------------ 逆圆插补dwell = G6 4 === ------------------- 暂停、准确停止xy plane = G3 17 ======------------- XY 平面zy plane = G3 19 =====--------- ---- YZ 平面xz plane = G3 18 =====------------- ZX 平面compensation off = G2 40 == ------ 取消刀具半径补偿compensation on left = G2 41 ==== 刀具半径左补偿compensation on right = G2 42 === 刀具半径右补偿imperial data = G4 20 ===== --------- 英寸输入metric data = G4 21 =======---------- 毫米输入absolute data = G5 90 ====----------- 指定绝对坐标编程incremental data = G5 91 ====-------- 指定增量坐标编程from = G3 54 ===== -------------------制定工作坐标系feedrate per minute not used ====== 每分钟进给feedrate per revoluti not used ===== 每转进给spindle rpm not used -------------- 每分钟转速constant surface speed not used------ 恒定的表面速度drill = G4 81 ==== -------------------钻孔循环锪镗循环break chip = G4 82 === ---------------钻孔循环或反镗循环deep drill = G4 83 ======----------- 深孔钻循环tap = G4 84 ======= ------------------攻丝循环bore 1 = G4 85 =======--------------- 镗孔循环bore 2 = G4 86 ======--------------- 镗孔循环bore 3 = G4 87 ======---------------- 背镗循环bore 4 = G4 88 ======---------------- 镗孔循环bore 5 = G4 89 ====== ----------------镗孔循环end of drill = G4 80 ======---------- 固定循环取消macro start not used ======= ---------宏程序模态调用macro end not used =====------------- 宏程序模态调用取消macro call not used ========--------- 宏程序调用cycle retract = G6 99 ==------------ 固定循环返回到 R 点tool length offset = G3 43 ====----- 正向刀具长度补偿spline not used ========------------- spline 插补方式stop = M1 0 ====--------------------- 程序停止opt stop = M1 1 =====---------------- 选择停止spindle on cw = M1 3 =====----------- 主轴正转spindle on ccw = M1 4 =====---------- 主轴逆转spindle off = M1 5 =====------------- 主轴停止spin coolant on cw =----------------- M1 13spin coolant on ccw =---------------- M1 14spin coolant off = M1 5 ====-------- 冷却液关change tool = M1 6 ===== ------------ 自动换刀coolant on mist = M1 7 === ---------- 雾状冷却液coolant on = M1 8 ====--------------- 冷却液开coolant on flood = M1 8 =------------ 冷却液开(喷出)coolant off = M1 9 ===== -------------冷却液关clamp on not used ------ -------------主轴锁紧clamp off not used--------------------主轴锁紧不使用end of tape = M1 2 =====------------- 程序结束end of prog = M1 30 ===== ------------程序结束gear range 1 not used---------------- 变速范围1不使用gear range 2 not used---------------- 变速范围2不使用gear range 3 not used---------------- 变速范围3不使用constant contour speed not used----- 持续的轮廓速度不使用constant contour speed 2 not used----持续的轮廓速度2不使用word drill not used------------------钻孔指令不使用word break chip not used------------不使用断屑word deep not used------------------孔深不使用word tap not used------------------冷却水不使用word bore 1 not used---------------孔1不使用word bore 2 not usedword bore 3 not usedword bore 4 not usedword bore 5 not usedcoolant on tap not used-------------冷却液不使用rigid tap not used ======----------- 刚性攻丝helical drill not used ------------ 螺旋钻孔helical retract drill not used------螺旋钻孔不使用end define=========================== 定义变量Print header ="Delcam Post processor"==== 定义打印标题machine name = "Fanuc6m version " === 机器名point ================================== 小数点zero = "0" ============================= 零tape headers = 1 ======================= 纸带标题integer 6 = 2====================== === 定义冷却液开(M07 、M08 )的输出方式,此变量共有三个选项——0 :在后处理时遇到相关指令时输出;1 :在下一段中单独输出;2 :在下一段中和坐标移动一起输出。

PowerMILL后处理修改教程

PowerMILL后处理修改教程

PowerMILL后处理修改教程本教程是偶在实际使用中的PowerMILL后处理文件修改知识的积累,其中有部分修改案例来源于帮助文件,在此仅以文字和图片的形式把他记录下来与初学者共同分享。

By mymould(风影爱人)一、完整的后处理文件介绍一个完整的后处理文件通常有:定义字符段、定义字符格式段、定义键值段、定义指令值段、变量定义、程序格式段等部分组成。

下面我们先来看一个比较完整的后处理文件,并把它分为数段,把需要修改的地方做个必要的解释:machine fanucom ——————后处理文件头=========================== 第一部分是定义字符段============================== define word TNaddress letter = "TOOL TYPE:- "address width = 13field width = 25end define具体解释:define word TN ——————————————定义字段;address letter = "TOOL TYPE:- " —————定义字段的返回值,比如在后处理文件里有“MS=C ; TN ToolType ; EM =C”,而在写程式的时候选用的是端铣刀,那么在CNC程式里就会有(TOOL TYPE:- ENDMILL);address width = 13 ———————————定义字符宽度,如上"TOOL TYPE:- ",从T开始算起一共13位,包括空格;field width = 25 ———————————定义返回字的宽度,如上"ENDMILL",如果fieldwidth = 2,那"TOOL TYPE:- "就返回EN;如果field width = 25,那"TOOL TYPE:- "就返回ENDMILL。

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

后处理的实际应用中,经常需要修改或删除的部分主要有几方面:程序头的修改;程序尾的修改;刀具调用的修改;第四轴的开启与关闭;各种注释部分的删除;钻孔循环的定制;行号的设定与省略;新参数的设定等。

(1)程序头的修改。

选中任务树窗口中的"Fanuc OM.pmopt Commands-Start Program"项,在右边图形窗口中,选中程序中不需要的部分,再点击上方的删除图标,可以删除该部分内容;如程序中默认的机床回参考点程序段"G91G28XOYOZO",如在程序启动时不必首先回参考点,可删除该段内容。

(2)程序尾的修改。

在任务树窗口中的"Fanuc OM.pmopt-Commands-Finish Program"项中可以定义程序尾部分的内容。

默认的程序尾包含了"G91G28Z0"和"G28XOY0"机床回参考点选项,如不需要也可以删除。

(3)换刀程序段的修改。

选中任务树窗口中的"Fanuc OM.pmopt -Commands-Tool Control-Load First Tool"项,可以通过选中图形窗口中的"M6"项,点击添加"BlockNumber",使T指令和M6指令分行;同样可以使Change Tool项中的T指令和M6指令分行;如采用手动换刀,则NC程序中不需换刀程序,可右键点击"Load First Tool"和"Change Tool",在快捷键中选中"Deactivate,以关闭换刀程序。

(4)第4轴的开启和关闭。

选中任务树窗口中的"Fanuc OM.pmopt-Settings-Machine Kinematics"项,右边图形窗口中"KinematicModel"的选项,默认的"3-Axis"项则关闭第4轴;"4-Axis"项则打开第4轴,第4轴打开后,需对其方向、原点及行程范围等进行设置。

(5)各种注释部分的删除。

程序头部分、换刀部分等都设定了相应的注释,如不需要这些注释,可以进人程序头部分、换刀部分,将其中的注释内容选中删除即可。

(6)钻孔循环指令的定制。

打开任务树窗口中的"Fanuc OM.pmopt-Commands-Drilling Cycles"项,这里定义了各种钻销循环。

如其中的"Single Pecking Setup"定义了基本钻削循环G81指令;"Deep Drill Setup"中定义深孔钻削循环G83指令。

如要取消,可右键点击该指令,在快捷键中选中"Deactivate",即可取消该项定义。

"DrillingCycles"子目录下还有其他钻镬削循环,可根据机床具体情况进行定义或删除。

(7)行号的设定与省略。

点击任务树窗口中的"Fanuc OM.pmopt-Settings-Global Constants"选项,右边图形窗口中"OutputBlock Number,项的"Value"框中的值,默认的为Yes ,显示行号;改为No,则不显示行号;"Block Increment"项为程序行号间距,"Value"值默认的为10,可根据需要修改成适合自己的行号间距。

(8)新参数的设定。

当数控机床的控制系统在PowerMILL自带的后置处理选项文件中没有的时候,就需要重
新定义新的控制系统选项文件。

如需专门定义各种常用G,M,F,S代码以及坐标表示等,可在"Fanuc OM.pmopt-Parameters"项中进行。

如,需修改快进G代码G00,可双击"Fanuc OM.pmopt -Parameters -General -MotionMode",在弹出的对话框中对"RAP状态项后面的"Value"值进行修改,还可以在对话框上半部分的"Prefix"修改快进指令的前缀+G ;如需修改冷却模式的M代码,可双击"Fanuc OM.pmopt-Parameters-General-Coolant Mode",在弹出的对话框中进行相应修改;主轴转速可在"Fanuc
OM.pmopt-Parameters-General-Spindle Speed"中进行。

4基于宏的后处理快速定制
在PowerMILL的应用过程中,一般软件自动编程所对应的机床控制系统都是固定不变的,如果每次启动都对NC程序的后处理进行相同的设置则显得较麻烦。

利用PowerMILL 自带的宏的编制,可以实现每次软件启动后自动进行NC程序后处理的默认定制,加速NC 程序代码的生成,简化NC程序生成过程。

PowerMILL默认每次启动后会自动运行的宏"pmuser.mac"保存在程序安装目录下"X:1ProgramFiles\Delcam\PowerMILL6008\lib\macro"。

其中"X"代表PowerMILL的安装根目录。

这里可以采用宏将固定不变的NC程序后处理相关设置步骤记录下来,实现程序启动后自动加载默认的后处理定制。

如:希望每次NC程序后处理默认的机床选项文件为系统自带的"Fanuc.pmopt",默认的NC程序后缀名改为".nc",所有NC程序的存放文件夹为"E:\Temp\FANUC"。

具体实现步骤如下:
(1)启动PowerMILL后,右键单击浏览器最下端的"宏",点选"记录",在弹出的"选取记录宏文件"的对话框中设置好宏的保存目录和文件名,程序开始将后面的每一步操作都记录在宏文件中。

(2)打开菜单"工具-选项",在弹出的"选项表格"对话框中的"NC程序"标签下,"文件类型"选择"NC程序","选项文件"选择"Fanuc",后缀名"tap"改为+nc;,路径输人"FANUC".
(3)右键点击浏览器中的"NC程序",选"参数选择",在弹出的"NC参数选择"对话框中的"输出目录"中输人"E:/1emp",在"机床选项文件"中找到"Fanuc.pmopt"的存放路径,本机存放路径为"D:/ProgramFiles/Delcam/PMPost40001fi1e/Genetic/Fanuc.pmopt"。

(4)右键单击浏览器中的宏停止宏的记录。

(5)在浏览器的宏目录下打开编辑刚才生成的宏,将其中的内容拷贝到系统用户宏"pmuser.mac"中。

每次启动PowerMILL后,程序都会自动读取宏进行默认的后处理设置。

通过以上操作,可方便实现PowerMILL宏程序的编制,完成包括后处理等在内的各种默认操作的定制。

如果对PowerMILL的操作命令较熟悉,也可以直接在宏"pmuser.mac"中输人各操作命令完成各项默认操作的定制。

如以上后处理的默认设置,可以在宏"pmuser.mac"中输人以下命令即可:
5结束语
本文对PowerMILL后处理方法及其设置进行总结探讨,并结合PowerMILL宏程序的编制,对快速定制PowerMILL默认后处理的方法进行讨论。

PowerMILL的后处理及其设置与早期版本有较大改动,使PowerMILL的后处理功能更加强大、更加简便、也更加快捷。

PowerMILL的使用者可以根据本文的方法,举一反三进行相应地调整,形成最适合自己的后处理模式。

相关文档
最新文档