{9/19/88 Modified: Dyna Myte 2000 Changes made per TF. Reverse Arc +-. Added literal 'NEWPART'. Modified FIRST TOOL IN SPINDLE. TD for CRC only. WFG}
{7/24/90, Added InitProg globally to posts with this remark, DWB}
{10/16/90 Modified: Dyna Myte 2000 M119.53 Updated to Version 3.4 per Fanuc 6M M001.76.1 Format. JR}
{1/30/91 Modified: Dyna Myte 2000 M119.76.1 Replaced Drill cycle output with source from Dyna Myte 4400. Added necessary formats to support new Drill cycles. Deleted the following from ToolPath (If PointFeat? AND NOT AutoCycle?): '? ' ' REPEAT X 01' EOL '? ' ' Xi= 0' EOL This occurred only in a drill cycle - what the hell was it doing here? JC}
{3/1/91 Modified: Dyna Myte 2000 M119.76.1a For: Gibbs & Associates Updated to Version 3.4 per Fanuc 6M M001.76.3 Format. Corrected Drill cycles, AutoCycles, Repeats and Arcs in all planes per results from tests on a Dyna Myte 2400 milling machine. NOTE: This post processor will not output correctly if the user requests MultipleParts and any operation contains AutoCycles or Repeats. DWB}
{4/03/91 Modified: Dyna Myte 2000 M119.76.3 For: Gibbs & Associates Updated to Version 4.0 per Fanuc 6M M001.80 Format. DWB}
{5/31/91 Modified: Dyna Myte 2000 M119.79 For: Gibbs & Associates Modified to output literal 'GOf' on all Rapid moves, Rapid is not a modal condition. Deleted 'TOOL Tool#' from FirstOperation, causes Spindle to Rapid into part. DWB}
{Prog Numeric Format Definitions *******************************************}
DoSubComment: IF UseComments? AND SubComment? '( SUB NUMBER: ' Program# ' )' EOL END RETURN
DoOpComments: IF UseComments? SetScale('1') IF OperationIDComment? '( OPERATION ' Operation# ': ' OperationType$ ' )' EOL END IF OperationComment? '( ' OperationComment$ ' )' EOL END IF WorkGroupComment? '( ' WorkGroupComment$ ' )' EOL END IF ToolTypeComment? '( TOOL ' Tool# ': ' ToolDiameter# ' ' ToolType$ ' )' EOL END IF ToolComment? '( ' ToolComment$ ' )' EOL END IF Metric? {CAM file is in metric, tools and tool path} SetScale('.03937007874') { change to English, this is an English post} END END RETURN
MoveType: 'G' {all moves get this} IF AutoCycle? 'R' {incremantal} ELSE 'O' {absolute} END RETURN
FeedRates: IF Milling? '? ' 'FR XY =' FeedContour# EOL END '? ' 'FR Z =' FeedEntry# EOL RETURN
PSInit: {reset flags} RotateF RETURN
PSStuff: {revised.72} IF FourthCW? FORMAT(FourthDegree#,2) '? ' ' A' FourthDegree# EOL FourthCWF {reset flag} END IF FourthCCW? FORMAT(FourthDegree#,3) '? ' ' A' FourthDegree# EOL FourthCCWF {reset flag} END IF FifthCW? FORMAT(FifthDegree#,2) '? ' ' B' FifthDegree# EOL FifthCWF {reset flag} END IF FifthCCW? FORMAT(FifthDegree#,3) '? ' ' B' FifthDegree# EOL FifthCCWF {reset flag} END RETURN
FormatArc: IF XYPlane? '? ' 'ARC ' EOL IF AutoCycle? SetAbs END '? ' ArcI EOL '? ' ArcJ EOL IF AutoCycle? SetInc END '? ' ' a=' IF ArcCW? '-' ELSE ' ' END ArcAngle# EOL ELSE IF Repeats? '*** ERROR - CANNOT USE XZ OR YZ ARCS WITH REPEATS' EOL ELSE IF XZPlane? '? ' 'ZERO Y' EOL ELSE {YZPlane} '? ' 'ZERO X' EOL END '? ' 'ZERO AT ' EOL '? ' ' Z' ArcJ# EOL '? ' 'GR Q' IF ArcCW? '-' ELSE ' ' END ArcAngle# EOL '? ' '>REF COODS' EOL END END RETURN
ToolPath: EACHFeat IF PointFeat? IF AutoCycle? IF NOT FirstFeat? '? ' 'GOfX' SPX# EOL '? ' 'GOfY' SPY# EOL END CalcACSRXY {calc tool position after sub call, CalcAutoCycleStatusRecordXY} SetStatusOff SetACSPCompF '? ' 'ZERO AT' EOL '? ' ' X' SPX# EOL '? ' ' Y' SPY# EOL '? ' 'CALL SUB ' Program# EOL '? ' '>REF COODS' EOL SetACSPComp SetStatusOn ELSE IF FIRO? OR Peck? '? ' ' X=' SPX# EOL '? ' ' Y=' SPY# EOL ELSE IF NOT FirstFeat? '? ' ' X=' SPX# EOL '? ' ' Y=' SPY# EOL END IF FIFO? '? ' 'GOcZ' SPZ# EOL ELSE {Tap} '? ' 'GO Z' SPZ# EOL '? ' 'GOf' ZCP2 EOL END END END ELSE IF RapidFeat? IF XMove? OR YMove? '? ' MoveType 'f' MoveX EOL '? ' MoveType 'f' MoveY EOL END IF ZMove? '? ' MoveType 'f' MoveZ EOL END ELSE IF LineFeat? IF XMove? OR YMove? '? ' MoveType ' ' MoveX EOL '? ' ' ' MoveY EOL IF Repeats? AND ZshiftOnly? AND NoZMoves? ELSE IF ZMove? '? ' ' ' MoveZ EOL END END ELSE IF ZMove? '? ' MoveType ' ' MoveZ EOL END END ELSE IF ArcFeat? EACHQuadrant { Do not use NOT, FIRST, LAST or NEXT modifiers in this loop } FormatArc NEXTQuadrant END END END END NEXTFeat RETURN
WFOStuff: { Note: This Post Processor does not support Work Fixture Offsets. } RETURN
AutoCycCutSub2: {part 2} ToolPath SetAbs IF Repeats? AND FeedConnect? AND ZshiftOnly? ELSE '? ' 'GOf' ZCP2 EOL END '? ' 'SUB RETURN' EOL CloseSub SetSRSubXY {restore SR to 1st position value} SetSRSubMove RETURN
AutoCycPat: SetPass2 {position pattern} ToolPath {call after NewProg for correct sub calls} SetPass1 {reset} RETURN
Milling: IF AutoCycle? NewProg AutoCycCutSub1 EntryMove AutoCycCutSub2 AutoCycPat ELSE EntryMove ToolPath END RETURN
XYOnlyRepAutoCycle: EachRep EACHFeat IF FirstCycle? AND FirstFeat? ELSE '? ' 'GOfX' SPX# EOL '? ' 'GOfY' SPY# EOL END CalcACSRXY {calc tool position after sub call, CalcAutoCycleStatusRecordXY} SetStatusOff SetACSPCompF '? ' 'ZERO AT' EOL '? ' ' X' SPX# EOL '? ' ' Y' SPY# EOL '? ' 'CALL SUB ' Program# EOL '? ' '>REF COODS' EOL SetACSPComp SetStatusOn NEXTFeat NextRep AutoCycCutSub1 EntryMove AutoCycCutSub2 RETURN
ZonlyRepAutoCycle: AutoCycPat {write pattern moves and main calls} StartSub NewProg EachCycle IF FeedConnect? '? ' 'GO ' ZInPlusInc EOL ELSE IF FeedEntry? IF NOT FirstCycle? '? ' 'GOf' ZCP2PlusInc EOL {.69 added Rapid, reads better} {can't call for cycle = 1, .69 changed to ZCP2PlusInc} END '? ' 'GO ' ZInPlusInc EOL ELSE '? ' 'GOf' ZInPlusInc EOL {.69 added Rapid, reads better} END END IF FirstCycle? SetStatusOff {protect Z position for incremental sub} END '? ' 'CALL SUB ' Program# EOL NextCycle SetStatusOn AutoCycCutSub1 {build element sub} AutoCycCutSub2 {.69, removed FinishSub1} IF FeedConnect? {there is no Z up in the sub, .69} '? ' 'GOf' ZCP2 EOL END '? ' 'SUB RETURN' EOL CloseSub RETURN
ZonlyRep: EachCycle IF NOT FirstCycle? IF FeedConnect? '? ' 'GO X' StartPosX# EOL '? ' ' Y' StartPosY# EOL ELSE '? ' 'GOfX' StartPosX# EOL '? ' 'GOfY' StartPosY# EOL END END IF FeedConnect? '? ' 'GO ' ZInPlusInc EOL {.71.2, changed to FeedC} ELSE {Entry/Exit Connect} IF FeedEntry? IF NOT FirstCycle? '? ' 'GOf' ZCP2PlusInc EOL {can't call for cycle =1} {.69 added Rapid, reads better} {.71.2, changed to RapidC, reads better} END '? ' 'GO ' ZInPlusInc EOL ELSE '? ' 'GOf' ZInPlusInc EOL {.69 added Rapid, reads better} {.71.2, changed to RapidC, reads better} END END '? ' 'CALL SUB ' Program# EOL NextCycle StartSub SkipZ ToolPath FinishSub1 '? ' 'SUB RETURN' EOL CloseSub RETURN
CheckPass: IF AutoCycle? {use the correct StrtPos} SetPass2 ELSE SetPass1 END RETURN
{Start of executable Prog **************************************************}
{setup and initializations} InitProg ReverseXZArcs UseSeparateSubCalls SetMaxSeparateSubCalls ('50') SetMaxRPM('3000') SetMaxFeed('30') SetLowerCaseOK IF PSComment? AND UseComments? 'PostScript:' EOL ' Literals: put between single or double quotes.' EOL ' Separate commands and literals with at least one space.' EOL ' A CR ( RETURN key ) will start a new line.' EOL ' Commands: may be capital and/or lower case letters. Separate commands with a space.' EOL ' EndOP -' EOL ' all literals and commands before an ENDOP command' EOL ' will appear at the beginning of the operation. All ' EOL ' literals and commands after an ENDOP command will appear' EOL ' at the end of the operation. ' EOL ' 4thAxisCW(12.5), 4ACW(12.5) -' EOL ' generates a + A move of the value you specify' EOL ' 4thAxisCCW(22.5), 4ACCW(22.5) -' EOL ' generates a - A move of the value you specify' EOL ' 5thAxisCW(30), 5ACW(30) -' EOL ' generates a + B move of the value you specify' EOL ' 5thAxisCCW(22.5), 5ACCW(22.5) -' EOL ' generates a - B move of the value you specify' EOL END IF MultipleParts? ' ' EOL '***** WARNING!!! This post processor does not support MultipleParts with *****' EOL '***** any operation that contains Arcs generated in the XZ or YZ plane, *****' EOL '***** or any operation that contains Repeats or AutoCycles, or both!!! *****' EOL ' ' EOL END EachOp {Start of post processing *********************} SetAbs Plane IF FirstOperation? EOR EOL '? ' 'START INS ' Program# EOL IF ToolChangeAtHome? SetHome END IF UseComments? IF ProgramNameComment? '( PROGRAM: ' ProgramName$ ' )' EOL END IF ProgramComment? '( ' ProgramComment$ ' )' EOL END IF FormatNameComment? '( FORMAT: ' FormatName$ ' )' EOL END IF TimeComment? '( ' Date$ ' AT ' Time$ ' )' EOL END IF MovesComment? '( OUTPUT IN ABSOLUTE INCHES )' EOL END IF PartsComment? '( PARTS PROGRAMMED: ' Parts# ' )' EOL END IF StartToolComment? '( FIRST TOOL IN SPINDLE )' EOL END END OpenSub IF Metric? {CAM file is in metric, tools and tool path} SetScale('.03937007874') { change to English, this is an English post} END IF MultipleParts? AND AllToolsOnePart? OpenMP END '? ' 'SETUP >zcxyu' EOL DoOpComments DoPostScript IF CutterRadiusCompensation? '? ' 'TD= ' ToolDiameter# EOL END FeedRates '? ' 'SPINDLE ON' EOL IF MultipleParts? AND OneToolAllParts? AND FullUp? OpenMP END CheckPass IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane? OpenMP END '? ' 'GOfX' StartPosX# EOL '? ' 'GOfY' StartPosY# EOL ELSE IF NewTool? IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane? CloseMP END '? ' 'Z>ZMAX' EOL IF MultipleParts? AND OneToolAllParts? AND FullUp? CloseMP END DoEndOpPS IF ToolChangeAtHome? '? ' 'GOfX' HomeX# EOL '? ' 'GOfY' HomeY# EOL END '? ' 'SPINDLE OFF' EOL IF LAST ProgStop? '? ' 'HALT' EOL ELSE IF OptionalStops? '? ' 'HALT' EOL END END
{Start new Operation}
DoOpComments DoPostScript '? ' 'TOOL ' Tool# EOL IF CutterRadiusCompensation? '? ' 'TD= ' ToolDiameter# EOL END FeedRates '? ' 'SPINDLE ON' EOL IF MultipleParts? AND OneToolAllParts? AND FullUp? OpenMP END CheckPass IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane? OpenMP END '? ' 'GOfX' StartPosX# EOL '? ' 'GOfY' StartPosY# EOL ELSE IF SameTool? DoEndOpPS IF LAST ProgStop? '? ' 'Z>ZMAX' EOL '? ' 'SPINDLE OFF' EOL '? ' 'HALT' EOL
GetStartOfSameTool FeedRates '? ' 'GOfX' StartPosX# EOL '? ' 'GOfY' StartPosY# EOL END END END END END {common point for all operations} IF Milling? '? ' 'GOf' ZCP2 EOL IF Repeats? NewProg IF ZshiftOnly? IF AutoCycle? {incremental Autocycle sub can have Z moves} ZonlyRepAutoCycle ELSE {Z shift only, NOT Auto Cycle} IF UseSeparateSubCalls? AND CyclesLessThanMaxSubCalls? FindAnyZMoves {for normal abs subroutine} IF NoZMoves? ZonlyRep ELSE G92Sub {pattern shift, not element} END ELSE {no sep subs desired} G92Sub END END {end Auto Cycle IF} ELSE {not Z only} IF AutoCycle? XYOnlyRepAutoCycle ELSE G92Sub END END {end Z only IF} ELSE {no repeat OPs} Milling END '? ' 'GOf' ZCP3 EOL ELSE IF Drilling? GetCycle IF Peck? OR FIRO? IF Repeats? NewProg '? ' 'CALL SUB ' Program# EOL '? ' 'REPEAT ' RepsLess1# EOL '? ' 'GOfX' RepeatX# EOL '? ' 'GOfY' RepeatY# EOL '? ' 'PROG.REF' EOL '? ' 'CALL SUB ' Program# EOL StartSub '? ' 'GOfX' StartPosX# EOL '? ' 'GOfY' StartPosY# EOL END IF Peck? '? ' 'DRIL PECK=' NumFullPecks# EOL ELSE '? ' 'DRIL PECK=00' EOL END '? ZH=' ClearancePlane2# EOL '? Zd= ' ZDepth# EOL ToolPath IF Repeats? '? ' 'SUB RETURN' EOL CloseSub '? ' 'REPEAT END' EOL '? ' 'GOfX' OriginUnshiftRX#('1') EOL '? ' 'GOfY' OriginUnshiftRY#('1') EOL '? ' 'PROG.REF' EOL END ELSE {NOT Peck? OR FIRO?} IF Repeats? StdSub '? ' 'GOfX' StartPosX# EOL '? ' 'GOfY' StartPosY# EOL END '? ' 'GOf' ZCP2 EOL ToolPath IF Repeats? FinishSubG92 END END '? ' 'GOf' ZCP3 EOL END END NextOp {loops back to EachOP until last Operation}
{End of program ************************************************************}
{finish last operation} IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane? CloseMP END '? ' 'Z>ZMAX' EOL IF MultipleParts? AND OneToolAllParts? AND FullUp? CloseMP END DoEndOpPS IF FIRST ToolChangeAtHome? {.71.2 added FIRST modifier} '? ' 'GOfX' FIRST HomeX# EOL '? ' 'GOfY' FIRST HomeY# EOL END '? ' 'SPINDLE OFF' EOL IF ProgStop? '? ' 'HALT' EOL END IF MultipleParts? AND AllToolsOnePart? CloseMP END '? ' 'SKIP TO ł' Tag# EOL CloseSub Post2 {organize Subs into one program} '>' Tag# EOL '? ' 'END NEWPART' EOL Close Retag IF UseComments? SetScale('1') {restore scale for comments} Reopen IF FileBytesComment? '( FILE LENGTH: ' FileBytes# ' CHARACTERS )' EOL END IF FileFeetComment? '( FILE LENGTH: ' FileFeet# ' FEET )' EOL END IF FileMetersComment? '( FILE LENGTH: ' FileMeters# ' METERS )' EOL END Close END