{Change Comments ***********************************************************}
{7/24/90, Added InitProg globally to posts with this remark, DWB}
{3/26/91
Modified: Bandit II Cadillac L070.58
For: Gibbs & Associates
Updated to Version 4.0 per Fanuc 10T MS [-] L001.80 Format.
Only Canned Cycles supported are RoughContour (Turning only) and all Drilling Cycles.
BUG NOTE: ComPost's Strings dialog indicates that '/X' and '/Z' are Rapid moves,
but Default Formats does not recognize the '/', so no value is output.
BUG NOTE: Canned RoughContour used an EachCycle/NextCycle loop which is a Milling command.
Could be that we need an EachPass/NextPass loop instead.
DWB}
{8/6/91
Updated: Bandit II Cadillac L070.80
For: Gibbs & Associates
Updated to Version 4.0 per Fanuc 6M M001.82 Format.
KM}
{9/28/93
Modified: Bandit II Cadillac L070.82
For: Gibbs & Associates
Corrected Rapid moves per BUG NOTE of 3/26/91.
Removed spaces between codes in Mach Spec.
JR}
{10/10/93
Copied & modified: Bandit II Cadillac L070.82.1
For:
Machine: Phaser Lathe
Control: Bandit
Changes made for output loaded to control from external device.
Changed X Arc Center Label from /K to K in Mach Specs Strings 1 Dialog.
Changed Y Arc Center Label from /J to J in Mach Specs Strings 1 Dialog.
Changed Rapid X End-Point Label from /X to J in Mach Specs Strings 1 Dialog.
Changed Rapid Z End-Point Label from /Z to K in Mach Specs Strings 1 Dialog.
Changed Feed Label from /F to F in Mach Specs Strings 1 Dialog.
No slashes required except for non-modal ThrdLead in Single Point Threading.
Changed Change Tool from M6 to M20 in Mach Specs Commands 4 Dialog.
Deleted GearRange at CheckOffset sub, FirstOperation and NewTool.
Moved SpinOn to before AbsOrInc at FirstOperation and NewTool.
Deleted CoolOn and FirstOperation and NewTool.
Deleted literal 'M11' at FirstOperation and NewTool.
Added literal 'M20' for ToolChange prior to ProgStop at NewTool and end of Prog.
Deleted Feed command at Home block at NewTool.
Ken Crowther}
{12/22/93
Modified: Bandit II Phaser L292.82.1
For: Gibbs & Associates
Versions: ncCad 4.32/ncCam 4.32/ncPost 4.32/Compost 4.21.19
Changes made per conversations with Ken Crowther.
Updated to Version 4.1 per Fanuc 10T MS [-] L001.82.1 Format.
Deleted CoolOn at CheckOffset sub.
Deleted CoolOff at CheckOffset sub.
Moved ThrdLead from RapidFeat to ThreadFeat of ToolPath.
FeedRate is not Modal and needs to be output on all Thread Passes for encoder to pick up Lead.
Added Variable(1) to keep track of Turret Indexes.
Turret is 4 station and needs to be indexed back to station 1 at end of program.
Var(1) set to 1 at FirstOperation for First Turret Station.
Var(1) incremented by 1 at NewTool.
Added logic to output literal 'M20' to return Turret back to Station 1 at end of prog.
NOTE: Ken Crowther requested that FeedRates be output in Inches per Minute instead of Revolution.
This is to be taken care of at a later date.
DWB}
{Prog Numeric Format Definitions *******************************************}
#1 = '#.00'
#2 = '###.####;0'
#3 = '#######0'
#4 = '#'
FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(Dwell#,2) {.72}
FORMAT(FeedIPR#,2)
FORMAT(Program#,3) {.72}
FORMAT(Operation#,3) {.72}
FORMAT(Tool#,3) {.72}
FORMAT(Tag#,4)
FORMAT(RapidF#,4)
{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 OperationComment?
'( ' OperationComment$ ' )' EOL
END
IF WorkGroupComment?
'( ' WorkGroupComment$ ' )' EOL
END
IF ToolTypeComment?
'( TOOL ' Tool# ': ' ToolSize$ ' ' ToolType$ ' )' EOL
END
IF ToolComment?
'( ' ToolComment$ ' )' 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 Threading?
IF CannedCycle?
IF Drilling?
FeedC
END
ELSE
FeedC
END
END
RETURN
FeedRateNoCan:
IF NOT Threading?
IF CannedCycle? AND Drilling?
ELSE
SeqLabC FeedRateC EOL
END
END
RETURN
ODApproachSP:
SeqLabC StockOnNoCan ZSPC EOL
SeqLabC StockOff XOpCDC EOL
StockOnNoCan
FeedRateNoCan
IF NotEqual? CycleStartX# XOpCD#
SeqLabC FeedNoCan XSPC EOL
END
RETURN
IDApproachSP:
SeqLabC StockOnNoCan ZSPC EOL
SeqLabC StockOff XOpCDC EOL { for SameTool ApproachID }
StockOnNoCan
FeedRateNoCan
IF NotEqual? CycleStartX# XOpCD#
SeqLabC FeedNoCan XSPC EOL
END
RETURN
FaceApproachSP:
SeqLabC StockOnNoCan XSPC EOL { for SameTool ApproachFace }
SeqLabC StockOff ZOpCPC EOL
StockOnNoCan
FeedRateNoCan
IF NotEqual? CycleStartZ# ZOpCP#
SeqLabC FeedNoCan ZSPC EOL
END
RETURN
AppMove:
StockOff ZCP
RETURN
Approach: { NOT FOR TAILSTOCK, .82 }
IF CannedCycle? AND Drilling?
ELSE
RapidF# { RapidF# Forces FeedRate }
END
Rapid
IF ApproachOD?
SeqLabC StockOff XCP AppMove EOL
ODApproachSP
ELSE
IF ApproachID?
SeqLabC StockOff XOpCD AppMove EOL
IDApproachSP
ELSE {ApproachFace}
SeqLabC StockOnNoCan XSP AppMove EOL
FaceApproachSP
END
END
RETURN
CheckOffset:
DoEndOpPS
IF LAST ProgStop?
SeqLabC 'M0' EOL
END
IF NewToolOffset?
SeqLabC ToolOfst '00' EOL
END
IF LAST ProgStop?
SeqLabC SpinOn EOL
END
DoPostScript
RETURN
FormatArc:
MoveXC MoveZC ArcIJ
RETURN
ToolPath:
EACHFeat
GetToolTip
IF LastFeat?
IF Drilling?
IF Tap?
SeqLabC SpinOff EOL
SeqLabC '/T2.' EOL
SeqLabC InverseSpinOn EOL
ELSE
IF Dwell?
SeqLabC '/T' Dwell# EOL
END
END
END
END
IF PointFeat?
SeqLabC MoveSXYC EOL
ELSE
IF RapidFeat?
SeqLabC RapidC MoveXC MoveZC EOL
ELSE
IF LineFeat?
SeqLabC FeedRateC EOL
SeqLabC FeedC MoveXC MoveZC EOL
ELSE
IF ArcFeat?
SeqLabC FeedRateC EOL
EACHQuadrant { Do not use NOT, LAST, FIRST or NEXT modifiers in this loop }
SeqLabC FormatArc EOL
NEXTQuadrant
ELSE
IF ThreadFeat?
SeqLabC ThrdLead EOL
SeqLabC Feed MoveZC EOL
END
END
END
END
END
NEXTFeat
RETURN
CheckRapid:
IF LAST CannedCycle?
Rapid
ELSE
RapidC
END
RETURN
{Start of executable Prog **************************************************}
{setup and initializations}
InitProg
ArcCPsDia
PosSideLathe
ReverseXZArcs
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?
' ' EOL
IF UseComments?
IF ProgramNameComment?
'( ' 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$ ' INCHES )' EOL
END
END
RestoreScale
OpenSub
StockOff {.71.2}
SetHome
DoOpComments
DoPostScript
Plane
SeqLab SpinOn EOL
SeqLabC AbsOrInc EOL
SeqLabC ToolOfst '00' EOL
Save# Num#('1') Num#('1') { First Turret Position }
SeqLabC Home Preset EOL
IF CannedCycle? AND Drilling?
ELSE
Approach
END
ELSE
IF NewTool?
{Finish off last Operation}
StockOff {.62}
CheckRapid
IF LAST ApproachOD?
SeqLabC XCPC EOL
ELSE
IF LAST ApproachID?
SeqLabC LAST XOpECDC EOL
END
END
SeqLabC ZCPC EOL
DoEndOpPS
SeqLabC NewHome EOL
SeqLabC 'T0' EOL
SeqLabC 'M20' EOL { Index Turret }
Save# Num#('1') ADD# Recall# Num#('1') Num#('1') { Increment Turret Position }
IF Equal? Recall# Num#('1') Num#('5') { Back at First Turret Position }
Save# Num#('1') Num#('1')
END
IF LAST ProgStop?
SeqLabC 'M0' EOL
ELSE
SeqLabC ProgStop EOL
END
{Start new Operation}
DoOpComments
DoPostScript
SeqLab SpinOn EOL
SeqLabC AbsOrInc EOL
SeqLabC ToolOfst '00' EOL
SeqLabC Home Preset EOL
IF CannedCycle? AND Drilling?
ELSE
Approach
END
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 ZCPC EOL
SeqLabC XCPC EOL
END
CheckOffset
ODApproachSP
ELSE
IF ApproachID?
IF LAST ApproachID?
SeqLabC LAST XOpECDC EOL
ELSE
IF LAST ApproachOD? {around}
SeqLabC XCPC EOL
END
SeqLabC ZCPC EOL
SeqLabC XOpCDC EOL
END
CheckOffset
IDApproachSP
ELSE {ApproachFace}
IF LAST ApproachFace?
SeqLabC LAST ZOpECPC EOL
ELSE
IF LAST ApproachOD? {around}
SeqLabC XCPC EOL
ELSE {LAST ApproachID}
SeqLabC LAST XOpECDC EOL
END
SeqLabC ZCPC EOL
END
CheckOffset
FaceApproachSP
END
END
END
END
END
END {common point for all operations}
IF CannedCycle?
StockOff
IF Roughing?
IF RoughContour?
TagInc
SetPass2
SeqLabC IncValue EOL
{EachCycle} { Why EachCycle/NextCycle Loop? }
SeqLabC StepMove XSP ZSP EOL
SeqLabC '/Nł' Tag# EOL
{NextCycle}
OpenSub
'>' Tag# EOL
SeqLab FeedRate EOL
ToolPath
SeqLabC '/N0' EOL
CloseSub
SeqLabC AbsOrInc EOL
SeqLabC Rapid XCSP ZCSP EOL
IF AutoFinish?
SeqLabC '/Nł' Tag# EOL
END
END
ELSE
IF Drilling?
IF Tap?
SeqLabC '/F' FeedIPR# EOL
ELSE
IF FirstOperation? OR NewTool?
SeqLabC FeedRate EOL
ELSE
SeqLabC FeedRateC EOL
END
END
SeqLabC ZDepth Dwell Peck Retract LCycle EOL
IF FirstOperation? OR NewTool?
Approach
ELSE
SeqLabC FeedC ZSP EOL
END
SeqLabC DrillOff EOL
IF AutoFinish?
SeqLabC ZDepth Dwell Peck Retract LCycle EOL
SeqLabC DrillOff 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
RapidC
IF ApproachFace?
SeqLabC ZOpECPC EOL
FaceApproachSP
ELSE
SeqLabC XOpECDC EOL
IF ApproachOD?
ODApproachSP
ELSE {ApproachID}
IDApproachSP
END
END
ELSE
SetPass2
SeqLabC RapidC XSPC ZSPC EOL
END
SeqLabC StockOff StrtPosC EOL
ToolPath
END
END
IF Drilling? AND Tap?
SeqLabC SpinOff EOL
SeqLabC '/T2.' EOL
SeqLabC SpinOn EOL
END
END
NextOp {loops back to EachOP until last Operation}
{End of program ************************************************************}
{finish last operation}
StockOff
SeqLabC SpinOff EOL
IF CannedCycle?
Rapid
ELSE
RapidC
END
IF ApproachOD?
SeqLabC XCPC EOL
ELSE
IF ApproachID?
SeqLabC XOpECDC EOL
END
END
SeqLabC ZCPC EOL
DoEndOpPS
SeqLabC FirstHome EOL
SeqLabC 'T0' EOL
IF Equal? Recall# Num#('1') Num#('1') { First Turret Position }
ELSE
IF Equal? Recall# Num#('1') Num#('2') { Second Turret Position }
SeqLabC 'M20' EOL
SeqLabC 'M20' EOL
SeqLabC 'M20' EOL
ELSE
IF Equal? Recall# Num#('1') Num#('3') { Third Turret Position }
SeqLabC 'M20' EOL
SeqLabC 'M20' EOL
ELSE { Fourth Turret Position }
SeqLabC 'M20' EOL
END
END
END
IF ProgStop?
SeqLabC 'M0' EOL
END
SeqLabC EOP EOL
Post
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:
Bandit II [MDR] L231 82 4mBandit II Cadillac L070 82 3Alchemia II Rozdział 8Do W cyrkulacja oceaniczna II rokTest II III etap VIII OWoUERecht 5 BVerfG IIBandit IV AB [DM] MV32 89 1Fanuc 2000C Mazak L168 82Budownictwo Ogolne II zaoczne wyklad 13 ppozFanuc 10T MS [2 G54] L066 82Język niemiecki dwujęzyczna arkusz IIAngielski II zaliczenieprzetworniki II opracowaneMiBM Zestaw IIProgram wykładu Fizyka II 14 15Neural Network II SCILABwięcej podobnych podstron