{Change Comments ***********************************************************}
{2/18/92
NOTE!!! This is a Mill Post Processor that was originally a Lathe Post Processor.
DWB}
{8/19/91
Copied & modified: Anilam Crusader L051.80
For: Norton Company
Machine: Knife Cutting Plotter
Control: Anilam Crusador II LatheMate.
Changes made per conversations with Pat Burke and sample program.
Control is a NegSideLathe, XsAreRadii type that does not support Tool, Spindle or Coolant Codes.
Literal '1003' following initial EOR (%) at beginning is needed to prevent the control from
stopping in the middle of the program.
'M1' causes PenUp, 'M2' causes PenDown.
Rapid outputs 'G1M1', Feed outputs 'G1M2', CWArc outputs 'G2M2' and CCWArc outputs 'G3M2'.
These commands are Modal
Supports 360Ą Arcs, Non-Modal Absolute Arc Centers.
No CannedCycles.
DWB}
{2/18/92
Copied & modified: Anilam Crusader L231.80
For: Norton Company
Changes made per conversations with Dan Jones.
Dan said that they haven't been able to use our system yet, and would like to.
He said they would loose nothing by changing to Mill, and probably everything to gain.
Material is placed on a stationary table, Origin is established at lower left.
A parallel bar straddles the table and travels left (Z+) to right (Z-).
Pen travels up (X-) and down (X+) the parallel bar.
There is no Y axis, just PenDown (M2) and PenUp (M1).
DWB}
{6/1/92
Modified: Lathe Mate KC Plotter M490.81
For: Norton Company
Changes made per conversations with Kile Davis at Norton Company and sample program.
Kile said that the G02/G03 arcs are wrong. It seems that they need G02 instead of G03, and
vice-versa.
Changed ReverseXZArcs to StandardXZArcs in setup and initializations.
DWB}
{6/29/92
Modified: Lathe Mate KC Plotter M490.81.1
For: Norton Company
Transversed the 'G02' and the 'G03' in the form. Prior
change to fix problem for some reason, did not work.
KLM}
{8/24/92
Modified: Lathe Mate KC Plotter M490.81.2
For: Norton Company
Changed the MoveYC MoveXC in the FormatArc to unconditional, per request.
KLM}
{3/31/94
Modified: Lathe Mate KC Plotter M490.81.3
For: Norton
Call Rapid at end of program if NOT FIRST ToolChangeAtHome to cause pen up,
also NewTool & SameTool ProgStop.
Jim Radcliffe}
{Prog Numeric Format Definitions *******************************************}
#1 = '#.00'
#2 = '####.####;0'
#3 = '########;0'
#4 = '*####.####;0'
FORMAT(FileFeet#,1)
FORMAT(FileMeters#,1)
FORMAT(ToolDiameter#,2) {.72}
FORMAT(Program#,3) {.72}
FORMAT(Operation#,3) {.72}
FORMAT(Tool#,3) {.72}
FORMAT(Parts#,3) {.72}
FORMAT(Tag#,3)
FORMAT(ADD#,4)
FORMAT(Recall#,4)
FORMAT(HomeX#,4)
FORMAT(HomeY#,4)
FORMAT(StartPosX#,4)
FORMAT(StartPosY#,4)
{Prog Subroutines **********************************************************}
DoPartCycleComment:
IF UseComments? AND SubComment?
TagInc
'( START PART NO. ' Tag# ' )' EOL
IF LastPart?
TagInit
END
END
RETURN
DoCycleComment:
IF UseComments? AND SubComment?
'( CYCLE START )' 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 Metric? {CAM file is in Metric, tools and tool path}
SetScale('.03937007874') { change to English, this is an English post}
END
END
RETURN
PSInit: {reset flags}
RETURN
PSStuff: {revised.72}
RETURN
DoPostScript:
PSInit
EachPS
SeqC PostScript EOL {literals}
PSStuff {commands}
NextPS
RETURN
DoEndOpPS:
PSInit
EachEOPS
SeqC EndOpPS EOL {literals}
PSStuff {commands}
NextPS
RETURN
GetConnect:
IF FeedConnect?
FeedC
ELSE
RapidC
END
RETURN
CycleWarning:
{ NOTE: This Post Processor takes care of Z Clearance. }
RETURN
GetACEP:
IF AutoCycle?
Save# Num#('3') ADD# Recall# Num#('1') SUB# EPX# MUL# CurOriginPosX# Num#('2')
Save# Num#('4') ADD# Recall# Num#('2') SUB# EPY# MUL# CurOriginPosY# Num#('2')
LoadFeat Recall# Num#('3') Recall# Num#('4') Num#('0')
END
RETURN
FormatArc:
IF ArcCW?
CWArcC
ELSE
CCWArcC
END
MoveY MoveX
IF AutoCycle?
'I' ADD# Recall# Num#('2') SUB# ArcJ# CurOriginPosY#
'K' ADD# Recall# Num#('1') SUB# ArcI# CurOriginPosX#
ELSE
ArcJ ArcI
END
RETURN
ToolPath:
EACHFeat
IF PointFeat?
SeqC RapidC MoveSYC MoveSXC EOL
SeqC FeedC EOL
ELSE
IF RapidFeat?
GetACEP
IF XMove? OR YMove?
SeqC FeedC MoveYC MoveXC EOL
END
ELSE
IF LineFeat?
GetACEP
IF XMove? OR YMove?
SeqC FeedC MoveYC MoveXC EOL
END
ELSE
IF ArcFeat?
GetACEP
SeqC FormatArc EOL
END
END
END
END
NEXTFeat
RETURN
WFOStuff:
{ NOTE: This Post Processor does not support WorkFixtureOffsets. }
RETURN
AutoCycCutSub1: {part 1}
SeqC MoveSYC MoveSXC EOL
Save# Num#('3') SPX#
Save# Num#('4') SPY#
CalcACSRXY {calc tool position, CalcAutoCycleStatusRecordXY}
SetStatusOff
SetACSPCompF
Save# Num#('1') SPX#
Save# Num#('2') SPY#
SetACSPComp
SetStatusOn
SaveSubStatus {save tool position}
SetPass1 {element cut moves}
SetSRXYtoSP
TrackXNO# Recall# Num#('3')
TrackYNO# Recall# Num#('4')
RETURN
AutoCycCutSub2: {part 2}
SetSRSubXY {restore SR to 1st position value}
ReSetPass2 {restore for positioning moves}
RETURN
XYZRep:
EachRep
IF NOT FirstCycle?
GetConnect
SeqC 'X' StartPosY# 'Z' StartPosX# EOL
END
DoCycleComment
ToolPath
NextRep
RETURN
NoRepAutoCycle:
EACHFeat
RapidC
AutoCycCutSub1
DoCycleComment
ToolPath
AutoCycCutSub2
NEXTFeat
RETURN
XYZRepAutoCycle:
CycleWarning
EachRep
EACHFeat
IF FirstCycle? AND FirstFeat?
ELSE
GetConnect
END
AutoCycCutSub1
DoCycleComment
ToolPath
AutoCycCutSub2
NEXTFeat
NextRep
RETURN
ZonlyRepAutoCycle:
EACHFeat
IF NOT FirstFeat?
GetConnect
END
AutoCycCutSub1
EachRep
IF FirstCycle?
DoCycleComment
ToolPath
ELSE
IF NOT FirstFeat?
GetConnect
SeqC MoveSYC MoveSXC EOL
END
DoCycleComment
ToolPath
END
NextRep
AutoCycCutSub2
ReSetPass2 {restore for positioning moves}
NEXTFeat
RETURN
CheckPass:
IF AutoCycle? {use the correct StrtPos}
SetPass2
ELSE
SetPass1
END
RETURN
GetStartOfSameTool:
PlaneC
DoOpComments
DoPostScript
CheckPass
RETURN
{Start of executable Prog **************************************************}
{setup and initializations}
InitProg
SetAbs
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
END
EachOp {Start of post processing *********************}
IF FirstOperation?
EOR EOL
'1003' EOL
IF UseComments? AND ProgramNameComment?
'( ' ProgramName$ ' )'
END
EOL
IF ToolChangeAtHome?
SetHome
END
IF UseComments?
IF ProgramComment?
'( ' ProgramComment$ ' )' EOL
END
IF FormatNameComment?
'( FORMAT: ' FormatName$ ' )' EOL
END
IF TimeComment?
'( ' Date$ ' AT ' Time$ ' )' EOL
END
IF MovesComment?
'( OUTPUT IN ABSOLUTE INCHES )' EOL
END
IF PartsComment?
'( PARTS PROGRAMMED: ' Parts# ' )' EOL
END
IF StartToolComment?
'( FIRST TOOL NOT IN SPINDLE )' EOL
END
END
OpenSub
IF Metric? {CAM file is in Metric, tools and tool path}
SetScale('.03937007874') { change to English, this is an English post}
END
IF MultipleParts? AND AllToolsOnePart?
EachPart
DoPartCycleComment
END
Plane
DoOpComments
DoPostScript
IF Milling?
Seq FeedRate EOL
ELSE
Seq FeedEnt EOL
END
IF MultipleParts? AND OneToolAllParts? AND FullUp?
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
END
END
CheckPass
SeqC Rapid 'X' StartPosY# 'Z' StartPosX# EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
CheckPass
SeqC Rapid 'X' StartPosY# 'Z' StartPosX# EOL
END
END
ELSE
IF NewTool?
{Finish off last Operation}
IF MultipleParts? AND OneToolAllParts?
NextPart
END
DoEndOpPS
IF ToolChangeAtHome?
SeqC Rapid 'X' HomeY# 'Z' HomeX# EOL
ELSE
SeqC Rapid EOL
END
IF LAST ProgStop?
SeqC 'G4' EOL
ELSE
SeqC ProgStop EOL
END
{Start new Operation}
PlaneC
DoOpComments
DoPostScript
IF Milling?
Seq FeedRate EOL
ELSE
Seq FeedEnt EOL
END
IF MultipleParts? AND OneToolAllParts? AND FullUp?
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
END
END
CheckPass
SeqC Rapid 'X' StartPosY# 'Z' StartPosX# EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
EachPart
DoPartCycleComment
IF NOT FirstPart?
DoOpComments
CheckPass
SeqC Rapid 'X' StartPosY# 'Z' StartPosX# EOL
END
END
ELSE
IF SameTool?
DoEndOpPS
IF LAST ProgStop?
SeqC Rapid EOL
SeqC 'G4' EOL
END
{Start new Operation}
GetStartOfSameTool
IF Milling?
SeqC FeedRateC EOL
ELSE
SeqC FeedEntC EOL
END
SeqC Rapid 'X' StartPosY# 'Z' StartPosX# EOL
END
END
END {common point for all operations}
IF Milling?
IF AutoCycle?
IF Repeats?
IF ZshiftOnly?
ZonlyRepAutoCycle
ELSE
XYZRepAutoCycle
END
ELSE
NoRepAutoCycle
END
ELSE { NOT AutoCycle }
IF Repeats?
XYZRep
ELSE
ToolPath
END
END
ELSE
IF Drilling?
IF Repeats?
EachRep
IF NOT FirstCycle?
SeqC RapidC 'X' StartPosY# 'Z' StartPosX# EOL
END
DoCycleComment
ToolPath
NextRep
ELSE
ToolPath
END
END
END
IF MultipleParts? AND LastOp?
{End of program ************************************************************}
{finish last operation}
IF OneToolAllParts?
NEXTPart
END
DoEndOpPS
IF FIRST ToolChangeAtHome? {.71.2 added FIRST modifier}
SeqC Rapid 'X' FIRST HomeY# 'Z' FIRST HomeX# EOL
ELSE
SeqC Rapid EOL
END
IF ProgStop?
SeqC 'G4' EOL
END
IF AllToolsOnePart?
NEXTPart
END
ELSE { NOT MultipleParts }
NextOp {loops back to EachOP until last Operation}
{End of program ************************************************************}
{finish last operation}
DoEndOpPS
IF FIRST ToolChangeAtHome? {.71.2 added FIRST modifier}
SeqC Rapid 'X' FIRST HomeY# 'Z' FIRST HomeX# EOL
ELSE
SeqC Rapid EOL
END
IF ProgStop?
SeqC 'G4' EOL
END
END
SeqC 'END' EOL
EOR EOL
Post
Close
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:
Fanuc Mate TC Gild L048 81 1Fanuc 10M MV40 [KC] M668 81 2Fanuc 10M (AGA) M147 81 2Tosnuc 600M VMC 45 M442 81 3kc ksiega1DM 81 Diper KenwoodaBP IIA (HAC) M200 81kc ksiega230 (81)Cnc Lathe MachiningArtran Contour MV83 81Yas MX3 Mat [AbsZAC] M591 81 2elementy prawa 102011 cz4 kc rzeczoweT81 2KC K W5więcej podobnych podstron