@emi100 said in Sensorless Homing problems on Duet 3 Mini 5+:
I have tried changing the V parameter from 500 to 2000. Any value for feed-rate returns the same errors, either too slow or too fast.
The homing speed needs to be faster than that set by the M915 H parameter, and slower than the speed set by the M596 V parameter. I have a 0.9° motor on X, and as you're using a Prusa Mk3 or 4, I expect you are too. For example, if I send:
M569 P0.0 S0 D3 V10
M569 P0.0
Drive 0 runs in reverse, active low enable, timing fast, mode stealthChop, ccr 0x00053, toff 3, tblank 0, tpwmthrs 10 (468.8 mm/sec), tcoolthrs 117 (40.1 mm/sec), pwmScaleSum 21, pwmScaleAuto 2, pwmOfsAuto 205, pwmGradAuto 28, pos 632
M915 X H400 S3 R0 F0
M915 X
Driver 0.0: stall threshold 3, full steps/sec 420, coolstep 0, action on stall: none
In M569, the changeover speed from stealthChop (which we need to use for stall homing) is 468.8mm/s, or 28,128mm/minute. Any speed below this for homing is fine.
In M915, H400 sets the minimum speed to 420 full steps/sec (I think it adds 5% to the H parameter value, not sure why). I have x16 microstepping, and 160 steps per mm, so (420 x 16) / 160 = 42mm per second, or 2,520mm/min as the lowest speed.
Here's my configuration for stall homing, on a Mini 5+. It will depend on your M92 steps per mm and M906 current setting,
in config.g
M569 P0.0 S0 D3 V9 ; x0 - low V for high changeover speed
M574 X1 S3 ; define endstop for stall detection
My axis speeds, accelerations, steps per mm etc:
; Axes
M584 X0.0 Y0.1 Z0.2:0.4 ; set drive mapping
M906 X1000 Y1000 Z800 ; set motor currents (mA) and motor idle factor in per cent
M350 X16 Y16 Z16 I1 ; configure microstepping with interpolation
M92 X160 Y160 Z800 ; set steps per mm
M566 X300 Y300 Z12 ; set maximum instantaneous speed changes (mm/min)
M203 X9000 Y9000 Z600 ; set maximum speeds (mm/min)
M201 X2000 Y2000 Z20 ; set accelerations (mm/s^2)
in homex.g
M915 X H400 S3 R0 F0 ; stall detection
M400 ; Wait for current moves to finish
M913 X50 ; drop motor current to 50%
M400 ; Wait for current moves to finish
G91 ; relative positioning
G1 H1 X-250 F4000 ; move quickly to X axis endstop and stop there (first pass)
G4 S1 ; pause for 1 second
G1 X25 ; move +25mm
G90 ; absolute positioning
M400 ; Wait for current moves to finish
M913 Z100 ; return current to 100%
M400 ; Wait for current moves to finish
M569 P0.0 S0 D3 V2000 ; x0 - high V for low changeover speed
It probably doesn't need all the M400 commands, it's just what I ended up with.
Ian