{Change Comments ***********************************************************}
{5/28/90
Copied & modified: K & T 800 Gem D17 M186.72.1
For: Hughes E&DSG
Machine: Kierney & Trecker 600
Control: Gemini D17
Changed literal HomeZ value to 'Z20.0' at FirstOperation, NewTool and end of Prog.
Added 'M19', Key Lock, to ToolChng Block.
Changed all Feed/FeedC commands to Rapid/RapidC.
All Rapid Moves use Rapid/RapidC and RapidF/RapidFC.
All Feed Moves use Rapid/RapidC and FeedRate/FeedRateC.
Added FeedC to FormatArc sub.
ArcFeats only work in Feed Mode, not Rapid.
Changed OpToolID to 'T' ToolComment$ at FirstOperation and NewTool.
Control uses 5-digit OpToolID value, which User will enter in ToolComment$ of Tool List.
Commented out PreTool at FirstOperation and NewTool because of 5-digit OpToolID value.
Changed OfstOn to ZCP1 ToolOfst at FirstOperation, NewTool and SameTool.
Corrected MultipleParts endless loop bug.
Modified Drilling IF RetractToCP1? = TRUE
Will output G80, Rapid ZCP1, and CannedCycle Block for next PointFeat.
Deleted 3 Blocks prior to EOP at end of Prog.
JR}
{7/17/90
Copied & modified: K & T 600 GEM D17 M318.71
For: Hughes E&DSG
Deleted literal 'Z20.0M25' at SameTool, 2 places.
Added EOL at end of SameTool to avoid appending bug.
DWB}
{7/24/90, Replaced all occurances of SetSRXYZero with SetSRXYtoSP, DWB}
{6/24/92
Modified: K & T 600 GEM D17 M318.72
For: Gibbs & Associates
Updated to Version 4.1 per LongHand [AbsOrInc] M001.81 Format.
This supports both Absolute and Incremental output.
Changed Commented-out PreTool to 'T' PreToolComment$ at GetDrillOffset sub,
FirstOperation and NewTool.
DWB}
{12/23/93
Modified: K & T 600 GEM D17 M318.81
For: Hughes Electro-Optical & Data Systems Group
Changed ULF to OIF for ProgramName$.
Changed FormatArc to unconditionally output XYIJ info.
Jim Radcliffe}
{Prog Numeric Format Definitions *******************************************}
#1 = '#.00'
#2 = '###.###;0.'
#3 = '*###.###;0.'
#4 = '####.####;0'
#5 = '#######0'
#6 = '#;0.'
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(Tag#,5)
FORMAT(RapidF#,6)
{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
DoPartCycleComment:
IF UseComments? AND SubComment?
TagInc
'(MSG, START PART NO. ' Tag# ')' EOL
IF LastPart?
TagInit
END
END
RETURN
DoCycleComment:
IF UseComments? AND SubComment?
'(MSG, CYCLE START)' EOL
END
RETURN
DoOpComments:
IF UseComments?
SetScale('1')
IF OperationIDComment?
'(MSG, OPERATION ' Operation# ': ' OperationType$ ')' EOL
END
IF OperationComment?
'(MSG, ' OperationComment$ ')' EOL
END
IF WorkGroupComment?
'(MSG, ' WorkGroupComment$ ')' EOL
END
IF ToolTypeComment?
'(MSG, TOOL ' Tool# ': ' ToolDiameter# ' ' ToolType$ ')' EOL
END
IF ToolComment?
'(MSG, ' ToolComment$ ')' EOL
END
RestoreScale
END
RETURN
PSInit: {reset flags}
RotateF
RETURN
PSStuff: {revised.72}
IF FourthCW?
FORMAT(FourthDegree#,2)
SeqC 'A' FourthDegree# EOL
FourthCWF {reset flag}
END
IF FourthCCW?
FORMAT(FourthDegree#,3)
SeqC 'A' FourthDegree# EOL
FourthCCWF {reset flag}
END
IF FifthCW?
FORMAT(FifthDegree#,2)
SeqC 'B' FifthDegree# EOL
FifthCWF {reset flag}
END
IF FifthCCW?
FORMAT(FifthDegree#,3)
SeqC 'B' FifthDegree# EOL
FifthCCWF {reset flag}
END
RETURN
DoPostScript:
PSInit
EachPS
SeqC PostScript EOL {literals}
PSStuff {commands}
NextPS
RETURN
DoEndOpPS:
PSInit
EachEOPS
SeqC EndOpPS EOL {literals}
PSStuff {commands}
NextPS
RETURN
EntryMove:
IF FeedEntry?
SeqC RapidC ZIn FeedEntC EOL
ELSE
SeqC RapidC ZIn RapidFC EOL
END
RETURN
GetConnectFeedRate:
IF FeedConnect?
FeedEntC
ELSE
RapidFC
END
RETURN
ExitMove:
IF NOT FeedConnect?
IF FIFO? { .81 }
SeqC RapidC PRIME ZCP2C FeedEntC EOL
ELSE
SeqC RapidC PRIME ZCP2C RapidFC EOL
END
END
RETURN
ExitMove2:
IF FIFO?
SeqC RapidC ZCP3C FeedEntC EOL
ELSE
SeqC RapidC ZCP3C RapidFC EOL
END
RETURN
CycleWarning:
{ NOTE: This Post Processor takes care of Z Clearance. }
RETURN
FormatArc:
FeedC
IF ArcCW?
CWArc
ELSE
CCWArc
END
MoveXY MoveZC ArcIJ
RETURN
StdLine: {enables CRC on first call, .70}
IF Decelerate?
IF RoomToDecel?
DecelMove1
SeqC CRCOnC RapidC MoveXYZC FeedRateC EOL
DecelMove2
END
SeqC CRCOnC RapidC MoveXYZC DecelFeed EOL
ELSE
IF XMove? OR YMove? OR ZMove?
SeqC CRCOnC RapidC MoveXYZC FeedRateC EOL
END
END
RETURN
ToolPath:
EACHFeat
IF PointFeat? { Drilling Only }
IF NOT FirstFeat?
IF RetractToCP1?
SeqC DrillOff EOL
SeqC Rapid ZCP1 RapidF EOL
SeqC Cycle MoveSXYZC RLevel Peck FeedEnt EOL
END
END
SeqC MoveSXYZC EOL
ELSE
IF RapidFeat?
IF LastFeat? AND AutoCycle? {.70}
SeqC CRCOffC RapidC MoveXYZC RapidFC EOL
ELSE
IF XMove? OR YMove? OR ZMove?
SeqC RapidC MoveXYZC RapidFC EOL
END
END
ELSE
IF LineFeat?
IF AutoCycle? {.70}
IF LastFeat?
SeqC CRCOffC RapidC MoveXYZC FeedRateC EOL
ELSE
IF ZMove? {skip CRCOn until first non-Z move line, skipping ramps}
SeqC RapidC 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
SeqC FormatArc ArcFeedC EOL
DecelMove2
END
SeqC FormatArc DecelFeed EOL
ELSE
SeqC FormatArc ArcFeedC EOL
END
NEXTQuadrant
END
END
IF LastFeat? AND CutterRadiusCompensation? AND NOT AutoCycle?
SeqC RapidC CRCOffC LastFeatExtend EOL
END
END
END
NEXTFeat
RETURN
WFOStuff: { FirstOperation only }
SeqC '(ZTB,H)' EOL { WorkFixtureOffsetOff }
SeqC '(OIF,' ProgramName$ ')' EOL { User Load FixtureOffset }
RETURN
AutoCycCutSub1: {part 1}
CalcACSRXY {calc tool position, CalcAutoCycleStatusRecordXY}
SaveSubStatus {save tool position}
SetPass1 {element cut moves}
SetSRXYtoSP
SeqC IncValue EOL
RETURN
AutoCycCutSub2: {part 2}
IF FIFO? {.81}
SeqC AbsOrInc RapidC ZCP2 FeedEntC EOL {.71.2 removed CRCOffC, gets turned off in ToolPath}
ELSE
SeqC AbsOrInc RapidC ZCP2 RapidFC EOL
END
SetSRSubXY {restore SR to 1st position value}
ReSetPass2 {restore for positioning moves}
RETURN
Milling:
EntryMove
ToolPath
RETURN
XYZRep:
CycleWarning
EachRep
IF NOT FirstCycle?
SeqC RapidC StrtPosC GetConnectFeedRate EOL
END
DoCycleComment
IF NOT FirstCycle? AND NOT FeedConnect? AND FeedEntry?
SeqC ZCP2C EOL
END
Milling
ExitMove
NextRep
RETURN
NoRepAutoCycle:
EACHFeat
IF SPXMove? OR SPYMove?
SeqC RapidC MoveSXYC RapidFC EOL
END
AutoCycCutSub1
DoCycleComment
Milling
AutoCycCutSub2
NEXTFeat
RETURN
XYZRepAutoCycle:
CycleWarning
EachRep
EACHFeat
IF SPXMove? OR SPYMove?
SeqC RapidC MoveSXYC GetConnectFeedRate EOL
END
AutoCycCutSub1
DoCycleComment
Milling
AutoCycCutSub2
NEXTFeat
NextRep
RETURN
ZonlyRepAutoCycle:
EACHFeat
IF SPXMove? OR SPYMove?
SeqC RapidC MoveSXYC GetConnectFeedRate EOL
END
AutoCycCutSub1
EachRep
IF FirstCycle?
DoCycleComment
EntryMove
ELSE
IF NOT FeedConnect?
ExitMove
END
IF SPXMove? OR SPYMove?
SeqC RapidC MoveSXYC GetConnectFeedRate EOL
END
DoCycleComment
IF NOT FeedConnect?
EntryMove
END
END
ToolPath
NextRep
AutoCycCutSub2
ReSetPass2 {restore for positioning moves}
NEXTFeat
RETURN
DoDrillOffset:
IF FirstOperation? OR NewTool?
ToolOfst
ELSE
IF NewToolOffset?
ToolOfst
END
END
RETURN
GetDrillOffset:
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
IF FirstPart?
DoDrillOffset
END
ELSE
IF Repeats?
IF FirstCycle?
DoDrillOffset
END
ELSE
IF FirstOperation?
Speed
IF NOT LastTool?
'T' PreToolComment$
END
SpinOn CoolOn
ELSE
IF NewTool?
Speed 'T' PreToolComment$ SpinOn CoolOn
ELSE
IF SameTool?
IF LAST ProgStop?
Speed SpinOn CoolOn
ELSE
SpeedC
IF NOT CoolOff? AND LAST CoolOff?
CoolOn
END
END
END
END
END
DoDrillOffset
END
END
RETURN
DrillStuff:
GetCycle
IF Repeats?
IF RetractToCP1?
SeqC Cycle StrtPos ZDepth RLevel Peck FeedEnt GetDrillOffset EOL
TrackZNO# ZDepth# {.81}
ELSE
IF FirstCycle?
SeqC Cycle StrtPos ZDepth RLevel Peck FeedEnt GetDrillOffset EOL
TrackZNO# ZDepth# {.81}
END
END
ELSE
SeqC Cycle StrtPos ZDepth RLevel Peck FeedEnt GetDrillOffset EOL
TrackZNO# ZDepth# {.81}
END
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
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?
'(NAM, ' ProgramName$ ')' EOL
END
IF ProgramComment?
'(MSG, ' ProgramComment$ ')' EOL
END
IF FormatNameComment?
'(MSG, FORMAT: ' FormatName$ ')' EOL
END
IF TimeComment?
'(MSG, ' Date$ ' AT ' Time$ ')' EOL
END
IF MovesComment?
'(MSG, OUTPUT IN ' MoveType$ ' INCHES)' EOL
END
IF PartsComment?
'(MSG, PARTS PROGRAMMED: ' Parts# ')' EOL
END
IF StartToolComment?
'(MSG, FIRST TOOL NOT IN SPINDLE)' EOL
END
END
OpenSub
RestoreScale
WFOStuff
IF MultipleParts? AND AllToolsOnePart?
EachPart
DoPartCycleComment
END
SeqC Plane 'G70' AbsOrInc 'G80G94' EOL
SeqC Rapid 'Z20.0M25' RapidF EOL
IF ToolChangeAtHome?
SeqC Home 'M25' EOL
END
DoOpComments
Seq 'T' ToolComment$ EOL { OpToolID }
SeqC 'M19' ToolChng EOL
DoPostScript
IF MultipleParts? AND OneToolAllParts? AND FullUp?
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
END
END
CheckPass
IF Milling?
SeqC AbsOrInc Rapid StrtPos RapidF Speed
IF NOT LastTool?
'T' PreToolComment$
END
SpinOn CoolOn EOL
SeqC ZCP1 ToolOfst EOL { OfstOn }
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
CheckPass
SeqC RapidC StrtPos RapidFC EOL
END
END
ELSE
IF Drilling?
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
SeqC Speed
IF NOT LastTool?
'T' PreToolComment$
END
SpinOn CoolOn EOL
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
END
ELSE
IF Repeats?
SeqC Speed
IF NOT LastTool?
'T' PreToolComment$
END
SpinOn CoolOn EOL
END
END
END
END
ELSE
IF NewTool?
{Finish off last Operation}
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
NextPart
END
SeqC CoolOff EOL
SeqC RapidC 'Z20.0M25' RapidFC EOL { IncValue OfstOff }
IF MultipleParts? AND OneToolAllParts? AND FullUp?
NextPart
END
DoEndOpPS
IF ToolChangeAtHome?
SeqC Home 'M25' EOL
END
IF LAST ProgStop?
SeqC 'M0' EOL
ELSE
SeqC ProgStop EOL
END
{Start new Operation}
DoOpComments
Seq 'T' ToolComment$ EOL { OpToolID }
SeqC 'M19' ToolChng EOL
DoPostScript
IF MultipleParts? AND OneToolAllParts? AND FullUp?
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
END
END
CheckPass
IF Milling?
SeqC AbsOrInc PlaneC Rapid StrtPos RapidF Speed 'T' PreToolComment$ SpinOn CoolOn EOL
SeqC ZCP1 ToolOfst EOL { OfstOn }
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
CheckPass
SeqC RapidC StrtPos RapidFC EOL
END
END
ELSE
IF Drilling?
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
SeqC Speed 'T' PreToolComment$ SpinOn CoolOn EOL
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
END
ELSE
IF Repeats?
SeqC Speed 'T' PreToolComment$ SpinOn CoolOn EOL
END
END
END
END
ELSE
IF SameTool?
DoEndOpPS
IF LAST ProgStop?
SeqC CoolOff EOL
SeqC 'M0' EOL
{Start new Operation}
GetStartOfSameTool
IF Milling?
SeqC PlaneC RapidC StrtPos RapidFC SpeedC SpinOn CoolOn EOL
SeqC ZCP1 ToolOfst EOL { OfstOn }
ELSE
IF Drilling?
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
SeqC Speed SpinOn CoolOn EOL
ELSE
IF Repeats?
SeqC Speed SpinOn CoolOn EOL
END
END
END
END
ELSE
IF CoolOff? AND LAST NOT CoolOff?
SeqC CoolOff EOL
END
{Start new Operation}
GetStartOfSameTool
IF Milling?
SeqC PlaneC RapidC StrtPos RapidFC SpeedC
IF NOT CoolOff? AND LAST CoolOff?
CoolOn
END
EOL
IF NewToolOffset?
SeqC ZCP1 ToolOfst EOL { OfstOn }
END
ELSE
IF Drilling?
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
SeqC SpeedC EOL
ELSE
IF Repeats?
SeqC SpeedC EOL
END
END
END
END
END
END
END
END {common point for all operations}
ResetCRCNum {.72}
IF Milling?
SeqC ZCP2C EOL
IF AutoCycle?
IF Repeats?
IF ZshiftOnly?
ZonlyRepAutoCycle
ELSE
XYZRepAutoCycle
END
IF NOT FeedConnect?
ExitMove2
END
ELSE
NoRepAutoCycle
ExitMove2
END
ELSE { NOT AutoCycle }
IF Repeats?
XYZRep
ELSE
Milling
END
ExitMove2
END
ELSE
IF Drilling?
IF Repeats?
EachRep
IF NOT FirstCycle?
IF RetractToCP1?
SeqC DrillOff EOL
SeqC Rapid ZCP1 RapidF EOL
END
END
DoCycleComment
DrillStuff
ToolPath
NextRep
ELSE
DrillStuff
ToolPath
END
SeqC DrillOff EOL
SeqC Rapid ZCP3 RapidF EOL
END
END
IF MultipleParts? AND LastOp?
{End of program ************************************************************}
{finish last operation}
IF OneToolAllParts? AND ExitClearancePlane?
NextPart
END
SeqC CoolOff EOL
SeqC RapidC 'Z20.0M25' RapidFC EOL { IncValue OfstOff }
IF OneToolAllParts? AND FullUp?
NextPart
END
DoEndOpPS
IF FIRST ToolChangeAtHome? {.71.2 added FIRST modifier}
SeqC FirstHome 'M25' EOL
END
IF ProgStop?
SeqC 'M0' EOL
END
IF AllToolsOnePart?
NextPart
END
ELSE { NOT MultipleParts }
NextOp {loops back to EachOP until last Operation}
{End of program ************************************************************}
{finish last operation}
SeqC CoolOff EOL
SeqC RapidC 'Z20.0M25' RapidFC EOL { IncValue OfstOff }
DoEndOpPS
IF FIRST ToolChangeAtHome? {.71.2 added FIRST modifier}
SeqC FirstHome 'M25' EOL
END
IF ProgStop?
SeqC 'M0' EOL
END
END
SeqC EOP EOL
Post
Close
IF UseComments?
SetScale('1') {restore scale for comments}
Reopen
IF FileBytesComment?
'(MSG, FILE LENGTH: ' FileBytes# ' CHARACTERS)' EOL
END
IF FileFeetComment?
'(MSG, FILE LENGTH: ' FileFeet# ' FEET)' EOL
END
IF FileMetersComment?
'(MSG, FILE LENGTH: ' FileMeters# ' METERS)' EOL
END
Close
END
Wyszukiwarka
Podobne podstrony:
K & T 800 Gem D17 LH D186 12mK & T 800 Gem D17 M186 87Fanuc 10M (AGA) M147 81 2Tosnuc 600M VMC 45 M442 81 3DM 81 Diper KenwoodaBP IIA (HAC) M200 81sirio 60030 (81)Artran Contour MV83 81Yas MX3 Mat [AbsZAC] M591 81 2SUZUKI GSXR 600 750więcej podobnych podstron