Heid 145C BP [PE] MU31 89 1m


{Change Comments ***********************************************************}

{11/16/95, M215.79.1, Updated for Catalyst v2.20 per Fanuc 6M M001.85 Format, DWB}
{5/24/96, Updated to .89 format, MPK}

{25Jun98
Original: Heid 145C BP M215.89m
Created: Heid 145C BP [PE] MU31.89m
For: Penico Engineering
Changes made per: Bob Jones
Deleted old version numbers and comments e.g. {.62}, {commands}, {literals}, etc
Changed FORMAT#8 from '###^0' to '###^#' in Prog Numeric Format Definitions
Changed Literal ' Z+0.0000' to ZCP1
Changed DoM to ' M99' at IF Drilling? ( in 2 places )
Changes M06 to M25 in MachSpec
Changed Literal 'S1.000' to 'S1000.000' in FirstOp and NewTool
Changed Literal 'Z+0.0000' to 'Z+0.000' at End of Prog
Added support for a custom tool list using SetupToolList sub and OutputToolData sub.
Because of the differences in the Compost Commands Tool# and TLNum# it is not possible to output
a List of Tools ( in numberical order ) where customers are using a combination of the Tool ID# and Tool Number.
This is because TLNum# is not the same as Tool#, and, TLNum# can ONLY be used inside an EachTool/NextTool Loop.
The solution is not elegant but it does provide a method to achieve this output regardless of whether the customer uses
Tool Number, Tool ID or a combination of both. It is limited here, to a maximum of 130 tools, although this can be increased.
Charles Winston}

{9Jul98
Original: Heid 145C BP [PE] MU31.89m
Created: Heid 145C BP [PE] MU31.89.1m
For: Penico Engineering
Changes made per: Bob Jones
Deleted FORMAT#8 in Prog Numeric Format Definitions
Changed FeedEntry# to FORMAT#5
Changed Default FORMAT for F, to #######0 in MachSpec
Added Format for TrackZNO# in Prog Numeric Format Definitions
Changed Literal 'F3999' to 'F9999' in RF Sub
Added Boolean in CheckMove to suppress Zmoves below 0.0005 MM
Changed Literal ' Z+0.000' to ZCP1 at end of Prog
Modified the Custom Tool List Subs to avoid using Variable Num#('0')
Charles Winston}

{Prog Numeric Format Definitions *******************************************}

#1 = '#0.00'
#2 = '###.###;0.'
#3 = '*###.###;0.'
#4 = 'ą####0.000'
#5 = '#######0'
#6 = '###0.000'
#7 = 'ą*####0.000'
#8 = '###^#'

FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(DIV#,4)
FORMAT(SPX#,4)
FORMAT(SPY#,4)
FORMAT(SPZ#,4)
FORMAT(EPX#,4)
FORMAT(EPY#,4)
FORMAT(EPZ#,4)
FORMAT(ArcI#,4)
FORMAT(ArcJ#,4)
FORMAT(ZDepth#,4)
FORMAT(RepeatX#,4)
FORMAT(RepeatY#,4)
FORMAT(RepeatZ#,4)
FORMAT(PartShiftX#,4)
FORMAT(PartShiftY#,4)
FORMAT(PartShiftZ#,4)
FORMAT(OriginUnShiftPX#,4)
FORMAT(OriginUnShiftPY#,4)
FORMAT(OriginUnShiftPZ#,4)
FORMAT(OriginUnShiftRX#,4)
FORMAT(OriginUnShiftRY#,4)
FORMAT(OriginUnShiftRZ#,4)
FORMAT(FeedEntry#,5)
FORMAT(Peck#,4)
FORMAT(ToolDiameter#,4) {.72}
FORMAT(TLDia#,4)
FORMAT(TLLength#,4)
FORMAT(ToolLength#,4)
FORMAT(DIV#,4)
FORMAT(TrackZNO#,4)
FORMAT(TLNum#,5)
FORMAT(CallMasterNum#,5)
FORMAT(Program#,5) {.72}
FORMAT(Operation#,5) {.72}
FORMAT(Tool#,5) {.72}
FORMAT(Parts#,5) {.72}
FORMAT(Recall#,5) {.72}
FORMAT(Num#,5) {.72}
FORMAT(Dwell#,6) {.72}
FORMAT(ABS#,7)
FORMAT(ClearancePlane2#,7)

{Special Subs **************************************************************}

DoL:
' L '
RETURN

DoZL:
' '
RETURN

Space: { 9 Spaces }
' '
RETURN

XYZSpace:
' ' Space
RETURN

XYSpace:
' ' Space Space
RETURN

ZSpace:
' ' Space Space Space
RETURN

IXYZSpace:
Space
RETURN

IXYSpace:
Space Space
RETURN

IZSpace:
Space Space Space
RETURN

DoR0:
IF NOT Flag?('3') { ArcFeat }
' '
END
IF Flag?('2') { CutterRadiusCompensation }
IF CRCleft?
' RL'
ELSE
' RR'
END
ELSE
' R0'
END
RETURN

RF: { RapidF }
' F9999'
RETURN

DoM:
' M'
RETURN

ckCRCOff:
IF Flag?('2') { CRCOn }
SetFlagF('2')
SeqLab DoL ' IX+0.0000 IY+0.0000' IXYSpace DoR0 RF DoM EOL
END
RETURN

{Prog Subroutines **********************************************************}

RestoreScale:
IF NOT Metric? { CAM file is in English, tools and tool path }
SetScale('25.4') { change to Metric, this is a Metric post }
ELSE
SetScale('1')
END
RETURN

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
RestoreScale
END
RETURN

PSInit: {reset flags}
RotateF
OptCyc1F
MasterOpF
CallMasterOpF
RETURN

PSStuff: {revised.72}
IF FourthCW?
FORMAT(FourthDegree#,2)
SeqLab 'A' FourthDegree# EOL
FourthCWF {reset flag}
END
IF FourthCCW?
FORMAT(FourthDegree#,3)
SeqLab 'A' FourthDegree# EOL
FourthCCWF {reset flag}
END
IF FifthCW?
FORMAT(FifthDegree#,2)
SeqLab 'B' FifthDegree# EOL
FifthCWF {reset flag}
END
IF FifthCCW?
FORMAT(FifthDegree#,3)
SeqLab 'B' FifthDegree# EOL
FifthCCWF {reset flag}
END
RETURN

DoPostScript:
PSInit
EachPS
SeqLab PostScript EOL {literals}
PSStuff {commands}
NextPS
RETURN

DoEndOpPS:
PSInit
EachEOPS
SeqLab EndOpPS EOL {literals}
PSStuff {commands}
NextPS
RETURN

EntryMove:
SeqLab DoZL
IF AutoCycle? {implies incremental}
' IZ' SPZ# IZSpace
ELSE
ZIn ZSpace
END
DoR0
IF FeedEntry?
Feed {no output}
FeedEnt ' '
ELSE
RF
END
DoM EOL
RETURN

StartSub:
OpenSub
DoSubComment
SeqLab ' LBL ' Program# EOL
RETURN

SubWarning:
IF NOT FeedConnect?
IF AnyZshift?
' ' EOL
'( WARNING Z CLEARANCE WILL CHANGE WITH EACH CYCLE OF SUB REPEAT )' EOL
' ' EOL
END
END
RETURN

StdSub:
SeqLab ' CALL LBL ' Program# ' REP' EOL
StartSub
RETURN

FinishSub1: {part 1}
IF NOT FeedConnect?
SeqLab DoZL ZCP3 ZSpace
IF Flag?('2') { CRCOn }
SetFlagF('2')
DoR0
SetFlag('2')
ELSE
DoR0
END
IF AutoCycle?
RF
ELSE
IF FIFO? {.81}
Feed {no output}
FeedEnt ' '
ELSE
RF
END
END
DoM EOL
END
ckCRCOff
RETURN

FinishSubG92: {part 2}
SeqLab ' CYCL DEF 7.0 DATUM SHIFT' EOL
SeqLab ' CYCL DEF 7.1 IX' RepeatX# EOL
SeqLab ' CYCL DEF 7.2 IY' RepeatY# EOL
SeqLab ' CYCL DEF 7.3 IZ' RepeatZ# EOL
SeqLab ' CALL LBL ' Program# ' REP ' RepsLess1 ' / ' RepsLess1 EOL
SeqLab ' LBL 0' EOL
CloseSub
SeqLab ' CYCL DEF 7.0 DATUM SHIFT' EOL
SeqLab ' CYCL DEF 7.1 IX' OriginUnShiftRX#('1') EOL
SeqLab ' CYCL DEF 7.2 IY' OriginUnShiftRY#('1') EOL
SeqLab ' CYCL DEF 7.3 IZ' OriginUnShiftRZ#('1') EOL
RETURN

OpenMP:
IF EquallySpacedOffsets?
NewProg
SeqLab ' CALL LBL ' Program# ' REP' EOL
StartSub
END
RETURN

CloseMP:
IF EquallySpacedOffsets?
SeqLab ' CYCL DEF 7.0 DATUM SHIFT' EOL
SeqLab ' CYCL DEF 7.1 IX' PartShiftX# EOL
SeqLab ' CYCL DEF 7.2 IY' PartShiftY# EOL
SeqLab ' CYCL DEF 7.3 IZ' PartShiftZ# EOL
SeqLab ' CALL LBL ' Program# ' REP ' PartsLess1 ' / ' PartsLess1 EOL
SeqLab ' LBL 0' EOL
CloseSub
SeqLab ' CYCL DEF 7.0 DATUM SHIFT'EOL
SeqLab ' CYCL DEF 7.1 IX' OriginUnShiftPX#('1') EOL
SeqLab ' CYCL DEF 7.2 IY' OriginUnShiftPY#('1') EOL
SeqLab ' CYCL DEF 7.3 IZ' OriginUnShiftPZ#('1') EOL
END
RETURN

DoAbsOrInc:
IF Flag?('1') AND AbsoluteMoves?
IF ZMove? AND AbsValue?
SetInc
ELSE
IF NOT ZMove? AND NOT AbsValue?
SetAbs
END
END
END
RETURN

DoDrillAbsOrInc:
IF Flag?('1') AND AbsoluteMoves?
IF SPZMove? AND AbsValue?
SetInc
ELSE
IF NOT SPZMove? AND NOT AbsValue?
SetAbs
END
END
END
RETURN

RestoreAbsOrInc:
IF Flag?('1') AND AbsoluteMoves? AND NOT AbsValue?
SetAbs
END
RETURN

CheckMove:
IF AutoCycle? OR NOT AbsValue?
IF XMove? OR YMove? OR ArcFeat?
' IX' EPX# ' IY' EPY#
IF ZMove?
IF GTEqual? Abs# Sub# SPZ# EPZ# Num#('0.0005')
' IZ' EPZ# IXYZSpace
END
ELSE
IXYSpace
END
ELSE
IF ZMove?
' IZ' EPZ# IZSpace
END
END
ELSE
IF XMove? OR YMove? OR ArcFeat?
MoveX MoveY
IF ZMove?
MoveZC XYZSpace
ELSE
XYSpace
END
ELSE
IF ZMove?
MoveZC ZSpace
END
END
END
RETURN

ckCRC:
IF CutterRadiusCompensation?
IF LastFeat?
SetFlagF('2') { CRCOff }
ELSE
IF NOT ZMove?
SetFlag('2') { CRCOn }
END
END
END
RETURN

ckCRCNum:
{ Not Supported }
RETURN

FormatArc:
DoAbsOrInc
SeqLab ' CC '
IF AutoCycle? OR NOT AbsValue? {implies incremental}
' IX' ArcI# ' IY' ArcJ#
ELSE
ArcIJ
END
EOL
SeqLab ' C ' CheckMove
IF ArcCW?
'DR-' CWArc {no output}
ELSE
'DR+' CCWArc {no output}
END
SetFlag('3')
DoR0
SetFlagF('3')
RETURN

FormatLine:
IF ZMove? AND NOT XMove? AND NOT YMove?
DoZL
ELSE
DoL
END
DoAbsOrInc CkCRC CheckMove DoR0
RETURN

ToolPath:
EACHFeat
IF PointFeat?
IF NOT FirstFeat?
Rapid {no output}
IF AutoCycle?
SeqLab DoL MoveSX MoveSY XYSpace DoR0 RF ' M99' EOL
ELSE
SeqLab DoL DoDrillAbsOrInc
IF AbsValue?
MoveSX MoveSY
IF SPZMove?
MoveSZ XYZSpace
ELSE
XYSpace
END
ELSE
' IX' SPX# ' IY' SPY# ' IZ' SPZ# IXYZSpace
END
DoR0 RF ' M99' EOL
END
END
IF AutoCycle?
SeqLab ' CALL LBL ' Program# ' REP' EOL
CalcACSRXY {calc tool position after sub call, CalcAutoCycleStatusRecordXY}
END
ELSE
IF RapidFeat?
Rapid {no output}
IF XMove? OR YMove? OR ZMove?
SeqLab FormatLine RF DoM EOL
END
ELSE
IF LineFeat?
Feed {no output}
IF XMove? OR YMove? OR ZMove?
IF Decelerate?
IF RoomToDecel?
DecelMove1
SeqLab FormatLine FeedRate ' ' DoM EOL
DecelMove2
END
SeqLab FormatLine DecelFeed ' ' DoM EOL
ELSE
SeqLab FormatLine FeedRate ' ' DoM EOL
END
END
ELSE
IF ArcFeat?
EACHQuadrant
IF LastQuadrant? AND Decelerate?
IF RoomToDecel?
DecelMove1
FormatArc ArcFeed ' ' DoM EOL
DecelMove2
END
FormatArc DecelFeed ' ' DoM EOL
ELSE
FormatArc ArcFeed ' ' DoM EOL
END
NEXTQuadrant
END
END
END
END
NEXTFeat
RestoreAbsOrInc
RETURN

WFOStuff:
{ NOTE: This Post Processor does not support WorkFixtureOffsets. }
RETURN

AutoCycCutSub1: {part 1}
SaveSubStatus {save tool position}
SetPass1 {element cut moves}
StartSub
SetSRXYtoSP
SetInc
RETURN

AutoCycCutSub2: {part 2}
ToolPath
SetAbs
IF Repeats? AND FeedConnect? AND ZshiftOnly?
{.69 removed RapidC} {.71.2 removed CRCOffC, gets turned off in ToolPath}
ELSE
SeqLab DoZL ZCP2 ZSpace DoR0
IF FIFO? {.81}
FeedEnt ' '
ELSE
RF
END
DoM EOL
END
SeqLab ' LBL 0' 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

G92Sub:
SubWarning
StdSub
SetAbs
SeqLab DoL StrtPos XYSpace DoR0
IF FeedConnect?
FeedEnt ' '
ELSE
RF
END
DoM EOL
Milling
FinishSub1
FinishSubG92
RETURN

ZonlyRepAutoCycle:
AutoCycPat {write pattern moves and main calls}
StartSub
NewProg
EachCycle
SetSRXYtoEP
IF FeedConnect?
IF NOT FirstCycle?
IF SPXMove? OR SPYMove?
SetInc
SeqLab DoL ' IX' SPX# ' IY' SPY# IXYSpace DoR0 FeedRate ' ' DoM EOL
AbsOrInc
END
END
SeqLab DoZL ZInPlusInc ZSpace DoR0 FeedEnt ' ' DoM EOL
ELSE
IF NOT FirstCycle?
IF SPXMove? OR SPYMove?
SetInc
SeqLab DoL ' IX' SPX# ' IY' SPY# DoR0 RF DoM EOL
AbsOrInc
IF FeedEntry?
SeqLab DoZL ZCP2PlusInc ZSpace DoR0 RF DoM EOL
SeqLab DoZL ZInPlusInc ZSpace DoR0 FeedEnt ' ' DoM EOL
ELSE
SeqLab DoZL ZInPlusInc ZSpace DoR0 RF DoM EOL
END
ELSE
IF FeedEntry?
SeqLab DoZL ZCP2PlusInc ZSpace DoR0 RF DoM EOL
SeqLab DoZL ZInPlusInc ZSpace DoR0 FeedEnt ' ' DoM EOL
ELSE
SeqLab DoZL ZInPlusInc ZSpace DoR0 RF DoM EOL
END
END
ELSE
IF FeedEntry?
SeqLab DoZL ZInPlusInc ZSpace DoR0 FeedEnt ' ' DoM EOL
ELSE
SeqLab DoZL ZInPlusInc ZSpace DoR0 RF DoM EOL
END
END
END
IF FirstCycle?
SetStatusOff {protect Z position for incremental sub}
END
SeqLab ' CALL LBL ' Program# ' REP' EOL
NextCycle
SetStatusOn
AutoCycCutSub1 {build element sub}
AutoCycCutSub2
{.69, removed FinishSub1}
IF FeedConnect? {there is no Z up in the sub, .69}
Rapid {no output}
SeqLab DoZL ZCP2 ZSpace DoR0
IF FIFO? {.81}
FeedEnt ' '
ELSE
RF
END
DoM EOL {.69}
END {.69}
SeqLab ' LBL 0' EOL
CloseSub
{Element shift, not pattern}
RETURN

ZonlyRep:
EachCycle
IF NOT FirstCycle?
SeqLab DoL StrtPos XYSpace DoR0
IF FeedConnect?
FeedEnt ' '
ELSE
RF
END
DoM EOL
END
IF FeedConnect?
Feed {no output}
SeqLab DoZL ZInPlusInc ZSpace DoR0 FeedEnt ' ' DoM EOL
ELSE
IF FeedEntry?
IF NOT FirstCycle?
Rapid {no output}
SeqLab DoZL ZCP2PlusIncC ZSpace DoR0 RF DoM EOL
END
Feed {no output}
SeqLab DoZL ZInPlusInc ZSpace DoR0 FeedEnt ' ' DoM EOL
ELSE
Rapid {no output}
SeqLab DoZL ZInPlusInc ZSpace DoR0 RF DoM EOL
END
END
SeqLab ' CALL LBL ' Program# ' REP' EOL
NextCycle
StartSub
TrackZNO# FIRST SPZ#
ToolPath
FinishSub1
SeqLab ' LBL 0' EOL
CloseSub
RETURN

CheckPass:
IF AutoCycle? {use the correct StrtPos}
SetPass2
ELSE
SetPass1
END
RETURN

SkipToLastFeat:
EachFeat
IF LastFeat?
TrackXNO# SPX#
TrackYNO# SPY#
END
NextFeat
RETURN

SetDrillEndOpZ:
IF RetractToCP1?
TrackZNO# ClearancePlane1#
ELSE
TrackZNO# ClearancePlane2#
END
RETURN

GetStartOfSameTool:
DoOpComments
DoPostScript
CheckPass
RETURN

SetZero:
Save# Num#('50') ADD# Recall# Num#('50') Num#('1')
Save# Recall# Num#('50') Num#('0')
RETURN

Call_SetZero:
Save# Num#('50') Num#('0') { Setup the Op Number to be examined, (Initialized to zero) }
SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero
SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero
SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero
SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero
SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero SetZero {Call 49 times}
Save# Num#('50') Num#('0')
RETURN

ToolData:
Save# Num#('50') ADD# Recall# Num#('50') Num#('1') { Increment tool number to be examined by 1 }
IF NOTEqual? Num#('0') Recall# Operation#
SetFlag('9')
EachOp
IF Equal? Tool# Recall# Num#('50')
IF Flag?('9')
SetScale('1')
SeqLab ' TOOL DEF ' Tool#
RestoreScale
' L' ToolLength# ' ' XYSpace
'R' DIV# ToolDiameter# Num#('2') { ToolRadius# }
EOL
SetFlagF('9')
END
END
NextOp
END
RETURN

OutputToolData:
Save# Num#('50') Num#('0') { Setup the Tool Number to be examined, (Initialized to zero) }
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData
ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData ToolData {Call 130 times}
Save# Num#('50') Num#('0')
RETURN

SetupToolList:
EachOp
IF LTEqual? Operation# Num#('49')
Save# Operation# Tool#
END
NextOp
RETURN

{Start of executable Prog **************************************************}

{setup and initializations}
InitProg
ReverseXZArcs
UseSeparateSubCalls
SetMaxSeparateSubCalls('50')
SetMaxRPM('10000')
IF Metric?
SetMaxFeed('12700')
ELSE
SetMaxFeed('500')
END
SetFlagF('1') { Milling ZShiftOnly SepSubs }
SetFlagF('2') { CRCOff }
SetFlagF('3') { ArcFeat }
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? AND WorkFixtureOffsets?
'( *** WARNING *** )' EOL
'( THIS POST PROCESSOR DOES NOT SUPPORT WORKFIXTURE OFFSETS. )' EOL
'( PLEASE SELECT EQUALLY SPACED OFFSETS. )' EOL
'( *** WARNING *** )' EOL
END

' ' 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 MILLIMETERS )' EOL
END
IF PartsComment?
'( PARTS PROGRAMMED: ' Parts# ' )' EOL
END
IF StartToolComment?
'( FIRST TOOL NOT IN SPINDLE )' EOL
END
END
OpenSub
SetAbs
Plane Rapid {no output}

Call_SetZero
SetupToolList
OutputToolData
Call_SetZero

EachOp {Start of post processing *********************}
IF FirstOperation?
RestoreScale
IF MultipleParts? AND AllToolsOnePart?
OpenMP
END
SeqLab ' LBL 1' EOL
SeqLab ' TOOL CALL 0 Z S 0.000' EOL
SeqLab DoZL ZCP1 ZSpace DoR0 RF DoM EOL
SeqLab DoL Home XYSpace DoR0 RF DoM EOL
SeqLab ' LBL 0' EOL
DoOpComments
DoPostScript
SeqLab ' STOP' Space XYZSpace IZSpace ToolChng EOL
SeqLab ' TOOL CALL ' Tool# ' Z S 1000.000' EOL
IF MultipleParts? AND OneToolAllParts?
OpenMP
END
CheckPass
SeqLab DoL StrtPos XYSpace DoR0 RF SpinOn EOL
ELSE
IF NewTool?

{Finish off last Operation}

IF MultipleParts? AND OneToolAllParts?
CloseMP
END
DoEndOpPS

{Start new Operation}

SetAbs
Plane Rapid {no output}
SeqLab ' CALL LBL 1 REP' EOL
DoOpComments
DoPostScript
SeqLab ' STOP' Space XYZSpace IZSpace ToolChng EOL
SeqLab ' TOOL CALL ' Tool# ' Z S 1000.000' EOL
IF MultipleParts? AND OneToolAllParts?
OpenMP
END
CheckPass
SeqLab DoL StrtPos XYSpace DoR0 RF SpinOn EOL
ELSE
IF SameTool?
DoEndOpPS

{Start new Operation}

GetStartOfSameTool
SetAbs
Plane Rapid {no output}
SeqLab DoL StrtPos XYSpace DoR0 RF DoM EOL
END
END
END {common point for all operations}
IF Milling?
SeqLab DoZL ZCP2 ZSpace DoR0 RF DoM 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?
SetFlag('1') { Milling ZShiftOnly SepSubs }
ZonlyRep
SetFlagF('1')
ELSE {no sep subs desired}
G92Sub
END
END {end Auto Cycle IF}
ELSE {not Z only}
G92Sub
END {end Z only IF}
ELSE {no repeat OPs}
Milling
END
LoadFeat Num#('0') Num#('0') ClearancePlane3#
IF ZMove?
SeqLab DoZL ZCP3 ZSpace
IF Flag?('2') { CRCOn }
SetFlagF('2')
DoR0
SetFlag('2')
ELSE
DoR0
END
IF AutoCycle?
RF
ELSE
IF FIFO? {.81}
Feed {no output}
FeedEnt ' '
ELSE
RF
END
END
DoM EOL
END
ckCRCOff
ELSE
IF Drilling?
IF Repeats?
NewProg
StdSub
SeqLab DoL StrtPos XYSpace DoR0 RF DoM EOL
END
SeqLab DoZL
IF RetractToCP1?
ZCP1
ELSE
ZCP2
END
ZSpace DoR0 RF DoM EOL
GetCycle
IF Tap?
SeqLab ' CYCL DEF 2.0 TAPPING' EOL
SeqLab ' CYCL DEF 2.1 SETUP ' ABS# ClearancePlane2# EOL
SeqLab ' CYCL DEF 2.2 DEPTH ' ABS# ZDepth# EOL
SeqLab ' CYCL DEF 2.3 DWELL 0' EOL
SeqLab ' CYCL DEF 2.4 F' FeedEntry# EOL
ELSE
SeqLab ' CYCL DEF 1.0 PECKING' EOL
SeqLab ' CYCL DEF 1.1 SETUP ' ABS# ClearancePlane2# EOL
SeqLab ' CYCL DEF 1.2 DEPTH ' ABS# ZDepth# EOL
SeqLab ' CYCL DEF 1.3 PECKG '
IF Peck?
Peck#
ELSE
SetInc ABS# ZDepth# SetAbs
END
EOL
SeqLab ' CYCL DEF 1.4 DWELL '
IF Dwell?
Dwell#
ELSE
'0'
END
EOL
SeqLab ' CYCL DEF 1.5 F' FeedEntry# EOL
END
IF CallMasterOp?
SeqLab ' CALL LBL ' CallMasterNum# ' REP' EOL
SkipToLastFeat
ELSE
TrackZNO# FIRST SPZ#
IF MasterOp?
SetFlag('1') {std sep sub Zreps in effect}
NewMasterProg
SeqLab ' CALL LBL ' Program# ' REP' EOL
StartSub
SeqLab DoL StrtPos XYSpace DoR0 RF ' M99' EOL
ToolPath
SeqLab ' LBL 0' EOL
CloseSub
SetFlagF('1') {not std sep sub Zreps in effect}
ELSE
SeqLab DoL StrtPos XYSpace DoR0 RF ' M99' EOL
ToolPath
END
END
{SetDrillEndOpZ}
Rapid {no output}
SeqLab DoZL ZCP3 ZSpace DoR0 RF DoM EOL
IF Repeats?
FinishSubG92
END
END
END
NextOp {loops back to EachOP until last Operation}

{End of program ************************************************************}

{finish last operation}
IF MultipleParts? AND OneToolAllParts?
CloseMP
END
DoEndOpPS
Rapid {no output}
SeqLab ' TOOL CALL 0 Z S0.000'EOL
SeqLab DoZL ZCP1 ZSpace DoR0 RF DoM EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
CloseMP
END
SeqLab DoL FirstHome XYSpace DoR0 RF SpinOff EOL
IF MultipleParts? AND AllToolsOnePart?
CloseMP
END
SeqLab ' STOP M02'EOL
Post
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


Wyszukiwarka

Podobne podstrony:
Heid 145C BP M215 89m
Heid 415 BR [ST] MX50 89 1m
Heid TNC 155 [PB] M550 89 1m
Heid TNC 155 [KP] MV27 89 1m
Fadal Format 2 [HM] MV16 89 1m
BP Boss 1 6 M041 89 1
BP Boss 9 M174 89 2
Fadal Format 1 [PE] NMU96 89
BP Boss 6 M284 89 1
Yasnac MX1 3 MS M315 89 1m
Heid TNC 351B MD M989 89 5
BP Boss 8 M233 89 2
Heid TNC 151B [FE] MX96 89
Okuma 700M [SMH] MW08 89 1m
Heid TNC 2500 [ESS] M979 89 1
Fagor 8025 [PI] MY79 89 1m
Mazatrol M2 Mzk [ST] M630 89 1m
Fanuc 15M [YTC] MY61 89 1m

więcej podobnych podstron