Independent Z Motors- Endstop Error
-
Hello all!
I'm working on a machine with independent Z motors which are on either end of the X-axis. I hoped to use high-end, end-stops to level the X-axis at the top of the Z before using a BL Touch to probe the bed and establish my Z datum in my "homez.g".
However I'm getting 'G28 Z // Error: Failed to enable endstops' when I home Z. Here is my config and homez.g, which is on a Duet 2 Wifi and Duex 5. Previously I had just the Z probe, but when I went to add the two endstops I started getting the error.
; Configuration file for Duet WiFi (firmware version 3.3) ; executed by the firmware on start-up ; General preferences M575 P1 S1 B57600 ; enable support for PanelDue G90 ; send absolute coordinates... M83 ; ...but relative extruder moves M550 P"RL1 Proto V2" ; set printer name ; Drives M569 P0 S1 ; physical drive 0 goes forwards (eventually X) M569 P1 S1 ; physical drive 1 goes forwards (eventually Y) M569 P2 S1 ; physical drive 2 goes forwards (eventually Z) M569 P3 S1 ; physical drive 3 goes forwards (eventually E) M569 P4 S0 ; physical drive 5 goes backwards (eventually U1) M569 P5 S0 ; physical drive 6 goes backwards (eventually U2) M950 P0 C"duex.pb6" ; assign servo control to port 0 and link to PB6 GPIO on duex ; Motor Speeds and Accelerations M584 X0 Y1 Z2 E3 U4:5 ; set drive mapping M350 X16 Y16 Z16 E16 U16 I1 ; configure microstepping with interpolation M92 X80.00 Y80.00 Z400.00 E415.38918 U80 ; set steps per mm M566 X900.00 Y900.00 Z60.00 E120.00 U900 ; set maximum instantaneous speed changes (mm/min) M203 X6000.00 Y6000.00 Z180.00 E1200.00 V6000 ; set maximum speeds (mm/min) M201 X500.00 Y500.00 Z20.00 E250.00 U500.00 ; set accelerations (mm/s^2) M906 X800 Y800 Z800 E800 U800 V 800 I60 ; set motor currents (mA) and motor idle factor in per cent ; Axis Limits M208 X-40 Y-10 Z0 U0 S1 ; set axis minima M208 X313 Y174 Z300 U500 S0 ; set axis maxima ; Endstops M574 X2 S1 P"xstop" ; configure switch-type (e.g. microswitch) endstop for high end on X M574 Y2 S3 ; configure sensorless endstop for high end on Y M574 Z2 S1 P"zstop+e2stop" ; configure active-high endstops on Z via pins zstop and e1stop M574 U2 S1 P"e1stop" ; configure switch-type (e.g. microswitch) endstop for high end on U via pin e1stop M915 X R0 F0 S1 ; configure stall detection for x M915 Y R0 F0 S3 ; configure stall detection for Y ; Z-Probe M950 S0 C"duex.pwm1" ; Duet 2 WiFi/Ethernet + DueX2/5 M558 P9 C"^zprobe.in" H5 F120 T6000 ; Duet 2 WiFi/Ethernet, DueX2/5 G31 P500 X-7 Y0 Z6.017 ; set Z probe trigger value, offset and trigger height
;homez.g G91 ; relative mode G1 H1 Z320 F5000 ; move quickly to Z axis endstop and stop there G90 ; back to absolute mode G1 X30 Y100 F2000 ; put head over the centre of the bed, or wherever you want to probe G30 ; lower head, stop when probe triggered and set Z to trigger height G1 X0 Y0 Z15 ; send to over origin
-
-
Can you send M122 and M98 P"config.g" and post the results?
Can you also post your homeall?
Does G30 by itself work to use the probe?
-
Yes the probe works by itself. Posted results below:
M122
=== Diagnostics ===
RepRapFirmware for Duet 2 WiFi/Ethernet version 3.3 (2021-06-15 21:44:54) running on Duet WiFi 1.02 or later + DueX5
Board ID: 08DGM-917NK-F2MS0-7JKDL-3SN6J-TDS0G
Used output buffers: 3 of 24 (12 max)
=== RTOS ===
Static ram: 23876
Dynamic ram: 75920 of which 0 recycled
Never used RAM 14620, free system stack 184 words
Tasks: NETWORK(ready,12.9%,237) HEAT(delaying,0.0%,330) Move(notifyWait,0.1%,340) DUEX(notifyWait,0.0%,24) MAIN(running,86.1%,441) IDLE(ready,0.9%,29), total 100.0%
Owned mutexes: WiFi(NETWORK)
=== Platform ===
Last reset 00:01:25 ago, cause: power up
Last software reset at 2022-07-10 16:28, reason: User, GCodes spinning, available RAM 11412, slot 1
Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x0041f000 BFAR 0xe000ed38 SP 0x00000000 Task MAIN Freestk 0 n/a
Error status: 0x00
Aux0 errors 0,0,0
Step timer max interval 0
MCU temperature: min 23.1, current 28.5, max 29.0
Supply voltage: min 24.1, current 24.2, max 24.5, under voltage events: 0, over voltage events: 0, power good: yes
Heap OK, handles allocated/used 0/0, heap memory allocated/used/recyclable 0/0/0, gc cycles 0
Driver 0: position 0, standstill, SG min/max not available
Driver 1: position 0, standstill, SG min/max not available
Driver 2: position 0, standstill, SG min/max not available
Driver 3: position 0, standstill, SG min/max not available
Driver 4: position 0, standstill, SG min/max not available
Driver 5: position 0, standstill, SG min/max not available
Driver 6: position 0, standstill, SG min/max not available
Driver 7: position 0, standstill, SG min/max not available
Driver 8: position 0, standstill, SG min/max not available
Driver 9: position 0, standstill, SG min/max not available
Driver 10: position 0
Driver 11: position 0
Date/time: 2022-07-10 17:56:00
Cache data hit count 3106634543
Slowest loop: 5.08ms; fastest: 0.17ms
I2C nak errors 0, send timeouts 0, receive timeouts 0, finishTimeouts 0, resets 0
=== Storage ===
Free file entries: 10
SD card 0 detected, interface speed: 20.0MBytes/sec
SD card longest read time 4.2ms, write time 0.0ms, max retries 0
=== Move ===
DMs created 83, maxWait 0ms, bed compensation in use: none, comp offset 0.000
=== MainDDARing ===
Scheduled moves 0, completed moves 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1
=== AuxDDARing ===
Scheduled moves 0, completed moves 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1
=== Heat ===
Bed heaters = -1 -1 -1 -1, chamberHeaters = 2 -1 -1 -1
Heater 1 is on, I-accum = 0.0
=== GCodes ===
Segments left: 0
Movement lock held by null
HTTP is idle in state(s) 0
Telnet is idle in state(s) 0
File is idle in state(s) 0
USB is idle in state(s) 0
Aux is idle in state(s) 0
Trigger is idle in state(s) 0
Queue is idle in state(s) 0
LCD is idle in state(s) 0
Daemon is idle in state(s) 0
Autopause is idle in state(s) 0
Code queue is empty.
=== DueX ===
Read count 1, 0.70 reads/min
=== Network ===
Slowest loop: 15.60ms; fastest: 0.00ms
Responder states: HTTP(0) HTTP(0) HTTP(0) HTTP(0) FTP(0) Telnet(0), 0 sessions
HTTP sessions: 1 of 8- WiFi -
Network state is active
WiFi module is connected to access point
Failed messages: pending 0, notready 0, noresp 0
WiFi firmware version 1.26
WiFi MAC address 24:a1:60:2e:a8:8a
WiFi Vcc 3.38, reset reason Turned on by main processor
WiFi flash size 4194304, free heap 21600
WiFi IP address 192.168.1.98
WiFi signal strength -42dBm, mode 802.11n, reconnections 0, sleep mode modem
Clock register 00002002
Socket states: 0 0 0 0 0 0 0 0
M98 P"config.g"
HTTP is enabled on port 80
FTP is disabled
TELNET is disabled
Error: Unknown pin name 'fan3'
Error: Fan number 3 not found;homeall M98 P"homeu.g" M98 P"homex.g" M98 P"homey.g" M98 P"homez.g"
Looks like I have a fan to fix too
- WiFi -
-
@jrcl said in Independent Z Motors- Endstop Error:
;homeall M98 P"homeu.g" M98 P"homex.g" M98 P"homey.g" M98 P"homez.g"
Can you post those as well?
-
;homeu.g G91; relative positioning G1 H1 U700 F5000 ; move quickly to U axis endstop and stop there (first pass) G90 ; absolute positioning
;homex G91 ;relative positioning G1 H2 Z10 F200 ; raise head 10mm to ensure it is above the Z probe trigger height G1 H1 X450 F10000 ; move quickly to X axis endstop and stop there (first pass) G90 ; absolute positioning G1 X0 F10000 ; move to zero on x axis
;homey.g G91 ; relative positioning G1 H2 Z10 F200 ; raise head 4mm to ensure it is above the Z probe trigger height G1 H1 Y320 F10000 ; move quickly to X axis endstop and stop there (first pass) G1 H2 Y-5 F12000 ; go back a few mm G1 H1 Y320 F7000 ; move slowly to X axis endstop once more (second pass) G90 ; absolute positioning G1 H1 Y0 F10000 ; move to 0 on y axis
;homez.g G91 ; relative mode G1 H1 Z320 F5000 ; move quickly to Z axis endstop and stop there (first pass) G90 ; back to absolute mode G1 X30 Y100 F2000 ; put head over the centre of the bed, or wherever you want to probe G30 ; lower head, stop when probe triggered and set Z to trigger height G1 X0 Y0 Z15 ; send to over origin
-
What is the U axis? You have two endstops defined for Z, but only a single driver. You have two drivers assigned to U, but only a single endstop.
You also seem to be referencing a V axis...
M203 X6000.00 Y6000.00 Z180.00 E1200.00 V6000
M906 X800 Y800 Z800 E800 U800 V 800 I60
-
@phaedrux U axis is an external carriage for thermoforming. What is a driver in this case? One end stop on the U was intentional as it doesn't need to be very level.
Whoops the V's should be gone, the firmware was copied from an old one to start which had a V axis. Looks like I missed a few!
-
You can only use independent Z motor leveling with 2 endstops if you are using 2 independent drives for the Z axis.
-
@phaedrux Ohhh, I see. So I can't use both the Z drive connections, the other has to use a different driver.
-
The 2 Z motor connectors on the board are wired in series to the same driver. To get independant control, you'd need to use a second driver for the second motor.
See here for more details.
https://docs.duet3d.com/en/User_manual/Connecting_hardware/Z_probe_auto_levelling
You're on the right start. Once you fix up the driver mappings and clean up the U/V stuff it should work.
-
@phaedrux Awesome! Wouldn't have figured that one out for a bit should be an easy fix then, thanks for the help.
-
-
-
Here is my new config.g with updated driver setup and elimination of V axis. Made sure my end stop wiring corresponded to the drivers in the same order as the pin call out "zstop+e2stop" as well. I'm still getting a G28 Z Failed to Enable End Stops, error message.
; Drives M569 P0 S1 ; physical drive 0 goes forwards (eventually X) M569 P1 S1 ; physical drive 1 goes forwards (eventually Y) M569 P2 S1 ; physical drive 2 goes forwards (eventually Z1) M569 P3 S1 ; physical drive 3 goes forwards (eventually E) M569 P4 S0 ; physical drive 4 goes backwards (eventually U1) M569 P5 S0 ; physical drive 5 goes backwards (eventually U2) M569 P6 S1 ; physical drive 6 goes forwards (eventually Z2) M950 P0 C"duex.pb6" ; assign servo control to port 0 and link to PB6 GPIO on duex ; Motor Speeds and Accelerations M584 X0 Y1 Z2:6 E3 U4:5 ; set drive mapping M350 X16 Y16 Z16 E16 U16 I1 ; configure microstepping with interpolation M92 X80.00 Y80.00 Z400.00 E415.38918 U80 ; set steps per mm M566 X900.00 Y900.00 Z60.00 E120.00 U900 ; set maximum instantaneous speed changes (mm/min) M203 X6000.00 Y6000.00 Z180.00 E1200.00 U6000 ; set maximum speeds (mm/min) M201 X500.00 Y500.00 Z20.00 E250.00 U500.00 ; set accelerations (mm/s^2) M906 X800 Y800 Z800 E800 U800 I40 ; set motor currents (mA) and motor idle factor in per cent ; Axis Limits M208 X-40 Y-10 Z0 U0 S1 ; set axis minima M208 X160 Y170 Z300 U500 S0 ; set axis maxima ; Endstops M574 X2 S1 P"xstop" ; configure switch-type (e.g. microswitch) endstop for high end on X M574 Y2 S3 ; configure sensorless endstop for high end on Y M574 Z2 S1 P"zstop+e2stop" ; configure active-high endstops on Z via pins zstop and e1stop M574 U2 S1 P"e1stop" ; configure switch-type (e.g. microswitch) endstop for high end on U via pin e1stop M915 Y R0 F0 S3 ; configure stall detection for Y ; Z-Probe M950 S0 C"duex.pwm1" ; Duet 2 WiFi/Ethernet + DueX2/5 M558 P9 C"^zprobe.in" H5 F120 T6000 ; Duet 2 WiFi/Ethernet, DueX2/5 G31 P500 X-7 Y0 Z6.017 ; set Z probe trigger value, offset and trigger height
-
@jrcl said in Independent Z Motors- Endstop Error:
G28 Z Failed to Enable End Stops, error message.
You're only getting that error when you send G28 Z?
Does homeall work?Can you send M119 and share the results?
Can you send M574 and share the results? -
@jrcl said in Independent Z Motors- Endstop Error:
M574 Z2 S1 P"zstop+e2stop"
I suspect that line isn't working as intended. As you have a DueX in the system, you should use this:
M574 Z2 S1 P"zstop+duex.e2stop"
-
@dc42 Aha! That fixed the problem, Z is homing as expected now. Thank you!
-