Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: PaulWC on May 18, 2013, 03:48:08 AM

Title: Unexpected Crop Circles
Post by: PaulWC on May 18, 2013, 03:48:08 AM
I've been away from Mach3 for a few years, so am frantically clearing mental cobwebs...

I have a problem with my first major attempt with Mach3.

3D G-code generated from STL model using the latest version of MeshCAM. Code proofed in CutViewerMill... all good.

Run code on Mach3 R3.043.066 install on CNC router, runs great, then suddenly takes off in a large circle.

The stray tool path occurs at a G2/G3 IJ code line, and behaves like it loses reference for absolute IJ distances. There is a G90 line at the start of code.

Attached pic shows a large circle that occured while running at approx line 1800. The smaller circle happened when restarting the  code.

Any suggestions?
Title: Re: Unexpected Crop Circles
Post by: Hood on May 18, 2013, 04:45:49 AM
G90 is not Abs IJ mode, it is  G90.1.
However if that is what you had please attach your xml and I will take a look.
Hood
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 18, 2013, 10:06:00 AM
The G90 was inserted by MeshCAM. I can easily change it to G90.1. Couldn't find a ref to G90.1 in RS274NGC_3 Docs?

Starting XML attached. No General Config changes other than screen on running XML, which is a 20 mile trip away.

Thanks, Paul
Title: Re: Unexpected Crop Circles
Post by: Hood on May 18, 2013, 01:41:05 PM
Can you attach the xml you are using at the moment as settings can be changed by code and yours may be different from that one.
Hood
Title: Re: Unexpected Crop Circles
Post by: Hood on May 18, 2013, 01:43:30 PM
Also if you click on the button on the main page in Mach that says G Code you will get a list and explanations of the ones used by Mach.
Hood
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 18, 2013, 02:17:48 PM
Can you attach the xml you are using at the moment as settings can be changed by code and yours may be different from that one.
Hood

Will do soon...
Title: Re: Unexpected Crop Circles
Post by: ger21 on May 18, 2013, 07:14:19 PM
You should have both a G90 and a G91.1, and they need to be on separate lines.
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 18, 2013, 07:15:52 PM
OK... here's the current running XML
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 18, 2013, 07:16:13 PM
You should have both a G90 and a G91.1, and they need to be on separate lines.

Done!

Thanks
Title: Re: Unexpected Crop Circles
Post by: Hood on May 19, 2013, 03:26:34 AM
Ok first look of your xml and it seems fine.
Do you see the crop circles in your toolpath view?
Can you attach the code you are getting it with?

Hood
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 19, 2013, 01:37:53 PM
Did not see crop circles or any other anomalies in toolpath view. Code ran fine in CutViewer Mill simulator. Problem showed with two different code sources.

I've attached the code I was running when I was there to see it happen (client's machine). Wide circle occurred at line 5788, a G3 line of code... far past the first G3 in the program. For what I observed, it appeared the math logic randomly lost it's place.

The attached file has the G90.1 line added, but was not there during the run.
Title: Re: Unexpected Crop Circles
Post by: ger21 on May 19, 2013, 02:44:03 PM
Quote
The attached file has the G90.1 line added, but was not there during the run.

It should be G91.1

It won't run with G90.1. I get an error when I load it into mach3. Change it to G91.1 and it's fine.
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 19, 2013, 03:13:50 PM
I have to admit... I'm confused by the use of absolute distance combined with incremental IJ?

On line 5788 the XY coordinates are absolute, which goes along with the G90 placed in the header by MeshCAM.

In addition to changing the G90.1 to G91.1, should General Config also be changed to Incremental IJ?

I could use some clarification instruction. Just do it because it works is not a real confidence builder.  ;)
Title: Re: Unexpected Crop Circles
Post by: Hood on May 19, 2013, 04:11:18 PM
Is that the code that you are showing a pic of in the first post?
Hood
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 19, 2013, 04:41:27 PM
No... The pic was sent to me by the client after running the attached code. The previous attached code was the one I ran at his site and witnessed the behavior.
Title: Re: Unexpected Crop Circles
Post by: ger21 on May 19, 2013, 05:13:45 PM
I have to admit... I'm confused by the use of absolute distance combined with incremental IJ?

That's what 99% of CAM programs output.

Quote

In addition to changing the G90.1 to G91.1, should General Config also be changed to Incremental IJ?


IJ mode is modal. If your g-code has a G91.1 in it, it is changing it in General Config, and it should remain Incremental until you change it, or run code with a G90.1 in it, which will change it back to Absolute IJ.

It's good practice to have your CAM software add the G90.1 or G91.1 to your g-code, which will automatically set Mach3 to the correct IJ mode for that particular code. In almost all cases, this would be G91.1.
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 19, 2013, 07:48:36 PM
Well... I started this topic saying I had Mental cobwebs to clear out!  :o

Thanks to all for the assistance.

Paul
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 19, 2013, 09:41:00 PM


IJ mode is modal. If your g-code has a G91.1 in it, it is changing it in General Config, and it should remain Incremental until you change it, or run code with a G90.1 in it, which will change it back to Absolute IJ.

It's good practice to have your CAM software add the G90.1 or G91.1 to your g-code, which will automatically set Mach3 to the correct IJ mode for that particular code. In almost all cases, this would be G91.1.
[/quote]

I looked at General Config after loading my code with added G91.1, and the Absolute IJ button is still selected?

I modified my MeshCAM Mach3 Post Processor to include the G91.1. And I emailed a note to the MeshCAM author asking for his input on the issue. I'm guessing a large percentage of his customers are running Mach3 systems.

Paul
Title: Re: Unexpected Crop Circles
Post by: ger21 on May 19, 2013, 10:23:23 PM
Quote
I looked at General Config after loading my code with added G91.1, and the Absolute IJ button is still selected?

Run the g-code, then look at it. It will be changed.
 However, it doesn't appear to be modal between sessions, so you should probably change it in General Config, in case your g-code doesn't specify the mode.

I've been using MeshCAM since the very first beta version. I normally don't use arc fitting, but I have my post modified as well.
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 20, 2013, 02:32:13 AM
And... Presto! There it is!  ::)

Once again, assuming brought unwanted results. I assumed the pre-scan of the code would trigger the change.

Oh well... cycled dry with machine off. No harm, no foul, nothing to break... all good.

I'm not a Beta user of MeshCAM, but Robert called me personally to thank me for my license purchase. Sadly, the five years I spent away from my shop while machining for a paycheck, along with four strokes, put a dent in the 64+ year old gray cells.  :(

Thanks, Paul
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 20, 2013, 01:52:50 PM
Gerry,

I got a definite maybe response from Robert:

"I just had to go back in my code to double check but Meshcam should be
outputting absolute IJ. I may have to do some more testing to make sure
I'm not reading old code wrong but that's what it looks like to me.

For what it's worth, I use Mach3 on a Tormach and it works as-is.

That being said, your machine may have a different default configuration
so if it works, keep it."
-Robert
Title: Re: Unexpected Crop Circles
Post by: ger21 on May 20, 2013, 03:26:38 PM
I think Robert's mistaken, as it runs for me with Incremental IJ.
Title: Re: Unexpected Crop Circles
Post by: PaulWC on May 20, 2013, 06:40:54 PM
I'll go with his last words...

"So if it works, keep it."  8)
(Incremental IJ)