Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

OK,     it is the G91.1

I put // on that line  all is fine.


CodeInches "G20" // inches mode (Inches/Metric determined by Units above ^^^)
CodeMetric "G21" // metric mode
// Distance modes
CodeAbsolute "G90" // absolute distance coords
//CodeRelative "G91" // relative distance coords

// Spindle
CodeSpindleCW "M3"
CodeSpindleCCW "M4"

That's rather confusing. You say that you commented the CodeRelative "G91" line from the post-processor but the G-code you're outputting doesn't even have a G91 in it - it's using the CodeAbsolute/G90. There's a G91.1 that's being included via the PrefixBlock but that's a different code altogether and only applies to arc/helical motion command coordinates (which PixelCNC doesn't generate yet, just linear feeds and rapids right now).

I have a feeling that what "worked" was something else other than commenting out the CodeRelative line, because that should have no impact on the G-code that's output. I'd investigate further and compare the G-code that is actually being generated. Compare a program generated with and without the CodeRelative line commented out in the post, because they should really just be identical  due to the CodeRelative variable not being referenced anywhere in the actual command block definitions. I'm inclined to  think that the problem might be the G91.1 that's included in the PrefixCodeBlock and that Mach3 controller doesn't know that it's a G91.1, seeing it as a G91 instead. ...but that doesn't explain how "initializing" the machine with a different program causes it to work even with the G91.1 still in there.

Hrmmm.