{Change Comments ***********************************************************}
{7/24/90, Added InitProg globally to posts with this remark, DWB}
{1/28/91
Copied & modified: Sharnoa-Tiger III M023.55
For: Gibbs & Associates
Machine: Tiger III
Control: Sharnoa
Updated to Version 3.2 per Fanuc 6M M001.76.1 Format.
Added 'T' label to CRCOffset in Form.
DWB}
{5/7/91
Modified: Sharnoa-Tiger III M023.76.1
For: Gibbs & Associates
Updated to new 4.0 Version per Fanuc 6M M001.80
DWB}
{Prog Numeric Format Definitions *******************************************}
#1 = '#.00'
#2 = '###.###;0.'
#3 = '*###.###;0.'
#4 = '####.####;0.'
#5 = '########;0'
#6 = '####.###;'
FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(EPX#,4)
FORMAT(EPY#,4)
FORMAT(EPZ#,4)
FORMAT(SPZ#,4)
FORMAT(ArcR#,4)
FORMAT(ToolDiameter#,4) {.72}
FORMAT(Program#,5) {.72}
FORMAT(Operation#,5) {.72}
FORMAT(Tool#,5) {.72}
FORMAT(NewWFO#,5) {.72}
FORMAT(Parts#,5) {.72}
FORMAT(Dwell#,6) {.72}
{Prog Subroutines **********************************************************}
DoSubComment:
IF UseComments? AND SubComment?
NewProg
'/ SUB NUMBER: ' Program# EOL
END
RETURN
DoOpComments:
IF UseComments?
SetScale('1')
IF OperationIDComment?
SeqLabC '/OPERATION ' Operation# ': ' OperationType$ EOL
END
IF OperationComment?
SeqLabC '/' OperationComment$ EOL
END
IF WorkGroupComment?
SeqLabC '/' WorkGroupComment$ EOL
END
IF ToolTypeComment?
SeqLabC '/TOOL ' Tool# ': ' ToolDiameter# ' ' ToolType$ EOL
END
IF ToolComment?
SeqLabC '/' 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
PSInit: {reset flags}
NewWFOF
RotateF
RETURN
PSStuff: {revised.72}
IF FourthCW?
FORMAT(FourthDegree#,2)
SeqLabC 'A' FourthDegree# EOL
FourthCWF {reset flag}
END
IF FourthCCW?
FORMAT(FourthDegree#,3)
SeqLabC 'A' FourthDegree# EOL
FourthCCWF {reset flag}
END
IF FifthCW?
FORMAT(FifthDegree#,2)
SeqLabC 'B' FifthDegree# EOL
FifthCWF {reset flag}
END
IF FifthCCW?
FORMAT(FifthDegree#,3)
SeqLabC 'B' FifthDegree# EOL
FifthCCWF {reset flag}
END
RETURN
DoPostScript:
PSInit
EachPS
SeqLabC PostScript EOL {literals}
PSStuff {commands}
NextPS
RETURN
DoEndOpPS:
PSInit
EachEOPS
SeqLabC EndOpPS EOL {literals}
PSStuff {commands}
NextPS
RETURN
EntryMove:
IF AutoCycle? { Implies Incremental }
IF FeedEntry?
SeqLabC Feed ' Z/' SPZ# FeedEnt EOL
ELSE
SeqLabC RapidC ' Z/' SPZ# EOL
END
ELSE
IF FeedEntry?
SeqLabC Feed ZIn FeedEnt EOL
ELSE
SeqLabC RapidC ZIn EOL
END
END
RETURN
StartSub:
OpenSub
DoSubComment
'>' Tag# EOL
SeqLab
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:
SeqLabC SubCall RepLab 'ł' Tag# ' E' RepCycs EOL
StartSub
RETURN
FinishSub1: {part 1}
UnSkipZ
IF NOT AutoCycle?
SeqLabC RapidC EOL
SeqLabC CRCOff ZCP3 EOL
IF NOT FeedConnect?
SeqLabC ZCP3C EOL
END
END
RETURN
FinishSubG92: {part 2}
SeqLabC Preset ShftSR EOL
SeqLabC EndSub EOL
CloseSub
SeqLabC ' G99' EOL { Restore Control to Original Origin. }
SeqLabC ZCP2 EOL
RETURN
OpenMP:
TagInc
IF WorkFixtureOffsets?
NewWFO
EachWFO
SeqLabC ' G99' SetWFO EOL
SeqLabC SubCall ' Lł' Tag# EOL
IncWFO
NextWFO
ELSE
SeqLabC SubCall ' Lł' Tag# ' E' Parts EOL
END
StartSub
RETURN
CloseMP:
IF WorkFixtureOffsets?
SeqLabC EndSub EOL
CloseSub
ELSE
SeqLabC Preset ShftSP EOL
SeqLabC EndSub EOL
CloseSub
SeqLabC ' G99' EOL
END
RETURN
CheckMove:
IF AutoCycle? { Implies Incremental }
IF ArcFeat?
' X/' EPX# ' Y/' EPY#
IF ZMove?
' Z/' EPZ#
END
' R' ArcR#
ELSE { NOT ArcFeat }
IF RapidFeat?
IF NOT FirstFeat? AND LAST ArcFeat?
Rapid
ELSE
RapidC
END
ELSE
IF LineFeat?
IF NOT FirstFeat? AND LAST ArcFeat?
Feed
ELSE
FeedC
END
END
END
IF XMove?
' X/' EPX#
END
IF YMove?
' Y/' EPY#
END
IF ZMove?
' Z/' EPZ#
END
END
ELSE { NOT AutoCycle }
SharnoaMill
END
RETURN
StdLine: {enables CRC on first call, .70}
IF AutoCycle?
SeqLabC CRCOnC CRCOffsetC FeedRateC EOL
END
IF Decelerate?
IF RoomToDecel?
DecelMove1
SeqLabC CRCOnC CheckMove CRCOffsetC FeedRateC EOL
DecelMove2
END
SeqLabC CRCOnC CheckMove CRCOffsetC DecelFeed EOL
ELSE
IF XMove? OR YMove? OR ZMove?
SeqLabC CRCOnC CheckMove CRCOffsetC FeedRateC EOL
END
END
RETURN
ToolPath:
ResetCRCNum {.72}
EACHFeat
IF PointFeat?
SeqLabC MoveSXYC EOL
IF AutoCycle?
SeqLabC SubCall RepLab 'ł' Tag# EOL
SeqLabC ' G99' EOL { Restore Control to Original Origin. }
CalcACSRXY {calc tool position after sub call, CalcAutoCycleStatusRecordXY}
END
ELSE
IF RapidFeat?
IF LastFeat? AND AutoCycle? {.70}
SeqLabC CheckMove FeedRateC EOL
ELSE
IF XMove? OR YMove? OR ZMove?
SeqLabC CheckMove EOL
END
END
ELSE
IF LineFeat?
IF AutoCycle? {.70}
IF LastFeat?
SeqLabC CheckMove FeedRateC EOL
ELSE
IF ZMove? {skip CRCOn until first non-Z move line, skipping ramps}
SeqLabC CheckMove FeedRateC EOL
ELSE
StdLine {enables CRC on first call}
END
END
ELSE
StdLine
END
ELSE
IF ArcFeat?
IF AutoCycle? AND LAST NOT ArcFeat?
IF ArcCW?
' G2'
ELSE
' G3'
END
END
EACHQuadrant { Do not use NOT, FIRST, LAST or NEXT modifiers in this loop }
IF LastQuadrant? AND Decelerate?
IF RoomToDecel?
DecelMove1
SeqLabC CheckMove ArcFeedC EOL
DecelMove2
END
SeqLabC CheckMove DecelFeed EOL
ELSE
SeqLabC CheckMove ArcFeedC EOL
END
NEXTQuadrant
END
END
END
END
NEXTFeat
RETURN
WFOStuff:
IF NewWFO?
IF MultipleParts?
'*** WARNING *** DO NOT USE NEWWFO() WITH NCPOST MULTIPLE PARTS' EOL
ELSE
SeqLabC ' G99 O' NewWFO# EOL
END
ELSE
IF NOT SameTool?
IF NeedWFO1?
SeqLabC ' G99 O' NewWFO# EOL
END
END
END
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?
SeqLabC CRCOff EOL
ELSE
SeqLabC RapidC EOL
SeqLabC CRCOff ZCP2 EOL
END
SeqLabC EndSub 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?
AutoCycCutSub1
EntryMove
AutoCycCutSub2
AutoCycPat
ELSE
EntryMove
ToolPath
END
RETURN
G92Sub:
SubWarning
StdSub
IF AutoCycle?
TagInc
END
SetAbs
SeqLabC Connect StrtPos EOL
Milling
FinishSub1
FinishSubG92
RETURN
ZonlyRepAutoCycle:
AutoCycPat {write pattern moves and main calls}
StartSub
TagInc
EachCycle
IF FeedConnect?
SeqLabC Feed ZInPlusInc FeedEnt EOL
ELSE
IF FeedEntry?
IF NOT FirstCycle?
SeqLabC Rapid ZCP2PlusInc EOL {.69 added Rapid, reads better}
{can't call for cycle = 1, .69 changed to ZCP2PlusInc}
END
SeqLabC Feed ZInPlusInc FeedEnt EOL
ELSE
SeqLabC Rapid ZInPlusInc EOL {.69 added Rapid, reads better}
END
END
IF FirstCycle?
SetStatusOff {protect Z position for incremental sub}
END
SeqLabC SubCall RepLab 'ł' Tag# EOL
SeqLabC ' G99' EOL { Restore Control to Original Origin. }
NextCycle
SetStatusOn
AutoCycCutSub1 {build element sub}
AutoCycCutSub2
{.69, removed FinishSub1}
IF FeedConnect? {there is no Z up in the sub, .69}
SeqLabC Rapid ZCP2 EOL {.69}
END {.69}
SeqLabC EndSub EOL
CloseSub
{Element shift, not pattern}
SeqLabC ZCP2 EOL
RETURN
ZonlyRep:
EachCycle
IF NOT FirstCycle?
SeqLabC Connect StrtPos EOL {.71.2, added Connect}
END
IF FeedConnect?
SeqLabC FeedC ZInPlusInc FeedEnt EOL {.71.2, changed to FeedC}
ELSE {Entry/Exit Connect}
IF FeedEntry?
IF NOT FirstCycle?
SeqLabC RapidC ZCP2PlusIncC EOL {can't call for cycle =1} {.69 added Rapid, reads better} {.71.2, changed to RapidC, reads better}
END
SeqLabC Feed ZInPlusInc FeedEnt EOL
ELSE
SeqLabC RapidC ZInPlusInc EOL {.69 added Rapid, reads better} {.71.2, changed to RapidC, reads better}
END
END
SeqLabC SubCall ' Lł' Tag# EOL
NextCycle
StartSub
SkipZ
ToolPath
FinishSub1
SeqLabC EndSub EOL
CloseSub
SeqLabC ' G99' EOL { Restore Control to Original Origin. }
SeqLabC ZCP2 EOL
RETURN
CheckPass:
IF AutoCycle? {use the correct StrtPos}
SetPass2
ELSE
SetPass1
END
RETURN
GetStartOfSameTool:
DoOpComments
DoPostScript
WFOStuff
CheckPass
RETURN
{Start of executable Prog **************************************************}
{setup and initializations}
InitProg
SetAbs
ReverseXZArcs
InitWFONum
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
' 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
EachOp {Start of post processing *********************}
IF AutoCycle?
QuadStop
ELSE
NoQuadStop
END
IF FirstOperation?
EOR EOR EOL
IF ToolChangeAtHome?
SetHome
END
IF UseComments?
IF ProgramNameComment?
SeqLabC '/PROGRAM: ' ProgramName$ EOL
END
IF ProgramComment?
SeqLabC '/' ProgramComment$ EOL
END
IF FormatNameComment?
SeqLabC '/FORMAT: ' FormatName$ EOL
END
IF TimeComment?
SeqLabC '/' Date$ ' AT ' Time$ EOL
END
IF MovesComment?
SeqLabC '/OUTPUT IN ABSOLUTE INCHES' EOL
END
IF PartsComment?
SeqLabC '/PARTS PROGRAMMED: ' Parts# EOL
END
IF StartToolComment?
SeqLabC '/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
SeqLab DrillOff EOL
SeqLabC CRCOff EOL
SeqLabC Plane EOL
DoPostScript
WFOStuff
DoOpComments
SeqLabC OpToolID Speed SpinOn EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
OpenMP
END
CheckPass
SeqLabC Rapid StrtPos EOL
SeqLabC ZCP1 EOL
SeqLabC CoolOn EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
OpenMP
SeqLabC StrtPos EOL
END
ELSE
IF NewTool?
{Finish off last Operation}
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
CloseMP
END
SeqLabC CoolOff EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
CloseMP
END
DoEndOpPS
IF ToolChangeAtHome?
SeqLabC Rapid Home SpinOff EOL
ELSE
SeqLabC SpinOff EOL
END
IF LAST ProgStop?
SeqLabC ' M' EOL
ELSE
SeqLabC ProgStop EOL
END
{Start new Operation}
SeqLab OpToolID ToolChng EOL
DoOpComments
SeqLabC DrillOff EOL
SeqLabC CRCOff EOL
SeqLabC PlaneC EOL
DoPostScript
WFOStuff
SeqLabC Speed SpinOn EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
OpenMP
END
CheckPass
SeqLabC Rapid StrtPos EOL
SeqLabC ZCP1 EOL
SeqLabC CoolOn EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
OpenMP
SeqLabC StrtPos EOL
END
ELSE
IF SameTool?
DoEndOpPS
IF LAST ProgStop?
SeqLabC CoolOff EOL
SeqLabC SpinOff EOL
SeqLabC ' M' EOL
{Start new Operation}
GetStartOfSameTool
SeqLabC PlaneC Rapid StrtPos SpeedC SpinOn EOL
SeqLabC ZCP1 EOL
SeqLabC CoolOn EOL
ELSE
IF CoolOff? AND LAST NOT CoolOff?
SeqLabC CoolOff EOL
END
IF NewToolOffset?
{Start new Operation}
GetStartOfSameTool
SeqLabC PlaneC Rapid StrtPos SpeedC EOL
SeqLabC ZCP1 EOL
ELSE
{Start new Operation}
GetStartOfSameTool
SeqLabC PlaneC Rapid StrtPos SpeedC EOL
END
IF NOT CoolOff? AND LAST CoolOff?
SeqLabC CoolOn EOL
END
END
END
END
END {common point for all operations}
IF Milling?
SeqLabC ZCP2C EOL
IF Repeats?
TagInc
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}
G92Sub
END {end Z only IF}
ELSE {no repeat OPs}
IF AutoCycle?
TagInc
END
Milling
IF NOT Autocycle?
IF CutterRadiusCompensation?
SeqLabC Rapid EOL
SeqLabC CRCOff ZCP3 EOL
ELSE
SeqLabC Rapid ZCP3 EOL
END
END
END
ELSE
IF Drilling?
IF Repeats?
TagInc
StdSub
SeqLabC Rapid StrtPos EOL
END
SeqLabC DrillCP EOL
GetCycle
SeqLabC Cycle StrtPos RLevel ' P' ZDepth Dwell Peck Retract FeedEnt EOL
EachFeat
SeqLabC DrilFeat EOL
NextFeat
SeqLabC DrillOff EOL
IF Repeats?
SeqLabC ZCP2 EOL
FinishSubG92
END
END
END
NextOp {loops back to EachOP until last Operation}
{End of program ************************************************************}
{finish last operation}
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
CloseMP
END
SeqLabC CoolOff EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
CloseMP
END
DoEndOpPS
IF FIRST ToolChangeAtHome? {.71.2 added FIRST modifier}
SeqLabC Rapid FirstHome SpinOff EOL
ELSE
SeqLabC SpinOff EOL
END
IF ProgStop?
SeqLabC ' M' EOL
END
IF MultipleParts? AND AllToolsOnePart?
CloseMP
END
SeqLabC EOP EOL
CloseSub
Post2 {organize Subs into one program}
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:
Sharnoa Tiger IV CO M389 89 2Sharnoa Tiger V M810 89 2Sharnoa Tiger V MY02 89Sharnoa Tiger IV [WT] MX24 89 2III CZP 80 03Sharnoa Tiger VI MY01 89OLYMPUS µ [mju] III 80 instrukcja obsługiSharnoa Udo M005 80MOduł III nauka i wiedzażuraw 80Test II III etap VIII OWoUEPJU zagadnienia III WLS 10 11OTWP 2010 TEST IIIKlucz Odpowiedzi Chemia Nowej Ery III Węgiel i jego związki z wodoremwięcej podobnych podstron