I failed to set an included angle for my chamfer mill (V-bit). It generated some g-code that had a very bad failure mode. The tool path generated sent it to Z- which would have been catastrophic. I wasn’t running anything (just checking the generated g-code, so maybe it would have not sent it to the machine.
Here is the generated g-code:
It gave me a few weird error dialogs, but the one that made me check the tool definition was something about having zero tool length. Made sense once I saw the included angle was 0. Perhaps a more appropriate default, like 90.
Here is a representative .mage file and the output .gc
Granted, this creates an error message and asks if you want to continue, but when you do it generates a tool path that will crash any machine that doesn’t have soft limits enabled.
After creating that file I tried to Preview and it froze MailMage. I had to Force Quit the app. Once I fixed the included angle on the chamfer mill, it previewed without issue.
Has this been resolved? I’m trying to find a simple but complete solution for our students to generate Toolpaths for our XCarve. If MillMage still generates improper g-code that will crash the machine, it is pretty much a non-starter.
To edit this, go to CNC Tools > Tool Library > Select the tool, then click the Edit pencil, and enter an included angle on the tool.
This should be a warning when generating the GCode, I would think, so I’ll poke into that detail, but if you’re getting a bad or no preview, check that your tools are defined fully in the Tool Library.
I understand why it happened. I posted that earlier. CAM software should never generate invalid g-code. It should have errored out and not produced any toolpath for the invalid tool. The fact that it chose -MAXINT shows that it recognized an error, but failed to abort out completely.
It has been - an included angle of less than 1 is now an error, and if the calculated depth exceeds the project depth, you get a warning with an option to stop:
Having said that, any cnc package could generate tool paths that could crash the machine. If I set up my project settings to use a 15mm material, and then use that project on 1/8" plywood, it’s going to go straight through the material into the bed, and there’s no way we could detect that.
We’ll obviously do what we can to prevent things from going wrong based on the settings we’ve been given, and will warn when a path will cut through your material, but sometimes that’s intended (drill operations, for example, usually need to cut slightly through).