Fanuc 15M Kit [OT] NMQ39 16 2


{
MILL=T
LATHE=F
SIMPLE_ROT_POS=F
ROTARY_MILL=F
ADV_MILL=F
SUBS=F
MILLTURN_Y-AXIS=F
METRIC=F
}

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

{8/30/95, M008.81.2, Updated for Catalyst v2.20 per Fanuc 6M M001.85 Format, DWB}

{1/17/96, Updated .85 to .86 version, MPK}

{3/22/96, Tested zonlyRepAutoCycle, Changed version # to .89, MPK}

{4/21/97
Initial: Fanuc 10M M008.89
Created: Fanuc 15M Kitamura [PP] MX07.89
For: Price Products
Changed OptoolID and Toolchange onto same line.
'M98P9000' before the first tool change
'M98P9002' before M30
Deleted saftey start block from 1st op and newtool sections,
added Plane to start Pos block in first Op and Newtool
Moved OffsetOn and SpinOn blocks to Start Pos block in 1st Op and NewTool
Deleted CoolOff, SpinOff ( in NOT ToolChangeatHome? ) and OffsetOff Block from NewTool and Prog End Sections,
Added OffsetOff to MP_OTAP_FU? to send tool full up
Changed all ':' to ' -' in Comments
Changed M6 to M101 for ToolChanges
Moved CoolOn before StartPos in FirstOp and NewTool
Added IF RigitTap? 'S2500M5' in FirstOp and NewTool
Deleted wFOStuff from GetStartofSameTool
Deleted CoolOff in Endops
Added FORMAT(FeedTapIPR#,4)
Added IF NOT RigidTap? for Speed Spindle in 1st Op, NewTool,SameTool
Added 'G5.1Q1' and 'G5.1P1Q0' for high speed machining in toolPath:
Added CalcPreToolPosition: to allow PreTooling in the middle of a toolPath when milling
Charles Winston}

{6Aug97
Original: Fanuc 15M Kitamura [PP] MX07.89
Created: Fanuc 15M Kitamura [PP] MX07.89.1
For: Price Products
Changes made per: Mike Olander
Added PreToolCheck Sub, used to PreTool in toolPath
Added PreventPreTool Sub, used to prevent a PreTool in autoCycCutSub2
Added DoPreTool Sub, used to PreTool in Drilling, zonlyRep and toolPath AutoCycles
Added Booloeans to call DoPreTool in toolPath AutoCycle, zonlyRep, Drilling CallMasterOp and MasterOp
Added Booloeans to call PreToolCheck at RapidFeat, LineFeat and ArcFeat in toolPath
Deleted Pretool call at the end of toolPath
Deleted SpinOff at End of Prog
Deleted version comments {.72}, {.69}, {reset flags}, {revised.72}, {literals}, {commands} etc
Charles Winston}

{09Mar99
Original: Fanuc 15M Kmura [PP] MX07.89.1
Created: Fanuc 15M Kit [OT] NMQ39.16
For: Ort Tool
Changes made per: Jeff Burgard
Develop: Catalyst 5.05/ComPost2 1.7b15
Added Post Header Comment at the top of Prog.
NEW POST : FIRST DRAFT
Updated to.16 format per Fanuc 6M M001.16.2
Deleted all Pretooling.
Added Untool in end2
Changed M101 to M06 in MachSpec
Added Spaces before all codes.
Modified all drill cycles per customers requirements.
Modified FirstOp, NewTool, Sametool and End of Prog per Jeff Burgard.
Updated to Longhand per Fanuc 6M NMU99.16
Charles Winston}

{12Mar99
Original: Fanuc 15M Kit [OT] NMQ39.16
Created: Fanuc 15M Kit [OT] NMQ39.16.1
For: Ort Tool
Changes made per: Jeff Burgard
Added Custom Coolant Subs. doCoolOff, ckCoolOFF and doCoolOn.
Added Support for Coolant On and Off in Opguts.
Added a Boolean in wFOStuff to suppress wFO except in FirstOperation when MultipleParts is FALSE.
Rearranged the order of the Operation Comments. Customer requires the ToolComment output first.
Changes to Rigid Tap Cycle per customers requirements.
Deleted EOR and ProgID1 at initOp.
ReWrote FirstOp, NewTool and NewTool per Customers requirements.
Charles Winston}

{17Mar99
Original: Fanuc 15M Kit [OT] NMQ39.16.1
Created: Fanuc 15M Kit [OT] NMQ39.16.2
For: Ort Tool
Changes made per: Jeff Burgard
Switched G41 to G42 and G42 to G41 in MachSpec.
Charles Winston}

{Prog Numeric Format Definitions ****}

#1 = '#.00'
#2 = '#####.###;0.'
#3 = '*#####.###;0.'
#4 = '####.####;0.'
#5 = '#######0'
#6 = '####^##0'
#7 = '#'

FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(FeedEntIPR#,4)
FORMAT(ADD#,4)
FORMAT(ToolDiameter#,4)
FORMAT(TrackXNO#,4)
FORMAT(TrackYNO#,4)
FORMAT(TrackZNO#,4)
FORMAT(Recall#,5)
FORMAT(PartNum#,5)
FORMAT(Program#,5)
FORMAT(Operation#,5)
FORMAT(Tool#,5)
FORMAT(NewWFO#,5)
FORMAT(Parts#,5)
FORMAT(Dwell#,6)
FORMAT(RapidF#,7)

{Custom Subroutines ****}

doCoolOff:
IF NOT CoolOff?
IF NOT LastOp?
IF NEXT NOT SameTool?
CoolOff
END
ELSE
CoolOff
END
END
RETURN

ckCoolOFF:
IF MultipleParts?
IF AllToolsOnePart?
doCoolOff
ELSE {implied OneToolAllParts?}
IF FullUp?
doCoolOff
ELSE {implied ExitClearancePlane?}
IF LastPart?
doCoolOff
END
END
END
ELSE
doCoolOff
END
RETURN

doCoolOn:
IF Flag?('10')
IF SameTool?
IF NOT CoolOff? AND LAST CoolOff?
SeqC CoolOn EOL
END
ELSE
SeqC CoolOn EOL
END
SetFlagF('10')
END
RETURN

{Prog Subroutines ****}

restoreScale:
IF Metric? {CAM file is in Metric, tools and tool path}
SetScale('.03937007874') { change to English, this is an English post}
END
RETURN

wfo:
' G' NewWFO#
RETURN

wFOStuff:
IF NewWFO?
IF MultipleParts? AND WorkFixtureOffsets?
EOL
'*** WARNING *** DO NOT USE NEWWFO() WITH MULTIPLE PARTS AND WORK FIXTURE OFFSETS' EOL
ELSE
wFO
END
ELSE
IF Flag?('2') { Need to output wFOStuff twice for MP-ESO-OTAP-ECP, once for all others }
IF NOT SameTool?
IF MultipleParts?
IF WorkFixtureOffsets?
SetWFO
ELSE
wFO
END
ELSE
IF FirstOperation?
wFO
END
END
END
END
END
SetFlagF('2') { Do not output WFO second time wFOStuff is called for MP-WFO-OTAP-ECP }
RETURN

resetWFO:
IF WorkFixtureOffsets?
SeqC WFO1 EOL
END
RETURN

doPartCycleComment:
IF MultipleParts? AND UseComments? AND SubComment?
'( PART NUMBER - ' PartNum# ' )' EOL
END
RETURN

doCycleComment:
IF UseComments? AND SubComment?
'( CYCLE START )' EOL
END
RETURN

doOpComments:
IF UseComments?
SetScale('1')
IF NOT SameTool?
IF ToolTypeComment?
'( TOOL ' Tool# ' - ' ToolDiameter# ' ' ToolType$ ' )' EOL
END
IF ToolComment?
'( ' ToolComment$ ' )' EOL
END
END
IF OperationIDComment?
'( OPERATION ' Operation# ' - ' OperationType$ ' )' EOL
END
IF OperationComment?
'( ' OperationComment$ ' )' EOL
END
IF WorkGroupComment?
'( ' WorkGroupComment$ ' )' EOL
END
restoreScale
END
RETURN

pSInit:
NewWFOF
RotateF
OptCyc1F
MasterOpF
CallMasterOpF
RETURN

pSStuff:
IF FourthCW?
FORMAT(FourthDegree#,2)
SeqC ' A' FourthDegree# EOL
FourthCWF
END
IF FourthCCW?
FORMAT(FourthDegree#,3)
SeqC ' A' FourthDegree# EOL
FourthCCWF
END
IF FifthCW?
FORMAT(FifthDegree#,2)
SeqC ' B' FifthDegree# EOL
FifthCWF
END
IF FifthCCW?
FORMAT(FifthDegree#,3)
SeqC ' B' FifthDegree# EOL
FifthCCWF
END
RETURN

doPostScript:
pSInit
EachPS
SeqC PostScript EOL
pSStuff
NextPS
RETURN

doEndOpPS:
pSInit
EachEOPS
SeqC EndOpPS EOL
pSStuff
NextPS
RETURN

loadPRIMEZCP2:
LoadFeat Num#('0') Num#('0') PRIME ClearancePlane2#
RETURN

pRIMEZCP2:
PRIME ZCP2
RETURN

loadPRIMEZCP3:
LoadFeat Num#('0') Num#('0') PRIME ClearancePlane3#
RETURN

pRIMEZCP3:
PRIME ZCP3
RETURN

connectC:
IF FeedConnect?
FeedC
ELSE
RapidC
END
RETURN

absValueC:
IF NOT AbsValue?
AbsValue
END
RETURN

incValueC:
IF AbsValue?
IncValue
END
RETURN

absOrIncC:
IF AbsoluteMoves?
absValueC
ELSE
incValueC
END
RETURN

entryMove:
IF Repeats? AND ZShiftOnly? AND FeedConnect?
SeqC FeedC ZInC
IF NOT EmptyLine?
FeedEnt
END
EOL
ELSE
IF FeedEntry?
SeqC FeedC ZInC
IF NOT EmptyLine?
FeedEnt
END
EOL
ELSE
SeqC RapidC ZInC EOL
END
END
RETURN

autoCycExitMove:
SeqC absOrIncC CRCOffC
IF FIFO?
FeedC pRIMEZCP2 FeedEntC
ELSE
RapidC pRIMEZCP2
END
EOL
RETURN

exitMove:
IF AutoCycle?
SeqC ckCoolOFF EOL
SeqC CRCOffC ZCP3C EOL
ELSE
IF NOT Flag?('9')
SeqC ckCoolOFF EOL
ELSE
SetFlagF('9')
END
IF FIFO?
SeqC CRCOffC FeedC ZCP3C FeedEntC EOL
ELSE
SeqC CRCOffC RapidC ZCP3C EOL
END
END
RETURN

finishSub1:
SeqC CRCOffC
IF NOT FeedConnect?
loadPRIMEZCP3
IF ZMove?
IF AutoCycle?
pRIMEZCP3
SetFlagF('9')
ELSE
IF Flag?('9')
SeqC ckCoolOFF EOL
END
IF FIFO?
FeedC pRIMEZCP3 FeedEntC
ELSE
RapidC pRIMEZCP3
END
END
ELSE
SetFlagF('9')
END
ELSE
SetFlagF('9')
END
EOL
RETURN

formatArc:
IF ArcCW?
CWArcC
ELSE
CCWArcC
END
MoveXYZC
IF ArcIJFormat?
ArcIJC
ELSE
ArcRC
END
RETURN

ckCRC:
IF LastFeat?
CRCOffC
ELSE
IF NOT ZMove?
CRCOnC
END
END
RETURN

ckCRCNum:
IF NOT LastFeat? AND Equal? SPZ# EPZ#
CRCOffsetC
END
RETURN

doPeck: { longDrillStuff }
{ not supported }
RETURN

drillFeature: { longDrillStuff }
{ not supported }
RETURN

toolPath:
EACHFeat
IF PointFeat? { Drilling Only }
SeqC MoveSXYZC EOL
ELSE
IF RapidFeat?
IF XMove? OR YMove? OR ZMove?
SeqC ckCRC RapidC MoveXYZC ckCRCNum EOL
END
ELSE
IF LineFeat?
IF XMove? OR YMove? OR ZMove?
SeqC ckCRC FeedC MoveXYZC FeedRateC ckCRCNum EOL
END
ELSE
IF ArcFeat?
EACHQuadrant { Do not use NOT, FIRST, LAST or NEXT modifiers in this loop }
SeqC formatArc ArcFeedC EOL
NEXTQuadrant
END
END
END
END
NEXTFeat
RETURN

autoCycCutSub1: {part 1}
CalcACSRXY {calc tool position, CalcAutoCycleStatusRecordXY}
SaveSubStatus {save tool position}
SetPass1 {element cut moves}
SetSRXYtoSP
IF Repeats? AND ZShiftOnly?
entryMove
END
SeqC incValueC EOL
RETURN

autoCycCutSub2: {part 2}
SeqC absOrIncC CRCOffC
IF FIFO?
FeedC ZCP2C FeedEntC
ELSE
RapidC ZCP2C
END
EOL
SetSRSubXY {restore SR to 1st position value}
ReSetPass2 {restore for positioning moves}
RETURN

cutAutoCycle:
SetFlag('10')
IF Repeats? AND NOT ZShiftOnly?
EachRep
IF NOT FirstCycle?
IF FIFO?
Rapid
END
SeqC RapidC StrtPos EOL
IF NOT FeedConnect?
SeqC ZCP2C EOL
END
END
END
EACHFeat
doCycleComment
IF SPXMove? OR SPYMove?
IF FIFO?
Rapid
END
SeqC RapidC MoveSXYC EOL
END
autoCycCutSub1
IF Repeats? AND ZShiftOnly?
EachRep
doCoolOn
IF NOT FirstCycle?
doCycleComment
IF SPXMove? OR SPYMove?
SeqC connectC incValueC MoveSXYC EOL
END
absOrIncC
IF FeedConnect?
entryMove
ELSE
IF FeedEntry?
SeqC RapidC ZCP2C EOL
END
entryMove
END
SeqC incValueC EOL
END
toolPath
IF NOT FeedConnect?
autoCycExitMove
END
NextRep
ELSE
entryMove
doCoolOn
toolPath
END
autoCycCutSub2
NEXTFeat
IF Repeats? AND NOT ZShiftOnly?
finishSub1
NextRep
END
SetPass1
RETURN

milling:
IF Repeats?
Save# Num#('9') Num#('0')
EachRep
Save# Num#('9') Add# Recall# Num#('9') Num#('1') { Count up to the last Repeat }
doCycleComment
IF SPXMove? OR SPYMove?
SeqC connectC MoveSXYC EOL
END
IF FeedConnect?
entryMove
ELSE
IF FeedEntry?
SeqC RapidC ZCP2C EOL
END
entryMove
END
IF Equal? Recall# Num#('9') Num#('1')
IF SameTool?
IF NOT CoolOff? AND LAST CoolOff?
SeqC CoolOn EOL
END
ELSE
SeqC CoolOn EOL
END
END
toolPath
IF Equal? Repeats# Recall# Num#('9')
SetFlag('9')
END
finishSub1
NextRep
ELSE
entryMove
IF SameTool?
IF NOT CoolOff? AND LAST CoolOff?
SeqC CoolOn EOL
END
ELSE
SeqC CoolOn EOL
END
toolPath
END
RETURN

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

drilling:
SeqC DrillCP EOL
GetCycle
SeqC
IF RigidTap?
' G95 G84.3'
ELSE
SeqC ' G94' Cycle
END
FromCP ZDepth RLevel Dwell Peck Retract
IF RigidTap?
Speed ' F' FeedEntIPR#
ELSE
FeedEnt
END
EOL
TrackZNO# FIRST SPZ# {.81.2}
toolPath
setDrillEndOpZ
SeqC Rapid ' G80' ZCP3 ckCoolOff EOL
RETURN

longDrilling:
SeqC DrillCP EOL
GetCycle
SeqC StrtPosC EOL
toolPath
LoadFeat Num#('0') Num#('0') ClearancePlane3#
IF ZMove?
SeqC RapidC ZCP3C EOL
END
RETURN

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

opGuts:
ResetCRCNum
IF FirstOperation? OR NewTool?
RapidF# { Forces FeedEntC/FeedRateC }
END
IF Milling?
SeqC ZCP2C EOL
IF AutoCycle?
cutAutoCycle
ELSE
milling
END
exitMove
ELSE
IF SameTool?
IF NOT CoolOff? AND LAST CoolOff?
SeqC CoolOn EOL
END
ELSE
SeqC CoolOn EOL
END
IF Drilling?
drilling
END
END
RETURN

progStart:
InitProg
ReverseXZArcs
InitWFONum
SetFlood
SetMaxRPM('10000')
IF Metric?
SetMaxFeed('12700')
ELSE
SetMaxFeed('500')
END
Save# Num#('1') Num#('0') { MultipleParts Current Tool FirstOp# }
Save# Num#('2') Num#('0') { MultipleParts ToolOp# Counter }
Save# Num#('3') Num#('0') { LongHand PeckCycle }
SetFlagF('2') { Need to output wFOStuff twice for MP-ESO-OTAP-ECP, once for all others }
IF PSComment? AND UseComments?
'Utility Data:' EOL
' At Op Start: All literals and commands will appear at the beginning of the operation.' EOL
' At Op End: All literals and commands will appear at the end of the operation.' 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
' NewWFO(56), NWFO(56) -' EOL
' The Work Fixture Offset # you specify will be used for all following operations.' EOL
' Do not use with the ncPost multiple part option.' 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
RETURN

initOp:
IF UseComments? AND ProgramNameComment?
'( ' ProgramName$ ' )'
END
EOL
EachOp
IF FirstOperation?
IF ToolChangeAtHome?
SetHome
END
END
NextOp
IF UseComments?
IF ProgramComment?
'( ' ProgramComment$ ' )' EOL
END
IF FormatNameComment?
'( FORMAT - ' FormatName$ ' )' EOL
END
IF TimeComment?
'( ' Date$ ' AT ' Time$ ' )' EOL
END
IF MovesComment?
'( OUTPUT IN ' MoveType$ ' INCHES )' EOL
END
IF PartsComment?
'( PARTS PROGRAMMED - ' Parts# ' )' EOL
END
IF StartToolComment?
'( FIRST TOOL NOT IN SPINDLE )' EOL
END
END
restoreScale
RETURN

firstOp1:
SeqC AbsOrInc Rapid Plane ' G17' wFOStuff ' G80' CRCOff EOL
IF ToolChangeAtHome?
SetHome
END
doPartCycleComment
doOpComments
doPostScript
RETURN

firstOp2:
checkPass
SeqC RapidC StrtPos
IF NOT RigidTap?
Speed SpinOn
END
EOL
RETURN

firstOp3:
SeqC OfstOn EOL
RETURN

newToolOp1:
SeqC SpinOff EOL
Seq Rapid ' G28' IncValue CRCOff ' Z0' OpToolID EOL
doPartCycleComment
doOpComments
SeqC ' G28 Y0' EOL
RETURN

newToolOp2:
doEndOpPS
IF ToolChangeAtHome?
SeqC AbsOrIncC Rapid PRIME Home EOL
END
IF LAST ProgStop?
SeqC ' M0' EOL
ELSE
SeqC ProgStop EOL
END
RETURN

newToolOp3: {Start new Operation}
SeqC ToolChng EOL
doPostScript
RETURN

newToolOp4:
checkPass
SeqC AbsOrInc Rapid Plane wFOStuff StrtPos
IF NOT RigidTap?
Speed SpinOn
END
EOL
RETURN

newToolOp5:
SeqC OfstOn EOL
RETURN

sameToolOp1:
doEndOpPS
IF LAST ProgStop?
SeqC CoolOff EOL
SeqC incValueC OfstOff EOL
SeqC SpinOff EOL
SeqC ' M0' EOL
ELSE
IF CoolOff? AND LAST NOT CoolOff?
SeqC CoolOff EOL
END
IF NewToolOffset?
SeqC incValueC OfstOff EOL
END
END
RETURN

sameToolOp2: {Start new Operation}
doPartCycleComment
doOpComments
doPostScript
checkPass
RETURN

sameToolOp3: {Start new Operation}
IF LAST ProgStop?
SeqC AbsOrInc Rapid Plane wFOStuff StrtPos
IF NOT RigidTap?
Speed SpinOn
END
EOL
SeqC OfstOn EOL
ELSE
SeqC AbsOrInc Rapid PlaneC wFOStuff StrtPos
IF NOT RigidTap?
SpeedC
END
EOL
IF NewToolOffset?
SeqC OfstOn EOL
END
END
RETURN

end1:
SeqC CoolOff EOL
SeqC SpinOff EOL
RETURN

end2:
doEndOpPS
IF ToolChangeAtHome?
SeqC AbsOrInc Rapid FirstHome EOL
END
Seq Rapid ' G28' IncValue CRCOff ' Z0'
IF NOT FirstTool?
UnTool
END
EOL
SeqC ' G28 Y0' EOL
IF ProgStop?
SeqC ' M0' EOL
ELSE
SeqC ProgStop EOL
END
SeqC ToolChng EOL
RETURN

end3:
SeqC EOP EOL
EOR EOL
Close
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
RETURN

mPallTools1P: {Multiple Parts, All Tools 1 Part}
IF FirstOperation? OR EquallySpacedOffsets?
SetFlag('2') { Need to output wFOStuff twice for MP-ESO-OTAP-ECP, once for all others }
END
IF FirstOperation?
firstOp1
firstOp2
firstOp3
ELSE
IF NewTool?
newToolOp1
newToolOp2
newToolOp3
newToolOp4
newToolOp5
ELSE {implied SameTool?}
sameToolOp1
sameToolOp2
sameToolOp3
END
END
opGuts
RETURN

mP1ToollAllPfu: {Multiple Parts, 1 Tool all Parts, full up}
SetFlag('2') { Need to output wFOStuff twice for MP-ESO-OTAP-ECP, once for all others }
IF FirstOperation?
firstOp1
firstOp2
firstOp3
ELSE
IF NewTool?
newToolOp1
resetWFO
newToolOp2
newToolOp3
newToolOp4
newToolOp5
ELSE {implied SameTool?}
sameToolOp1
sameToolOp2
sameToolOp3
END
END
opGuts
RETURN

mP1ToollAllPXcp: {Multiple Parts, 1 Tool all Parts, exit Clearance plane}
SetFlag('2') { Need to output wFOStuff twice for MP-ESO-OTAP-ECP, once for all others }
IF FirstOperation?
firstOp1
firstOp2
firstOp3
ELSE
IF NewTool?
newToolOp1
resetWFO
newToolOp2
newToolOp3
newToolOp4
newToolOp5
ELSE {implied SameTool?}
sameToolOp1
sameToolOp2
sameToolOp3
END
END
opGuts
RETURN

noMPs: {no multiple parts}
SetFlag('2') { Need to output wFOStuff twice for MP-ESO-OTAP-ECP, once for all others }
IF FirstOperation?
firstOp1
firstOp2
firstOp3
ELSE
IF NewTool?
newToolOp1
newToolOp2
newToolOp3
newToolOp4
newToolOp5
ELSE {implied SameTool?}
sameToolOp1
sameToolOp2
sameToolOp3
END
END
opGuts
RETURN

masterSub:
IF MultipleParts?
IF AllToolsOnePart?
mPallTools1P
ELSE {implied OneToolAllParts?}
IF FullUp?
mP1ToollAllPfu
ELSE {implied ExitClearancePlane?}
mP1ToollAllPXcp
END
END
ELSE
noMPs
END
RETURN

endPartSub:
{End of program ************************************************************}

{finish last operation}
end1
IF MultipleParts? AND OneToolAllParts?
resetWFO
END
end2
RETURN

newPart1: {Finish off last Part}
IF FullUp?
SeqC CoolOff EOL
SeqC SpinOff EOL
Seq Rapid ' G28' IncValue CRCOff ' Z0' OpToolID EOL
SeqC ' G28 Y0' EOL
END
{doEndOpPS}
RETURN

newPart2: {Start new Part}
sameToolOp2
RETURN

newPart3: {Start new Part}
SetFlag('2') { Need to output wFOStuff twice for MP-ESO-OTAP-ECP, once for all others }
SeqC AbsOrInc Rapid Plane wFOStuff StrtPos
IF NOT RigidTap?
Speed SpinOn
END
EOL
IF FullUp?
SeqC OfstOn EOL
END
RETURN

mPLoop:
Save# Num#('2') Recall# Num#('1')
IF WorkFixtureOffsets?
NewWFO
EachWFO
ELSE
EachPart
END
IF AllToolsOnePart?
EachOp
masterSub
NextOp
endPartSub
ELSE { OneToolAllParts }
EachOp
IF Equal? Operation# Recall# Num#('2') { Valid Tool Op }
IF FirstOperation? OR NewTool?
IF FirstPart?
masterSub
ELSE
newPart1
newPart2
newPart3
opGuts
END
ELSE
masterSub
END
IF LastOp?
IF LastPart?
Save# Num#('1') Num#('0')
END
Save# Num#('2') Recall# Num#('1')
ELSE
IF NEXT SameTool?
Save# Num#('2') NEXT Operation#
ELSE
IF LastPart?
Save# Num#('1') NEXT Operation#
Save# Num#('2') Num#('0')
ELSE
Save# Num#('2') Recall# Num#('1')
END
END
END
END
NextOp
END
IF WorkFixtureOffsets?
IncWFO
NextWFO
ELSE
NextPart
END
RETURN

{Start of executable Prog, Top Level ****}

progStart {setup and initializations}
initOp

IF MultipleParts?
IF WorkFixtureOffsets?
{'NOTE: This Post Processor does not support Work Fixture Offsets for Multiple Parts.' EOL
'It is recommended that you change your selection to Equally Spaced Offsets.' EOL}
END
IF AllToolsOnePart?
mPLoop
resetWFO
ELSE
EachOp
IF FirstOperation?
Save# Num#('1') Operation#
END
NextOp
mPLoop mPLoop mPLoop mPLoop mPLoop
mPLoop mPLoop mPLoop mPLoop mPLoop
mPLoop mPLoop mPLoop mPLoop mPLoop
mPLoop mPLoop mPLoop mPLoop mPLoop
mPLoop mPLoop mPLoop mPLoop mPLoop
endPartSub
END
ELSE
EachOp
masterSub
NextOp
endPartSub
END
end3


Wyszukiwarka

Podobne podstrony:
Fanuc 15M Krk [OT] NCQ16 16 2
Fanuc 15M MTS [OT] NCQ32 16 1
Fanuc 15M MTS [OT] NCQ32 16 1
Fanuc 15M MTS [CP] NDU66 16 2m
Fanuc 15M Mon [SM] MT98 16 1
Fanuc 15M Kmura [PP] CX07 16
Fanuc 10M Kit PM028 17 3
Fanuc 0M LH P&W [SP] CV84 16 3
Fanuc 15M Mitsui [EG] CW15 12
Fanuc 10M Kit [LM] M904 89
Fanuc 18M MS [CST] NCT81 16
Fanuc 10M Kit C028 12
Fanuc 16M Makino [EE] NMT56 16
Fanuc 15M Matsuura C695 12
Fanuc 10M Kit M028 89 1
Fanuc 15M [PIW] MW82 89 2
Fanuc 11M Tyd [CGB] CT37 16 4
Fanuc 15M Matsuura M695 87m

więcej podobnych podstron