Hello Guest it is March 28, 2024, 01:14:14 PM

Author Topic: Mach3 executing commands not issued  (Read 5900 times)

0 Members and 1 Guest are viewing this topic.

Mach3 executing commands not issued
« on: April 11, 2014, 02:48:48 PM »
Looking to get some help with my machine...

While running a program, Mach3 occasionally stops executing the written code and begins to SLOWLY move any number of axes in random directions. After resetting the program and rebooting the computer the program will run flawlessly for many cycles. Eventually, though, the same behavior begins to show up again. Any thoughts on what causes this to occur?

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
    • View Profile
Re: Mach3 executing commands not issued
« Reply #1 on: April 11, 2014, 04:30:16 PM »
Couple of questions,
 Do the DROs show the uncommanded  motion?
What version of Mach are you using?

Lastly can you please attach the xml of the profile you are using.
To attach you can use the additional options button on the reply page. You will need to have a unique name for your xml for the forum to accept. I suggest you zip it and call the zip file MDS2880

Hood

Offline rcaffin

*
  •  1,052 1,052
    • View Profile
Re: Mach3 executing commands not issued
« Reply #2 on: April 12, 2014, 11:37:50 PM »
Quote
While running a program, Mach3 occasionally stops executing the written code and begins to SLOWLY move any number of axes in random directions. After resetting the program and rebooting the computer the program will run flawlessly for many cycles. Eventually, though, the same behavior begins to show up again.
No, Mach per se does not do that. Accept that and move on.

Oh, and what OS, what version of Mach, and what interface (I/O device) are you using anyhow? Without that info - hopeless.

You could have a corrupted operating system of device driver.
You could have a corrupted installation of Mach.
You could have a corrupted I/O device, be it PP, USS or ESS or whatever.
You could have defective electronics.
You could have defective encoders (if using servos)
You could have a faulty power supply to the drivers.

I am sure I have missed lots of other possibilities.

Cheers

Re: Mach3 executing commands not issued
« Reply #3 on: April 13, 2014, 02:36:37 PM »
Any thoughts on what causes this to occur?

Asked to guess based on no other info I'd say your PC
Re: Mach3 executing commands not issued
« Reply #4 on: April 14, 2014, 07:48:43 AM »
Thank you for the responses...

Yes the Mach DRO's show the uncommanded movements as they are occurring.
Mach3 version R3.043.066.

Operating System Win7 64-bit
PC connected to ethernet smoothstepper

XML file attached

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
    • View Profile
Re: Mach3 executing commands not issued
« Reply #5 on: April 14, 2014, 04:49:23 PM »
With the DROs showing the motion then it would seem it is being commanded from somewhere and as you are using an external controller its even stranger.
Does the toolpath view show the axis going way off from the path they are supposed to be taking?
Hood

Offline rcaffin

*
  •  1,052 1,052
    • View Profile
Re: Mach3 executing commands not issued
« Reply #6 on: April 14, 2014, 05:42:56 PM »
Quote
Yes the Mach DRO's show the uncommanded movements as they are occurring. Mach3 version R3.043.066.
Operating System Win7 64-bit, PC connected to ethernet smoothstepper
Now that is REALLY wierd!
I can only suggest that something is getting corrupted somewhere, possibly in Mach's program buffer, and Mach is doing its best to interpret the gibberish as position commands. To test this you will need to COMPLETELY unload Mach from your system and then reinstal it, without any shortcuts at all.

It can't be a problem at the ESS as that would not be seen in the DROs.

Another possibility is a seriously corrupted nc program file, but that seems inconsistent with your description.

Um ... one other possibility is a memory corruption in your PC hardware. This could affect either Windows or where Mach stores the loaded program. Hum ... I would treat this as a serious possibility since the problem goes away after a reboot. Run some sort of VERY low-level system/memory check program for a few hours.

Cheers
Re: Mach3 executing commands not issued
« Reply #7 on: April 15, 2014, 08:02:59 AM »
The toolpath view does not show the expected path while my machine is running... let me explain what I am doing.

My machine is in an industrial environment as a station on an assembly line for wood burial caskets. Each casket gets a few holes drilled into the top edge where the lid will mate. The trouble is that we have 50+ different length/width combinations that go through this machine. Each casket also is not in the same location in the machine (could be rotated with respect to the machine X-Y axes). When the upstream operator pushes a casket into the machine, I use the probe function with a laser sensor to detect the edges (and therefore the dimensions and location) of the current casket. Based on the information collected I calculate where to drill the holes.

Since I am doing a LOT of geometry and using a LOT of conditionals, my entire program exists in a macro that I call from the G-Code program. Because every single run cycle is different than the previous cycles, the toolpath view only shows a few of the first moves and nothing more. The first few moves are the same for each job, but after that the moves are dependent upon what I have found.

I have read in the forums about issues with macros and have tried to incorporate what I have learned. As stated previously, the machine does operate correctly for most cycles using this macro setup.

The computer was purchased new for sole use with this machine. It has nothing running on it other than Mach and whatever came with it from the manufacturer. I have not yet tried to re-install Mach but I guess it can't hurt so I will.

I considered the effect of communication interference due to my environment (lots of power tools) but I find it hard to believe that interference is causing multiple axes to move oddly AND changing the feedrate simultaneously.

Offline rcaffin

*
  •  1,052 1,052
    • View Profile
Re: Mach3 executing commands not issued
« Reply #8 on: April 15, 2014, 08:25:43 AM »
Quote
The toolpath view does not show the expected path while my machine is running.
Understood.

Quote
Since I am doing a LOT of geometry and using a LOT of conditionals, my entire program exists in a macro that I call from the G-Code program. Because every single run cycle is different than the previous cycles, the toolpath view only shows a few of the first moves and nothing more. The first few moves are the same for each job, but after that the moves are dependent upon what I have found.

I have read in the forums about issues with macros and have tried to incorporate what I have learned. As stated previously, the machine does operate correctly for most cycles using this macro setup.
Oh Dear. I have a very bad feeling about this.  Two possibilities come to mind here.

The first is a bug in your software. I'll leave you to check that one.

The second is the size of the macro you describe. You see, Mach3 does not handle subroutines very well. I use them extensively as I do a lot of parametric programming, and virtually zero conventional CAD/CAM stuff. I have to be very careful with the depth of subroutines and what commands get called deep down. Otherwise, Mach3 gets into a bit of a tangle and I have to rewrite the code using fewer nestings.

Would it be possible for you to break your single macro into a number of consecutive shorter macros? You could use global variables like #1000 and upwards. That might clear some buffers. I am not saying this IS the problem or that it WILL solve your problem, but it is what immediately comes to mind.

Cheers
Roger
PS: yes, I recant. Mach can do strange things at times - but you have to work at it ...
Re: Mach3 executing commands not issued
« Reply #9 on: April 15, 2014, 08:39:27 AM »
I would not use Mach V.066 it's known to have problems. Smoothstepper recommends using Mach V.062 and ESS driver v10pqd1f. The new driver has fixes for data transmission problems on older drivers. In the ESS config page change the precalculated (lower left hand corner) number to 1500 or 2000.

 I was using V.066 and the machine would glitch unexpectedly. Went back to mach V.062 and problem disappeared.