Nozzle crashed into bed while homing - can this be avoided?



  • Hey everyone,

    First of all, I am a completely new Duet user, so excuse my lack of experience.

    I just finished the initial assembly of my CoreXY 3D printer, running a Duet 3. When I wanted to start my first test print, I realized I had to change some things up, and therefore paused and cancelled it. I started printing again afterwards, but during homing, the nozzle crashes straight into my bed and made a hole in it - damn!

    I cannot seem to figure out exactly why it crashed the bed, or how I can ensure it does not happen again. What I think is that when homing X or Y fails, it for some reason still goes on with the movements to home Z, but without deploying the probe. I plan to tune the sensorless homing to be more reliable, or even add micro switches for homing, but I would still like for this to not happen if something is off.

    I don't know exactly which of these errors relate, but these are what I could find in my console:
    16.6.2020 23.28.22 G28
    Error: G0/G1: insufficient axes homed
    16.6.2020 23.32.24 Error: Z probe was not triggered during probing move
    Error: Z probe was not triggered during probing move
    16.6.2020 23.33.29 M120 G91 G1 Z25 F6000 G90 M121
    Error: G0/G1: insufficient axes homed

    What I think might be relevant from my setup:

    • Sensorless homing on X and Y and BLTouch on Z.
    • All my motors are the E3D high torque motor.
    • I am running true bed levelling

    Trying to attach the relevant configs and the gcode I was trying to print here. It got flagged as spam when I initially tried. Hopefully this works:
    3DBenchy.gcode
    config.g
    homeall.g
    homey.g
    homex.g
    homez.g
    bed.g

    Here is a picture of what the printer looks like at the moment. Thank you in advance!
    IMG_2840.jpg



  • Nozzle crashed into bed while homing - can this be avoided?

    in general test limit switchs first
    then test motor directions with small moves
    and use normally closed limit switches so that any most failures of the switch will prevent movement when homing.

    (and reduce motor speed and current while testing)



  • @bearer said in Nozzle crashed into bed while homing - can this be avoided?:

    Nozzle crashed into bed while homing - can this be avoided?

    in general test limit switchs first
    then test motor directions with small moves
    and use normally closed limit switches so that any failure of the switch will prevent movement when homing.

    I was considering whether I should use switches, but I thought that, since I don't need that much accuracy on homing (unless if I have to resume after power loss), it should be fine without for the time being. I did test the motor directions and sort all of that out first, and also got sensorless homing working. It just seems that it sometimes fail homing X/Y when the tool head starts from the middle of the bed instead of close to where it homes against.

    But is there not a way to halt everything in case it misses homing an axis instead of it just continuing to move stuff?


  • Moderator

    Not sure exactly what the sequence of events was to cause the problem. If the stall detection detected a false positive then you wouldn't get the insufficient axis error. You should definitely do some more testing and tuning on the sensorless homing. It can work fine, but it's not as reliable as a simple switch.

    Can you post your pause.g and cancel.g macros if they exist? I can't see this part anywhere in your posted files G91 G1 Z25 F6000 G90

    Dropping the motor currents (especially for z) during homing is a good idea. Ideally you can get it low enough to stall reliably when it's blocked, but still high enough to move reliably.



  • @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    Not sure exactly what the sequence of events was to cause the problem. If the stall detection detected a false positive then you wouldn't get the insufficient axis error. You should definitely do some more testing and tuning on the sensorless homing. It can work fine, but it's not as reliable as a simple switch.

    Can you post your pause.g and cancel.g macros if they exist? I can't see this part anywhere in your posted files G91 G1 Z25 F6000 G90

    Dropping the motor currents (especially for z) during homing is a good idea. Ideally you can get it low enough to stall reliably when it's blocked, but still high enough to move reliably.

    I am not entirely sure either. Also I cannot figure out whether it actually was caused by the print, pause, cancel, print sequence, or whether it could happen on any print start. I cannot either see how false positives in sensorless homing could make this happen, and not sure if it did. I got a feeling that it tried to sensorless home X or Y, did not get a positive, but carried one with the movements involved in homing Z without actually deploying a probe or anything.

    Sorry I did not attach those other configs, I am still trying to wrap my head around all the new things here. I do not have a cancel, but I do have a stop config. I will also attach the deploy and retract probe configs:

    stop.g sleep.g retractprobe.g pause.g deployprobe.g

    I am using SuperSlicer by the way, and I will just paste my start/end gcodes here:
    Start:

    M106 P0 S0 ; Turn part fan off
    G28 ; Home all
    ;G32 ; True Bed Levelling
    G0 X0 Y0 F9000 ; Go to front
    G0 Z0.15 ; Drop to bed
    G92 E0 ; zero the extruded length
    G1 X200 E30 F500 ; Extrude 25mm of filament in a 4cm line
    G92 E0 ; zero the extruded length
    G1 E-1 F500 ; Retract a little
    G1 X220 F4000 ; Quickly wipe away from the filament line
    G1 Z0.3 ; Raise and begin printing.
    

    End:

    M104 S0 ; turn off extruder
    M140 S0 ; turn off bed
    G91 ; use relative coordinates for jogging
    G1 Z10 F1800 ; raise Z by 10mm at 1800 mm/min
    G90 ; switch back to absolute coordinates
    M84 ; disable motors
    M106 P0 S0 ; Turn part fan off
    

  • Moderator

    I don't see anything unusual in the rest of your files.

    The only thing I would recommend would be to change any Z moves in your start and end gcode to include ; E in the comment so that the DWC parser ignores those moves when determining the object height and layer thickness.

    Can you try to duplicate the behaviour by pausing and canceling a print?

    Also can you confirm which firmware you are using by sending M115?



  • Thank you very much for your help thus far, it is highly appreciated.

    @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    I don't see anything unusual in the rest of your files.

    Good to know there is nothing too unreasonable in there at least. It is all probably a bit messy since I am still learning, so please excuse that.

    @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    The only thing I would recommend would be to change any Z moves in your start and end gcode to include ; E in the comment so that the DWC parser ignores those moves when determining the object height and layer thickness.

    I am sorry, I did not quite catch what you meant by that recommendation. Do you mind explaining that a bit more what that does and how to use it? I unfortunately could not find a resource explaining it so I could read up on it.

    Do you mean that I change:

    M106 P0 S0 ; Turn part fan off
    G28 ; Home all
    G0 X0 Y0 F9000 ; Go to front
    G0 Z0.15 ; E ; Drop to bed
    G92 E0 ; zero the extruded length
    G1 X200 E30 F500 ; Extrude 25mm of filament in a 4cm line
    G92 E0 ; zero the extruded length
    G1 E-1 F500 ; Retract a little
    G1 X220 F4000 ; Quickly wipe away from the filament line
    G1 Z0.3 ; E ; Raise and begin printing.
    

    to:

    M106 P0 S0 ; Turn part fan off
    G28 ; Home all
    G0 X0 Y0 F9000 ; Go to front
    G0 Z0.15 ; E ; Drop to bed
    G92 E0 ; zero the extruded length
    G1 X200 E30 F500 ; Extrude 25mm of filament in a 4cm line
    G92 E0 ; zero the extruded length
    G1 E-1 F500 ; Retract a little
    G1 X220 F4000 ; Quickly wipe away from the filament line
    G1 Z0.3 ; E ; Raise and begin printing.
    

    And end will look like this:

    M104 S0 ; turn off extruder
    M140 S0 ; turn off bed
    G91 ; use relative coordinates for jogging
    G1 Z10 F1800 ; E ; raise Z by 10mm at 1800 mm/min
    G90 ; switch back to absolute coordinates
    M84 ; disable motors
    M106 P0 S0 ; Turn part fan off
    

    @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    Can you try to duplicate the behaviour by pausing and canceling a print?

    I just reproduced the error by doing the same thing. I had moved the bed way down so I did not crash this time of course. I got the following in my console:

    18.6.2020 00.41.31	
    Error: Z probe was not triggered during probing move
    Error: Z probe was not triggered during probing move
    Error: Z probe was not triggered during probing move
    

    Afterwards I did it again, while filming it so you can see what I am doing and what happens. Please excuse my English and that I am not a born YouTuber. https://www.youtube.com/watch?v=Sl63v2Ay5L0

    First of all, I had a few weird things happening with my sensorless probing before, but when I was filming it was REALLY messed up. First it was messy when I started the first print, but it turned completely wild on the second. I understand that tuning my sensorless homing is a separate issue from what we are discussing here, but if you have any tips, I would really appreciate that too. It seems it can sensorless home fine if the toolhead carriage is positioned fairly close (maybe 20mm) from the end of the axes it is homing. Otherwise it does not work reliably. What it did here looks like it is starting to move in the perpendicular axis along the end of the axis it is trying to home. Afterwards it does not know where it is and starts crashing all over the place. I might have to look into putting switches on there instead.

    But in regards to the problem we are discussing here, this happens during the Z homing, where you see the probe is not deploying. This is what the console says:

    18.6.2020 01.03.08	
    Warning: the height map was loaded when the current Z=0 datum was not determined probing. This may result in a height offset.
    18.6.2020 01.03.07	
    Error: Insufficient axes homed for bed probing
    Error: Insufficient axes homed for bed probing
    Error: Insufficient axes homed for bed probing
    Error: Insufficient axes homed for bed probing
    Error: Insufficient axes homed for bed probing
    

    @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    Also can you confirm which firmware you are using by sending M115?

    Running 3.1.1

    M115
    FIRMWARE_NAME: RepRapFirmware for Duet 3 MB6HC FIRMWARE_VERSION: 3.1.1 ELECTRONICS: Duet 3 MB6HC v0.6 or 1.0 FIRMWARE_DATE: 2020-05-19b2
    

  • Moderator

    @pandaym said in Nozzle crashed into bed while homing - can this be avoided?:

    Do you mean that I change:

    Yup, you got it. Having Z moves in the start and end can sometimes confuse the DWC parser which messes up the layer count or object height etc. But it ignores moves with extrusion, so adding the ;E is a bit of a work around. Alternatively you can move the slicer start and end stuff into separate macros and and call them from the slicer. I only mentioned it as a precaution.


  • Moderator

    As for the stall detection homing problem, I think part of the problem is that in the pause.g file it moves the head to x0 y0

    G1 X0 Y0 F6000 ; go to X=0 Y=0

    This places the print head up against the frame, correct? When trying to home after that it's already up against the frame, so it can't accelerate enough to trigger the homing I think.

    So as a test, try changing the pause positioning to be x10 y10.



  • @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    @pandaym said in Nozzle crashed into bed while homing - can this be avoided?:

    Do you mean that I change:

    Yup, you got it. Having Z moves in the start and end can sometimes confuse the DWC parser which messes up the layer count or object height etc. But it ignores moves with extrusion, so adding the ;E is a bit of a work around. Alternatively you can move the slicer start and end stuff into separate macros and and call them from the slicer. I only mentioned it as a precaution.

    Ok, that makes sense and is added. Thank you.

    @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    As for the stall detection homing problem, I think part of the problem is that in the pause.g file it moves the head to x0 y0

    G1 X0 Y0 F6000 ; go to X=0 Y=0

    This places the print head up against the frame, correct? When trying to home after that it's already up against the frame, so it can't accelerate enough to trigger the homing I think.

    So as a test, try changing the pause positioning to be x10 y10.

    Correct, it places it against the frame. So you are right that it should get away from the corner before trying to home, and that will at least limit a potential homing failure. Unfortunately though, you can see on the video that it fails starting from other places too.

    What I am mostly worried about sorting out first though, is the fact that it runs the Z homing move without deploying a probe after and crashes straight into the bed. This concerns me, as I feel like that could occur again, also if I decide to go with switches instead of sensorless homing. Therefore it seems critical that I make sure this cannot happen, and then afterwards look at getting homing working perfectly. Do you have a feeling about where this issue comes from?


  • Moderator

    Are you still getting errors in the console when homing? I'm really hoping that if we can get reliable homing for X and Y from the stall detection that the Z homing will behave better.

    Can you try altering your homeall to include all of the commands from homex/y/z and removing the G32 from the homez?

    Can you also test homing each axis individually?



  • @pandaym it appears you are calling G28 to home all. This will cause Z to crash because in RRF 3 it cannot be defined as an endstop and a probe. You need to call G28 XY and then After your move to probing location call G30 to use probe for Z homing.

    Try calling G30 with the bed lowered way down and see if the probe deploys and can be triggered.


  • Moderator

    @mikep419 I'm not sure what you mean. his homeall calls his other homing files in turn. I'll put them all inline so they're a bit easier to glance.

    ; homeall.g
    ; called to home all axes
    ;
    M98 Phomex.g
    M98 Phomey.g
    M98 Phomez.g
    
    ; homex.g
    ; called to home the X axis
    ;
    M400                         ; Finishes all current moves and and thus clears the buffer
    M913 X50 Y50                 ; Set motor currents to 50% 
    M201 X500 Y500               ; Set acceleration on X/Y to 500 stop improve reliability of stall detection
    M915 X Y S2 R0 F0            ; Configure motor stall detection on X and Y as they work together on corexy - sensitivity 2, don’t take action, don’t filter, 400steps/sec
    G91                          ; Set to Relative Positioning
    ;G1 Z5 F1200 H2               ;
    G1 H1 X-300 F4000            ; Move 300 mm left, stopping at the endstop - Speed is 4000 which is about twice the Hmin due to two motors working together on Corexy
    G1 X30 F1200                 ; Move 30 mm out from Xmin
    ;G1 Z-5 F1200 H2              ; 
    G90                          ; Set to Absolute Positioning
    M400                         ; Finishes all current moves and and thus clears the buffer
    M913 X100 Y100               ; Set motor currents back to 100%
    M201 X1000 Y1000             ; Set acceleration back to 1000
    
    ; homey.g
    ; called to home the Y axis
    ;
    M400                         ; Finishes all current moves and and thus clears the buffer
    M913 X50 Y50                 ; Set motor currents to 30% 
    M201 X500 Y500               ; Set acceleration on X/Y to 500 stop improve reliability of stall detection
    M915 X Y S2 R0 F0            ; Configure motor stall detection on X and Y as they work together on corexy - sensitivity 2, don’t take action, don’t filter, 400steps/sec
    G91                          ; Set to Relative Positioning
    ;G1 Z5 F1200 H2               ;
    G1 H1 Y-300 F4000            ; Move 300 mm back, stopping at the endstop - Speed is 4000 which is about twice the Hmin due to two motors working together on Corexy
    G1 Y30 F1200                 ; Move 30 mm out from Xmin
    ;G1 Z-5 F1200 H2              ; 
    G90                          ; Set to Absolute Positioning
    M400                         ; Finishes all current moves and and thus clears the buffer
    M913 X100 Y100               ; Set motor currents back to 100%
    M201 X1000 Y1000             ; Set acceleration back to 1000
    
    ; homez.g
    ; called to home the Z axis
    ;
    G1 X150 Y117 F12000 ; Move probe to middle of bed
    M558 F500 ; Set the probing speed
    G30 ; Do a single probe to home our Z axis
    M558 F50  ; Set a slower probing speed
    G30
    M558 F200
    G32 ; Run 3-point bed calibration defined in bed.g
    
    ; bed.g
    ; called to perform automatic bed compensation via G32
    ;
    M561 ; clear any bed transform
    ;G28 ; home
    M558 F160 T16000
    G30 P0 X35 Y173 Z-99999 ; probe near a leadscrew
    G30 P1 X265 Y173 Z-99999 ; probe near a leadscrew
    G30 P2 X150 Y290 Z-99999 S3 ; probe near a leadscrew and calibrate 3 motors
    G1 X20 Y20 F16000
    G29 S1
    
    ; Configuration file for Duet 3 (firmware version 3)
    ; executed by the firmware on start-up
    ;
    ; generated by RepRapFirmware Configuration Tool v3.1.3 on Sun Jun 14 2020 14:49:36 GMT+0200 (Centraleuropæisk sommertid)
    
    ; General preferences
    G90                                                   ; send absolute coordinates...
    M83                                                   ; ...but relative extruder moves
    M550 P"CoreXY"                                        ; set printer name
    M669 K1                                               ; select CoreXY mode
    
    ; Network
    M540 PBE:62:38:32:53:34                               ; set custom MAC address
    M552 P0.0.0.0 S1                                      ; enable network and acquire dynamic address via DHCP
    M586 P0 S1                                            ; enable HTTP
    M586 P1 S0                                            ; disable FTP
    M586 P2 S0                                            ; disable Telnet
    
    ; Drives
    M569 P0.0 S0                                          ; X motor - physical drive 0.0 goes forwards
    M569 P0.5 S0                                          ; Y motor - physical drive 0.5 goes forwards
    M569 P0.1 S1                                          ; Z motor 1 - physical drive 0.1 goes forwards
    M569 P0.3 S1                                          ; Z motor 2 - physical drive 0.2 goes forwards
    M569 P0.4 S1                                          ; Z motor 3 - physical drive 0.2 goes forwards
    M569 P0.2 S1                                          ; Hemera motor - physical drive 0.2 goes forwards
    
    M584 X0.0 Y0.5 Z0.4:0.1:0.3 E0.2                      ; set drive mapping - X Y frontLeftZ FrontRightZ RearZ E
    
    M671 X-35:335:150 Y173:173:335 S15 	                  ; Bed rotational center - front left, front right and rear center
    
    M350 X16 Y16 Z16 E16 I1                               ; configure microstepping with interpolation
    M92 X160.00 Y160.00 Z800.00 E381.81                   ; set steps per mm
    M566 X900.00 Y900.00 Z12.00 E120.00                   ; set maximum instantaneous speed changes (mm/min)
    M203 X16000.00 Y16000.00 Z180.00 E1200.00             ; set maximum speeds (mm/min)
    M201 X2000.00 Y2000.00 Z20.00 E250.00                 ; set accelerations (mm/s^2)
    M906 X800 Y800 Z800 E800 I30                          ; set motor currents (mA) and motor idle factor in per cent
    M84 S30                                               ; Set idle timeout
    
    ; Axis Limits
    M208 X0 Y0 Z0 S1                                      ; set axis minima
    M208 X320 Y320 Z320 S0                                ; set axis maxima
    
    ; Endstops
    M574 X1 S3                                            ; configure sensorless endstop for low end on X
    M574 Y1 S3                                            ; configure sensorless endstop for low end on Y
    M574 Z0                                               ; 
    
    ; Z-Probe
    M950 S0 C"io7.out"                                    ; create servo pin 0 for BLTouch
    M558 P9 C"^io7.in" H5 F120 T6000                      ; set Z probe type to bltouch and the dive height + speeds
    ;M558 H30                                              ;*** Remove this line after delta calibration has been done and new delta parameters have been saved
    G31 P500 X1 Y24 Z0.80                                  ; set Z probe trigger value, offset and trigger height
    M557 X15:215 Y15:195 S20                              ; define mesh grid
    
    ; Heaters
    M308 S0 P"temp0" Y"thermistor" T100000 B3950          ; configure sensor 0 as thermistor on pin temp0
    M950 H0 C"out0" T0                                    ; create bed heater output on out0 and map it to sensor 0
    M307 H0 B0 S1.00                                      ; disable bang-bang mode for the bed heater and set PWM limit
    M140 H0                                               ; map heated bed to heater 0
    M143 H0 S200                                          ; set temperature limit for heater 0 to 200C
    M308 S1 P"temp1" Y"thermistor" T100000 B4725 C7.06e-8 ; configure sensor 1 as thermistor on pin temp1
    M950 H1 C"out1" T1                                    ; create nozzle heater output on out1 and map it to sensor 1
    M307 H1 B0 S1.00                                      ; disable bang-bang mode for heater  and set PWM limit
    M143 H1 S300                                          ; set temperature limit for heater 1 to 300C
    
    ; Fans
    M950 F0 C"out7" Q500                                  ; create fan 0 on pin out7 and set its frequency
    M106 P0 S0 H-1                                        ; set fan 0 value. Thermostatic control is turned off
    M950 F1 C"out4" Q500                                  ; create fan 1 on pin out4 and set its frequency
    M106 P1 S1 H1 T45                                     ; set fan 1 value. Thermostatic control is turned on
    
    ; Tools
    M563 P0 S"Hemera" D0 H1 F0                            ; define tool 0
    G10 P0 X0 Y0 Z0                                       ; set tool 0 axis offsets
    G10 P0 R0 S0                                          ; set initial tool 0 active and standby temperatures to 0C
    
    ; Custom settings are not defined
    
    ; Miscellaneous
    T0                                                    ; select first tool
    M501												  ; load saved data from non volatile memory
    


  • @Phaedrux i apologize for not being clear. In his start g-code he posted above he calls G28. My understanding was when he started the print the crash occurred. I had not seen his homing files. What I should’ve said was make sure he’s using G30 on the homez.g macro.



  • @mikep419 said in Nozzle crashed into bed while homing - can this be avoided?:

    @Phaedrux i apologize for not being clear. In his start g-code he posted above he calls G28. My understanding was when he started the print the crash occurred. I had not seen his homing files. What I should’ve said was make sure he’s using G30 on the homez.g macro.

    Just picking up on your replies now, so I will just reply to this one. It happens apparently when I start a second print, or at random, not sure. I fail to see the exact pattern or logic in what happens, but it just seems to be trying to probe Z without deploying the probe - possibly based on a failed X or Y home?`
    Should be all good with my homez.g macro, as I am using G30 there.



  • @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    Are you still getting errors in the console when homing? I'm really hoping that if we can get reliable homing for X and Y from the stall detection that the Z homing will behave better.

    Can you try altering your homeall to include all of the commands from homex/y/z and removing the G32 from the homez?

    Can you also test homing each axis individually?

    I have not seen any other errors than what I posted above which indicate that either X or Y fails to home, and the probe cannot be deployed. I am just worried about the fact that it ignores this and continues to move the bed upwards. I hope I can find the reason for this, so that even when I get the homing of X and Y reliable, I still know it won't crash the bed if something should happen on X/Y.

    I will try make a homeall that includes all the commands instead of calling the others, remove 3 point true bed levelling from homez and test it. I think it might be best to not try and fix X/Y homing before this other thing is fixed, as I will have a hard time figuring out if it works then. I'll get back with the results.


  • Moderator

    @pandaym said in Nozzle crashed into bed while homing - can this be avoided?:

    I think it might be best to not try and fix X/Y homing before this other thing is fixed, as I will have a hard time figuring out if it works then.

    I disagree. I think X and Y homing must be reliable regardless because the Z homing depends on being able to accurately place the probe where you want it.

    For the probe not deploying the pin it's possible there is a wiring issue. The BLTouch has a lot of wires and the crimps are often a cause of problems, so definitely double check your wiring.

    G31 P500 X1 Y24 Z0.80 I also note that your trigger height is very low. Typically, when the BLtouch is mounted correctly, the base of the probe body is ~8mm above the nozzle tip, which leads to a trigger height of ~2mm. This is the sweet spot for accurate and reliable results.

    By the way, what version of BLTouch is it? Is it genuine or a clone?



  • @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    @pandaym said in Nozzle crashed into bed while homing - can this be avoided?:

    I think it might be best to not try and fix X/Y homing before this other thing is fixed, as I will have a hard time figuring out if it works then.

    I disagree. I think X and Y homing must be reliable regardless because the Z homing depends on being able to accurately place the probe where you want it.

    For the probe not deploying the pin it's possible there is a wiring issue. The BLTouch has a lot of wires and the crimps are often a cause of problems, so definitely double check your wiring.

    G31 P500 X1 Y24 Z0.80 I also note that your trigger height is very low. Typically, when the BLtouch is mounted correctly, the base of the probe body is ~8mm above the nozzle tip, which leads to a trigger height of ~2mm. This is the sweet spot for accurate and reliable results.

    By the way, what version of BLTouch is it? Is it genuine or a clone?

    I understand your point about the X and Y. I just assumed that it did not really matter where on the build plate the probe were for probing Z, as I am only in this phase of the build.

    There truly are a lot of wires that has to be done right on the BLTouch. I checked my wiring and crimping and it all looks good.

    I reconfigured a bit like you suggested, and what I noticed was that it seemed like true bed levelling was causing the issues. I therefore went through my configs and currently have them configured like this:

    homex.g:

    ; homex.g
    ; called to home the X axis
    ;
    ;Prepare for homing
    M400                         ; Finishes all current moves and and thus clears the buffer
    G91                          ; Set to Relative Positioning
    G1 Z5 F1200 H2               ; Move the bed down slightly
    
    ;Prepare for sensorless homing
    M913 X50 Y50                 ; Set motor currents to 50% 
    M201 X500 Y500               ; Set acceleration on X/Y to 500 to improve reliability of stall detection
    M915 X Y S2 R0 F0            ; Configure motor stall detection on X and Y as they work together on corexy - sensitivity 2, don’t take action, don’t filter, 400steps/sec
    
    ;Sensorless homing X
    G1 H1 X-300 F4000            ; Move 300 mm left, stopping at the endstop - Speed is 4000 which is about twice the Hmin due to two motors working together on Corexy
    G1 X30 F1200                 ; Move 30 mm out from Xmin
    
    ;End of sensorless homing
    M913 X100 Y100               ; Set motor currents back to 100%
    M201 X2000 Y2000             ; Set acceleration back to 2000
    
    ;End of homing
    G90                          ; Set to Absolute Positioning
    

    homey.g:

    ; homey.g
    ; called to home the Y axis
    ;
    ;Prepare for homing
    M400                         ; Finishes all current moves and and thus clears the buffer
    G91                          ; Set to Relative Positioning
    G1 Z5 F1200 H2               ; Move the bed down slightly
    
    ;Prepare for sensorless homing
    M913 X50 Y50                 ; Set motor currents to 50% 
    M201 X500 Y500               ; Set acceleration on X/Y to 500 to improve reliability of stall detection
    M915 X Y S2 R0 F0            ; Configure motor stall detection on X and Y as they work together on corexy - sensitivity 2, don’t take action, don’t filter, 400steps/sec
    
    ;Sensorless homing Y
    G1 H1 Y-300 F4000            ; Move 300 mm back, stopping at the endstop - Speed is 4000 which is about twice the Hmin due to two motors working together on Corexy
    G1 Y30 F1200                 ; Move 30 mm out from Xmin
    
    ;End of sensorless homing
    M913 X100 Y100               ; Set motor currents back to 100%
    M201 X2000 Y2000             ; Set acceleration back to 2000
    
    ;End of homing
    G90                          ; Ensure we are in Absolute Positioning
    

    homez.g:

    ; homez.g
    ; called to home the Z axis
    ;
    ;Prepare for homing
    M400                         ; Finishes all current moves and and thus clears the buffer
    G91                          ; Set to Relative Positioning
    G1 Z5 F1200 H2               ; Move the bed down slightly
    G90                          ; Set to Absolute Positioning
    
    
    ;Probe Z
    G1 X150 Y117 F12000 		 ; Move probe to middle of bed
    M558 F500 					 ; Set the first probing speed
    G30 						 ; First Z probe
    M558 F50  					 ; Set a slower probing speed
    G30							 ; Second Z probe
    
    ;End of homing
    G90                          ; Set to Absolute Positioning
    

    homeall.g:

    ; homeall.g
    ; called to home all axes
    ;Prepare for homing
    M400                         ; Finishes all current moves and and thus clears the buffer
    G91                          ; Set to Relative Positioning
    G1 Z5 F1200 H2               ; Move the bed down slightly
    
    ;Prepare for sensorless homing
    M913 X50 Y50                 ; Set motor currents to 50% 
    M201 X500 Y500               ; Set acceleration on X/Y to 500 to improve reliability of stall detection
    M915 X Y S2 R0 F0            ; Configure motor stall detection on X and Y as they work together on corexy - sensitivity 2, don’t take action, don’t filter, 400steps/sec
    
    
    ;Sensorless homing X
    G1 H1 X-300 F4000            ; Move 300 mm left, stopping at the endstop - Speed is 4000 which is about twice the Hmin due to two motors working together on Corexy
    G1 X30 F1200                 ; Move 30 mm out from Xmin
    
    ;Sensorless homing Y
    G1 H1 Y-300 F4000            ; Move 300 mm back, stopping at the endstop - Speed is 4000 which is about twice the Hmin due to two motors working together on Corexy
    G1 Y30 F1200                 ; Move 30 mm out from Xmin
    
    ;End of sensorless homing
    M913 X100 Y100               ; Set motor currents back to 100%
    M201 X2000 Y2000             ; Set acceleration back to 2000
    G90                          ; Set to Absolute Positioning
    
    ;BLTouch home Z
    G1 X150 Y117 F12000 		 ; Move probe to middle of bed
    M558 F500 					 ; Set the first probing speed
    G30 						 ; First Z probe
    M558 F50  					 ; Set a slower probing speed
    G30							 ; Second Z probe
    
    ;End of homing
    G90                          ; Ensure we are in Absolute Positioning
    

    bed.g:

    ; bed.g
    ; called to perform automatic bed compensation via G32
    ;
    M561 						; Clear any bed transform
    M401 						; TEST!!! Deploy probe - deployprobe.g
    G30 P0 X35 Y173 Z-99999  	; Probe near front-left leadscrew
    G30 P1 X265 Y173 Z-99999 	; Probe near front-right leadscrew
    G30 P2 X150 Y290 Z-99999 S3 ; Probe near rear-center leadscrew and adjust bed parallel to corexy kinematics
    M402 						; TEST!!! Retract Probe - retractprobe.g
    G1 X20 Y20 F12000			; Move close to home
    

    For the bed.g, I tried various things to see if the probe would deploy, and ended up finding this to work. I found this particular way of doing it in the same guide I used to set up my BLTouch. This is the guide I used.

    So in response to your question about trigger height, I found the value in the same guide. It basically tells you to move the nozzle down all the way to the build plate and run:

    G92 Z0 ; Tell the machine we are at Z=0
    G1 Z10 ; Move Z 10 mm  away from nozzle
    G30 S-1 ; The value you get here is the offset you put in G31.
    

    The guide also notes that as low a value as possible is best, which to me makes sense, as that will leave the most clearence under the nozzle when probing. I am not sure I understand why the trigger height in itself affects the accuracy or reliability, could you explain that?

    I tried to measure the physical delta, and it is actually around 8mm. The Hemera carriage with BLtouch mount is one I downloaded off of thingiverse, so I did not design this delta myself.

    Last thing, yes it is a genuine BLTouch v3.1. Only clone component on the printer are the linear rails.

    So where do we go from here? 🙂



  • As you recommended, I also tuned the sensorless homing.
    I think the main reason was that I had no H value on the M915 commands. I am running 0.9 motors, so I set that to 400 and sensitivity to 1, and now that part at least seems to work good:
    https://www.youtube.com/watch?v=tnWOXK7N014



  • So while waiting to see what you guys think is going on, I went ahead and did a test print. Seems I have more issues 😉
    IMG_2875.jpg


  • Moderator

    I wonder if part of the issue is binding on the axis...



  • @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    I wonder if part of the issue is binding on the axis...

    I don’t think there’s any binding going on. I completely disassembled, flushed, greased and carefully assembled all the linear rails. I spent a lot of time with squares and calipers during the build and would say that the machine is very mechanically sound. That is my strong side, so I am more concerned with electronics/firmware where I am still very challenged.

    I just saw the other post with @dlc60 having 45 degree layer shifts. Mine are exactly 45 deg and exactly the same direction and distance between them. I wonder if we are seeing the same thing?



  • @Phaedrux
    I am trying to tune some different things right now, and it just happened again 😞

    It seems completely random! This time I know for sure that the X/Y homing when fine, but still the probe did not come out, and I just managed to stop it before crashing hard..

    Console says:

    19.6.2020 14.55.16	
    Error: Z probe was not triggered during probing move
    Error: Z probe was not triggered during probing move
    Error: Homing failed
    

  • Moderator

    Alright you must check your BLTouch wiring for continuity. The crimps are notorious failure points. This is by far the most likely problem at this point.



  • @Phaedrux said in Nozzle crashed into bed while homing - can this be avoided?:

    Alright you must check your BLTouch wiring for continuity. The crimps are notorious failure points. This is by far the most likely problem at this point.

    Alright I ran through it.

    I got it wired uip to IO_7

    Red wire runs to 5V_EXT - Continuity, measured ~2.2 ohm
    Yellow wire runs to io7.out - Continuity, measured ~2.2 ohm
    Brown and black wire run to GND - Continuity, measured ~2.2 ohm
    White wire runs to io7.in - Continuity, measured ~2.2 ohm

    Earlier today I was doing a test print, and I noticed the red LED was flickering while it was printing. Afterwards I noticed that it was blinking after homing. So I looked it up on Google, and found something that I did not comprehend entirely, but it was someone talking about the probe thinking it is too close to the bed to be able to deploy. I rebooted the machine and noticed that BLTouch did not do it's self-test either. So I allowed movement without homing, lowered the bed a lot, rebooted, and when powering it back on, it did self-test again and constant red LED.

    Don't know if the LED blinking observation has anything to do with this issue, but just wanted to mention it.

    I do not know much about any of this, but I would have assumed that there were a safety measure in place that immediately stopped the Z movement for G30, in case an error is thrown that the BLTouch cannot deploy for whatever reason. Maybe I could code that into my homings to create a safety net for this issue till we hopefully solve it?


Log in to reply