{Change Comments ***********************************************************}
{9/16/91
Copied & modified: Okuma OSP 5000 LB15 L103.82
For: Otto Nementz
Changes made per Dick Cavdek at Otto Nementz.
Deleted literal 'M42'.
Changed Full Peck Address from 'D' to 'L' in Form.
Changed Partial Peck Address from 'DA' to 'D' in Form.
'DA' was causing machine to crash.
The 'DA' was crashing the machine.
Moved Retract command to before IF PeckFullRetract? in Canned Drilling.
Moved Preset command to before IF ConstantSurfaceFeed? at FirstOperation.
G50 required by control.
Added literal move to ' X20 Z20' prior to Approach at FirstOperation.
KLM}
{6/8/92
Modified: Okuma OSP 500L-G L237.82.1
For: Otto Nementz
Changed ArcIJC to ArcIJ for unconditional Arc Centers at FormatArc.
Was causing control to issue an alarm.
KLM}
{5/24/94
Modified: Okuma OSP 500L-G L237.82.2
For: Gibbs & Associates per Matsurra 'Okuma OSP 5020L Tnnn.82.2'
Versions: ncCad 4.33/ncCAM 4.33/ncPost 4.33.03/Compost 4.21.21
Updated to Version 4.1 per Fanuc 10T MS [-] L001.82.1a Format.
Added RestoreScale Sub per 4-Axis Post Processor.
Added Logic to suppress Feed and FeedRate for Approaches.
Modified output of Speed & ConstantSurfaceFeed for SameTool in CheckOffset sub.
Added SetAbs at setup and initializations.
Added bypass of AutoFinish for Non-Canned RoughSimple Operations.
Added bypass of AutoFinish for Non-Canned Threading Operations.
Modified AutoFinish Approach.
Added XSPC ZSPC at AutoFinish for NOT CannedCycle AND NOT Turning Operations.
Changed RapidC StrtPos to StockOff StrtPosC at AutoFinish for NOT CannedCycle Operations.
DWB}
{11/29/95
Copied: Okuma OSP 500L-G L237.82.3
Created: Okuma OSP 500L-G Lxxx.82.3
For: Accurate Tool
Changed all comments to output to their liking.
Changed heading as follows: ascii 0, $ sign, Program Name, ascii 0 again, and then % sign.
This is the correct Okuma format if you want the control to read in a program name before
the main program. I also used ProgramComment$ for the Program Name because they use a slightly
different format between the FileName and the Program Name, and they wanted to type it in
independently of the FileName.
Also added ascii 0 after the end-of-record % sign at the end of program.
Changed 'CheckOffset' so that Constant Surface Speed (G96) will not be suppressed
in SameTool.
Changed format for thread lead to five places after the decimal.
Added high/low spindle logic (low speed/M41 for roughing ops, high speed/M42 for finish,
or contouring ops, low speed/M41 for drilling, and low speed/M41 for threading under 850 rpm
and high speed/M42 for threading over 850 rpm).
Also added logic so that an M42 high speed call will be made in SameTool. They often rough
and finish with the same tool, and they always rough in low speed and finish in high speed.
Joe Cusimano}
{6/15/97
Copied: Okuma OSP 500L-G Lxxx.82.3
Created: Okuma OSP 500L-G Lxxx.85
For: Accurate Tool
Changed comments back to normal (we can now control them in Preferences).
Updated to .85 format.
Joe Cusimano}
{Prog Numeric Format Definitions *******************************************}
#1 = '#.00'
#2 = '+####.####;0'
#3 = '#######0'
#4 = '###.##;0'
#5 = '####.####;0'
#6 = '###0'
#7 = '#'
FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(XCutDepth#,2)
FORMAT(ZCutDepth#,2)
FORMAT(Program#,3) {.72}
FORMAT(Operation#,3) {.72}
FORMAT(Tool#,3) {.72}
FORMAT(Dwell#,4) {.72}
FORMAT(Peck#,5)
FORMAT(CalcEPRPM#,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
DoOpComments:
IF UseComments?
SetScale('1')
IF OperationIDComment?
'( OPERATION ' Operation# ': ' OperationType$ ' )' EOL
END
IF WorkGroupComment?
'( ' WorkGroupComment$ ' )' EOL
END
IF NOT SameTool?
IF ToolTypeComment?
'( TOOL ' Tool# ': ' ToolSize$ ' ' ToolType$ ' )' EOL
END
IF ToolComment?
'( ' ToolComment$ ' )' EOL
END
END
IF OperationComment?
'( ' OperationComment$ ' )' EOL
END
RestoreScale
END
RETURN
PSInit: {reset flags from last Op, .70}
RETURN
PSStuff:
RETURN
DoPostScript:
PSInit
EachPS
SeqLabC PostScript EOL {literals}
PSStuff {commands}
NextPS
RETURN
DoEndOpPS:
PSInit
EachEOPS
SeqLabC EndOpPS EOL {literals}
PSStuff {commands}
NextPS
RETURN
StockOnNoCan:
IF NOT CannedCycle?
StockOn {need stock for SP positioning, if not a canned cycle}
END
RETURN
FeedNoCan:
IF NOT CannedCycle?
FeedC
END
RETURN
FeedRateNoCan:
IF NOT CannedCycle?
FeedRateC
END
RETURN
ApproachSP:
IF ApproachFace?
SeqLabC StockOnNoCan XSPC EOL
SeqLabC StockOff ZOpCPC EOL
StockOnNoCan
IF NotEqual? CycleStartZ# ZOpCP#
SeqLabC FeedNoCan ZSPC FeedRateNoCan EOL
END
ELSE { ODApproach/IDApproach }
SeqLabC StockOnNoCan ZSPC EOL
SeqLabC StockOff XOpCDC EOL
StockOnNoCan
IF NotEqual? CycleStartX# XOpCD#
SeqLabC FeedNoCan XSPC FeedRateNoCan EOL
END
END
RETURN
AppMove:
StockOff ThisOpEntryZCP
RETURN
Approach: { NOT FOR TAILSTOCK, .82 }
RapidF# { RapidF# Forces FeedRate }
IF ApproachOD?
SeqLabC ThisOpEntryXCP AppMove EOL
ELSE
IF ApproachID?
SeqLabC XOpCD AppMove EOL
ELSE {ApproachFace}
SeqLabC StockOnNoCan XSP AppMove EOL
END
END
ApproachSP
RETURN
CheckOffset:
DoEndOpPS
IF LAST ProgStop?
SeqLabC ' M0' EOL
ELSE
IF CoolOff? AND LAST NOT CoolOff?
SeqLabC CoolOff EOL
END
END
IF NewToolOffset?
SeqLabC LOfstOff '00' EOL
SeqLabC OpToolID LatheOffset EOL
END
IF ConstantSurfaceFeed?
SeqLabC Preset MaxRPM
IF Turning?
' M42' {high speed}
END
EOL
SeqLabC CSSOn ' G96' Speed EOL
ELSE
IF LAST ConstantSurfaceFeed?
SeqLabC CSSOff ' G97' Speed EOL
END
END
IF LAST ProgStop?
SeqLabC SpeedC SpinOn EOL
SeqLabC CoolOn EOL
ELSE
IF NOT ConstantSurfaceFeed?
SeqLabC SpeedC EOL
END
IF NOT CoolOff? AND LAST CoolOff?
SeqLabC CoolOn EOL
END
END
DoPostScript
RETURN
FormatArc:
IF ArcCW?
CWArcC
ELSE
CCWArcC
END
MoveXC MoveZC
IF ArcIJFormat?
ArcIJ
ELSE
ArcRC
END
RETURN
CkCRC: { 4.2 }
IF XMove? OR ZMove? { Approach Length Feature and Multiple Pockets }
IF NOT LastFeat?
CRCOnC
END
END
IF LastFeat? AND EmptyLine? { Exit Length Feature }
CRCOffC
END
RETURN
ToolPath:
EACHFeat
GetToolTip
IF LastFeat?
IF Drilling?
IF Tap?
SeqLabC SpinOff EOL
SeqLabC ' G4 P2000' EOL
SeqLabC Speed InverseSpinOn EOL
ELSE
IF Dwell?
SeqLabC ' G4 P' Dwell# EOL
END
END
END
END
IF PointFeat?
SeqLabC MoveSXYC EOL
ELSE
IF RapidFeat?
SeqLabC RapidC MoveXC MoveZC EOL
ELSE
IF LineFeat?
SeqLabC CkCRC FeedC MoveXC MoveZC FeedRateC EOL
ELSE
IF ArcFeat?
EACHQuadrant { Do not use NOT, LAST, FIRST or NEXT modifiers in this loop }
SeqLabC FormatArc FeedRateC EOL
NEXTQuadrant
ELSE
IF ThreadFeat?
SeqLabC ' G33' MoveXC MoveZC ThrdLead EOL
Rapid
END
END
END
END
END
NEXTFeat
RETURN
CheckRapid:
CRCOffC
IF LAST CannedCycle?
Rapid
ELSE
RapidC
END
RETURN
GetSpindleRange:
IF Threading? OR IF Drilling?
IF LTEqual? SpeedRPM# Num#('850')
' M41' {low speed}
ELSE
' M42' {high speed}
END
END
IF Turning?
' M42' {high speed}
END
IF Roughing?
' M41' {low speed}
END
RETURN
{Start of executable Prog **************************************************}
{setup and initializations}
InitProg
SetAbs
PosSideLathe
StandardXZArcs
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?
ASCII('0') '$' ProgramComment$ ASCII('0') 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
END
END
RestoreScale
OpenSub
StockOff {.71.2}
SetHome
DoOpComments
DoPostScript
Plane
SeqLab Preset
IF ConstantSurfaceFeed?
MaxRPM EOL
SeqLabC
END
Rapid CSSOff ' G97'
IF ConstantSurfaceFeed?
CalcRPM1
ELSE
Speed
END
OpToolID LatheOffset SpinOn CoolOn GetSpindleRange EOL
SeqLabC ' X20 Z20' EOL
Approach
ELSE
IF NewTool?
{Finish off last Operation}
StockOff {.62}
CheckRapid
IF LAST ApproachOD?
SeqLabC LAST OpExitXCPC EOL
ELSE
IF LAST ApproachID?
SeqLabC LAST XOpECDC EOL
END
END
SeqLabC LAST OpExitZCPC EOL
IF LAST ConstantSurfaceFeed?
SeqLabC CSSOff ' G97' CalcRPM2 EOL
END
SeqLabC NewHome
IF LAST ProgStop?
' M0'
ELSE
ProgStop
END
EOL
{Start new Operation}
DoOpComments
DoPostScript
SeqLab
IF ConstantSurfaceFeed?
Preset MaxRPM EOL
SeqLabC
END
Rapid CSSOff ' G97'
IF ConstantSurfaceFeed?
CalcRPM1
ELSE
Speed
END
OpToolID LatheOffset SpinOn CoolOn GetSpindleRange EOL
Approach
ELSE
IF SameTool? {.62}
{Start new Operation}
StockOff
DoOpComments
IF LAST StraightConnect?
CheckOffset
CheckRapid
SeqLabC StockOnNoCan XSPC ZSPC EOL
ELSE
CheckRapid
IF ApproachOD?
IF LAST ApproachOD?
SeqLabC LAST XOpECDC EOL
ELSE {around}
IF LAST ApproachID?
SeqLabC LAST XOpECDC EOL
END
SeqLabC LAST OpExitZCPC EOL
SeqLabC LAST OpExitXCPC EOL
END
ELSE
IF ApproachID?
IF LAST ApproachID?
SeqLabC LAST XOpECDC EOL
ELSE
IF LAST ApproachOD? {around}
SeqLabC LAST OpExitXCPC EOL
END
SeqLabC LAST OpExitZCPC EOL
SeqLabC XOpCDC EOL
END
ELSE {ApproachFace}
IF LAST ApproachFace?
SeqLabC LAST ZOpECPC EOL
ELSE
IF LAST ApproachOD? {around}
SeqLabC LAST OpExitXCPC EOL
ELSE {LAST ApproachID}
SeqLabC LAST XOpECDC EOL
END
SeqLabC LAST OpExitZCPC EOL
END
END
END
CheckOffset
ApproachSP
END
END
END
END {common point for all operations}
IF ConstantSurfaceFeed? AND NOT SameTool?
SeqLabC CSSOn ' G96' Speed EOL
END
IF CannedCycle?
StockOff
IF Roughing?
IF RoughSimple?
{ Not Supported }
ELSE
TagInc
SetPass2
IF RoughContour?
SeqLabC ' G85 Nł' Tag# CutDepth FeedRate XStkLeft ZStkLeft EOL
'>' Tag# EOL
IF ApproachFace?
SeqLab ' G82' EOL
ELSE
SeqLab ' G81' EOL
END
SeqLabC StepMove StrtPos EOL
ELSE
IF RoughPatternShift?
SeqLabC ' G86 Nł' Tag#
IF ApproachFace?
' D' ZCutDepth#
ELSE
' D' XCutDepth#
END
FeedRate XStkLeft ZStkLeft EOL
'>' Tag# EOL
IF ApproachFace?
SeqLab ' G82' EOL
ELSE
SeqLab ' G81' EOL
END
SeqLabC Rapid StrtPos EOL
END
END
ToolPath
SeqLabC ' G80' EOL
IF AutoFinish?
SeqLabC ' G87 Nł' Tag# EOL
END
SetPass1
TrackXNO# CycleStartX#
TrackZNO# CycleStartZ#
END
ELSE
IF Threading?
SeqLabC ' G71' XatFinZ FinZ XTapAtZ
IF SingleEdgeCut?
ToolAngle
ELSE
' B0'
END
CutDepth ThrdHeight ThrdLead ' M32'
IF ConstantVolumeCut?
' M75'
ELSE
' M74'
END
IF Chamfer?
' M23'
ELSE
' M22'
END
EOL
IF AutoFinish?
SeqLabC ' G33' XatFinZ FinZ XTapAtZ ThrdLead EOL
SeqLabC Rapid XCSP EOL
SeqLabC ZCSP EOL
END
ELSE
IF Drilling?
SeqLabC
IF Tap? AND NOT CWSpindle?
' G78'
ELSE
LCycle
END
XCSP ZDepth Peck Retract
IF PeckFullRetract?
' L' Peck#
END
FeedRate Dwell EOL
END
END
END
ELSE
StockOn
SetPass1
ToolPath
IF AutoFinish?
IF NOT Drilling? AND NOT Grooving? AND NOT RoughSimple? AND NOT Threading?
StockOff
IF Turning?
SetPass1
IF ApproachFace?
SeqLabC RapidC ZOpECPC EOL
ELSE
SeqLabC RapidC XOpECDC EOL
END
ApproachSP
ELSE
SetPass2
SeqLabC RapidC XSPC ZSPC EOL
END
SeqLabC StockOff StrtPosC EOL
ToolPath
END
END
IF Drilling? AND Tap?
SeqLabC SpinOff EOL
SeqLabC ' G4 P2000' EOL
SeqLabC Speed SpinOn EOL
END
END
NextOp {loops back to EachOP until last Operation}
{End of program ************************************************************}
{finish last operation}
StockOff
CRCOffC
IF CannedCycle?
Rapid
ELSE
RapidC
END
IF ApproachOD?
SeqLabC OpExitXCPC EOL
ELSE
IF ApproachID?
SeqLabC XOpECDC EOL
END
END
SeqLabC OpExitZCPC EOL
DoEndOpPS
SeqLabC CoolOff EOL
IF ConstantSurfaceFeed?
SeqLabC CSSOff ' G97 S' CalcEPRPM# EOL
END
SeqLabC FirstHome
IF ProgStop?
'M0'
ELSE
ProgStop
END
EOL
SeqLabC EOP EOL
Post
EOR ASCII('0') EOL
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:
Okuma OSP 500L G L237 85 2Okuma OSP 5020L [PB] L604 85 1Okuma OSP 500L GTR L290 82 2Okuma OSP 5020L [AT] L397 82 3Okuma OSP 5000 [NC] L606 85 1Okuma OSP 5020 [TPM] L572 85Okuma OSP 5020L [CP] L787 85Okuma OSP 7000L [JDHW] L707 85 1mOkuma OSP 3000 LC20 L049 85Okuma OSP 5020L [WMC] L676 85 3Okuma OSP 5500 Cadet L331 85Okuma OSP 5020L [GCS] L540 85Okuma OSP 5020L [MP] L626 85więcej podobnych podstron