How to heatup nozzle and heatbed at same time


When starting the job at first only the heatbed heats up, then after
temperature is at aim, the nozzle starts to heatup.

how to heatup nozzle and heatbed at same time ?

I have a Anycubic i3 Mega 3D printer now with octoPrint (octoPi) 1.3.10
I am new at octoprint, so maybe it is a simple thing to change settings in order to heatup both (heatbed and hotend) at same time.

For slicing i use Cura.
Thanks for soon help from here
have a nice weekend,
Thomas germany


Hi Thomas, please share the “start gcode” configured in Cura, then we can help you modify it.


Hi tedder,
thank you for fast answer.
So here is the gcode file for a small cube test-print.
I made with cura 2.3.1(32bit) also tried with 3.6(64bit version) on
different PC's. So in cura can't have directly access to the generated
gcode-file, just can add a post-script like pause at height etc.
In octoprint have more possibilities with pre and post scripts.
So there, i need also a script after end of job to move hotend to X0 and Y0 (M28 X0 Y0) manually ok but should also be automatically after every print.

So let's solve the first,
thanks a lot

cube_30x30x30_test.gcode (278.6 KB)


It helps to look up the difference between the blocking and non-blocking versions of heating up the hotend(s) and the bed:

Which Non-blocking Blocking
Tool M104 M109
Bed M140 M190
Build chamber M141 M191

The strategy then is to anticipate the relative slowness of the bed's heater and factor it into the strategy for startup gcode:

; Target hotend/bed temperature of 190/60 in this scenario
M140 S50       ; Most of the way there, but next command begins immediately
M104 S160      ; Close, but below the plastic level for PLA, next command begins immediately
M190 S60       ; The longest delay will be between the last command and this, blocking
M109 S190      ; Should go quickly by comparison, blocking

Need help with Bed Temp

ok i think i understand, that blocking means, that the gcode-interpreter (printer) waits till the temperature is being arrived.
actual gcode:
M190 S80
M104 S205
M109 S205

So first command M190: First heating bed up to 90°C
and then when is done, heating up tool (hotend) to 205°C.
Ok so i can manually change to f.e.:
M140 S90
M104 S205
M190 S90
so i think both hotbed and hotend starts heating up, and
only the temperature from hotbed (which takes muc longer to heatup)
will be the trigger to go ahead in gcode.
But, do i have to change this manually on every file ?
I think there should be a better solution within cura or octoprint, right ?
So let's figure out how to put into gcode every time the same start routine automatically.


Sorry about that, I left out the "S" in each of the commands before (edited).

But no, you don't change this in every file you produce (unless you're into that). Usually you'd adjust things in your slicer so that it does this for you.


thanks for adding the "S".
So i will try this next days


the m140 is not needed.
The heatup starting order depends also on the power of your heaters.

My mk42 heatbed heats up to PLA(60) in 30s ABS(100) in 90s
The hotend to PLA(200) in 40s and to ABS in 65s
So at PLA the heatbed is faster and at ABS the nozzle is faster...


From what I understand, some of the cheaper printers have a combination of insufficient voltage and cheap bed heaters which result in a timeout on a blocking M190 otherwise. So the M140 gets things started a bit first with an immediate OK return from the firmware and then the blocking version which is now part of the way.


Heating the nozzle and bed at the same time may be less than ideal. The bed thermistor is usually located right next to or in the bed heater such that when the thermistor indicates a desired temperature has been reached, the top surface of the bed ( glass, Buildtac type material, magnetic plates, etc ) will not yet have reached temperature. Heating the nozzle second allows some time for the bed to simmer and stabilize before printing begins.