Jump to content

Marlin 2.1.2.1 on UM2+ stops and reboots when starting print


lwmbecker
Go to solution Solved by Allrounder,

Recommended Posts

Posted · Marlin 2.1.2.1 on UM2+ stops and reboots when starting print

Hei,

 

The x-axis stepper driver burnt out (motor making weird noises on that stepper driver) on our UM2+, which is why I swapped the stepper to the E2 axis and swapped the pins accordingly in marlin. Previously we were using stock software.

Now I think I made the new firmware (marlin 2.1.2.1) work as far as homing and bed levelling and extrusion with e1. No unusual noises. Everything moves apparently in the correct directions.

 

The issue is now that when I start printing it starts up correctly (heats bed and nozzle, homing, move to front left, extrude some feed stock etc).. but then, just after it moves to the first coordinates of the actual print (in this case the skirt/base thing) marlin suddenly fails and reboots without any error message. I think it’s round about the line of of where I print “problems start…” 

 

Any hints to where I could continue my bug search? I am guessing it’s still something that is set incorrectly in marlin.. but what? 🤷🏻‍♂️


Anyone? 🙂

 

gcode snippet:

 

;FLAVOR:Marlin
;TIME:2945
;Filament used: 0.83648m
;Layer height: 0.15
;MINX:62.004
;MINY:85.927
;MINZ:0.27
;MAXX:133.287
;MAXY:140.301
;MAXZ:15.72
;Generated with Cura_SteamEngine main
M140 S60 ;set bed temp
M105 ;send temp report to host
M190 S60 ;wait for bed to reach temp 
M104 S200 ;set hotend temp
M105 ;send temp report to host
M109 S200 ;wait for hotend to reach temp
M82 ;absolute extrusion mode
G21 ;metric values
G90 ;absolute positioning
M82 ;set extruder to absolute mode
M107 ;start with the fan off
G28 Z0 ;move Z to bottom endstops
G28 X0 Y0 ;move X/Y to endstops
G1 X15 Y0 F4000 ;move X/Y to front of printer
G1 Z15.0 F9000 ;move the platform to 15mm
G92 E0 ;zero the extruded length
G1 F200 E10 ;extrude 10 mm of feed stock
G92 E0 ;zero the extruded length again
G1 Y50 F9000
;Put printing message on LCD screen
M117 Printing...
G92 E0
G92 E0
G1 F1500 E-6.5
;LAYER_COUNT:104
;LAYER:0
M107
G0 F4500 X69.088 Y98.143 Z0.27
G0 X64.233 Y102.949
;TYPE:SKIRT
M117 problems start…
G1 F1500 E0
G1 F1800 X64.646 Y102.417 E0.0114
G1 X65.539 Y101.364 E0.03478
G1 X66.004 Y100.863 E0.04635
G1 X66.992 Y99.886 E0.06987
G1 X67.494 Y99.431 E0.08134
G1 X68.56 Y98.546 E0.1048
G1 X69.088 Y98.143 E0.11604
G1 X70.221 Y97.355 E0.13941
G1 X70.892 Y96.938 E0.15278

  • Link to post
    Share on other sites

    Posted · Marlin 2.1.2.1 on UM2+ stops and reboots when starting print

    Actually, this behaviour is slightly different depending on if I choose the gcode flavor “marlin” or “marlin volumetric” in Cura.

    I mixed the two in the post above, updated and correct below. 

    As you can see below the problem starts slightly earlier in the “marlin” flavor, and slightly later in the “marlin volumetric” flavor. In the “marlin” flavor it already reboots just after it extruded 10mm.. but doesn’t move to the actual starting position of the piece.

     

    gcode snippet:

     

    ;FLAVOR:Marlin
    ;TIME:2945
    ;Filament used: 0.83648m
    ;Layer height: 0.15
    ;MINX:62.004
    ;MINY:85.927
    ;MINZ:0.27
    ;MAXX:133.287
    ;MAXY:140.301
    ;MAXZ:15.72
    ;Generated with Cura_SteamEngine main
    M140 S60 ;set bed temp
    M105 ;send temp report to host
    M190 S60 ;wait for bed to reach temp 
    M104 S200 ;set hotend temp
    M105 ;send temp report to host
    M109 S200 ;wait for hotend to reach temp
    M82 ;absolute extrusion mode
    G21 ;metric values
    G90 ;absolute positioning
    M82 ;set extruder to absolute mode
    M107 ;start with the fan off
    G28 Z0 ;move Z to bottom endstops
    G28 X0 Y0 ;move X/Y to endstops
    G1 X15 Y0 F4000 ;move X/Y to front of printer
    G1 Z15.0 F9000 ;move the platform to 15mm
    G92 E0 ;zero the extruded length
    G1 F200 E10 ;extrude 10 mm of feed stock
    G92 E0 ;zero the extruded length again
    G1 Y50 F9000

    M117 problems start…
    ;Put printing message on LCD screen
    M117 Printing...
    G92 E0
    G92 E0
    G1 F1500 E-6.5
    ;LAYER_COUNT:104
    ;LAYER:0
    M107
    G0 F4500 X69.088 Y98.143 Z0.27
    G0 X64.233 Y102.949
    ;TYPE:SKIRT
    G1 F1500 E0
    G1 F1800 X64.646 Y102.417 E0.0114
    G1 X65.539 Y101.364 E0.03478
    G1 X66.004 Y100.863 E0.04635
    G1 X66.992 Y99.886 E0.06987
    G1 X67.494 Y99.431 E0.08134
    G1 X68.56 Y98.546 E0.1048
    G1 X69.088 Y98.143 E0.11604
    G1 X70.221 Y97.355 E0.13941
    G1 X70.892 Y96.938 E0.15278

     

    another snipped (volumetric):

     

    ;FLAVOR:Marlin(Volumetric)
    ;TIME:2860
    ;Filament used: 5336.23mm3
    ;Layer height: 0.15
    ;MINX:62.004
    ;MINY:85.927
    ;MINZ:0.27
    ;MAXX:133.287
    ;MAXY:140.301
    ;MAXZ:15.72
    ;Generated with Cura_SteamEngine main
    M190 S60
    M104 S200
    M109 S200
    M82 ;absolute extrusion mode
    G21 ;metric values
    G90 ;absolute positioning
    M82 ;set extruder to absolute mode
    M107 ;start with the fan off
    G28 Z0 ;move Z to bottom endstops
    G28 X0 Y0 ;move X/Y to endstops
    G1 X15 Y0 F4000 ;move X/Y to front of printer
    G1 Z15.0 F9000 ;move the platform to 15mm
    G92 E0 ;zero the extruded length
    G1 F200 E10 ;extrude 10 mm of feed stock
    G92 E0 ;zero the extruded length again
    G1 Y50 F9000
    ;Put printing message on LCD screen
    M117 Printing...
    G92 E0
    G92 E0
    G10
    ;LAYER_COUNT:104
    ;LAYER:0
    M107
    G0 F4500 X69.088 Y98.143 Z0.27
    G0 X64.233 Y102.949
    ;TYPE:SKIRT

    M117 problems start…
    G11
    G1 F1800 X64.646 Y102.417 E0.07274
    G1 X65.539 Y101.364 E0.22185
    G1 X66.004 Y100.863 E0.29567
    G1 X66.992 Y99.886 E0.44574
    G1 X67.494 Y99.431 E0.51891
    G1 X68.56 Y98.546 E0.66854
    G1 X69.088 Y98.143 E0.74028
    G1 X70.221 Y97.355 E0.88933

  • Link to post
    Share on other sites

    Posted · Marlin 2.1.2.1 on UM2+ stops and reboots when starting print

    Hello,

     

    this may be a serial cable problem see here:

    #define SERIAL_OVERRUN_PROTECTION has help for me.

     
    // Bad Serial-connections can miss a received command by sending an 'ok'
    // Therefore some clients abort after 30 seconds in a timeout.
    // Some other clients start sending commands while receiving a 'wait'.
    // This "wait" is only sent when the buffer is empty. 1 second is a good value here.
    //#define NO_TIMEOUTS 1000 // Milliseconds
     
    // Some clients will have this feature soon. This could make the NO_TIMEOUTS unnecessary.
    //#define ADVANCED_OK
     
    // Printrun may have trouble receiving long strings all at once.
    // This option inserts short delays between lines of serial output.
    //#define SERIAL_OVERRUN_PROTECTION
     
    // For serial echo, the number of digits after the decimal point
    //#define SERIAL_FLOAT_PRECISION 4
  • Link to post
    Share on other sites

    Posted · Marlin 2.1.2.1 on UM2+ stops and reboots when starting print

    Hei, thanks for the reply!

     

    That is a good idea and fits with the observations I made today. Inserted an M0 command between all lines where it stopped previously and it seemed to work fine when clicking through each command, so I got a bit further in the print. The next command after the last M0 led again to a reboot. 
    Will try your idea with SERIAL_OVERRUN_PROTECTION on Monday.


    Tried this btw as well with the newest version of the bugfix 2.1.x branch, but the results were quite similar. Just that with this firmware I could not complete the manual bed levelling procedure. Measured all 9 points correctly, but then rebooted during homing.

  • Link to post
    Share on other sites

    Posted · Marlin 2.1.2.1 on UM2+ stops and reboots when starting print

    Hm, actually I just double checked in the source codes and in both cases those lines where already defined (#define ADVANCED_OK and #define SERIAL_OVERRUN_PROTECTION).

     

    But could it maybe be something related to the buffer size? All test so far have been done via the build in SD card reader.

     

    // @section gcode

    // The number of linear moves that can be in the planner at once.
    #if ALL(HAS_MEDIA, DIRECT_STEPPING)
      #define BLOCK_BUFFER_SIZE  8
    #elif HAS_MEDIA
      #define BLOCK_BUFFER_SIZE 16
    #else
      #define BLOCK_BUFFER_SIZE 16
    #endif

    // @section serial

    // The ASCII buffer for serial input
    #define MAX_CMD_SIZE 96
    #define BUFSIZE 16

     

  • Link to post
    Share on other sites

    • Solution
    Posted · Marlin 2.1.2.1 on UM2+ stops and reboots when starting print

    and what happens if you deactivate all these options?

    12 hours ago, lwmbecker said:

    #define ADVANCED_OK and #define SERIAL_OVERRUN_PROTECTION).

     

    12 hours ago, lwmbecker said:

      #define BLOCK_BUFFER_SIZE 16

     

     

    12 hours ago, lwmbecker said:

    #define BUFSIZE 16

    Ich habe da 8 gemacht, 16 geht natürlich auch.

     

    I also had this problem with my Arduino 4Due that the board simply reboots and the printing stops. It was years ago, I think the problem was with the buffer and serial cable. If you reduce your print speed to minimum, should it print and reboot the board at full speed? If so, then the above problem or display controller misconfigured.

  • Link to post
    Share on other sites

    Posted · Marlin 2.1.2.1 on UM2+ stops and reboots when starting print

    Awesome, thanks for the help! 
    Tried disabling everything or only some of them, but that showed no difference. 
     

    On 11/4/2023 at 11:06 AM, Allrounder said:

    Ich habe da 8 gemacht, 16 geht natürlich auch.

    Nice, I tried 8 for BUFSIZE now as well, leaving all other mentioned parameters untouched and hurray! That did the trick. 
    Danke! 🤩

  • Link to post
    Share on other sites

    Posted · Marlin 2.1.2.1 on UM2+ stops and reboots when starting print

    I'm glad it still worked out, thought you had already given up. The Germans are good, aren't they?

    I would definitely enable #define SERIAL_OVERRUN_PROTECTION if you have a long print, long I mean hours or days, otherwise you may reboot the printer.

    I recommend you to activate this function: Input Shaping -- EXPERIMENTAL , so that your print head never vibrates like crazy again.

     

      *Input Shaping -- EXPERIMENTAL

      *

     * Zero Vibration (ZV) Input Shaping for X and/or Y movements.

     *

     * This option uses a lot of SRAM for the step buffer. The buffer size is

     * calculated automatically from SHAPING_FREQ_[XY], DEFAULT_AXIS_STEPS_PER_UNIT,

     * DEFAULT_MAX_FEEDRATE and ADAPTIVE_STEP_SMOOTHING. The default calculation can

     * be overridden by setting SHAPING_MIN_FREQ and/or SHAPING_MAX_FEEDRATE.

     * The higher the frequency and the lower the feedrate, the smaller the buffer.

     * If the buffer is too small at runtime, input shaping will have reduced

     * effectiveness during high speed movements.

     *

     * Tune with M593 D<factor> F<frequency>:

     *

     *  D<factor>    Set the zeta/damping factor. If axes (X, Y, etc.) are not specified, set for all axes.

     *  F<frequency> Set the frequency. If axes (X, Y, etc.) are not specified, set for all axes.

     *  T[map]       Input Shaping type, 0:ZV, 1:EI, 2:2H EI (not implemented yet)

     *  X<1>         Set the given parameters only for the X axis.

     *  Y<1>         Set the given parameters only for the Y axis.

     */

    #define INPUT_SHAPING_X

    #define INPUT_SHAPING_Y

    //#if EITHER(INPUT_SHAPING_X, INPUT_SHAPING_Y)

      //#if ENABLED(INPUT_SHAPING_X)

        #define SHAPING_FREQ_X  50          // (Hz) The default dominant resonant frequency on the X axis.

        #define SHAPING_ZETA_X  0.15f       // Damping ratio of the X axis (range: 0.0 = no damping to 1.0 = critical damping).

      //#endif

      //#if ENABLED(INPUT_SHAPING_Y)

        #define SHAPING_FREQ_Y  50          // (Hz) The default dominant resonant frequency on the Y axis.

        #define SHAPING_ZETA_Y  0.15f       // Damping ratio of the Y axis (range: 0.0 = no damping to 1.0 = critical damping).

      //#endif

      #define SHAPING_MIN_FREQ  20        // By default the minimum of the shaping frequencies. Override to affect SRAM usage.

      #define SHAPING_MAX_STEPRATE 10000  // By default the maximum total step rate of the shaped axes. Override to affect SRAM usage.

      #define SHAPING_MENU                // Add a menu to the LCD to set shaping parameters.

    //#endif

  • Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now
    • Our picks

      • UltiMaker Cura 5.7 stable released
        Cura 5.7 is here and it brings a handy new workflow improvement when using Thingiverse and Cura together, as well as additional capabilities for Method series printers, and a powerful way of sharing print settings using new printer-agnostic project files! Read on to find out about all of these improvements and more. 
         
          • Like
        • 26 replies
      • S-Line Firmware 8.3.0 was released Nov. 20th on the "Latest" firmware branch.
        (Sorry, was out of office when this released)

        This update is for...
        All UltiMaker S series  
        New features
         
        Temperature status. During print preparation, the temperatures of the print cores and build plate will be shown on the display. This gives a better indication of the progress and remaining wait time. Save log files in paused state. It is now possible to save the printer's log files to USB if the currently active print job is paused. Previously, the Dump logs to USB option was only enabled if the printer was in idle state. Confirm print removal via Digital Factory. If the printer is connected to the Digital Factory, it is now possible to confirm the removal of a previous print job via the Digital Factory interface. This is useful in situations where the build plate is clear, but the operator forgot to select Confirm removal on the printer’s display. Visit this page for more information about this feature.
          • Like
        • 0 replies
    ×
    ×
    • Create New...