Parts of generated gCode not modifyable

I find it difficult to understand where I can change some of the gCode settings.
Most importantly, Line 28 “; PATHIO: Pathio necessary settings” and the the following gCode Prefix.

The prefix can be edited but not the stuff following “PATHIO: Pathio necessary settings”. Specifically, I don’t need M200 D0. My printer doesn’t understand it.

Then, in the prefix, the selected extruder for the object to print is not respected and the gCode always heats up Extruder 0. Even adding “T{{ state/active_toolhead }} ; Select desired extruder” to that section does still select T0. I have one object on the bed and it needs to be printed with T1. I select T1 in every option but T1 is only ever heated AFTER T0 is already at full temperature - in the “PATHIO: New layer” settings.

Then, printing all settings inside the gCode makes sense. But the way it is done is not good as some of the lines have 14600+ characters. My printer pre-processor to x3g does not like that very much and gives a buffer overflow error.

In other words, even after one hour or attempting to configure the slicer for my printer there are many gcodes I can’t edit. Therefore, I can’t print, yet.

All gCodes need to be modifyable if you want the slicer to be adaptable for all printers. Making good suggestions on how to lay out the code is good. But making “necessary settings” that are messing with some printers is not a good idea.

1 Like

Hi @McNugget
As mentioned in this thread we’re looking into moving the “necessary settings” into the starting gcode. That will let you adjust them for your printer, as not all printers need each of those commands. We’d do it right now, but we’re a little worried that people might remove them without knowing what they do and get weird errors. We’re planning on adding scripting warnings to make sure you know what you’re doing if you forget important settings like those.

As for heating the right hotend, this is a little tricky. First of all, note that {{ state/active_toolhead }} will give you the toolhead that Pathio thinks you’re currently printing with. Since it hasn’t been changed yet at the start of the print, I suspect that’s why you’re getting T0 when you want T1. We’ll look into that.

If you want to heat the correct HotEnd, I think you might have to set your T0 temperature to be 0 degrees C, or you’ll have to update your start gcode and comment out the line that heats T0. This case of handling heating (and presumably priming) of multiple hotends is something we’re still investigating. Do you have a suggestion on how to best present it to you?

Last, for the dump of the slicing settings: we’ve got a bug at the moment that is causing those lines to be huge. It sounds like we should make those optional, too since not all printers will like the dump of slicing settings at the start…

1 Like