This is a "for what it's worth" comment that may be worth no more than you paid for it but:
I have been having trouble with the M3 compile issue for the past year -- but only intermittently.
Intermittently was that I could go for months without the issue and then it seemed to happen several jobs in a row.
The fix I found that had worked was to delete the Macro/My Profile directory and let Mach3 remake it when restarted.
After breaking a tool when I wasn't quick enough to notice the skipped M3 after a tool change, I decided to take a little more scientific approach to see if I could find the cause and eliminate it.
First a hint on where the problem comes from -- at least so far in my experience.
I had started keeping some records (mostly just copies of the defective Macro/profile directory but also the jobs that ran OK and those that then preceeded a failure).
I looked at this information to see if I could find a correlation with some action to identify the cause.
The first thing I noticed was that it seemed to happen only when I had used a cam program to create the G-Code so I studied the difference in the GCode from there and the jobs that didn't cause a problem.
The only difference I found was that the cam program was issuing an M3 S#### command on the same line. As my spindle speed is not controlled by Mach, I never do that.
Over the past few days I have run a dozen jobs with the cam program but edited the M3 lines to eliminate the S####. I placed the S#### above the M3 on its own line and so far the problem has not re-occurred.
Now to an improved fix.
I ran one of the unmodified files with the M3 S#### on the same line and immediately created the message and lost my M3 functionality
I have become tired of deleting the Macro/Profile directory because Mach3 needed stopping and restarting plus I had to remember to restore my original tools and offsets files. While I have read that some have found extraneous characters in the M3.mls file, I have never seen this, but re-creating the Macro/Profile file was always 100% effective at "fixing" the problem.
This time I looked carefully at the differences between one of my "bad" Macro/profile directory copies and the new directory created by Mach3. Other than the tools and fixtures files, the only differences were that the dates of the curve?.dat files had been modified. It appears that some of these are modified each time Mach3 runs.
I deleted all of them and lo and behold, my M3 problem was "fixed".
I have my doubts whether this will address all the causes but it has made my life much easier.
To summarize:
- Avoid using the S command on the same line as the M3 M4 commands. Note that I have read elsewhere that you must have at least one S command in the file for some versions of Mach3 or you will have other problems so I always add S1100 at the beginning of the file.
- If you encounter the problem, try deleting the curve?.dat files (and possibly the linearity.dat) from the Mach3/Macro/yourprofile directory.
I hope this helps someone... It sure drove me nuts for a long time.
Graham
Mach3 R3.043.066