Problems with sensorless homing
-
@bearer I don’t see why it would be intermittent like it is if that were the case. The homing files were also created by the web configuration tool and I only modified the current %’s. Also it seems worse after sitting over night too. The only information I could find suggested it could be missing a step from a bad cable or driver that would cause it to rotate the wrong direction but I’ve replaced the cable already and both cables I know worked before switching to the duet.
-
Please copy and paste the text of your config.g and homing files.
-
; Configuration file for Duet WiFi (firmware version 3)
; executed by the firmware on start-up
;
; generated by RepRapFirmware Configuration Tool v3.1.4 on Sat Sep 26 2020 16:50:18 GMT-0600 (Mountain Daylight Time); General preferences
G90 ; send absolute coordinates...
M83 ; ...but relative extruder moves
M550 P"Duet Multicolor" ; set printer name; Network
M551 P"18831883" ; set password
M552 S1 ; enable network
M586 P0 S1 ; enable HTTP
M586 P1 S0 ; disable FTP
M586 P2 S0 ; disable Telnet; Drives
M569 P0 S1 ; physical drive 0 goes forwards (X)
M569 P1 S0 ; physical drive 1 goes backwards (Y)
M569 P2 S0 ; physical drive 2 goes backwards (Z)
M569 P3 S1 ; physical drive 3 goes forwards (E0)
M569 P4 S1 ; physical drive 4 goes forwards (E1)
M569 P5 S1 ; physical drive 5 goes forwards (E2)
M569 P6 S1 ; physical drive 6 goes forwards (E3)
M569 P7 S1 ; physical drive 7 goes forwards(E4)
M569 P8 S1 ; physical drive 8 goes forwards(E5)
M584 X0 Y1 Z2 E3:4:5:6:7:8 ; set drive mapping
M350 X16 Y16 Z16 E16:16:16:16:16:16 I1 ; configure microstepping with interpolation
M92 X80.71 Y80.66 Z403.84 E106.47:97.07:96.49:96.00:96.00:96.00 ; set steps per mm
M566 X1200.00 Y1200.00 Z18.00 E8000.00:1200.00:1200.00:1200.00:1200.00:1200.00 ; set maximum instantaneous speed changes (Jerk) (mm/min)
M203 X8700.00 Y8700.00 Z2100.00 E8700.00:8700.00:8700.00:8700.00:8700.00:8700.00 ; set maximum speeds (mm/min)
M201 X3000.00 Y3000.00 Z50.00 E3000.00:1500.00:1500.00:1500.00:1500.00:1500.00 ; set accelerations (mm/s^2)
M906 X1000 Y1000 Z600 E1000:900:900:900:900:900 I50 ; set motor currents (mA) and motor idle factor in per cent
M84 S30 ; Set idle timeout; Axis Limits
M208 X-9 Y-9 Z0 S1 ; set axis minima
M208 X305 Y305 Z400 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 Z1 S2 ; configure Z-probe endstop for low end on Z
M915 X R0 F0 S2 ; set X threshold
M915 Y R0 F0 S3 ; set Y threshold; Z-Probe
M950 S0 C"duex.pwm5" ; create servo pin 0 for BLTouch
M558 P9 C"^zprobe.in" H5 F120 T6000 ; set Z probe type to bltouch and the dive height + speeds
G31 P500 X30 Y0 Z.8 ; set Z probe trigger value, offset and trigger height
M557 X25:275 Y25:275 S125 ; define mesh grid; Heaters
M308 S0 P"bedtemp" Y"thermistor" T100000 B4138 ; configure sensor 0 as thermistor on pin bedtemp
M950 H0 C"bedheat" T0 ; create bed heater output on bedheat 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 S100 ; set temperature limit for heater 0 to 100C
M308 S1 P"e0temp" Y"thermistor" T100000 B4138 ; configure sensor 1 as thermistor on pin e0temp
M950 H1 C"e0heat" T1 ; create nozzle heater output on e0heat and map it to sensor 1
M307 H1 B0 S1.00 ; disable bang-bang mode for heater and set PWM limit; Disable Heater to free up PWM channel
M307 H7 A-1 C-1 D-1 ; disable heater 7 for BLTouch; Fans
M950 F0 C"fan0" Q500 ; create fan 0 on pin fan0 and set its frequency
M106 P0 S0 H-1 ; set fan 0 value. Thermostatic control is turned off
M950 F1 C"fan1" Q500 ; create fan 1 on pin fan1 and set its frequency
M106 P1 S1 H1 T45 ; set fan 1 value. Thermostatic control is turned on; Tools
M563 P0 S"Extruder 0" 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
M563 P1 S"Extruder 1" D1 H1 F0 ; define tool 1
G10 P1 X0 Y0 Z0 ; set tool 1 axis offsets
G10 P1 R0 S0 ; set initial tool 1 active and standby temperatures to 0C
M563 P2 S"Extruder 2" D2 H1 F0 ; define tool 2
G10 P2 X0 Y0 Z0 ; set tool 2 axis offsets
G10 P2 R0 S0 ; set initial tool 2 active and standby temperatures to 0C
M563 P3 S"Extruder 3" D3 H1 F0 ; define tool 3
G10 P3 X0 Y0 Z0 ; set tool 3 axis offsets
G10 P3 R0 S0 ; set initial tool 3 active and standby temperatures to 0C
M563 P4 S"Extruder 4" D4 H1 F0 ; define tool 4
G10 P4 X0 Y0 Z0 ; set tool 4 axis offsets
G10 P4 R0 S0 ; set initial tool 4 active and standby temperatures to 0C
M563 P5 S"Extruder 5" D5 H1 F0 ; define tool 5
G10 P5 X0 Y0 Z0 ; set tool 5 axis offsets
G10 P5 R0 S0 ; set initial tool 5 active and standby temperatures to 0C; Custom settings are not defined
; Miscellaneous
M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power lossM501
-
; homeall.g
; called to home all axes
;
; generated by RepRapFirmware Configuration Tool v3.1.4 on Sat Sep 26 2020 16:50:18 GMT-0600 (Mountain Daylight Time)
M400
M913 X70 Y80 ; drop motor current %
M400 G91; relative positioning
G1 H2 Z5 F12000 ; lift Z relative to current position
G1 H1 X-305 F6000 ; move quickly to X and Y axis endstops and stop there (first pass)
G1 H2 X5 F6000 ; go back a few mm
G1 H1 X-305 F3600 ; move slowly to X and Y axis endstops once more (second pass)
G1 H1 Y-305 F6000 ; move quickly to X and Y axis endstops and stop there (first pass)
G1 H2 Y5 F6000 ; go back a few mm
G1 H1 Y-305 F3600 ; move slowly to X and Y axis endstops once more (second pass)
G90 ; absolute positioning
M400
M913 X100 Y100 ; return current to 100%
M400
G1 X130 Y150 F6000 ; go to first bed probe point and home Z
G30 ; home Z by probing the bed; Uncomment the following lines to lift Z after probing
;G91 ; relative positioning
;G1 Z5 F100 ; lift Z relative to current position
;G90 ; absolute positioning -
; homey.g
; called to home the Y axis
;
; generated by RepRapFirmware Configuration Tool v3.1.4 on Sat Sep 26 2020 16:50:19 GMT-0600 (Mountain Daylight Time)
M400
M913 Y90 ; drop motor current to 90%
M400 G91; relative positioning
G1 H2 Z5 F6000 ; lift Z relative to current position
G1 H1 Y-305 F6000 ; move quickly to Y axis endstop and stop there (first pass)
G1 H2 Y5 F6000 ; go back a few mm
G1 H1 Y-305 F3600 ; move slowly to Y axis endstop once more (second pass)
G1 H2 Z-5 F6000 ; lower Z again
G90 ; absolute positioning
M400
M913 Y100 ; return current to 100%
M400 -
Thanks. Can you also send M115 and confirm your firmware version?
-
It’s a completely new setup, I deleted the old files and did a restore to 3.1.1 for my initial setup then used the web configuration tool to generate the setup and then made the changes I needed.
Date Event
2020-10-25, 2:29:19 PM M115
FIRMWARE_NAME: RepRapFirmware for Duet 2 WiFi/Ethernet FIRMWARE_VERSION: 3.1.1 ELECTRONICS: Duet WiFi 1.02 or later + DueX5 FIRMWARE_DATE: 2020-05-19b2 -
@c-bldwn said in Problems with sensorless homing:
M913 X70 Y80 ; drop motor current %
@c-bldwn said in Problems with sensorless homing:
G1 H1 X-305 F3600 ; move slowly to X and Y axis endstops once more (second pass)
@c-bldwn said in Problems with sensorless homing:
M913 Y90 ; drop motor current to 90%
First. The motor current you're dropping down to is inconsistent. You will need to find the absolute lowest current you can use and still get reliable motion. Having low current is critical to getting a reliable stall.
Second. Don't do multiple passes when using stall detection homing. The stall is going to be most reliable on a fast pass. Once it hits and you back off slightly and then slowly try to stall again it's never going to work as well as the first fast pass. There is no accuracy gain here as there might be from multiple slower passes on an endstop. The stall is going to snap to the nearest motor full step.
-
Maybe that’s something that should be also changed in the web configuration tool as that is not something I added. I had my concerns about that as I know you don’t generally want it and I had removed it on my other printer still running marlin but left it in as I figured maybe duet had a reason for it. How can I find out the best current setting, I’ve tried between 40% and 90% in increments of 10 already and didn’t have any luck. Here are my motor specs.
Motor Model 42HS1411-20B19
Step Angle(°) 1.8
Holding torque(mN.m) 280
Rated current(A) 1.5
Rated Voltage(V) 3
Resistance per phase(Ω) 2.1±10%(20℃)
Inductance per phase(mH) 2.5±20%
Mass 0.2kg
Rotor inertia(g.cm²) 45
Insulation Class: B
Ambient Working Temperature Range(℃) " -20 to + 60℃ "
"Temperature rise MAX (rated current, 2 phase on) (℃)" 80℃ -
@c-bldwn said in Problems with sensorless homing:
How can I find out the best current setting
For normal operation to recommendation is to use 60-85% of the rated max current for the motor.
So 1500 max * 60% = 900
or 1500 max * 85% = 1300And in your config you have 1000ma, which is fine.
To find the lowest current for reliable movement, simply use M913 to lower it down to the lowest you can still get movement.
Try M913 X10 and try to move the X axis around with the jog buttons. Try blocking it with your hand. If it sometimes stalls without any effort on your part, increase it to X20. etc.
Do the same for the Y axis.
-
Oh I forgot to mention before switching to duet, on the factory arduino 2560 mega board with tmc2209 drivers I was running the Y axis at 1000ma normal and 50% of that for homing and didn’t have any issues before.
-
Doesn't really matter. Once you drop the current and do a single fast homing move stall detection should improve.
-
Ok so I tested as you reccomended, got best results with X60 and Y90. I ended up bumping The current up for the Y from 1000 to 1200 and tested again and found Y80 to work well. I then had to up the Y threshold to 5 to get it to move and seems to work as expected when it hits the home. However I’m still having issues with the y axis wanting to go the wrong direction sometimes. I bumped the threshold up to 7 and seems to be more reliable. I’ll test this out a bit and let you know if I’m still getting the problem or not.
-
This post is deleted! -
Ok so after testing for a bit last night and today my problem seems to be fixed. Thanks for the help!!