Corexy A/B steppers move when Z moves up or down...



  • I have a CoreXY build i am working on with a Duet 2 ethernet and Duex 5 on latest firmware. I have it setup far enough along to where I can start figuring out my wiring. I have the 4 Z steppers, the 2 A/B motors for XY and 1 extruder currently plugged in and to the best of my knowledge configured properly. When I give it G92 X0 Y0 Z0 just so i can test it (No homing switches yet) the A/B motors for the XY axis move when I only command the Z axis to move. A/B (or XY) and E0 steppers are plugged into the Duet 2 just as they are labeled on the board. the 4 Z steppers are on the Duex5 on 5-9 as labeled on the board as well.

    Here is my drive mapping
    M584 X0 Y1 Z5:6:7:8 E3:4:2 ; Set Drive Mapping

    and the gcode to set it as corexy movement
    M667 S1 ; Select CoreXY mode

    Thanks for any advice!



  • Can you post your entire config file?

    Any other details on the problem would help as well. Like does the XY work normally (no Z motion?), how are you commanding the Z moves, etc.



  • Hey @nhof All movements are being requested through DWC2. If i try to move the XY axis individually they move fine. Its when i request any Z movement on DWC2 that the XY steppers move as well.

    Here is my config.g

    ; Configuration file for Voron 2.1 with Duet 2 Ethernet (firmware version 2.02 or newer)
    ;
    ; General preferences ---------------------------------------------------------------------------------------------------------------------------------------------------
    M111 S0 ; Debugging off
    M555 P2 ; Set firmware compatibility to look like Marlin
    M911 S23 R24 P"M913 X15 Y15 Z75 G91 M83 G1 Z3 E-5 F1000"; Set power monitor threshold voltages P=channel 0 S=cutoff voltage min (23v) R=resume voltage (24v) P"command string" (run macro)
    M575 P1 B57600 S1 ; Set auxiliary serial port baud rate and require checksum (for PanelDue)
    ;
    ; Network ---------------------------------------------------------------------------------------------------------------------------------------------------------------
    M550 PBUILD ; Set machine name
    M551 Preprap ; Set password
    M552 S1 P192.168.1.50 ; Set Duet IP address
    M553 P255.255.255.0 ; Set subnet mask
    M554 P192.168.1.1 ;Set gateway
    M586 P0 S1 ; Enable HTTP
    M586 P1 S0 ; Disable FTP
    M586 P2 S0 ; Disable Telnet
    ;
    ; Movement CoreXY configuration -----------------------------------------------------------------------------------------------------------------------------------------
    G21 ; Set units to millimetres
    G90 ; Set to absolute coordinates
    M83 ; Set extruders to relative coordinates
    M667 S1 ; Select CoreXY mode
    M208 X-175 Y150 Z0 S1 ; Set axis min (X350/Y300/Z300)
    M208 X175 Y-150 Z300 S0 ; Set axis max (X350/Y300/Z300)
    ;M556 S100 X0.0 Y0.0 Z0.0 ; Set axis skew compensation
    ;
    ; Endstops --------------------------------------------------------------------------------------------------------------------------------------------------------------
    M574 X2 Y2 Z0 S0 ; Set active high endstops, no z switch
    ;
    ; Probe Tools
    ; BLTouch Z Probe -------------------------------------------------------------------------------------------------------------------------------------------------------
    ;M558 P9 H5 F100 T2000 R0 A2 S0.03 ; Set Z probe type to BLTouch and the dive height + speeds
    ;G31 P25 X____ Y____ Z____ ; Set Z probe trigger value, offset and trigger height
    ;M557 X-150:150 Y-100:100 S50 ; Define sparse mesh grid
    ;M376 H1.0 ; Set bed compensation taper at specified Z axis location
    ;
    ; Drives ---------------------------------------------------------------------------------------------------------------------------------------------------------------
    ; Default Motor layout: 0:X; 1:Y; 2:ZAB; 3:E0; 4:E1; 5:E2; 6:E3; 7:E4; 8:E5; 9:E6
    M584 X0 Y1 Z5:6:7:8 E3:4 ; Set Drive Mapping
    M569 P0 S1 ; Drive 0 goes forwards (X AXIS)
    M569 P1 S1 ; Drive 1 goes forwards (Y AXIS)
    ;M569 P2 S1
    M569 P3 S1 ; Drive 3 goes forwards (E0 MOTOR)
    M569 P4 S1 ; Drive 4 goes forwards (E1 MOTOR)
    M569 P5 S1 ; Drive 5 goes forwards (Z-- 1 MOTOR)
    M569 P6 S1 ; Drive 6 goes forwards (Z+- 2 MOTOR)
    M569 P7 S1 ; Drive 7 goes forwards (Z-+ 3 MOTOR)
    M569 P8 S1 ; Drive 8 goes forwards (Z-- 4 MOTOR)
    M569 P9 S1
    M671 X-180:185:-180:185 Y-125:-125:205:205 S20 ; Define position of Z axis (X350/Y300/Z300) !!!MUST BE AFTER M667/M669!!!
    ; Driver Microstepping
    M350 X16 Y16 I0 ; Set XY axis microstepping to 1/16 and interpolation OFF
    M350 Z16 I0 ; Set Z axis microstepping to 1/16 and interpolation OFF
    M350 E16:16 I0 ; Set E0 and E1 microstepping to 1/16 and interpolation OFF
    ; Driver Steps/mm
    M92 X80 Y80 ; Set XY axis steps/mm for 1/16 miscrostepping !!!MUST BE AFTER M350!!!
    M92 Z400 ; Set Z axis steps/mm for 1/16 miscrostepping !!!MUST BE AFTER M350!!!
    M92 E576:576 ; Set Extruders steps/mm for 1/16 miscrostepping !!!MUST BE AFTER M350!!!
    ; Driver Current Idle
    ;M84 S86400 ; Set motor idle timeout to 24 hours
    ;M906 I0 ; Set motor current idle percentagee (0%)
    ; Driver Current, Velocity, Acceleration, Jerk
    M906 X750 Y750 Z750 E500 ; set absolute motor drive current
    ;; Set reduced physics parameters to help prevent missed steps.
    M203 X4500 Y4500 ; maximum speed (mm/min)
    M201 X900 Y900 ; maximum acceleration (mm/min/s)
    M566 X180 Y180 ; instantaneous speed change (mm/min)
    ;
    ; Heaters ---------------------------------------------------------------------------------------------------------------------------------------------------------------
    ; H0=bed, H1=T0/E0, H2=T1/E1, 200-203=Duet PT1000, 204-207=Duex PT1000
    ; H0 bed 0 (Keenovo)
    M570 H0 P10 T10 ; Set bed heater 0 fault detection H=heater P=time in seconds T=temperature excursion from setpoint
    M143 H0 S100 ; Set bed heater 0 maximum heater temperature to 90C
    M305 P0 T100000 B4725 C0 R4700 ; Set bed heater 0 thermistor + ADC parameters
    M307 H0 A119.8 C600.0 D0.3 S1.00 V24.0 B0 ; Set bed heater 0 PID Heater 0 model:
    M912 P0 SO ; Set bed heater 0 electronics temperature monitor adjustment in degC
    ; H1 extruder 0 (E3D 24V 65W Hi-temp )
    M570 H1 P5 T10 ; Set E0 heater 1 fault detection H=heater P=time in seconds T=temperature excursion from setpoint
    M143 H1 S265 ; Set E0 heater 1 maximum heater temperature to 265C
    M305 P1 X200 ; Set E0 heater 1 PT1000 Duet Channel 200
    M307 H1 A650.0 C316.6 D4.8 S1.00 V24.3 B0
    ;M307 H1 A791.4 C179.7 D5.2 S1.00 V24.1 B0 ; Set E0 E3D V6 Hi-temp set heater 1 PID heater
    M912 P1 SO ; Set E0 heater 1 electronics temperature monitor adjustment in degC
    ; H2 extruder 1 (E3D 24V 30W ceramic)
    ;M570 H2 P5 T10 ; Set E1 heater 1 fault detection H=heater P=time in seconds T=temperature excursion from setpoint
    ;M143 H2 S265 ; Set E1 heater 1 maximum heater temperature to 265C
    ;M305 P2 X201 ; Set E1 heater 1 PT1000 Duet Channel 201
    ;M307 H2 A650.0 C316.6 D4.8 S1.00 V24.3 B0 ; Set E1 E3D V6 Standard set heater 2 PID heater
    ;M912 P2 SO ; Set E1 heater 1 electronics temperature monitor adjustment in degC
    ; H7 heater 7/PWM channel 5
    M307 H3 A-1 C-1 D-1 ; Disable the heater 7 on Duex5 to free up PWM channel 5 on the Duex5 board for BLtouch
    ;
    ; Tools ------------------------------------------------------------------------------------------------------------------------------------------------------------------
    ; T0 (E3D Hi-temp Setup - E3D V6 W/ PT100, Titanium Heatbreak, plated copper block, nozzle X and 24v Hi-Temp heater)
    M563 P0 D0 H1 ; Set tool 0 with extruder 0 and heater 1
    G10 P0 S0 R0 X0 Y0 ; Set tool 0 temperatures and offsets
    ;M592 D0 A0.010 B0 ; Configure nonlinear extrusion
    ;M591 D0 P2 C3 S1 ; Configure E0 filament detector
    ; T1 (E3D Precision Setup - E3D V6 Heatsing w/ PT100, SS Heatbreak, plated copper block, plated copper nozzle and ceramic 24v 30w heater)
    ;M563 P1 D1 H2 ; Set tool 1 with extruder 1 and heater 2
    ;G10 P1 S0 R0 X0 Y0 ; Set tool 1 temperatures and offsets
    ;M592 D1 A0.010 B0 ; Configure nonlinear extrusion
    ;M591 D1 P2 C4 S1 ; Configure E1 filament detector
    ;
    ; Fans -------------------------------------------------------------------------------------------------------------------------------------------------------------------
    M106 P0 S1 I0 H-1 ;C"Tool1" ; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off
    M106 P1 S1 I0 H-1 C"Tool2" ; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned off
    ;
    ; Sensors ----------------------------------------------------------------------------------------------------------------------------------------------------------------
    M305 P101 S"Duet Drivers" ; Configure name and enable display of Duet stepper drivers on channel 1001
    M305 P102 S"Duex Drivers" ; Configure name and enable display of Duex stepper drivers on channel 1002
    ;M305 P3 R4700 T100000 B3950 S"Chamber" ; Configure thermistor and enable display of chamber thermistor on channel 3
    ;M305 P103 X4 R4700 T100000 B3950 S"Heatbreak" ; Configure thermistor and enable display of E0 cold end thermistor on channel 103
    ;



  • I also noticed that I had driver 2 (the dual Z stepper output on the Duet 2 defined as extruder 3
    M584 X0 Y1 Z5:6:7:8 E3:4:2 ; Set Drive Mapping

    so i changed it to this
    M584 X0 Y1 Z5:6:7:8 E3:4 ; Set Drive Mapping

    If I unplug the XY steppers and only request a Z axis movement I get an error about drivers 0 and 1 not being connected properly. Seems like somewhere something is messing up the axis assignment? Also even thought the X and Y move when the Z does, it seems like the Z axis raised/lowers by different amounts which makes me think that the steps/mm are also incorrect somehow.



  • Assume you are overriding the homing requirement with M564? Any homing script or similar which might mess with the axis mapping? (such as a Z home script)?

    Also try moving the M584 line to the first line of your config. Shouldn't make a big difference but some g-codes have to be set in the config in a specific order.

    When you say the Z raises/lowers by different amounts do you mean inconsistent motion with the same command?

    Such as: I command Z+5 move, Z moves up by 2mm. I command another Z+5 move, Z moves up by 13mm.

    or: I command Z+5 move, three of the screws move 5mm, one screw moves 2.3mm.

    or similar



  • " I command Z+5 move, three of the screws move 5mm, one screw moves 2.3mm" is what happens. Its belt driven on the Z but mechanically and belt tension look ok.

    I just tried using M584 H0 and then tried some moves... what do you know the XY steppers dont move. Why is that? I tried it with another config.g that is very close to what I have... mostly just format changes and it worked when entering G92 X0 Y0 Z50 and then requested movement.



  • Do both XY motors move when Z is commanded or just one? If just one it will move on a diagonal only.

    Did you try M564 or M584? M564 changes behavior of homing (allows/blocks axis moves before homing) while M584 will remap your axis. If you called M584 H0 it might unassign driver0 from X which would stop it from moving.

    M564 H0 will cause the printer demand that you home axes before movement.



  • I figured out the reason my one Z was not moving the same distance as the other 3... wrong GT2 tooth count lol. If i start the printer from a fresh power up and send G92 X0 Y0 Z0 so it thinks XYZ are homed at 0,0,0 and command a Z movement both the XY motors move. Not sure if their direction is correct as I dont have my X gantry on. If from a fresh power up i send M564 H0 and move the Z axis, it moves correctly and the XY steppers do not move.



  • I found the culprit.... and it seems to cause RRF to glitch. It had to due with my axis min and max in the follow gcode:

    M208 X-175 Y150 Z0 S1 ; Set axis min (X350/Y300/Z300)
    M208 X175 Y-150 Z300 S0 ; Set axis max (X350/Y300/Z300)

    You can see the my min and max Y are reversed. I noticed that when I moved the Z axis and the XY motors moved the Y coordinate would with be 150 or -150, no values in between, @dc42 could there be a checked implemented for this?



  • @nikker Interesting. IIRC another user reported unexpected behavior with unusual M208 values recently as well. Glad it's solved at least.


  • administrators

    @nikker said in Corexy A/B steppers move when Z moves up or down...:

    @dc42 could there be a checked implemented for this?

    Yes, I'll add a check. Unfortunately, error messages generated when config.g is run are often not seen by the user.


Log in to reply