{Copied & modified; Bandit IV AB M089.54, for N.C. Eng..
Add 'G80G40' saftey blocks to beginning of program.
Change 'M7' to 'M8' for coolant in Format & move to 'OfstOn' line.
Add 'GearRange' & 'Table' for gears & speeds.
Move 'CRCOffC LastFeatExtend' to line before 'ZCP3'.
Use '_' instead of sapces inside comments.
Other minor format changes.
Jim Radcliffe}
{2/23/90, Updated: AB 8400 Cincinati (NCE) to .70.3 format, JR}
{7/24/90, Added InitProg globally to posts with this remark, DWB}
{7/24/90, Replaced all occurances of SetSRXYZero with SetSRXYtoSP, DWB}
{5/9/91, Updated AB 8400 Cincinati M292.71 to .80 format, minor corrections to CRC, JR}
{5/9/91
Copied & modified: AB 8400 Cincinati M292.80
For: Ginacue
Control: Allen Breadley 8400
Machine: 3 Spindle Custom Made Knee Mill
Changed TABLE's & GearRange's to Speed commands.
Deleted Preset from beginning of program.
No Coolant.
4th axis is a W axis, changed accordingly and deleted 5th axis stuff.
M codes to instruct which spindle to use.
Using tool# for WFO#
Set up for 2 types of use:
Differant tool in each spindle:
Spindle activated by tool number.
Same tool and same operations in all spindles:
Using OptCyc1 to activate all spindles at the same time.
Jim Radcliffe}
{6/13/91
Deleted Offset Off command before tool changes, and at the end of the program,
changed Offset Off command to output a 'G45' 'O0' , deleted 'Y0' and replaced
with 'GZ' and 'GY'
Kim Michelman}
{11/21/91
Modified: AB 8400 [Gin] M417.80.1
For: Ginacue/James Moore
Updated to Version 4.0 per Fanuc 6M M001.81 Format.
Changed RepsLess1 to RepCycs per request.
Kim Michelman}
{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(NewWFO#,5) {.72}
FORMAT(Parts#,5) {.72}
FORMAT(Dwell#,6)
{Prog Subroutines **********************************************************}
DoSubComment:
IF UseComments? AND SubComment?
';_SUB_NUMBER:_' Program# EOL
END
RETURN
DoOpComments:
IF UseComments?
SetScale('1')
IF NOT SameTool?
IF ToolTypeComment?
';_TOOL_' Tool# ':_' ToolDiameter# '_' ToolType$ EOL
END
IF ToolComment?
';_T' Tool# '_' ToolComment$ EOL
END
END
IF OperationIDComment?
';_OPERATION_' Operation# ':_' OperationType$ EOL
END
IF OperationComment?
';_' OperationComment$ EOL
END
IF WorkGroupComment?
';_' WorkGroupComment$ 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}
NewWFOF
RotateF
RETURN
PSStuff: {revised.72}
IF FourthCW?
FORMAT(FourthDegree#,2)
SeqC 'W' FourthDegree# EOL
FourthCWF {reset flag}
END
IF FourthCCW?
FORMAT(FourthDegree#,3)
SeqC 'W' FourthDegree# EOL
FourthCCWF {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 Feed ZIn FeedEnt EOL
ELSE
SeqC RapidC ZIn EOL
END
RETURN
StartSub:
OpenSub
EOR EOL
DoSubComment
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:
SeqC CallLab RepLab RepCycs EOL
StartSub
RETURN
FinishSub1: {part 1}
UnSkipZ
IF NOT FeedConnect?
IF AutoCycle?
ZCP3C
ELSE
IF FIFO? {.81}
FeedC ZCP3C FeedRateC
ELSE
SeqC RapidC ZCP3C EOL
END
END
END
EOL
RETURN
FinishSubG92: {part 2}
SeqC Preset ShiftRC EOL
SeqC EndSub EOL
EOR EOL
CloseSub
SeqC Preset UnshftRC EOL
RETURN
OpenMP:
NewProg
IF WorkFixtureOffsets?
NewWFO
EachWFO
SeqC 'G45' SetWFO EOL
SeqC CallLab EOL
IncWFO
NextWFO
ELSE
SeqC CallLab RepLab PartsLess1 EOL
END
StartSub
RETURN
CloseMP:
IF WorkFixtureOffsets?
SeqC EndSub EOL
EOR EOL
CloseSub
SeqC 'G99' EOL
SeqC 'G45' WFO1 EOL
ELSE
SeqC Preset ShiftPC EOL
SeqC EndSub EOL
EOR EOL
CloseSub
SeqC Preset UnshftPC EOL
END
RETURN
FormatArc:
IF ArcCW?
CWArc
ELSE
CCWArc
END
MoveXYZC
ArcIJ
RETURN
StdLine: {enables CRC on first call, .70}
IF Decelerate?
IF RoomToDecel?
DecelMove1
SeqC CRCOnC EOL
SeqC FeedC MoveXYZC FeedRateC EOL
DecelMove2
END
SeqC CRCOnC EOL
SeqC FeedC MoveXYZC DecelFeed EOL
ELSE
IF XMove? OR YMove? OR ZMove?
SeqC CRCOnC EOL
SeqC FeedC MoveXYZC FeedRateC EOL
END
END
RETURN
ToolPath:
EACHFeat
IF PointFeat?
IF AutoCycle?
SeqC MoveSXYC EOL
SeqC CallLab EOL
CalcACSRXY {calc tool position after sub call, CalcAutoCycleStatusRecordXY}
ELSE
SeqC MoveSXYC EOL {.80.01}
END
ELSE
IF RapidFeat?
IF LastFeat? AND AutoCycle? {.70}
SeqC RapidC EOL
SeqC CRCOffC MoveXYZC EOL
ELSE
IF XMove? OR YMove? OR ZMove?
SeqC RapidC MoveXYZC EOL
END
END
ELSE
IF LineFeat?
IF AutoCycle? {.70}
IF LastFeat?
SeqC FeedC EOL
SeqC CRCOffC MoveXYZC FeedRateC EOL
ELSE
IF ZMove? {skip CRCOn until first non-Z move line, skipping ramps}
SeqC FeedC MoveXYZC FeedRateC EOL
ELSE
StdLine {enables CRC on first call}
END
END
ELSE
StdLine
END
ELSE
IF ArcFeat?
EACHQuadrant
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
END
END
NEXTFeat
RETURN
WFOStuff:
IF NewWFO?
IF MultipleParts?
'*** WARNING *** DO NOT USE NEWWFO() WITH NCPOST MULTIPLE PARTS'
ELSE
'G45O' NewWFO#
END
ELSE
IF NOT SameTool?
IF NeedWFO1?
'G45O' Tool#
END
END
END
RETURN
AutoCycCutSub1: {part 1}
SaveSubStatus {save tool position}
SetPass1 {element cut moves}
StartSub
SetSRXYtoSP
Seq IncValue EOL
RETURN
AutoCycCutSub2: {part 2}
ToolPath
IF Repeats? AND FeedConnect? AND ZshiftOnly?
SeqC AbsOrInc EOL
ELSE
IF FIFO? {.81}
SeqC AbsOrInc FeedC ZCP2 FeedRateC EOL
ELSE
SeqC AbsOrInc EOL
SeqC RapidC ZCP2 EOL
END
END
SeqC EndSub EOL
EOR 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?
SeqC FeedC EOL
SeqC CRCOffC LastFeatExtend EOL
END
END
RETURN
G92Sub:
SubWarning
StdSub
SeqC Connect StrtPos EOL
Milling
FinishSub1
FinishSubG92
RETURN
ZonlyRepAutoCycle:
AutoCycPat {write pattern moves and main calls}
StartSub
NewProg
EachCycle
IF FeedConnect?
SeqC Feed ZInPlusInc FeedEnt EOL
ELSE
IF FeedEntry?
IF NOT FirstCycle?
SeqC Rapid ZCP2PlusInc EOL {.69 added Rapid, reads better}
{can't call for cycle = 1, .69 changed to ZCP2PlusInc}
END
SeqC Feed ZInPlusInc FeedEnt EOL
ELSE
SeqC Rapid ZInPlusInc EOL {.69 added Rapid, reads better}
END
END
IF FirstCycle?
SetStatusOff {protect Z position for incremental sub}
END
SeqC CallLab EOL
NextCycle
SetStatusOn
AutoCycCutSub1 {build element sub}
AutoCycCutSub2
{.69, removed FinishSub1}
IF FeedConnect? {there is no Z up in the sub, .69}
IF FIFO? {.81}
SeqC Feed ZCP2 FeedRate EOL {.69}
ELSE
SeqC Rapid ZCP2 EOL {.69}
END
END {.69}
SeqC EndSub EOL
EOR EOL
CloseSub
{Element shift, not pattern}
RETURN
ZonlyRep:
EachCycle
IF NOT FirstCycle?
SeqC Connect StrtPos EOL
END
IF FeedConnect?
SeqC FeedC ZInPlusInc FeedEnt EOL
ELSE
IF FeedEntry?
IF NOT FirstCycle?
SeqC RapidC ZCP2PlusIncC EOL {can't call for cycle =1}
{.69 added Rapid, reads better}
END
SeqC Feed ZInPlusInc FeedEnt EOL
ELSE
SeqC RapidC ZInPlusInc EOL {.69 added Rapid, reads better}
END
END
SeqC CallLab EOL
NextCycle
StartSub
SkipZ
ToolPath
IF CutterRadiusCompensation?
SeqC FeedC EOL
SeqC CRCOffC LastFeatExtend EOL
END
FinishSub1
SeqC EndSub EOL
EOR EOL
CloseSub
RETURN
CheckPass:
IF AutoCycle? {use the correct StrtPos}
SetPass2
ELSE
SetPass1
END
RETURN
GetStartOfSameTool:
DoOpComments
DoPostScript
SeqC WFOStuff EOL
SeqC PlaneC EOL
CheckPass
RETURN
{Start of executable Prog **************************************************}
{setup and initializations}
InitProg
OptCyc1F
ReverseXZArcs
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 + W move of the value you specify' EOL
' 4thAxisCCW(22.5), 4ACCW(22.5) -' EOL
' generates a - W move of the value you specify' EOL
END
EachOp
IF FirstOperation?
EOR EOL
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$ '_INCHES' EOL
END
IF PartsComment?
';_PARTS_PROGRAMMED:_' Parts# EOL
END
IF StartToolComment?
';_FIRST_TOOLS_IN_SPINDLES' EOL
END
END
IF ToolChangeAtHome?
SetHome
END
OpenSub
IF Metric? {CAM file is in Metric, tools and tool path}
SetScale('.03937007874') { change to English, this is an English post}
END
SeqC 'G99' EOL
SeqC 'G80' EOL
SeqC 'G40' EOL
SeqC AbsOrInc EOL
IF MultipleParts? AND AllToolsOnePart?
OpenMP
END
DoOpComments
DoPostScript
Seq WFOStuff EOL
SeqC Plane EOL
IF OptCyc1?
SeqC 'M39' EOL {activate spindle #1}
SeqC 'M41' EOL {activate spindle #2}
SeqC 'M43' EOL {activate spindle #3}
ELSE
IF ToolOver?('1')
IF ToolOver?('2')
SeqC 'M43' EOL {activate spindle #3}
ELSE
SeqC 'M41' EOL {activate spindle #2}
END
ELSE
SeqC 'M39' EOL {activate spindle #1}
END
END
SeqC Speed SpinOn EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
OpenMP
END
CheckPass
SeqC Rapid StrtPos EOL
SeqC RapidC OfstOn EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
OpenMP
SeqC StrtPos EOL
END
ELSE
IF NewTool?
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
CloseMP
END
IF MultipleParts? AND OneToolAllParts? AND FullUp?
CloseMP
END
DoEndOpPS
IF ToolChangeAtHome?
SeqC RapidC Home SpinOff EOL
ELSE
SeqC SpinOff EOL
END
IF OptCyc1?
SeqC 'M40' EOL {deactivate spindle #1}
SeqC 'M42' EOL {deactivate spindle #2}
SeqC 'M44' EOL {deactivate spindle #3}
ELSE
IF LAST ToolOver?('1')
IF LAST ToolOver?('2')
SeqC 'M44' EOL {deactivate spindle #3}
ELSE
SeqC 'M42' EOL {deactivate spindle #2}
END
ELSE
SeqC 'M40' EOL {deactivate spindle #1}
END
END
IF LAST ProgStop?
SeqC 'M00' EOL
ELSE
IF OptCyc1? {need program stop to change all tools}
SeqC 'M00' EOL
ELSE
SeqC 'G4F2.' EOL {dwell for spindle to catch up}
END
END
{Start new Operation}
DoOpComments
DoPostScript
Seq WFOStuff EOL
SeqC PlaneC EOL
IF OptCyc1?
SeqC 'M39' EOL {activate spindle #1}
SeqC 'M41' EOL {activate spindle #2}
SeqC 'M43' EOL {activate spindle #3}
ELSE
IF ToolOver?('1')
IF ToolOver?('2')
SeqC 'M43' EOL {activate spindle #3}
ELSE
SeqC 'M41' EOL {activate spindle #2}
END
ELSE
SeqC 'M39' EOL {activate spindle #1}
END
END
SeqC Speed SpinOn EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
OpenMP
END
CheckPass
SeqC Rapid StrtPos EOL
SeqC RapidC OfstOn EOL
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
OpenMP
SeqC StrtPos EOL
END
ELSE
IF SameTool?
DoEndOpPS
IF LAST ProgStop?
SeqC SpinOff EOL
SeqC 'M00' EOL
{Start new Operation}
GetStartOfSameTool
SeqC SpeedC SpinOn EOL
SeqC RapidC StrtPos EOL
SeqC OfstOn EOL
ELSE
IF NewToolOffset?
{Start new Operation}
GetStartOfSameTool
SeqC SpeedC EOL
SeqC RapidC StrtPos EOL
SeqC OfstOn EOL
ELSE
{Start new Operation}
GetStartOfSameTool
SeqC SpeedC EOL
SeqC RapidC StrtPos EOL
END
END
END
END
END {common point for all operations}
IF Milling?
SeqC ZCP2C 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
IF AutoCycle?
SeqC ZCP3C EOL
ELSE
IF FIFO? {.81}
SeqC FeedC ZCP3C FeedRateC EOL
ELSE
SeqC RapidC ZCP3C EOL
END
END
ELSE
IF Drilling?
IF Repeats?
NewProg
StdSub
SeqC Rapid StrtPos EOL
END
SeqC DrillCP EOL
GetCycle
SeqC Cycle ZDepth RLevel
IF Dwell?
'D' Dwell#
END
IF Peck?
Peck FromCP FeedEnt
IF PeckChipBreaker?
'J*K*W' Retract 'U*'
END
ELSE
FromCP FeedEnt
END
EOL
SeqC StrtPos EOL
TrackZNO# ZDepth# {.81}
ToolPath
IF RetractToCP1? {.81}
TrackZNO# ClearancePlane1#
ELSE
TrackZNO# ClearancePlane2#
END
SeqC 'G80' EOL
IF Repeats?
FinishSubG92
END
SeqC ZCP3C EOL
END
END
NextOp
IF MultipleParts? AND OneToolAllParts? AND ExitClearancePlane?
CloseMP
END
SeqC 'G45' 'O0' EOL
IF MultipleParts? AND OneToolAllParts? AND FullUp?
CloseMP
END
DoEndOpPS
IF FIRST ToolChangeAtHome?
SeqC RapidC FirstHome SpinOff EOL
ELSE
SeqC SpinOff EOL
END
IF OptCyc1?
SeqC 'M40' EOL {deactivate spindle #1}
SeqC 'M42' EOL {deactivate spindle #2}
SeqC 'M44' EOL {deactivate spindle #3}
ELSE
IF ToolOver?('1')
IF ToolOver?('2')
SeqC 'M44' EOL {deactivate spindle #3}
ELSE
SeqC 'M42' EOL {deactivate spindle #2}
END
ELSE
SeqC 'M40' EOL {deactivate spindle #1}
END
END
IF ProgStop?
SeqC 'M00' EOL
END
IF MultipleParts? AND AllToolsOnePart?
IF NOT ProgStop?
IF OptCyc1? {need program stop to change all tools}
SeqC 'M00' EOL
ELSE
SeqC 'G4F2.' EOL {dwell for spindle to catch up}
END
END
CloseMP
END
SeqC 'G99' EOL
SeqC 'GZ' EOL
SeqC 'GY' EOL
SeqC EOP EOL
EOR EOL
Post
Close
IF UseComments?
SetScale('1')
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:
AB 8400 Rev E M581 87AB 8400 Rev F [CAS] M876 89 2AB 8400 Rev F [EI] MW43 89 1AB 8400 Moore JG M422 80 4AB 8400 [AQL] M609 89 2AB 8400 Cincinnati M292 87AB 8400 Monarch L610 85AB 8400 (OSF)[Y] M309 79W & S 2SC AB [CE] L186 82 1AB CNC 8400 LP L623 85W & S 2SC AB 7360 L096 82 1Stromlaufplan Passat 82 Gefährdeten Alarmsystem (Passat Protect) ab 06 2001AB 7370 CHNC4 L161 82AB 8200 B&S L236 82 1Stromlaufplan Passat 82 Motor 1,8l 92kW ARG,APT Motronic ab 01 1999AB Sheldon [BRL ] L142 82 2AB CNC 8400 LP L623 85mwięcej podobnych podstron