# Re: Which way would you do this?

"alphonso" <alphamachine-nospam@xxxxxxxxxxxxx> wrote in message
news:Xns97A8AE2B612Aalphonso@xxxxxxxxxxxxxx
"Beege" <bwgilmanhah@xxxxxxxxxxx> wrote in news:4443d55c_5
@newsfeed.slurp.net:

Beege

Okay, now that y'all have helped me sort out this little problem, how
the bigger problem.

N10 G17 G40 G49 G80
N20 G91 G28 Z.0
N30 T25 (1/2 X .125 BULL NOSE CARBIDE END MILL) M6
N40 G54
N50 G0 G90 X-2.0 Y2.0 S1000 M3
N60 G43 Z4.0 H25
N70 G1 Y-2.0 F30.
N80 X2.0
N90 Y2.0
N110 G0 X15.0
N115 G55
N120 M98 P2001
(MOVE TO OTHER END OF PART AN REPEAT CYCLE)
M140 M98 P12002
N160 G0 G28 G40 G91 Z.0
N170 G28 Y.0
N180 G90
N200 M30

:2001 G69 G17
G1 X2.0 Z4.
G18 G03 X2.5 Z3.5 I.0 K-.5
M99

:2002 G68 X0 Y0 G91 R180.
G90 M98 P2001
M99
%

In the second part of the program(G55), I want to do an arc in the ZX
plane
(G18), use G68 (coordinate rotation) to move the tool to the opposite end
of the part, and repeat the arc.

When run as written, the first time the sub runs, it does what is
expected.
The second time, called from :O2002, it runs again in the same place.

Edit one of :O2001

:O2001 G01 X2.0 Z4. G69 G17
G18 G03 X2.5 Z3.5 I.0 K-.5
M99

The first sub run is okay. The second sub run: moves to X-2. Y2. instead
of X-2. Y-2. then the arc move is CW down (as the first run) then moves to
X2.

Edit two:

Move G69 G17 down to their own line. Same results as edit one.

Edit three:

Remove G17. Same results as edit one and two.

Edit 4:

Remove G69. First sub run is okay. Second run moves to X-2 Y2, arc move
CW up (6 to 9 o'clock).

Removing the G18 move and replacing it with some linear moves produces
moves like I expected. First sub run goes to X2. Y2., second sub run goes
to X-2. Y-2.

It was suggested in another forum that I didn't need to have a G18 at all.
I tried removing that and got an "illegal plane selection" error.

Any ideas?

Keep in mind that G68 AND G69 are modal.

You have in O2002 a G68, but you cancel it in 02001

Try it this way...

N115 G55 G69
N120 M98 P2001
(MOVE TO OTHER END OF PART AN REPEAT CYCLE)
M140 M98 P2002
N160 G0 G28 G40 G91 Z.0
N170 G28 Y.0
N180 G90
N200 M30

:2001
G1 X2.0 Z4. (UNLESS USING CUTTER COMP, LINEAR MOVES DON"T NEED PLANE CODE)
G18 G03 X2.5 Z3.5 I.0 K-.5
M99

:2002 G68 X0 Y0 G91 R180.
G90 M98 P2001
G69
M99
%

Beege

.

## Relevant Pages

• Re: Which way would you do this?
... Okay, now that y'all have helped me sort out this little problem, how about the bigger problem. ... Edit one of:O2001 ... The first sub run is okay. ... The second sub run: moves to X-2. ...
(alt.machines.cnc)
• Re: ANNOUNCE: DJGPP port of GNU Emacs 23.3 uploaded
... Still crashed when typing 'e' (edit) under ... Dired on blah.sh file (though most other files are okay). ... font lock for the rest of the file, heh, oh well. ...
(comp.os.msdos.djgpp)
• Re: Which way would you do this?
... (MOVE TO OTHER END OF PART AN REPEAT CYCLE) ... When run as written, the first time the sub runs, it does what is expected. ... Edit one of:O2001 ... The second sub run: moves to X-2. ...
(alt.machines.cnc)