Anomatic II Ano [QI] M578 87m


{Change Comments ***********************************************************}

{6/16/93
Notes from: Anomatic II Anorad M406.81.3m
2 Axis with Z Rotary Table.
Turn Laser on to cut, off to position.
All Comments start with literal 'G69'.
WFO's by request only, activated by MP or PS.
FeedRates are inches per second, taken directly from CAM.
FullUp & ExitClearancePlane in ncPost will have the same effect.
No CRC.
Feeds called on line prior to axis move.
2 G codes per line maximum?
F900 for RapidF.
M Codes Prog Command Effect
106 SpinOn Laser On
107 SpinOff Laser Off
108 ------ Shutter Open (allows laser thru)
109 ------ Shutter Closed
110 ------ Optional Gas On
111 ------ Optional Gas Off
114 CoolOn Gas On
115 CoolOff Gas Off
DWB}

{6/16/93
Copied & modified: Anomatic II Anorad M406.81.3m
For: Quasar Industries
Machine: Anorad 6 CO2 Laser
Control: Anomatic II Level III
Changes made per conversations with Dave Krajci at Quasar Industries.
M Codes Prog Command Effect
114 ------ Shutter Open (allows laser thru)
115 ------ Shutter Closed
118 CoolOn Gas On
119 CoolOff Gas Off
Added FORMAT#7 = '###^#0' for FeedContour# and FeedEntry#.
Added literal 'V1=#' where # =FeedContour# and FeedEntry# for Milling and Drilling Operations.
V1 is FeedRate Variable which stores FeedContour# and FeedEntry# values.
Deleted output at EntryMove.
Added OptCyc1 PostScript Command.
Used for Drilling Operations only.
Customer has subroutines that contain variables for machining of standard Hole patterns.
Will output call to literal sub 'KN7000' following every move.
Will output literal 'Hole' instead of OperationType$ at DoOpComments.
Added SetRapidF sub which outputs literal 'FX' RapidF# 'FY' RapidF#.
This sets Table Axis FeedRates to maximum.
Added SetFeedRate sub which outputs literal 'FV1'.
This sets FeedRate to stored value contained in FeedRate Variable.
Added SecScale('1') and ResetScalle.
Changed literal 'M108' to 'M114' at OpenShutter sub.
Changed literal 'M109' to 'M115' at CloseShutter sub.
Changed CoolOn from M114 to M118 in Mach Spec.
Changed CoolOff from M115 to M119 in Mach Spec.
Deleted output at ExitMove.
Added ' ' EOL to SeqLab at StartSub.
Moved call to DoSubComment following SeqLab at StartSub.
NOTE: TagInc does not work for Nested Autocycle Repeats Sub.
Changed all TagInc with Save# Num#('1') ADD# Recall# Num#('1') Num#('1')
Changed all Tag# with Recall# Num#('1')
Added blank lines between Operations and SubPrograms.
Added CkArcMove sub.
This sub checks to make sure ArcIJ is GTEqual Minimum resolution.
If ArcIJ is LessThan, Flag(1) is set and call to StdLine instead of ArcMoves.
Deleted FeedRateC at StdLine.
Added call to SetFeedRate following DecelMove at StdLine.
Added AbsOrInc to MoveSXYC at ToolPath AutoCycle PointFeat.
Added test for OptCyc1 at ToolPath Drilling PointFeat.
Added 'KN1' at ToolPath FirstFeat.
Added 'F(V1-20)' at ToolPath FirstFeat.
This subtracts 20 from stored value.
Added call to SetRapidF at ToolPath RapidFeat.
Deleted RapidF at ToolPath RapidFeat.
Changed all ocurrances of Rapid/RapidC to Feed/FeedC.
Added call to SetFeedRate at ToolPath LineFeat.
Deleted FeedRate at ToolPath LineFeat.
Deleted FeedRateC at ToolPath ArcFeat.
Added call to SetFeedRate following DecelMove at ToolPath ArcFeat.
Added call to SetFeedRate following output of FirstFeat at ToolPath.
Added literal 'G9' following output of FirstFeat at ToolPath.
Added literal 'G0' following output of LastFeat at ToolPath.
G9 sets control into Continuous Velocity - No Deceleration.
G0 cancels G9.
Added 'KN2' at ToolPath LastFeat.
Added call to SetRapidF at ToolPath LastFeat.
Changed Connect to AbsOrInc at G92Sub.
Added StartProgCode sub to output miscellaneous codes at beginning of output.
Added EndProgCode sub to output miscellaneous codes at end of output.
Calling DoPostScript prior to DoOpComments for correct handling of OperationType$.
Changed Rapid RapidF to AbsOrInc at StrtPos at FirstOperation, NewTool and SameTool.
DWB}

{2/23/94
Modified: Anomatic II Ano [QI] M578.81.3m
For: 3 Dimensional Services
Versions: ncCad 4.32/ncCAM 4.32/ncPost 4.32.02/Compost 4.21.20
Changes made per Dave Krajci at 3 Dimensional Services.
M Codes Prog Command Effect
122 ------ Shutter Open (allows laser thru)
123 ------ Shutter Closed
Changed literal 'M114' to 'M122' at OpenShutter sub, see 6/16/93.
Changed literal 'M115' to 'M115' at CloseShutter sub, see 6/16/93.
Changed literal 'G4X.2' to 'G4X1' when calling OpenShutter sub at EndProgCode sub.
Deleted literal 'G4X.2' when calling CloseShutter sub at EndProgCode sub.
Simplified logic for setting Flag(1) at CkArcMove sub.
Customer requested ToolPath to be output incrementally at all times.
Works IF AbsoluteMoves? AND NOT AutoCycle? = TRUE.
Added IncValue at start of ToolPath.
Added AbsValue at end of ToolPath.
Commented out SetAbsOrInc for Non-AutoCycle operations at CkArcMove sub.
Added missing SeqLabC commands
Added EndSub at start of EndProgCode sub.
EndSub outputs M6.
DWB}

{2/9/96, Updated .81 number to .84, no changes necessary, MPK}

{3/22/96, Updated .84 version to .87, TH}

{Prog Numeric Format Definitions *******************************************}

#1 = '#.00'
#2 = '###.####;0'
#3 = '*###.####;0'
#4 = '#####.###;0'
#5 = '#######0'
#6 = '####^##0'
#7 = '###^#0'

FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(ToolDiameter#,4) {.72}
FORMAT(Tag#,5)
FORMAT(Recall#,5)
FORMAT(Program#,5) {.72}
FORMAT(Operation#,5) {.72}
FORMAT(Tool#,5) {.72}
FORMAT(NewWFO#,5) {.72}
FORMAT(Parts#,5) {.72}
FORMAT(Dwell#,6) {.72}
FORMAT(FeedContour#,7)
FORMAT(FeedEntry#,7)

{Prog Subroutines **********************************************************}

RestoreScale:
IF NOT Metric? {CAM file is in English, tools and tool path}
SetScale('25.4') { change to Metric, this is an Metric post}
END
RETURN

DoSubComment:
IF UseComments? AND SubComment?
NewProg { Update Program# }
'G69 SUB NUMBER: ' Program# EOL
END
RETURN

DoOpComments:
IF UseComments?
SetScale('1')
IF OperationIDComment?
'G69 OPERATION ' Operation# ': '
IF Drilling? AND OptCyc1?
'Hole'
ELSE
OperationType$
END
EOL
END
IF OperationComment?
'G69 ' OperationComment$ EOL
END
IF WorkGroupComment?
'G69 ' WorkGroupComment$ EOL
END
IF ToolTypeComment?
'G69 TOOL ' Tool# ': ' ToolDiameter# ' ' ToolType$ EOL
END
IF ToolComment?
'G69 ' ToolComment$ EOL
END
RestoreScale
END
RETURN

PSInit: {reset flags}
NewWFOF
RotateF
OptCyc1F { For Drilling only, Custom Hole Machining Sub }
RETURN

PSStuff: {revised.72}
IF FourthCW?
FORMAT(FourthDegree#,2)
SeqLabC 'Z' FourthDegree# EOL
FourthCWF {reset flag}
END
IF FourthCCW?
FORMAT(FourthDegree#,3)
SeqLabC 'Z' FourthDegree# EOL
FourthCCWF {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

LaserOn:
'M106'
RETURN

LaserOff:
'M107'
RETURN

OpenShutter: { Allows Laser thru }
'M122'
RETURN

CloseShutter:
'M123'
RETURN

OptGasOn:
'M110'
RETURN

OptGasOn:
'M111'
RETURN

GasOn:
CoolOn { M118 }
RETURN

GasOff:
CoolOff { M119 }
RETURN

EntryMove:
{ NOT Needed }
RETURN

ExitMove:
{ NOT Needed }
RETURN

StartSub:
OpenSub
' ' EOL
'>' Recall# Num#('1') EOL
SeqLab ' ' EOL { unconditional for Proper Tagging }
DoSubComment
RETURN

SubWarning:
{ NOT Needed }
RETURN

StdSub:
SeqLabC CallLabB 'ł' Recall# Num#('1') RepLab RepCycs EOL
StartSub
RETURN

FinishSub1: {part 1}
IF NOT FeedConnect?
IF NOT AutoCycle?
ExitMove
END
END
RETURN

FinishSubG92: {part 2}
SeqLabC Preset ShiftRC EOL
SeqLabC EndSub EOL
CloseSub
SeqLabC Preset UnshftRC EOL
RETURN

OpenMP:
Save# Num#('1') ADD# Recall# Num#('1') Num#('1') { TagInc }
IF WorkFixtureOffsets?
NewWFO
EachWFO
SeqLabC SetWFO EOL
SeqLabC CallLabB 'ł' Recall# Num#('1') RepLab OnePart EOL
IncWFO
NextWFO
ELSE
SeqLabC CallLabB 'ł' Recall# Num#('1') RepLab Parts EOL
END
StartSub
RETURN

CloseMP:
IF WorkFixtureOffsets?
SeqLabC EndSub EOL
CloseSub
SeqLabC WFO1 EOL
ELSE
SeqLabC Preset ShiftPC EOL
SeqLabC EndSub EOL
CloseSub
SeqLabC Preset UnshftPC EOL
END
RETURN

CkArcMove:
SetInc
SetStatusOff
IF LessThan? ABS# ArcI# Num#('.0005')
IF LessThan? ABS# ArcJ# Num#('.0005')
SetFlag('1')
END
END
SetStatusOn
{IF NOT AutoCycle?
SetAbsOrInc
END}
RETURN

FormatArc:
IF ArcCW?
CWArcC
ELSE
CCWArcC
END
RETURN

FormatArc2:
MoveXYC ArcIJ
RETURN

SetRapidF:
SetScale('1')
SeqLabC 'FX' RapidF# 'FY' RapidF# EOL { Set Table Axis Move }
RestoreScale
RETURN

SetFeedRate:
SeqLabC 'FV1' EOL { Set FeedRate to FeedRate Variable }
RETURN

StdLine: {enables CRC on first call, .70}
IF NOT FirstFeat? AND LAST RapidFeat?
SetFeedRate
END
IF LAST FirstFeat?
Feed
END
IF Decelerate?
IF RoomToDecel?
DecelMove1
SeqLabC FeedC MoveXYC EOL
DecelMove2
END
SeqLabC FeedC DecelFeed MoveXYC EOL
SetFeedRate
ELSE
IF XMove? OR YMove?
SeqLabC FeedC MoveXYC EOL
END
END
RETURN

ToolPath:
EACHFeat
IF PointFeat?
IF AutoCycle?
IF NOT FirstFeat?
AbsOrInc
END
SeqLabC MoveSXYC EOL
SeqLabC CallLabB 'ł' Recall# Num#('1') EOL
CalcACSRXY {calc tool position after sub call, CalcAutoCycleStatusRecordXY}
ELSE
IF OptCyc1? { For Custom Hole Machining Sub }
IF NOT FirstFeat?
' ' EOL
SeqLabC AbsOrInc MoveSX MoveSY EOL
END
SeqLabC 'V7=6.35' EOL { Hole Size Variable set 1/4 INCH }
SeqLabC 'KN7000' EOL { Call Custom Hole Machining Sub }
ELSE
SeqLabC MoveSXYC EOL
SeqLabC LaserOn 'G4X.2' EOL
SeqLabC LaserOff 'G4X.3' EOL
END
END
ELSE
IF FirstFeat?
SeqLabC 'KN1' EOL { Call OpenShutter SubProgram }
IF AbsoluteMoves? AND NOT AutoCycle?
SeqLabC IncValue EOL
END
SeqLabC 'F(V1-20)' EOL { Set FeedRate to FeedRate Variable minus 20 }
IF NOT AutoCycle? AND NOT ArcFeat?
SeqLabC Feed MoveXYC EOL
END
IF RapidFeat?
SetRapidF
ELSE
SetFeedRate
END
SeqLabC 'G9' EOL { Continuous Velocity - No Deceleration at the end of programmed moves }
END
IF RapidFeat?
IF NOT FirstFeat? AND LAST NOT RapidFeat?
SetRapidF
END
IF LAST FirstFeat?
Feed
END
IF XMove? OR YMove?
SeqLabC FeedC MoveXYC EOL
END
ELSE
IF LineFeat?
StdLine
ELSE
IF ArcFeat?
SetFlagF('1')
CkArcMove
IF Flag?('1')
SetFlagF('1')
StdLine { Arc is too small }
ELSE
IF NOT FirstFeat? AND LAST RapidFeat?
SetFeedRate
END
EACHQuadrant { Do not use NOT, FIRST, LAST or NEXT modifiers in this loop }
IF LastQuadrant? AND Decelerate?
IF RoomToDecel?
DecelMove1
SeqLabC FormatArc ArcFeed FormatArc2 EOL
DecelMove2
END
SeqLabC FormatArc DecelFeed FormatArc2 EOL
SetFeedRate
ELSE
SeqLabC FormatArc FormatArc2 EOL
END
NEXTQuadrant
END
END
END
END
IF LastFeat?
SeqLabC 'G0' EOL { Cancel G9 Continuous Velocity }
IF AbsoluteMoves? AND NOT AutoCycle?
SeqLabC AbsValue EOL
END
SeqLabC 'KN2' EOL { Call OpenShutter SubProgram }
SetRapidF
END
END
NEXTFeat
RETURN

WFOStuff:
IF NewWFO?
IF MultipleParts? AND WorkFixtureOffsets?
'*** WARNING *** DO NOT USE NEWWFO() WITH NCPOST MULTIPLE PARTS' EOL
ELSE
SeqLabC 'G' NewWFO# EOL
END
END
RETURN

AutoCycCutSub1: {part 1}
SaveSubStatus {save tool position}
SetPass1 {element cut moves}
StartSub
SetSRXYtoSP
SeqLabC IncValue EOL
RETURN

AutoCycCutSub2: {part 2}
ToolPath
SeqLabC AbsOrInc EOL
SeqLabC EndSub EOL
CloseSub
SetSRSubXY {restore SR to 1st position value}
SetSRSubMove
RETURN

AutoCycPat:
SetPass2 {position pattern}
ToolPath {call after TagInc for correct sub calls}
SetPass1 {reset}
RETURN

Milling:
IF AutoCycle?
Save# Num#('1') ADD# Recall# Num#('1') Num#('1') { TagInc }
AutoCycCutSub1
EntryMove
AutoCycCutSub2
AutoCycPat
ELSE
EntryMove
ToolPath
END
RETURN

G92Sub:
StdSub
SeqLabC AbsOrInc StrtPos EOL
Milling
FinishSub1
FinishSubG92
RETURN

ZonlyRepAutoCycle:
{ NOT Needed }
RETURN

ZonlyRep:
{ NOT Needed }
RETURN

CheckPass:
IF AutoCycle? {use the correct StrtPos}
SetPass2
ELSE
SetPass1
END
RETURN

SetFeedRateVar:
IF FirstOperation?
IF Milling?
SeqLabC 'V1=' FeedContour# EOL
ELSE
SeqLabC 'V1=' FeedEntry# EOL
END
ELSE
IF NewTool?
IF Milling?
SeqLab 'V1=' FeedContour# EOL
ELSE
SeqLab 'V1=' FeedEntry# EOL
END
ELSE { SameTool }
IF Milling?
IF LAST Milling?
IF NotEqual? FeedContour# LAST FeedContour#
SeqLab 'V1=' FeedContour# EOL
END
ELSE
IF NotEqual? FeedContour# LAST FeedEntry#
SeqLab 'V1=' FeedContour# EOL
END
END
ELSE
IF LAST Milling?
IF NotEqual? FeedEntry# LAST FeedContour#
SeqLab 'V1=' FeedEntry# EOL
END
ELSE
IF NotEqual? FeedEntry# LAST FeedEntry#
SeqLab 'V1=' FeedEntry# EOL
END
END
END
END
END
RETURN

StartProgCode:
SeqLab 'G0' EOL { Cancel G9 Continuous Velocity }
SeqLabC 'KN2' EOL { Call CloseShutter SubProgram }
SeqLabC 'G71' EOL { Metric Mode }
SeqLabC GasOff EOL
SetFeedRateVar
SeqLabC 'V2=0' EOL { HomeX }
SeqLabC 'V3=0' EOL { HomeY }
SeqLabC Preset 'XV2YV3' EOL
SetRapidF
SeqLabC AbsOrInc 'X0Y0' EOL
SeqLabC 'M0' EOL { Forced ProgStop }
' ' EOL
SeqLabC GasOn 'G4X.2' EOL
SeqLabC CallLabB 'ł' Recall# Num#('1') EOL
OpenSub
' ' EOL
'>' Recall# Num#('1') EOL
SeqLab ' ' EOL { unconditional for Proper Tagging }
DoSubComment
RETURN

EndProgCode:
SeqLabC EndSub EOL
' ' EOL
'N1' EOL { Open Shutter Sub }
SeqLabC OpenShutter 'G4X1' EOL
SeqLabC EndSub EOL
' ' EOL
'N2' EOL { Close Shutter Sub }
SeqLabC CloseShutter EOL
SeqLabC EndSub EOL
' ' EOL
'N7000' EOL { Hole Machining Sub }
SeqLabC 'V10=V7-.14' EOL { Variable 10 equals Hole Diameter Size minus .14 }
SeqLabC 'KN1' EOL { Call Open Shutter Sub }
SeqLabC IncValue EOL
SeqLabC 'F(V1/2)' EOL { Set FeedRate to 1/2 FeedRate Variable }
SeqLabC 'X(V10/2)' EOL { Set X-Axis Shift to 1/2 Hole Diameter Size Variable }
SetFeedRate
SeqLabC 'G03X0Y0I-(V10/2)J0' EOL
SeqLabC 'G0' EOL { Cancel G9 Continuous Velocity }
SeqLabC 'KN2' EOL { Call Close Shutter Sub }
SetRapidF
SeqLabC EndSub EOL
CloseSub { Balances OpenSub at StartProgCode }
RETURN

GetStartOfSameTool:
' ' EOL
Plane { no output }
DoOpComments
DoPostScript
WFOStuff
CheckPass
RETURN

{Start of executable Prog **************************************************}

{setup and initializations}
InitProg
SkipZ
InitWFONum
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
' NewWFO(56), NWFO(56) -' EOL
' The Work Fixture Offset # you specify will be used for all following operations.' EOL
' Do not use with the ncPost multiple part option.' EOL
' 4thAxisCW(12.5), 4ACW(12.5) -' EOL
' generates a + Z move of the value you specify' EOL
' 4thAxisCCW(22.5), 4ACCW(22.5) -' EOL
' generates a - Z move of the value you specify' EOL
' OptionalCycle1, OptCyc1 -' EOL
' Drilling Operation sets up standard Hole Machining call KN7000' EOL
END
EachOp {Start of post processing *********************}
IF FirstOperation?
IF ToolChangeAtHome?
SetHome
END
IF UseComments?
IF ProgramNameComment?
'G69 ' ProgramName$ EOL
END
IF ProgramComment?
'G69 ' ProgramComment$ EOL
END
IF FormatNameComment?
'G69 FORMAT: ' FormatName$ EOL
END
IF TimeComment?
'G69 ' Date$ ' AT ' Time$ EOL
END
IF MovesComment?
'G69 OUTPUT IN ' MoveType$ ' METERS' EOL
END
IF PartsComment?
'G69 PARTS PROGRAMMED: ' Parts# EOL
END
IF StartToolComment?
'G69 FIRST TOOL NOT IN SPINDLE' EOL
END
END
OpenSub
RestoreScale
StartProgCode
IF MultipleParts? AND AllToolsOnePart?
OpenMP
END
Plane { no output }
DoPostScript
DoOpComments
WFOStuff
CheckPass
SeqLabC AbsOrInc StrtPos EOL
IF MultipleParts? AND OneToolAllParts?
OpenMP
SeqLabC StrtPos EOL
END
ELSE
IF NewTool?

{Finish off last Operation}

IF MultipleParts? AND OneToolAllParts?
CloseMP
END
DoEndOpPS
SeqLabC 'M0' EOL { Forced ProgStop }

{Start new Operation}

' ' EOL
Plane { no output }
DoPostScript
DoOpComments
WFOStuff
CheckPass
SetFeedRateVar
SeqLabC AbsOrInc StrtPos EOL
IF MultipleParts? AND OneToolAllParts?
OpenMP
SeqLabC StrtPos EOL
END
ELSE
IF SameTool?
DoEndOpPS
IF LAST ProgStop?
SeqLabC 'M0' EOL
END

{Start new Operation}

GetStartOfSameTool
SetFeedRateVar
SeqLabC AbsOrInc StrtPos EOL
END
END
END {common point for all operations}
IF Milling?
IF Repeats?
Save# Num#('1') ADD# Recall# Num#('1') Num#('1') { TagInc }
G92Sub
IF FeedConnect?
ExitMove
END
ELSE {no repeat OPs}
Milling
IF NOT AutoCycle?
ExitMove
END
END
ELSE
IF Drilling?
IF Repeats?
Save# Num#('1') ADD# Recall# Num#('1') Num#('1') { TagInc }
StdSub
SetRapidF
SeqLabC StrtPos EOL
END
ToolPath
IF Repeats?
FinishSubG92
END
END
END
NextOp {loops back to EachOP until last Operation}

{End of program ************************************************************}

{finish last operation}
IF MultipleParts? AND OneToolAllParts?
CloseMP
END
DoEndOpPS
IF ProgStop?
SeqLabC 'M0' EOL
END
IF MultipleParts? AND AllToolsOnePart?
CloseMP
END
EndProgCode
SeqLabC EOP EOL
CloseSub
Post2 {organize Subs into one program}
Close
ReTag
IF UseComments?
SetScale('1') {restore scale for comments}
Reopen
' ' EOL
IF FileBytesComment?
'G69 FILE LENGTH: ' FileBytes# ' CHARACTERS' EOL
END
IF FileFeetComment?
'G69 FILE LENGTH: ' FileFeet# ' FEET' EOL
END
IF FileMetersComment?
'G69 FILE LENGTH: ' FileMeters# ' METERS' EOL
END
Close
END


Wyszukiwarka

Podobne podstrony:
Anomatic II Ano [QI] M578 87
Anomatic II Anorad M406 81 3
Anomatic II Anorad M406 81 3m
Alchemia II Rozdział 8
Do W cyrkulacja oceaniczna II rok
Test II III etap VIII OWoUE
Recht 5 BVerfG II
Budownictwo Ogolne II zaoczne wyklad 13 ppoz
Język niemiecki dwujęzyczna arkusz II
Angielski II zaliczenie
przetworniki II opracowane
MiBM Zestaw II
Program wykładu Fizyka II 14 15
Neural Network II SCILAB
Administracja wodna II RP kopia U W II RP

więcej podobnych podstron