Most likely the original poster has moved on but yesterday when I was searching for a solution to a couple of issues this was the place that I ended up. This post will also serve as documentation for me and I hope it may help someone else in a similar situation. This is for newbies like myself, experts can feel free to ignore me
I have a Chinese OMIOCNC X6-2200 engraving machine. I ripped out the USB controller that came with it for Mach3 and installed a Mesa 7i76e and LinuxCNC. I'm good at the electronics, but not so much on Linux.
I use Solidworks2020 which has an HSMWorks post processor. There is a post processor you can select "LinuxCNC (EMC2)/linuxcnc".
Using this post I had 2 issues:
1- Material was being cut before my spindle motor was up to speed.
2- I was getting rounded corners on inside cuts.
After some googling the solution to 1 is to add "G4 P4" after the motor on command which adds a 4 second delay.
The solution to rounded corners is to add "G64 P.001 Q.001" on the header line. Seems pretty simple, and it is, but nowhere could I find how to do this automatically.
These instructions are for a windows machine.
1- Make a copy of the linuxcnc.cps likely found at c:\Program Files\HSMXpress\posts and put it on your desktop.
2- rename it
3- using Notepad++ or something similar open the file
4- Searched for "spindleSpeed" which takes you to the following line:
sOutput.format(spindleSpeed), mFormat.format(tool.clockwise ? 3 : 4)
5- Added to the end of the line so it looks like:
sOutput.format(spindleSpeed), mFormat.format(tool.clockwise ? 3 : 4), ("G4 P4")
6- Searched for "91.1" which takes you to the following line:
writeBlock(gAbsIncModal.format(90), gFeedModeModal.format(94), gPlaneModal.format(17), gFormat.format(91.1));
7- Added to the end of the line so it looks like:
writeBlock(gAbsIncModal.format(90), gFeedModeModal.format(94), gPlaneModal.format(17), gFormat.format(91.1), ("G64 P.001 Q.001"));
8- save the file
9- double click on the file and HSMWorks will attempt to compile the file. If successful it will offer to Install the Post for HSMWorks.
If you get this message respond "Yes" and you are done. If you get an error message then you have a syntax error in the file and you will need to fix it before the compile is successful.
Now when you "Post Process" a file in Solidworks you select "Setup" "Use Personal Post Library". Select the file name you used in Line 2 above and you are good to go. Check that your .ngc file has the additional G codes and your good to go.
Thanks to all that pointed me in the right direction.