Fanuc 6M Kit [WR] M138 89 1


{Fanuc 6M M001.56}
{11/29/88 Removed G17,G80, G40, G54, G90, M98P2L2 & G92 codes. Changed G91 to}
{G49, G28 to G27 and I & J format to R format. Output is in 3 place decimals.}
{Removed subroutines. - Danny Ball}

{4/17/90, Update: Fanuc 6M Kit/Wood M138.56 to .71.1 format, JR}

{7/24/90, Replaced all occurances of SetSRXYZero with SetSRXYtoSP, DWB}

{4/03/91
Modified: Fanuc 6M Kit/Wood M138.72
For: Gibbs & Associates
Updated to Version 4.0 per Fanuc 6M M001.80 Format.
DWB}

{
Format: Fanuc 6M Kit/Wood M138.89
For: Woodruff
4/18/96
Updated to .89
Replaced 'G49' with IncValue
Replaced OfstOff with 'G30Y0Z0'
TH}

{5/6/96
Initial: Fanuc 6M Kit [WR] M138.89
Created: Fanuc 6M Kit [WR] M138.89.1
Customized Tool Length Offset On/Off as per customer request, moved first tool ID onto line by itself,
added PreTool, MPK}

{Prog Numeric Format Definitions ****}

#1 = '#.00'
#2 = '###.###;0.'
#3 = '*###.###;0.'

FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)

{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

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

PSInit:
NewWFOF
RotateF
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

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

EntryMove:
IF FeedEntry?
SeqC Feed ZIn FeedEnt EOL
ELSE
SeqC RapidC ZIn EOL
END
RETURN

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

CkCRC: { 4.2 }
IF XMove? OR YMove? { Approach Length Feature and Multiple Pockets }
IF NOT ZMove? AND NOT LastFeat?
CRCOnC
IF NOT EmptyLine?
ResetCRCNum
END
END
END
IF LastFeat? AND EmptyLine? { Exit Length Feature }
CRCOffC
END
RETURN

StdLine: {enables CRC on first call, .70}
IF Decelerate?
IF RoomToDecel?
DecelMove1
SeqC CkCRC FeedC MoveXYZC FeedRateC CRCOffsetC EOL
DecelMove2
END
SeqC CkCRC FeedC MoveXYZC DecelFeed CRCOffsetC EOL
ELSE
SeqC CkCRC FeedC MoveXYZC FeedRateC CRCOffsetC EOL
END
RETURN

ToolPath2:
EACHFeat
IF RapidFeat?
IF LastFeat?
SeqC CRCOffC RapidC MoveXYZC EOL
ELSE
SeqC RapidC MoveXYZC EOL
END
ELSE
IF LineFeat?
IF LastFeat?
SeqC CRCOffC FeedC MoveXYZC FeedRateC EOL
ELSE
IF ZMove? {skip CRCOn until first non-Z move line, skipping ramps}
SeqC FeedC MoveXYZC FeedRateC EOL
ELSE
StdLine {enables CRC on first call}
END
END
ELSE
IF ArcFeat?
EACHQuadrant
IF LastQuadrant? AND Decelerate?
IF RoomToDecel?
DecelMove1
SeqC FormatArc ArcFeedC EOL
DecelMove2
END
SeqC FormatArc DecelFeed EOL
ELSE
SeqC FormatArc ArcFeedC EOL
END
NEXTQuadrant
END
END
END
NEXTFeat
RETURN

CutAutoCycle:
SaveSubStatus {save tool position}
SetPass1 {element cut moves}
SetSRXYtoSP
SeqC IncValue EOL
IF Repeats? AND ZshiftOnly?
EachRep
DoSubComment
SeqC StrtPosC EOL
EntryMove
ToolPath2
IF NOT FeedConnect?
SeqC RapidC PRIME ZCP2 EOL
END
NextRep
SeqC AbsOrInc RapidC ZCP2 EOL
ELSE
SeqC StrtPosC EOL
EntryMove
ToolPath2
SeqC AbsOrInc RapidC ZCP2 EOL
END
SetSRSubXY {restore tool position}
SetSRSubMove
ReSetPass2 {restore for positioning moves}
RETURN

ToolPath:
EACHFeat
IF PointFeat?
SeqC MoveSXYC EOL
IF AutoCycle?
CutAutoCycle
END
ELSE
IF RapidFeat?
SeqC RapidC MoveXYZC EOL
ELSE
IF LineFeat?
StdLine
ELSE
IF ArcFeat?
EACHQuadrant
IF LastQuadrant? AND Decelerate?
IF RoomToDecel?
DecelMove1
SeqC FormatArc ArcFeedC EOL
DecelMove2
END
SeqC FormatArc DecelFeed EOL
ELSE
SeqC FormatArc ArcFeedC EOL
END
NEXTQuadrant
END
END
END
END
NEXTFeat
RETURN

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


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

{setup and initializations}
InitProg
ReverseXZArcs
SetFlood
UseSeparateSubCalls
SetMaxSeparateSubCalls ('50') {?}
SetMaxRPM('10000') {?}
SetMaxFeed('500') {?}
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
EachOp {Start of post processing *********************}
IF FirstOperation?
EOR EOL
ProgID1 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 ' MoveType$ ' )' EOL
END
IF PartsComment?
'( PARTS PROGRAMMED: ' Parts# ' )' EOL
END
IF StartToolComment?
'( FIRST TOOL NOT IN SPINDLE )' EOL
END
END
OpenSub
RestoreScale
IF MultipleParts? AND AllToolsOnePart?
EachPart
END
Seq IncValue 'G30Y0.Z0.' EOL
SeqC OpToolID EOL
SeqC ToolChng EOL
DoOpComments
DoPostScript
SeqC Speed SpinOn EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
EachPart
END
CheckPass
SeqC Rapid AbsOrInc StrtPos EOL
SeqC OfstOn PreTool EOL
SeqC CoolOn EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
EachPart
SeqC StrtPosC EOL
END
ELSE
IF NewTool?
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
NextPart
END
SeqC CoolOff EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp? AND NOT LastPart?
SeqC IncValue 'G30Y0Z0' EOL
NextPart
ELSE
SeqC IncValue 'G30Y0Z0' SpinOff EOL
END
DoEndOpPS
IF ToolChangeAtHome?
SeqC AbsOrInc Rapid Home EOL
END
IF LAST ProgStop?
SeqC 'M00' EOL
ELSE
SeqC ProgStop EOL
END

{Start new Operation}

Seq OpToolID EOL
SeqC ToolChng EOL
DoOpComments
DoPostScript
SeqC Speed SpinOn EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
EachPart
END
CheckPass
SeqC Rapid AbsOrInc StrtPos EOL
SeqC OfstOn PreTool EOL
SeqC CoolOn EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
EachPart
SeqC StrtPosC EOL
END
ELSE
IF SameTool?
DoEndOpPS
IF LAST ProgStop?
SeqC CoolOff EOL
SeqC IncValue 'G30Y0Z0' SpinOff EOL
SeqC 'M00' EOL

{Start new Operation}

DoOpComments
DoPostScript
CheckPass
SeqC PlaneC Rapid AbsOrInc StrtPos SpeedC SpinOn EOL
SeqC OfstOn EOL
SeqC CoolOn EOL
ELSE
IF CoolOff? AND LAST NOT CoolOff?
SeqC CoolOff EOL
END
IF NewToolOffset?
SeqC IncValue 'G30Y0Z0' EOL

{Start new Operation}

DoOpComments
DoPostScript
CheckPass
SeqC PlaneC Rapid AbsOrInc StrtPos SpeedC EOL
SeqC OfstOn EOL
ELSE
{Start new Operation}

DoOpComments
DoPostScript
CheckPass
SeqC PlaneC Rapid AbsOrInc StrtPos SpeedC EOL
END
IF NOT CoolOff? AND LAST CoolOff?
SeqC CoolOn EOL
END
END
END
END
END {common point for all operations}
IF Milling?
SeqC ZCP2C EOL
IF Repeats?
IF ZshiftOnly? AND AutoCycle?
ELSE
EachRep
DoSubComment
SeqC
IF FeedConnect?
FeedC
ELSE
RapidC
END
IF NOT FirstCycle?
StrtPos
END
EOL
END
END
IF NOT AutoCycle?
EntryMove
END
ToolPath
IF Repeats?
IF ZshiftOnly? AND AutoCycle?
ELSE
SeqC CRCOffC
IF NOT FeedConnect?
RapidC PRIME ZCP3C
END
EOL
NextRep
END
END
SeqC RapidC CRCOffC ZCP3C EOL
ELSE
IF Drilling?
IF Repeats?
EachRep
DoSubComment
SeqC StrtPosC EOL
END
SeqC DrillCP EOL
GetCycle
SeqC Cycle FromCP StrtPos ZDepth RLevel Dwell Peck Retract FeedEnt EOL
ToolPath
SeqC 'G80' EOL
IF Repeats?
NextRep
END
SeqC RapidC ZCP3C EOL
END
END
NextOp
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
NextPart
END
SeqC CoolOff EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp? AND NOT LastPart?
SeqC IncValue 'G30Y0Z0' EOL
NextPart
ELSE
SeqC IncValue 'G30Y0Z0' SpinOff EOL
END
DoEndOpPS
IF ToolChangeAtHome?
SeqC AbsValue Rapid FirstHome EOL
END
IF ProgStop?
SeqC 'M00' EOL
END
IF MultipleParts? AND AllToolsOnePart?
NextPart
END
SeqC EOP EOL
Post
EOR EOL
Close
IF UseComments?
SetScale('1')
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:
Fanuc 10M Kit [LM] M904 89
Fanuc 6M Makino [NRC] M869 89
Fanuc 10M Kit [GM] M303 89
Fanuc 6M Mazak [CKC] M662 89 1
Fanuc 6M HS [MM] M854 89
Fanuc 6M NN [TM] M988 89 2
Fanuc 6M HS WF M249 89
Fanuc 3M Kit [TCR] MZ07 89
Fanuc 6M Tkswa [GK] M397 89
Fanuc 6M Komo [GT] M925 89
Fanuc 6M MTS [RD] M839 89
Fanuc 0M Kit [EI] MV51 89
Fanuc 6M RR [TRS] MX88 89 1
Fanuc 6M MTS [GT] M717 89
Fanuc 6M Leblond [AT] MV42 89

więcej podobnych podstron