{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}
{6/17/93
Copied & modified: Anomatic II Ano [QI] M578.81.3m
For: Quasar Industries
Created INCH version.
Changed FORMATS in Mach Spec for 4 place decimals.
Changed RestoreScale sub.
Changed MovesComment from METERS to INCHES at FirstOperation.
Changed literal 'G71' to 'G70' at StartProgCode.
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 Metric? {CAM file is in Metric, tools and tool path}
SetScale('.03937007874') { change to English, this is an English 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 }
'M114'
RETURN
CloseShutter:
'M115'
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 GreaterThan? ArcI# Num#('-.0005')
IF LessThan? ArcI# Num#('.0005')
IF GreaterThan? ArcJ# Num#('-.0005')
IF LessThan? ArcJ# Num#('.0005')
SetFlag('1')
END
END
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 }
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 }
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
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
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 'G70' 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:
' ' EOL
'N1' EOL { Open Shutter Sub }
SeqLabC OpenShutter 'G4X.2' EOL
EndSub EOL
' ' EOL
'N2' EOL { Close Shutter Sub }
SeqLabC CloseShutter 'G4X.2' EOL
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
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$ ' INCHES' 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 87mAnomatic II Anorad M406 81 3Anomatic II Anorad M406 81 3mServo II M693 87Bostomatic SPC II [LAG] M458 87Alchemia II Rozdział 8Do W cyrkulacja oceaniczna II rokFanuc 10M MVJr[G43r] M192 87Test II III etap VIII OWoUERecht 5 BVerfG IIBudownictwo Ogolne II zaoczne wyklad 13 ppozJęzyk niemiecki dwujęzyczna arkusz IIAngielski II zaliczenieTosnuc 600M BMC 40 M440 87przetworniki II opracowanewięcej podobnych podstron