Swapped X and Y axis, Z endstips not working

I successfully swapped my X and Y axis around. My X axis is now the axis on the rollers and the Y axis is now the tube gantry axis. Endstops work for both X and Y including dual endstops for X.

In the process I needed to move Z2 endstop from XMAX. I changed this in configuration_adv.h:
// For Z set the number of stepper drivers
//
#define NUM_Z_STEPPER_DRIVERS 2 // (1-4) Z options change based on how many
#if NUM_Z_STEPPER_DRIVERS > 1
#define Z_MULTI_ENDSTOPS
#if ENABLED(Z_MULTI_ENDSTOPS)
#define Z2_USE_ENDSTOP ZMAX <<< Changed this from XMX
#define Z2_ENDSTOP_ADJUSTMENT 0
#if NUM_Z_STEPPER_DRIVERS >= 3
#define Z3_USE_ENDSTOP YMAX
#define Z3_ENDSTOP_ADJUSTMENT 0
#endif
#if NUM_Z_STEPPER_DRIVERS >= 4
#define Z4_USE_ENDSTOP ZMAX
#define Z4_ENDSTOP_ADJUSTMENT 0
#endif
#endif
#endif

Triggering the Z endstops while sending M119 shows that both do trigger. It tells me Z Zmin triggered and Z2 Zmax triggered yet when trying to home the Z axis the motors to not stop moving when the endstops get triggered.

I noticed that when homing the X axis it show me X Xmin triggered X2 Xmin triggered which is odd to me

My endstops are plugged in as follows:
X to xmin x2 to xmax
Y to ymin
Z to zmin Z2 to zmax

I’m obviously missing something.

The Z1 motor was already using ZMAX as the pin to stop it when homing. Instead, put YMAX in there, and make sure your two Z endstops are in ZMAX and YMAX. The two X endstops are in Xmin and Xmax. The Y endstop is at Ymin (although it isn’t needed, really). The Zmin is for a probe.

Thanks Jeff,
so I’m clear I should have my endstops like this:
X1 motor > XMIN X2 motor > XMAX
Y motor > YMIN
Z1 motor ZMAX Z2 motor YMAX
and change the code in configuration_adv.h to read as follows:
#if NUM_Z_STEPPER_DRIVERS > 1
#define Z_MULTI_ENDSTOPS
#if ENABLED(Z_MULTI_ENDSTOPS)
#define Z2_USE_ENDSTOP YMAX
etc…

Is this correct?

1 Like

Thanks Jeff! All seems to be working properly now.

2 Likes