{Change Comments ***********************************************************}
{12/18/89
Modified: Bostomatic SPC-II (1) M122.56
For: MDM
Updated per Fanuc 6M M001.64
Updated, PostScript commented out & SepSubs omitted.
IF Drilling? Changes:
Added Preset ZCP1 at start.
Output 'R' with DrillCP only IF NOT EmptyLine?.
Added IncValue 'X.0002Y.0002R' to force canned drill cycles to make a move so that control will
drill at StrtPos. See Bostomatic (HAC) M221.64.
Changed 'G94D81' to 'G81'.
Added 'G80R' after ToolPath command.
Output 'R' with FeedC ZCP3C outputs something at end only IF NOT EmptyLine?.
JR}
{2/7/90, Updated to Version 3.2 per Fanuc 6M M001.70 Format, DWB}
{7/24/90, Added InitProg globally to posts with this remark, DWB}
{7/24/90, Replaced all occurances of SetSRXYZero with SetSRXYtoSP, DWB}
{12/21/90
Copied & modified: Bostomatic 312 M122.71
For: Gibbs & Associates
Machine: Bostomatic
Control: 312
Updated to Version 3.2 per Fanuc 6M M001.76.1 Format.
DWB}
{4/03/91
Modified: Bostomatic 312 M122.76.1
For: Gibbs & Associates
Updated to Version 4.0 per Fanuc 6M M001.80 Format.
DWB}
{11/10/92
Copied & modified: Bostomatic 312 M122.79
Created metric version:
Changed all axis formats in MachSpec from a 3.4 to 4.3
Changed FORMAT #8 in Prog from '+##^0000' to '+###^000'
Changed 'X.0002Y.0002R' in Drilling to 'X.005Y.005'
Added ' MILLIMETERS' to MovesComment
Changed IF Metric? statments in Prog 2 Places.
Jim Radcliffe}
{Prog Numeric Format Definitions *******************************************}
#1 = '#.00'
#2 = '###.###;0.'
#3 = '*###.###;0.'
#4 = '####.####;0.'
#5 = '########;0'
#6 = '####^###;'
#7 = '##^0'
#8 = '+###^000'
FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(ToolDiameter#,4) {.72}
FORMAT(Program#,5) {.72}
FORMAT(Operation#,5) {.72}
FORMAT(Tool#,5) {.72}
FORMAT(Parts#,5) {.72}
FORMAT(Repeats#,5) {.72}
FORMAT(Dwell#,6) {.72}
FORMAT(FeedEntry#,7)
FORMAT(ZDepth#,8)
{Prog Subroutines **********************************************************}
DoSubComment:
IF UseComments? AND SubComment?
' SUB NUMBER: ' Program# EOL
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# ': ' ToolDiameter# ' ' ToolType$ EOL
END
IF ToolComment?
' ' ToolComment$ EOL
END
IF NOT Metric? {CAM file is in English, tools and tool path}
SetScale('25.4') { change to Metric, this is a Metric post}
END
END
RETURN
PSInit: {reset flags}
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
DoR: {Rapid moves need 'R'}
IF NOT EmptyLine?
'R'
END
RETURN
EntryMove:
IF FeedEntry?
SeqLabC FeedC ZIn FeedEnt EOL
ELSE
SeqLabC FeedC ZIn DoR EOL
END
RETURN
StartSub:
OpenSub
DoSubComment
SeqLab 'G92' SubID EOL
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 CallLab RepLab RepCycs EOL
StartSub
RETURN
FinishSub1: {part 1}
UnSkipZ
IF NOT FeedConnect?
SeqLabC FeedC ZCP3C DoR EOL
END
RETURN
FinishSubG92: {part 2}
SeqLabC Preset ShiftRC EOL
SeqLabC EndSub EOL
CloseSub
SeqLabC Preset UnshftRC EOL
RETURN
OpenMP:
NewProg
SeqLabC SubCall CallLab RepLab Parts EOL
StartSub
RETURN
CloseMP:
SeqLabC Preset ShiftPC EOL
SeqLabC EndSub EOL
CloseSub
SeqLabC Preset UnshftPC EOL
RETURN
FormatArc:
IF ArcCW?
CWArcC
ELSE
CCWArcC
END
IF XYPlane?
MoveX MoveY MoveZC
ELSE
IF XZPlane?
MoveX MoveYC MoveZ
ELSE
MoveXC MoveY MoveZ
END
END
ArcIJ
RETURN
StdLine: {enables CRC on first call, .70}
IF Decelerate?
IF RoomToDecel?
DecelMove1
SeqLabC CRCOnC FeedC MoveXYZC FeedRateC EOL
DecelMove2
END
SeqLabC CRCOnC FeedC MoveXYZC DecelFeed EOL
ELSE
IF XMove? OR YMove? OR ZMove?
SeqLabC CRCOnC FeedC MoveXYZC FeedRateC EOL
END
END
RETURN
ToolPath:
EACHFeat
IF PointFeat?
IF AutoCycle?
SeqLabC MoveSXYC DoR EOL
SeqLabC SubCall CallLab 'D1' EOL
CalcACSRXY {calc tool position after sub call, CalcAutoCycleStatusRecordXY}
ELSE
IF NOT FirstFeat?
SeqLabC MoveSXYC DoR EOL
SeqLabC Cycle EOL
END
END
ELSE
IF RapidFeat?
IF LastFeat? AND AutoCycle? {.70}
SeqLabC CRCOffC FeedC MoveXYZC DoR EOL
ELSE
IF XMove? OR YMove? OR ZMove?
SeqLabC FeedC MoveXYZC DoR EOL
END
END
ELSE
IF LineFeat?
IF AutoCycle? {.70}
IF LastFeat?
SeqLabC CRCOffC FeedC MoveXYZC FeedRateC EOL
ELSE
IF ZMove? {skip CRCOn until first non-Z move line, skipping ramps}
SeqLabC FeedC MoveXYZC FeedRateC EOL
ELSE
StdLine {enables CRC on first call}
END
END
ELSE
StdLine
END
ELSE
IF ArcFeat?
EACHQuadrant { Do not use NOT, FIRST, LAST or NEXT modifiers in this loop }
IF LastQuadrant? AND Decelerate?
IF RoomToDecel?
DecelMove1
SeqLabC FormatArc ArcFeedC EOL
DecelMove2
END
SeqLabC FormatArc DecelFeed EOL
ELSE
SeqLabC FormatArc ArcFeedC EOL
END
NEXTQuadrant
END
END
END
END
NEXTFeat
RETURN
WFOStuff:
{Note: This processor does not support work fixture offsets.}
RETURN
AutoCycCutSub1: {part 1}
SaveSubStatus {save tool position}
SetPass1 {element cut moves}
StartSub
SetSRXYtoSP
SeqLab IncValue EOL
RETURN
AutoCycCutSub2: {part 2}
ToolPath
IF Repeats? AND FeedConnect? AND ZshiftOnly?
SeqLabC AbsOrInc EOL {.69 removed RapidC} {.71.2 removed CRCOffC, gets turned off in ToolPath}
ELSE
SeqLabC AbsOrInc FeedC ZCP2 DoR EOL {.71.2 removed CRCOffC, gets turned off in ToolPath}
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?
NewProg
AutoCycCutSub1
EntryMove
AutoCycCutSub2
AutoCycPat
ELSE
EntryMove
ToolPath
IF CutterRadiusCompensation?
SeqLabC FeedC CRCOff LastFeatExtend EOL
END
END
RETURN
G92Sub:
SubWarning
StdSub
SeqLabC AbsOrInc Feed StrtPos
IF NOT FeedConnect?
DoR
END
EOL
Milling
FinishSub1
FinishSubG92
RETURN
ZonlyRepAutoCycle:
AutoCycPat {write pattern moves and main calls}
StartSub
NewProg
EachCycle
IF FeedConnect?
SeqLabC FeedC ZInPlusInc FeedEnt EOL
ELSE
IF FeedEntry?
IF NOT FirstCycle?
SeqLabC FeedC ZCP2PlusInc DoR EOL {.69 added Rapid, reads better}
{can't call for cycle = 1, .69 changed to ZCP2PlusInc}
END
SeqLabC FeedC ZInPlusInc FeedEnt EOL
ELSE
SeqLabC FeedC ZInPlusInc DoR EOL {.69 added Rapid, reads better}
END
END
IF FirstCycle?
SetStatusOff {protect Z position for incremental sub}
END
SeqLabC SubCall CallLab 'D1' EOL
NextCycle
SetStatusOn
AutoCycCutSub1 {build element sub}
AutoCycCutSub2
{.69, removed FinishSub1}
IF FeedConnect? {there is no Z up in the sub, .69}
SeqLabC FeedC ZCP2 DoR EOL {.69}
END {.69}
SeqLabC EndSub EOL
CloseSub
{Element shift, not pattern}
RETURN
ZonlyRep:
EachCycle
IF NOT FirstCycle?
SeqLabC FeedC StrtPos {.71.2, added Feed}
IF NOT FeedConnect?
DoR
END
EOL
END
IF FeedConnect?
SeqLabC FeedC ZInPlusInc FeedEnt EOL {.71.2, changed to FeedC}
ELSE {Entry/Exit Connect}
IF FeedEntry?
IF NOT FirstCycle?
SeqLabC FeedC ZCP2PlusIncC DoR EOL {can't call for cycle =1} {.69 added Rapid, reads better} {.71.2, changed to RapidC, reads better}
END
SeqLabC FeedC ZInPlusInc FeedEnt EOL
ELSE
SeqLabC FeedC ZInPlusInc DoR EOL {.69 added Rapid, reads better} {.71.2, changed to RapidC, reads better}
END
END
SeqLabC SubCall CallLab 'D1' EOL
NextCycle
StartSub
SkipZ
ToolPath
IF CutterRadiusCompensation?
SeqLabC FeedC CRCOff LastFeatExtend EOL
END
FinishSub1
SeqLabC EndSub EOL
CloseSub
RETURN
CheckPass:
IF AutoCycle? {use the correct StrtPos}
SetPass2
ELSE
SetPass1
END
RETURN
GetStartOfSameTool:
DoOpComments
DoPostScript
CheckPass
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
IF ToolChangeAtHome?
SetHome
END
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$ ' MILLIMETERS' EOL
END
IF PartsComment?
' PARTS PROGRAMMED: ' Parts# EOL
END
IF StartToolComment?
' FIRST TOOL IN SPINDLE' EOL
END
END
OpenSub
IF NOT Metric? {CAM file is in English, tools and tool path}
SetScale('25.4') { change to Metric, this is a Metric post}
END
IF MultipleParts? AND AllToolsOnePart?
OpenMP
END
SeqLab ' START OF MAIN PROGRAM' EOL
SeqLabC AbsOrInc Feed Plane CRCOff 'G49' EOL
DoOpComments
DoPostScript
SeqLabC ProSpeed SpinOn EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
OpenMP
END
CheckPass
SeqLabC StrtPos DoR EOL
SeqLabC OpToolID 'G48R' EOL
SeqLabC CoolOn EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
OpenMP
SeqLabC StrtPos DoR EOL
END
ELSE
IF NewTool?
{Finish off last Operation}
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
CloseMP
END
SeqLabC CoolOff EOL
SeqLabC 'G49R' EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
CloseMP
END
DoEndOpPS
IF ToolChangeAtHome?
SeqLabC FeedC Home SpinOff DoR EOL
ELSE
SeqLabC SpinOff EOL
END
IF LAST ProgStop?
SeqLabC 'M00' EOL
ELSE
SeqLabC ProgStop EOL
END
{Start new Operation}
DoOpComments
SeqLab OpToolID ToolChng EOL
DoPostScript
SeqLabC Plane ProSpeed SpinOn EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
OpenMP
END
CheckPass
SeqLabC Feed AbsOrInc StrtPos DoR EOL
SeqLabC OpToolID 'G48R' EOL
SeqLabC CoolOn EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
OpenMP
SeqLabC StrtPos DoR EOL
END
ELSE
IF SameTool?
DoEndOpPS
IF LAST ProgStop?
SeqLabC CoolOff EOL
SeqLabC 'G49R' EOL
SeqLabC SpinOff EOL
SeqLabC 'M00' EOL
{Start new Operation}
GetStartOfSameTool
SeqLabC Feed PlaneC AbsOrInc StrtPos ProSpeed SpinOn DoR EOL
SeqLabC OpToolID 'G48R' EOL
SeqLabC CoolOn EOL
ELSE
IF CoolOff? AND LAST NOT CoolOff?
SeqC CoolOff EOL
END
IF NewToolOffset?
SeqLabC 'G49R' EOL
{Start new Operation}
GetStartOfSameTool
SeqLabC Feed PlaneC AbsOrInc StrtPos ProSpeed DoR EOL
SeqLabC OpToolID 'G48R' EOL
ELSE
{Start new Operation}
GetStartOfSameTool
SeqLabC Feed PlaneC AbsOrInc StrtPos ProSpeed DoR EOL
END
IF NOT CoolOff? AND LAST CoolOff?
SeqC CoolOn EOL
END
END
END
END
END {common point for all operations}
IF Milling?
SeqLabC FeedC ZCP2C DoR EOL
IF Repeats?
NewProg
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}
Milling
END
SeqLabC FeedC ZCP3C DoR EOL
ELSE
IF Drilling?
SeqLabC Preset ZCP1 EOL
IF Repeats?
NewProg
StdSub
SeqLabC AbsOrInc FeedC StrtPos DoR EOL
END
SeqLabC DrillCP DoR EOL
GetCycle
SeqLabC 'V60D' ZDepth# EOL
SeqLabC 'V64' RLevel EOL
SeqLabC 'V67D' FeedEntry# EOL
IF Peck?
SeqLabC 'V63' Peck EOL
END
SeqLabC IncValue 'X.005Y.005R' EOL {see comment above}
SeqLabC AbsOrInc EOL
SeqLabC StrtPos DoR EOL
SeqLabC Cycle EOL
ToolPath
SeqLabC 'G80R' EOL
IF Repeats?
FinishSubG92
END
SeqLabC FeedC ZCP3C DoR EOL
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
SeqLabC 'G49R' EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
CloseMP
END
DoEndOpPS
IF FIRST ToolChangeAtHome? {.71.2 added FIRST modifier}
SeqLabC FeedC FirstHome SpinOff DoR EOL
ELSE
SeqLabC SpinOff EOL
END
IF ToolOver? ('1')
SeqLabC UnTool ToolChng EOL
END
IF ProgStop?
SeqC 'M00' EOL
END
IF MultipleParts? AND AllToolsOnePart?
CloseMP
END
IF UseComments?
SetScale('1') {restore scale for comments}
IF FileBytesComment?
' FILE LENGTH: ' FileBytes# ' CHARACTERS' EOL
END
IF FileFeetComment?
' FILE LENGTH: ' FileFeet# ' FEET' EOL
END
IF FileMetersComment?
' FILE LENGTH: ' FileMeters# ' METERS' EOL
END
END
SeqLabC EOP EOL
CloseSub
Post2 {organize Subs into one program}
Close
Retag
Wyszukiwarka
Podobne podstrony:
Bostomatic 312 M122 79Bostomatic 312 4K M532 79312[01] 03 122 Karta pracy egzaminacyjnej312[01]312[01] 01 081 STYCZEŃ 2008SHSpec 312 6310C15 Essentials of Auditing308 312 eth6ipyjabxlyqdlw3dgbeqgwx7wezxz3uyrzdawięcej podobnych podstron