{Change Comments ***********************************************************}
{9/23/88
Copied & modified: Okuma OSP 3000-LC20 L049.51
For: Shultz
Deleted ToolOver20? stuff.
Added conventional OpToolId stuff.
Deleted literal 'G95' from FirstOperation and NewTool.
Modified FORMAT to output 4 place trailing zeros.
Added spaces between codes.
Machine has one turret. Deleted special routines to handle index clearances.
JR}
{9/29/88
Copied & modified: Okuma OSP 3000 LB20 L067.55
For: Shultz
Worked on Canned Cycles.
JR & WFG}
{7/24/90, Added InitProg globally to posts with this remark, DWB}
{4/25/91
Modified: Okuma OSP 3000 LB20 L067.57
For: Gibbs & Associates
Updated to Version 4.0 per Fanuc 10T MS [-] L001.80 Format.
All normal Fanuc Canned Cycles except for SimpleRough are supported.
DWB}
{08/07/91
Updated: Okuma OSP 3000 LB20 L067.80
For: Gibbs & Associates
Updated to Version 4.0 per Fanuc 6M M001.82 Format.
Kim Michelman}
{Prog Numeric Format Definitions *******************************************}
#1 = '#.00'
#2 = '####^0000'
#3 = '########;0'
#4 = '###^00'
#5 = '#^#####0'
FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(FirstMoveEPX#,2)
FORMAT(FirstMoveEPZ#,2)
FORMAT(DiaDistanceToThread#,2)
FORMAT(Program#,3) {.72}
FORMAT(Operation#,3) {.72}
FORMAT(Tool#,3) {.72}
FORMAT(Dwell#,4) {.72}
FORMAT(FeedIPR#,5)
{Prog Subroutines **********************************************************}
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# ': ' ToolSize$ ' ' ToolType$ ' )' EOL
END
IF ToolComment?
'( ' 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
StockOnNoCan:
IF NOT CannedCycle?
StockOn
END
RETURN
PSInit: {reset flags from last Op, .70}
RETURN
PSStuff:
RETURN
DoPostScript:
PSInit
EachPS
SeqC PostScript EOL {literals}
PSStuff {commands}
NextPS
RETURN
DoEndOpPS:
PSInit
EachEOPS
SeqC EndOpPS EOL {literals}
PSStuff {commands}
NextPS
RETURN
CheckFeedRate:
IF SameTool?
FeedRate
END
RETURN
StockOnNoCan:
IF NOT CannedCycle?
StockOn {need stock for SP positioning, if not a canned cycle}
END
RETURN
ODApproachSP:
SeqC StockOnNoCan ZSPC EOL
SeqC StockOff XOpCDC EOL
SeqC Feed StockOnNoCan XSPC CheckFeedRate EOL
RETURN
IDApproachSP:
SeqC StockOnNoCan ZSPC EOL
SeqC StockOff XOpCDC EOL { for SameTool ApproachID }
SeqC Feed StockOnNoCan XSPC CheckFeedRate EOL
RETURN
FaceApproachSP:
SeqC StockOnNoCan XSPC EOL { for SameTool ApproachFace }
SeqC StockOff ZOpCPC EOL
SeqC Feed StockOnNoCan ZSPC CheckFeedRate EOL
RETURN
AppMove:
ZCP
RETURN
Approach: { NOT FOR TAILSTOCK, .82 }
IF ApproachOD?
SeqC XCP AppMove EOL
ODApproachSP
ELSE
IF ApproachID?
SeqC XOpCD AppMove EOL
IDApproachSP
ELSE {ApproachFace}
SeqC StockOnNoCan XSP StockOff AppMove EOL
FaceApproachSP
END
END
RETURN
CheckOffset:
DoEndOpPS
IF LAST ProgStop?
SeqC ' M0' EOL
ELSE
IF CoolOff? AND LAST NOT CoolOff?
SeqC CoolOff EOL
END
END
IF NewToolOffset?
SeqC LOfstOff '00' EOL
SeqC OpToolID LatheOffset EOL
END
IF ConstantSurfaceFeed?
IF LAST ConstantSurfaceFeed?
SeqC SpeedC EOL
ELSE
SeqC Preset MaxRPM EOL
SeqC CSSOn ' G96' Speed EOL
END
ELSE
IF LAST ConstantSurfaceFeed?
SeqC CSSOff ' G97' Speed EOL
ELSE
SeqC SpeedC EOL
END
END
IF LAST ProgStop?
SeqC SpinOn EOL
SeqC CoolOn EOL
ELSE
IF NOT CoolOff? AND LAST CoolOff?
SeqC CoolOn EOL
END
END
DoPostScript
RETURN
FormatArc:
IF ArcCW?
CWArcC
ELSE
CCWArcC
END
MoveXC MoveZC
IF ArcIJFormat?
ArcIJC
ELSE
ArcRC
END
RETURN
ToolPathPrim:
IF PointFeat?
SeqC MoveSXYC EOL
ELSE
IF RapidFeat?
SeqC RapidC MoveXC MoveZC EOL
ELSE
IF LineFeat?
SeqC FeedC MoveXC MoveZC FeedrateC EOL
ELSE
IF ArcFeat?
EACHQuadrant
SeqC FormatArc FeedrateC EOL
NEXTQuadrant
ELSE
IF ThreadFeat?
SeqC ' G32' MoveXC MoveZC ThrdLead EOL
END
END
END
END
END
RETURN
ToolPath:
EACHFeat
GetToolTip
IF LastFeat?
IF NOT CannedCycle?
IF Drilling?
IF Tap?
SeqC SpinOff EOL
SeqC ' G4 F200' EOL
SeqC Speed InverseSpinOn EOL
ELSE
IF Dwell?
SeqC ' G4 F' Dwell# EOL
END
END
END
ToolPathPrim
END
ELSE
ToolPathPrim
END
NEXTFeat
RETURN
CheckRapid:
IF LAST CannedCycle?
Rapid
ELSE
RapidC
END
RETURN
{Start of executable Prog **************************************************}
{setup and initializations}
InitProg
PosSideLathe
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: must be all capital letters when typed in.' 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
END
EachOp {Start of post processing *********************}
GetLCycle
IF FirstOperation?
EOR EOL
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 INCHES )' EOL}
'( OUTPUT IN ' MoveType$ ' INCHES )' EOL
END
END
IF Metric? {CAM file is in Metric, tools and tool path}
SetScale('.03937007874') { change to English, this is an English post}
END
OpenSub
StockOff {.71.2}
SetHome
DoOpComments
DoPostScript
Plane
Seq AbsOrInc EOL
IF ConstantSurfaceFeed?
SeqC Preset MaxRPM EOL
END
SeqC Rapid CSSOff ' G97'
IF ConstantSurfaceFeed?
CalcRPM1
ELSE
Speed
END
OpToolID LatheOffset SpinOn CoolOn ' M42' FeedRate EOL
Approach
ELSE
IF NewTool?
{Finish off last Operation}
StockOff {.62}
CheckRapid
IF LAST ApproachOD?
SeqC XCPC EOL
ELSE
IF LAST ApproachID?
SeqC LAST XOpECDC EOL
END
END
SeqC ZCPC EOL
DoEndOpPS
IF LAST ConstantSurfaceFeed?
SeqC CSSOff ' G97' CalcRPM2 EOL
END
IF LAST ProgStop?
SeqC ' M0' EOL
ELSE
SeqC ProgStop EOL
END
{Start new Operation}
DoOpComments
DoPostScript
Seq
IF ConstantSurfaceFeed?
SeqC Preset MaxRPM EOL
END
SeqC Rapid CSSOff ' G97'
IF ConstantSurfaceFeed?
CalcRPM1
ELSE
Speed
END
OpToolID LatheOffset SpinOn CoolOn ' M42' FeedRate EOL
Approach
ELSE
IF SameTool? {.62}
{Start new Operation}
DoOpComments
StockOff
IF LAST StraightConnect?
CheckOffset
CheckRapid
SeqC StockOnNoCan XSPC ZSPC EOL
ELSE
CheckRapid
IF ApproachOD?
IF LAST ApproachOD?
SeqC LAST XOpECDC EOL
ELSE {around}
IF LAST ApproachID?
SeqC LAST XOpECDC EOL
END
SeqC ZCPC EOL
SeqC XCPC EOL
END
CheckOffset
ODApproachSP
ELSE
IF ApproachID?
IF LAST ApproachID?
SeqC LAST XOpECDC EOL
ELSE
IF LAST ApproachOD? {around}
SeqC XCPC EOL
END
SeqC ZCPC EOL
SeqC XOpCDC EOL
END
CheckOffset
IDApproachSP
ELSE {ApproachFace}
IF LAST ApproachFace?
SeqC LAST ZOpECPC EOL
ELSE
IF LAST ApproachOD? {around}
SeqC XCPC EOL
ELSE {LAST ApproachID}
SeqC LAST XOpECDC EOL
END
SeqC ZCPC EOL
END
CheckOffset
FaceApproachSP
END
END
END
END
END
END {common point for all operations}
IF ConstantSurfaceFeed? AND NOT SameTool?
SeqC CSSOn ' G96' Speed EOL
END
IF CannedCycle?
StockOff
IF Roughing?
IF RoughContour?
SetPass2
SeqC LCycle EOL
IF ApproachFace?
SeqC ' G82' EOL
END
SeqC StepMove CutDepth XStkLeft ZStkLeft EOL
SeqC StrtPos EOL
ToolPath
SeqC ' G80' EOL
IF AutoFinish?
SeqC StepMove XCSPC ZCSPC EOL
SeqC XSPC ZSPC EOL
ToolPath
END
SeqC RapidC XCSPC ZCSPC EOL
ELSE
IF RoughPatternShift?
SetPass2
SeqC LCycle EOL
IF ApproachFace?
SeqC ' G82' EOL
END
SeqC Rapid
IF ApproachFace?
ZminusW
ELSE
XminusU
END
XStkLeft ZStkLeft EOL
SeqC StrtPos EOL
ToolPath
SeqC ' G80' EOL
IF AutoFinish?
SeqC Rapid XCSPC ZCSPC EOL
SeqC XSPC ZSPC EOL
ToolPath
END
SeqC RapidC XCSPC ZCSPC EOL
END
END
ELSE
IF Threading?
IF Chamfer?
SeqC ' M23' EOL
END
IF ConstantVolumeCut?
SeqC LCycle EOL
SeqC CutDepth ' E' DiaDistanceToThread# EOL
SeqC ' G33' XatFinZ FinZ XTapAtZ ThrdLead EOL
SeqC ' G80' EOL
IF AutoFinish?
SeqC ' G33' XatFinZ FinZ XTapAtZ ThrdLead EOL
END
ELSE
SeqC ' G33 X' FirstMoveEPX# FinZ XTapAtZ ThrdLead EOL
SimpleRough
SeqC XatFinZ EOL
IF AutoFinish?
SeqC XatFinZ EOL
END
END
IF Chamfer?
SeqC ' M22' EOL
END
ELSE
IF Drilling?
IF Tap?
SeqC LCycle ZDepth FeedRate EOL
SeqC SpinOff EOL
SeqC ' G4 F200' EOL
SeqC Speed InverseSpinOn EOL
SeqC ZSP EOL
ELSE
IF PeckChipBreaker?
SeqC LCycle EOL
SeqC ' G82' EOL
SeqC Peck ' E0' EOL
SeqC Feed ZDepth FeedRate EOL
SeqC DrillOff EOL
SeqC Rapid ZSP EOL
IF AutoFinish?
SeqC Feed ZDepth EOL
IF Dwell?
SeqC ' G4 F' Dwell# EOL
END
SeqC Rapid ZSP EOL
END
END
END
END
END
END
ELSE
StockOn
SetPass1
ToolPath
IF AutoFinish?
IF NOT Drilling? AND NOT Grooving?
StockOff
IF Turning?
SetPass1
ELSE
SetPass2
END
SeqC RapidC StrtPos EOL
ToolPath
END
END
END
IF Drilling? AND Tap?
SeqC SpinOff EOL
SeqC ' G4 F200' EOL
SeqC Speed SpinOn EOL
END
NextOp {loops back to EachOP until last Operation}
{End of program ************************************************************}
{finish last operation}
StockOff
IF CannedCycle?
Rapid
ELSE
RapidC
END
IF ApproachOD?
SeqC XCPC EOL
ELSE
IF ApproachID?
SeqC XOpECDC EOL
END
END
SeqC ZCPC EOL
DoEndOpPS
SeqC CoolOff EOL
IF ConstantSurfaceFeed?
SeqC CSSOff ' G97 S' CalcEPRPM# EOL
END
IF ProgStop?
SeqC ' M0' EOL
END
SeqC EOP EOL
Post
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
Wyszukiwarka
Podobne podstrony:
Okuma OSP 3000 LC10 L069 82 1Okuma OSP 500L GTR L290 82 2Okuma OSP 5000 LC10 L235 82 2Okuma OSP 5020L [AT] L397 82 3Okuma OSP 2200 LSN10 L089 82Okuma OSP 3000 LC20 L049 85Okuma OSP 5000 LB10 L351 82 2Okuma OSP 2200 LC10 L058 82 1Okuma 3000 LB20 [MK] L134 82 1Okuma OSP 5020L [PB] L604 85 1Okuma OSP 5020M [GSI] M648 87Okuma OSP 500L G L237 85 2Okuma OSP 5020M M374 89 2Okuma OSP 5020L LNC 8C L499 85Okuma OSP 5020M [LC] MY37 89 1Okuma OSP 700M LH [AT] MV57 12 3Okuma OSP 5020M [CS] MZ21 89Okuma OSP 5000 [NC] L606 85 1więcej podobnych podstron