You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, when the user clicks "stop" print, the function endingSequence in server/models/printers.py is hardcoded for the Prusa MK4.
If the printer has already extruded, commands are sent to just turn of bed/nozzle and fans and also home the printer. If the printer was stopped before first extrusion, the heat and fans just turn off and it doesn't home. It was causing issues to try to "home" the printer before it had extruded.
This "ending sequence" is what runs after a model is done printing. However, this is different from printer to printer. The ending sequence for the MK4 is different than for the MK3. Ideally, instead of having this hardcoded:
When the user registers the printer, they should also select the printer model. The printer model should be stored as a string in the printer table.
There should be another table that stores the "special" printer commands for a variety of 3D printers. Depending on which printer is printing, the code should draw the specific ending sequence from the database.
This same concept should also apply to other hard-coded GCode commands in the code, such as color change (M600), first extrusion (M569), M602 (pause).
We also hardcoded when there is a layer change. In the Prusa slicer for MK4, when the Gcode layer changes, the GCode file has a ;LAYER_CHANGE comment. This may not be universal to all printers. We need to detect when the layer changes so when the user clicks color change on the UI, the current layer finishes before changing color.
Keep in mind that not all printers support color change mid-print.
See how possible it is to expand this software compatibility. Start with just the MK3 and MK4. The ending sequences/special command can be found in various GitHub queueing software repositories in JSON documents.
The text was updated successfully, but these errors were encountered:
Right now, when the user clicks "stop" print, the function endingSequence in server/models/printers.py is hardcoded for the Prusa MK4.
If the printer has already extruded, commands are sent to just turn of bed/nozzle and fans and also home the printer. If the printer was stopped before first extrusion, the heat and fans just turn off and it doesn't home. It was causing issues to try to "home" the printer before it had extruded.
This "ending sequence" is what runs after a model is done printing. However, this is different from printer to printer. The ending sequence for the MK4 is different than for the MK3. Ideally, instead of having this hardcoded:
This same concept should also apply to other hard-coded GCode commands in the code, such as color change (M600), first extrusion (M569), M602 (pause).
We also hardcoded when there is a layer change. In the Prusa slicer for MK4, when the Gcode layer changes, the GCode file has a ;LAYER_CHANGE comment. This may not be universal to all printers. We need to detect when the layer changes so when the user clicks color change on the UI, the current layer finishes before changing color.
Keep in mind that not all printers support color change mid-print.
See how possible it is to expand this software compatibility. Start with just the MK3 and MK4. The ending sequences/special command can be found in various GitHub queueing software repositories in JSON documents.
The text was updated successfully, but these errors were encountered: