Errors printing over USB


New Member
I came across something lately that may be of help to someone.

Octoprint (and possibly Simplify3D too -- I had similar issues with it) has a problem with long running commands when printing over USB. Octoprint doesn't inspect the commands being sent to the printer so it has no idea how long a command takes. It has a constant timeout value in its settings that defaults to 5 seconds. Any command taking longer gets timed out and the next command ends up being sent before the printer is ready.

The printer will ask for resends, but there is a bug with that in Octoprint. Possibly in Simplify3D also because I had the same or similar issues with it.

Eventually the firmware gets confused enough to become completely unresponsive.

The solution I have for now is to calculate my longest possible move and change the communication timeout value in Octoprint. It was moving about 400mm (near the full length of the bed) creating a raft generated by Simplify3D at 470 mm/min. That math works out to about 51 seconds, so I set my timeout to be at 60 seconds for a little padding and a nice round number.

I am also going to look into improving Octoprint's command timeout to be smarter (the timeout value in the settings should be added onto the calculated time it takes to move the distance specified by the command).
This would explain a lot, Marcus.

I've had one of my printers just stop moving mid print and sit there with the nozzle at full temp until I discovered it sometimes hours later... Not good. This was with OctoPrint.

Will go back to SD cards for that one.

Also looking into Astroprint as it's the only one of these Pi control suites that'll control multiple extruders.


New Member
Yes, that's exactly what happened to me. I had to disconnect and reconnect to the printer in order to do anything. I was able to restart the print once or twice by deleting lines in the gcode up to where it stopped, reconnecting to the printer, set position to where it last stopped, and printing the altered gcode file. However I had to catch it before Octoprint's terminal lost the last command the printer acknowledged. That's too much babysitting for me on a 29 hour print.

The good news is that I can still print through Octoprint -- I just have to either load the gcode onto SD card or increase the command timeout in Octoprint's settings.

I like all the details I can get remotely through Octoprint's web interface when printing from USB through it, so I am leaning toward the increased timeout for now.