how to generate prefix postfix gcode
 
Notifications
Clear all

how to generate prefix postfix gcode  

  RSS
gratefulfrog
(@gratefulfrog)
New Member
how to generate prefix postfix gcode

Hi,

I've been using the old Slic3r and have tried to convert my settings to use prusaslicer 2.1.1, but I can't figure out how to add my own prefix and postfix gcode?

Can anyone point me to the solution?

Thanks for a great tool!

Best Answer by bobstro:

Do you mean Printer Settings->Custom G-code?

Posted : 23/02/2020 9:37 pm
bobstro
(@bobstro)
Illustrious Member
RE: how to generate prefix postfix gcode

Do you mean Printer Settings->Custom G-code?

My notes and disclaimers on 3D printing and miscellaneous other tech projects
He is intelligent, but not experienced. His pattern indicates two dimensional thinking. -- Spock in Star Trek: The Wrath of Khan...
Posted : 23/02/2020 9:59 pm
gratefulfrog
(@gratefulfrog)
New Member
Topic starter answered:
RE: how to generate prefix postfix gcode

Oh, I see that is only available in "expert mode". I hadn't noticed the simple advanced expert buttons on the far upper right, so far from all the other  buttons...

Thanks for your help I'm looking forward to slicing better than ever!

Cheers!

Bob

Posted : 23/02/2020 10:05 pm
gratefulfrog
(@gratefulfrog)
New Member
Topic starter answered:
RE: how to generate prefix postfix gcode

Now, I could add my own gcode, but how can I remove the unwanted prefix code?

M201 X9000 Y9000 Z500 E10000 ; sets maximum accelerations, mm/sec^2
M203 X500 Y500 Z12 E120 ; sets maximum feedrates, mm/sec
M204 P1500 R1500 T1500 ; sets acceleration (P, T) and retract acceleration (R), mm/sec^2
M205 X10.00 Y10.00 Z0.20 E2.50 ; sets the jerk limits, mm/sec
M205 S0 T0 ; sets the minimum extruding and travel feed rate, mm/sec
M107
Posted : 23/02/2020 10:16 pm
Neophyl
(@neophyl)
Famed Member
RE: how to generate prefix postfix gcode

@gratefulfrog

cant recall which start lines it is but if you dont have certain lines in your start up code Prusa Slicer will add them automatically, at least for Marlin firmware flavour option.

the ones you listed look like the ones I saw in a discussion on github about this.  iirc the issue/discussion was someone using a non prusa printer who was expecting the printer firmware to supply all the defaults so their start custom section didnt have the lines in.  However with Marlin selected as firmware type the lines get added so were over riding the firmware values.  The outcome was to either change firmware type or to read the firmware values back and enter them in the start gcode to make them the same.

Adding them to the start code is a better option as it should also make printing time estimates more accurate.

Posted : 24/02/2020 7:11 am
bobstro
(@bobstro)
Illustrious Member
RE: how to generate prefix postfix gcode
Posted by: @gratefulfrog

Now, I could add my own gcode, but how can I remove the unwanted prefix code?

M201 X9000 Y9000 Z500 E10000 ; sets maximum accelerations, mm/sec^2
M203 X500 Y500 Z12 E120 ; sets maximum feedrates, mm/sec
M204 P1500 R1500 T1500 ; sets acceleration (P, T) and retract acceleration (R), mm/sec^2
M205 X10.00 Y10.00 Z0.20 E2.50 ; sets the jerk limits, mm/sec
M205 S0 T0 ; sets the minimum extruding and travel feed rate, mm/sec
M107

Not exactly removal, but those settings should be derived from the values entered in Printer Settings->Machine limits in PrusaSlicer. Change those settings and you should get a reasonable set of M20x values in your gcode.

My notes and disclaimers on 3D printing and miscellaneous other tech projects
He is intelligent, but not experienced. His pattern indicates two dimensional thinking. -- Spock in Star Trek: The Wrath of Khan...
Posted : 24/02/2020 3:16 pm
gratefulfrog
(@gratefulfrog)
New Member
Topic starter answered:
RE: how to generate prefix postfix gcode

Hi @bobstro @neophyl,

Indeed, I am using a non prusa printer with firmware presets that are being overwritten by the default Marlin prefix code as thinks prusa-slicer.

After trying some other gcode flavours, it seems that repetier doesn't insert any prefeix code, but I would need to do more testing to be sure.

It would be nicer if the inserted prefix code were displayed and modifiable by the user, but that's the software developer in me talking.

Strangely, Slic3r doesn't insert any prefix code, despite being set to Marlin flavour.

I will try to do some more tests and post back results. 

Thanks for all your help!

B

Posted : 25/02/2020 9:06 am
Share: