Fanuc 16M Makino [EE] NMT56 16


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

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

{5/15/98,
Updated: LongHand M001.15
Created: Fanuc 6M NMU99.16
For: Gibbs & Associates
Versions: Catalyst v4.23.13(mac)/ComPost2 1.1b3
Update necessary to stay consistant with AdvancedMill Update.
Added AbsValueC, IncValueC and AbsOrIncC Procedures.
Simplifies readability of Prog.
Reduces redundancy of output.
Allows us to return to earlier versions
Improves upon earlier problem with incremental output of ShiftPC command at CloseMP while
allowing us to return to .85 OfstOff blocks.
AbsValueC called from AbsOrIncC.
IncValueC called from AbsOrIncC, DoAbsOrInc and DoDrillAbsOrInc.
IncValueC called for OfstOff Blocks at NewToolOp1, two places at SameToolOp1 and DoAbsOrInc.
AbsOrIncC called for ShiftPC Block at CloseMP.
AbsOrIncC called from DoAbsOrInc, DoDrillAbsOrInc and RestoreAbsOrInc.
AbsOrIncC called for Home Block at NewToolOp2.
AbsOrIncC called for FirstHome Block at End2.
Added CRCOffC at AutoCycCutSub2.
Corrects unique situation in ZonlyRepAutoCycle where one Operation is CRCLeft and LastFeat
is an ArcFeat followed by another Operation that is CRCRight.
CRCOffC did not get output at end of CRCLeft Operation and CRCOnC did not get output at start
of CRCRight Operation.
Oddly, CRCOnC only outputs if CRCOffC has been output, not if CRCSide changes.
6/18/98
Changed to Lowercase Procedure Names.
Added comments to all SetFlag, SetFlagF and IF Flag statements.
Changed literal 'G80' to DrillOff at end of IF Drilling.
Changed literal 'G80' to DrillOff at firstOp1 and newToolOp3.
To allow for change in FORM without having to recompile.
Changed SpeedC to Speed at for LAST ProgStop condition at sameToolOp3.
6/30/98
Deleted Gibbs System XYRepeat support.
Virtual only support ZShiftOnly Repeats.
Deleted CycleWarning procedure.
Added cutAutoCycle procedure.
Called for all AutoCycle Operations.
Supports NoRepeat and ZShiftOnly Repeats.
Replaces noRepAutoCycle and zonlyRepAutoCycle procedures
Deleted xYZRepAutoCycle procedure.
Changed XYZRep to ZOnlyRep.
Supports ZShiftOnly Repeats.
Moved LongDrillStuff from OpGuts to LongDrillStuff.
Rewrote OpGuts Procedure.
Deleted Drilling Repeats at IF Drilling.
Rewrote PostScript instructions at progStart.
7/22/98
Reverted back to Gibbs System XYRepeat support.
IF setup correctly, Virtual will support XShift and/or YShift Repeats for both Contour and
Patterns.
Rules for correct setup (as best as I understand at the moment).
Geometry CSGroup must be oriented to a plane that intersects CS#1 in a perpendicular direction.
Example, XZPlane and YZPlane, and any oriented rotation of either Plane around the XYPlane.
Any change in the ZPitch of the Origin will cause ZShiftOnly Repeat Operation.
Set Desired ZStep so that Operation will result in multiple passes.
NOTE: If correctly setup, ZStep would be misleading.
Step will be in line with depth axis of CSGroup.
Restored with slight modifications the xyRep Procedure.
Restored related code to OpGuts Procedure.
ZShiftOnly Contour Operations remain Full SepSub.
Any customer requesting G92 Style will require copying code from archives.
Deleted Deceleration from ToolPath LineFeat and ArcFeat.
There are plans to support this in the future through the use of Construction Tools in the
Virtual Process.
10/1/98
Versions: Virtual 4.29.75(Mac)/ComPost2 1.7b10 (Mac)
Versions: Virtual 4.29.75(Win)/ComPost2 1.7b10 (Win)
Added Post Header Comment at top.
Modified Prog for better usage.
Added loadPRIMEZCP2 Procedure.
Added pRIMEZCP2 Procedure.
Added loadPRIMEZCP3 Procedure.
Added pRIMEZCP3 Procedure.
Added connectC Procedure.
Moved absValueC, incValueC and absOrIncC Procedures to before entryMove Procedure.
Modified exitMove Procedure.
Added finishSub1 Procedure.
Deleted exitMove2 Procedure.
Modified handling of Pattern AutoCycles.
Added autoCycExitMove Procedure.
Modified autoCycCutSub1 Procedure.
Modified autoCycCutSub2 Procedure.
Modified cutAutoCycle Procedure.
Combines old NoRepAutoCycle, XYZRepAutoCycle and ZonlyRepAutoCycle Procedures.
Modified handling of Milling Operations.
Modified milling Procedure.
Combines old Milling and XYZRep Procedures.
Modified handling of Drilling Operations.
Modified drillStuff Procedure.
Renamed to drilling.
Moved code from opGuts Drilling.
Modified longDrillStuff Procedure.
Renamed to longDrilling.
Modified opGuts Procedure.
Added FirstOperation? OR NewTool? condition for RapidF# at opGuts Procedure.
Forces FeedEntC/FeedRateC while allowing for conditional during SameTool.
Now it just tests for AutoCycle, Milling OR Drilling.
Calls cutAutoCycle, milling OR drilling Procedures respectfully.
DWB}

{12/1/98,
Initial : Fanuc 6M NMU99.16
Created: Fanuc 16M Makino [EE] NMT56.16
Customer: Edro Engineering, Guy Recendez 909/594-5751
ComPost2: v1.7b13
MDD: 5d6c_hm3.mch

Changes to "Prog":

1. Changed firstOp1, 2, & 3 per customer spec.
2. Changed newToolOp1, 2, 3, 4, & 5 per customer spec.
3. Changed sameToolOp1 & 2 per customer spec.
4. Changed end1, 2, & 3 per customer spec.
5. Changed ckCRCNum sub to output D17 with all G41/42 blocks.
6. Added G76 and G86 drilling cycles. Also added M135 before rigid tapping.
7. Added FORMAT for Retract#, Pallet#, and SUB#.
8. Added thru spindle collant (M26).
9. Added saveMultiTCZ sub to save 3 TCZ variables.
10. Added doProbeCycle sub to be output at tape start.
11. Added SetPalletIn('1'), Save# Num#('21'), 22, ,23 & 24 at progStart sub.
12. Added Utility Data Comment in progStart sub for the use of probe cycle.
13. Removed EOR from tape start & end.
JHE}

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

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

FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(ADD#,4)
FORMAT(ToolDiameter#,4)
FORMAT(TrackXNO#,4)
FORMAT(TrackYNO#,4)
FORMAT(TrackZNO#,4)
FORMAT(Retract#,4) {Added - JHE}
FORMAT(SUB#,4) {Added - JHE}
FORMAT(Recall#,5)
FORMAT(PartNum#,5)
FORMAT(Program#,5)
FORMAT(Operation#,5)
FORMAT(Tool#,5)
FORMAT(NewWFO#,5)
FORMAT(Parts#,5)
FORMAT(Pallet#,5) {Added - JHE}
FORMAT(Dwell#,6)
FORMAT(RapidF#,7)

{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

wFOStuff:
IF NewWFO?
IF MultipleParts? AND WorkFixtureOffsets?
EOL
'*** WARNING *** DO NOT USE NEWWFO() WITH MULTIPLE PARTS AND WORK FIXTURE OFFSETS' EOL
ELSE
'G' NewWFO#
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
'G' NewWFO#
END
ELSE
'G' NewWFO#
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 NO. ' PartNum# ' )' EOL
END
RETURN

doCycleComment:
IF UseComments? AND SubComment?
'( CYCLE START )' 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

doProbeCycle: {Added this sub - JHE}
'#100=' Pallet# EOL
'#101=' SUB# XStockMax# XStockMin# EOL
'#102=' SUB# YStockMax# YStockMin# EOL
'#103=' SUB# ZStockMax# ZStockMin# EOL
FORMAT(Recall#,4)
'#106=' Recall# Num#('21') EOL
'#107=' Recall# Num#('22') EOL
'#108=' Recall# Num#('23') EOL
FORMAT(Recall#,5)
SeqC 'M98P8894' EOL {calling probe cycle - JHE}
SeqC 'M98P8895' EOL {calling probe cycle - JHE}
SeqC 'M11' EOL {unclamp rotary axis - JHE}
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

saveMultiTCZ: {Added this sub - JHE}
Save# Num#('24') ADD# Recall# Num#('24') Num#('1') {Probe Counter + 1 - JHE}
IF Equal? Recall# Num#('24') Num#('2')
Save# Num#('21') TCZ#
ELSE
IF Equal? Recall# Num#('24') Num#('3')
Save# Num#('22') TCZ#
ELSE
IF Equal? Recall# Num#('24') Num#('4')
Save# Num#('23') TCZ#
END
END
END
RETURN

doPostScript:
pSInit
EachPS
SeqC PostScript EOL
pSStuff
IF FirstOperation? {Added - JHE}
saveMultiTCZ
END
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?
FeedEntC
END
EOL
ELSE
IF FeedEntry?
SeqC FeedC ZInC
IF NOT EmptyLine?
FeedEntC
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 CRCOffC ZCP3C EOL
ELSE
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
ELSE
IF FIFO?
FeedC pRIMEZCP3 FeedEntC
ELSE
RapidC pRIMEZCP3
END
END
END
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#} {Removed - JHE}
IF CutterRadiusCompensation? {Changed to - JHE}
IF FirstFeat?
'D17'
END
END
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:
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
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
toolPath
END
autoCycCutSub2
NEXTFeat
IF Repeats? AND NOT ZShiftOnly?
finishSub1
NextRep
END
SetPass1
RETURN

milling:
IF Repeats?
EachRep
doCycleComment
IF SPXMove? OR SPYMove?
SeqC connectC MoveSXYC EOL
END
IF FeedConnect?
entryMove
ELSE
IF FeedEntry?
SeqC RapidC ZCP2C EOL
END
entryMove
END
toolPath
finishSub1
NextRep
ELSE
entryMove
toolPath
END
RETURN

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

drilling:
SeqC DrillCP EOL
GetCycle
IF RigidTap? {Added - JHE}
SeqC 'M135' EOL
END
IF FIStopOffWallRO? {Added - JHE}
SeqC 'G76'
ELSE
IF FIStopRO? {Added - JHE}
SeqC 'G86'
ELSE
SeqC Cycle
END
END
FromCP StrtPos ZDepth RLevel Dwell Peck
IF FIStopOffWallRO? {Added - JHE}
'Q' Retract# FeedEnt EOL
ELSE
FeedEnt EOL
END
TrackZNO# FIRST SPZ#
toolPath
setDrillEndOpZ
SeqC DrillOff Rapid ZCP3 EOL
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 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 }
SetPalletIn('1') {Added - JHE}
Save# Num#('21') Num#('0') {Probe Parameter #106 - JHE}
Save# Num#('22') Num#('0') {Probe Parameter #107 - JHE}
Save# Num#('23') Num#('0') {Probe Parameter #108 - JHE}
Save# Num#('24') Num#('0') {Probe TCZ# Counter - JHE}
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
' ' EOL
' Special Commands with First Operation:' EOL {Added - JHE}
' PIN(1) thru PIN(7) - Default is PIN(1)' EOL
' specify the probe cycle number to be output with #100.' EOL
' TCZ(n) - Default is TCZ(0)' EOL
' Up to 3 values can be entered to be output with #106, #107, & #108.' EOL
' A CR (RETURN key) must be entered between each command. i.e.:' EOL
' pin(2)' EOL
' tcz(2.25)' EOL
' tcz(8.5)' EOL
' tcz(1.375)' EOL
END
RETURN

initOp:
{EOR EOL} {Removed - JHE}
ProgID1
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:
IF Metric? {Added Inch/Metric Mode - JHE}
Seq 'G21' EOL
ELSE
Seq 'G20' EOL
END
doPostScript {Moved to here - JHE}
doProbeCycle {Added - JHE}
SeqC Plane CRCOff DrillOff AbsOrInc EOL
SeqC OpToolID EOL
SeqC ToolChng EOL
SeqC 'H1D17M56' EOL {Added, tool managment command - JHE}
doPartCycleComment
doOpComments
RETURN

firstOp2:
SeqC wFOStuff EOL
SeqC Speed SpinOn EOL
checkPass
SeqC Rapid AbsOrInc StrtPos PreTool EOL {Added PreTool - JHE}
IF ThruSpin?
SeqC 'M26' EOL {Added, thru spindle coolant - JHE}
END
RETURN

firstOp3:
SeqC 'G43' ZCP1 EOL {Changed from OfstOn - JHE}
SeqC CoolOn EOL
RETURN

newToolOp1:
SeqC RapidC ZCP1C CoolOff EOL {Added RapidC ZCP1C - JHE}
SeqC incValueC OfstOff EOL
RETURN

newToolOp2:
doEndOpPS
SeqC absOrIncC 'G49' SpinOff EOL {Added this line - JHE}
IF ToolChangeAtHome?
SeqC RapidC PRIME Home EOL {Removed absOrIncC SpinOff - JHE}
END
IF LAST ProgStop?
SeqC 'M0' EOL
ELSE
SeqC ProgStop EOL
END
RETURN

newToolOp3: {Start new Operation}
Seq Plane CRCOff DrillOff AbsOrInc EOL {Added AbsOrInc - JHE}
{SeqC OpToolID EOL} {Removed - JHE}
SeqC ToolChng EOL
SeqC 'H1D17M56' EOL {Added, tool managment command - JHE}
doPartCycleComment
doOpComments
doPostScript
RETURN

newToolOp4:
SeqC wFOStuff EOL
SeqC Speed SpinOn EOL
checkPass
SeqC Rapid AbsOrInc StrtPos PreTool EOL {Added PreTool - JHE}
IF ThruSpin?
SeqC 'M26' EOL {Added, thru spindle coolant - JHE}
END
RETURN

newToolOp5:
SeqC 'G43' ZCP1 EOL {Changed from OfstOn - JHE}
SeqC CoolOn EOL
RETURN

sameToolOp1:
doEndOpPS
IF LAST ProgStop?
SeqC RapidC ZCP1C CoolOff EOL {Added RapidC ZCP1C - JHE}
SeqC incValueC OfstOff EOL
SeqC absOrIncC 'G49' SpinOff EOL {Added absOrIncC 'G49' - JHE}
SeqC 'M0' EOL
ELSE
IF CoolOff? AND LAST NOT CoolOff?
SeqC CoolOff EOL
END
IF NewToolOffset?
SeqC incValueC OfstOff EOL
SeqC absOrIncC 'G49' EOL {Added this line - JHE}
END
END
RETURN

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

sameToolOp3: {Start new Operation}
SeqC wFOStuff EOL
IF LAST ProgStop?
SeqC Speed SpinOn EOL {Moved to here - JHE}
SeqC Rapid PlaneC AbsOrInc StrtPos EOL
IF ThruSpin?
SeqC 'M26' EOL {Added, thru spindle coolant - JHE}
END
SeqC 'G43' ZCP1 EOL {Changed from OfstOn - JHE}
SeqC CoolOn EOL
ELSE
SeqC Rapid PlaneC AbsOrInc StrtPos SpeedC EOL
IF NewToolOffset?
SeqC 'G43' ZCP1 EOL {Changed from OfstOn - JHE}
END
IF NOT CoolOff? AND LAST CoolOff?
IF ThruSpin?
SeqC 'M26' EOL {Added, thru spindle coolant - JHE}
END
SeqC CoolOn EOL
END
END
RETURN

end1:
SeqC RapidC ZCP1C CoolOff EOL {Added RapidC ZCP1C - JHE}
SeqC incValueC OfstOff EOL
RETURN

end2:
doEndOpPS
{IF FIRST ToolChangeAtHome?} {Removed - JHE}
SeqC 'G28X0.Y0.' EOL {Added, going Home - JHE}
SeqC absOrIncC 'G49' SpinOff EOL {Added this line - JHE}
IF ProgStop?
SeqC 'M0' EOL
ELSE
IF MultipleParts? AND AllToolsOnePart? AND NOT LastPart?
SeqC ProgStop EOL
END
END
RETURN

end3:
SeqC 'G10L2P1X0.Y0.Z0.B0.' EOL {Added this line - JHE}
SeqC EOP EOL
{EOR EOL} {Removed - JHE}
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 incValueC OfstOff 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 wFOStuff EOL
SeqC PlaneC AbsOrInc Rapid StrtPos Speed EOL
IF FullUp?
SeqC OfstOn EOL
SeqC CoolOn 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 16M Makino [EE] NMT56 16m
Fanuc 16M Makino [APM] C427 12
Fanuc 11M MS [EE] NMT57 16 2
Fanuc 11M MS [EE] NMT57 16 2m
Fanuc 16M Makino [MM] CX91 13m
Fanuc 16M Makino [MM] CX91 13
Fanuc 16M Makino M833 89m
Fanuc 16M LM [HE] NMQ59 16 1m
Fanuc 16M Makino A55 C948 13 5
Fanuc 16M Mit [JPL] DQ14 16
Fanuc 15M MTS [CP] NDU66 16 2m
Fanuc 16M Edgetec L570 85
Fanuc 0M LH P&W [SP] CV84 16 3
Fanuc 18M MS [CST] NCT81 16
Fanuc 6M Makino [NRC] M869 89
Fanuc 11M Tyd [CGB] CT37 16 4

więcej podobnych podstron