GCode optimization for retracts and rapids

Would it be possible for an absolute dummy like me to use? I have a hard time figuring out GitHub pages, which file to download etc.

I thought that the query was about more general optimization.

1 Like

it’s not complicated…

open browser
go to https://fenrus75.github.io/FenrusCNCtools/ncopt/ncopt.html
CLick “choose file”
Give it your gcode file

At the very top of the page a “Save gcode” shows up… click that

… and you have the optimized gcode.

5 Likes

I tried @fenrus tool and didn’t find that it was really adding the rapids I was expecting (perhaps fusion changed their gcode output style or something?). Also, carbide motion rejected some of the files I gave it after running them through that tool… so I re-wrote my tool to be way less hacky.

I discovered that you have to manually specify the feed height in order to get good results, unfortunately. But still worth it.

The tool still needs a little work to become really usable (still spits out debug info, needs drag-and-drop support, etc) but if you’re comfortable with making python calls, it works great! I’ll update it once I get back from visiting my family over Christmas…

Be mindful! This is a work in progress, and if you hurt yourself or your hardware, it’s on you!

2 Likes

@rmonroe
I want to try your python code, but I can’t figure out how to pass my test file to it. I put your script in a directory with a file named test.nc. I tried fusionFix_v02.py(test.nc) with a few variations in a cmd window, but nothing seemed to pass my file to it. If I can get the basics, I should be good from there.

I got it to run renaming it to: test.py. I ran it in a cmd window with ‘python test.py’. I passed my test.nc to it by renaming your dropbox pathway to test.nc. I get a value error in line 43 - It does not like the string that talks about ‘internal error:…’