Hello Guest it is April 19, 2024, 06:48:45 PM

Author Topic: G12 Problem  (Read 4002 times)

0 Members and 1 Guest are viewing this topic.

G12 Problem
« on: December 17, 2008, 05:27:38 AM »
Background: I am experimenting with making a solder mask for a pcb. My pcb layout programme gives me a list of x/y positions which indicate the centre of a pad. These need scaling by .0001 to represent inches, so at the start of my main programme I code g51 x.0001 y.0001. I have decided to use a circle to stencil a blob of paste on each land.
My milling tool is 32th, so for a 40th wide pad I use a subroutine:
O540 %40th wide pad
g0 z.004
g1 z-.004
g12 I.004
g0 z.1
m99

For some reason that code, when shown in the toolpath, gives a straight cut on the x axis to x0, wherever the starting coordinate position is, and no circle.
I have assumed no scaling on the I word as the manual says that scaling can apply to I and J but does not show the syntax for it. Anyway, the toolpath shows exactly the same path if I use g12 I4 instead.

I must be doing something obviously wrong, but I can't see it.

Dave
Re: G12 Problem
« Reply #1 on: December 29, 2008, 05:11:07 AM »
Sorry, I've just realised this is a statement and not a question.

What I omitted to say is can anyone suggest why my use of g12 is not responding as I was expecting?

Dave

Online Graham Waterworth

*
  • *
  •  2,672 2,672
  • Yorkshire Dales, England
    • View Profile
Re: G12 Problem
« Reply #2 on: December 29, 2008, 02:59:16 PM »
Try the code like this

Graham


O540 (40th wide pad)
g0 z.004
g1 z-.004
g12 I.004
g0 z.1
m99

Without engineers the world stops
Re: G12 Problem
« Reply #3 on: December 30, 2008, 11:39:55 AM »
Thanks for that. I can only see a difference in the comment and changing that made no difference.

It did prompt me to have another look however, and what I had not mentioned was that in the calling programme I had a line G51 X.0001 Y.0001.
When I first wrote that I read that the scaling covered xyzabcij and that you selected which to apply it to on the same line. I had assumed that it only applied to X and Y, but adding G50 at the start of the subroutine and G51 X.0001 Y.0001 at the end made everything work as required, so the G51 worked on I and J automatically.

Dave