How to configure Marlin for dual z and dual Y axis

Sorry if its been asked before but im new to configuring Marlin. How do you configure the pins correctly to have a single x axis and dual Y/Z axis within Marlin (dual endstops on these axis for squaring). I flashed Ryans dual firmware to the board but this is for the MPCNC more so than the Lowrider. Physically plugging the steppers into the Rambo 1.4 is easy and already laid out in other post.

In configuration_adv.h, you can find the settings for X_DUAL_DRIVERS or something similar. I can never remember exactly.

Disable X, enable Z. Make sure the z2 endstop is what you want.

Thanks for the response Jeff. You help out a ton on here. Ill try to keep it short…Im looking for what to exactly type into arduino and where to type it into to get up and running. I built the MPCNC with dual endstops and had no issues as it squares up nicely. The Lowrider has the potential to be a dream but demands more programming for the same results. I need the Z axis to auto square and the Y axis (long side of table). Does anyone have the software file to flash the board (Rambo 1.4)? I need the precision as I build aluminum panels for my Pitts aerobatic aircraft. The MPCNC has done wonders for me but I have to build larger panels now.

You’ll have to do a bit of combining here, as dual on the lr isn’t standard.

Here are the instructions for flashing a rambo:

https://docs.v1engineering.com/electronics/marlin-firmware/

Here is the version that has dual endstops, configured for an MPCNC:

I would suggest trying to just go through the steps first, and make sure you can flash it with that software without changing it.

You will have to open Marlin/Marlin/configuration_adv.h and change and save it. The parts you need to change look like this:

#define X_DUAL_STEPPER_DRIVERS
#if ENABLED(X_DUAL_STEPPER_DRIVERS)
  #define INVERT_X2_VS_X_DIR true   // Set 'true' if X motors should rotate in opposite directions
  #define X_DUAL_ENDSTOPS
  #if ENABLED(X_DUAL_ENDSTOPS)
    #define X2_USE_ENDSTOP _XMAX_
    #define X2_ENDSTOP_ADJUSTMENT  0
  #endif
#endif

You need to comment out the X, so it no longer has dual X. That first line should look like this:
// #define X_DUAL_STEPPER_DRIVERS

Then a few lines lower you’ll see the Z section (which looks a little different):

Change that to: #define NUM_Z_STEPPER_DRIVERS 2

And then enable the endstops by removing the leading slashes on:
//#define Z_MULTI_ENDSTOPS
So:
#define Z_MULTI_ENDSTOPS

It looks like it is set to use xmax. For Z2.

E0 will be Y2. E1 will be Z2.

You can do this. :+1: If you get off track, go back and carefully look to see if you made a mistake. If you get an error, post it here, and one of us will help you.

2 Likes

Thank you Jeff! It worked…now the next issue is that Z2 goes to XMAX and triggers properly however I dont know where Z1 is suppose to plug in. Im trying to get the Z axis to home in the up position.

1 Like

Nevermind…you have already solved this issue in a different form…Thank you a ton for all your work Jeff!

1 Like

Where did you find the solution, I am having the same issue

Hi guys, i have the same problem with an skr 1.3, i try to set the parameter same as Jeff guide, but to work i need to comment //#define Y_DUAL_ENDSTOPS, same as z, or i receive compile error…

this… “USE_YMAX_PLUG is required when Y2_USE_ENDSTOP is YMAX.”… what’s i wrong?

There is preconfigured dual endstop low rider firmware now. Head over to MarlinBuilder releases and get the skr1p3 DualLR version.

oh my god…i love you!!! thanks Jeff :slight_smile:

Jeff, or my board dont like the official dual firmware, or is broken, any advice to clean the board of the old firmware?

There isn’t any clean up needed. There is persistent storage (Eeprom). You can clear that by sending M502 and M500. But it should run ok even without that. Maybe open an issue for your board and setup and we can all work on your issue.

This is a little off topic for this thread, but you are talking about setting DUAL_DRIVERS in Marlin & they seem to not be used anymore with that setting.

I was working on putting dual Z motors on the Z motor & E1 motor & haven’t quite figured it out yet. This is on a SKR V1.4 board with Bigtreetech TMC2209s in UART mode with diag pin clipped for no sensorless homing. In a google search, I saw a reference to setting Z_DUAL_STEPPER_DRIVERS in the firmware. Doing a string search on configuration.h & configuration_adv.h found no references, so I searched the whole directory tree on current Marlin 2.1.1 & found these lines in the file SanityCheck.h in the folder Marlin\src\inc
I added the line numbers where they appear in the file. I am wondering if it just works by default.
533 #elif defined(Z_DUAL_STEPPER_DRIVERS)
534 #error “Z_DUAL_STEPPER_DRIVERS is no longer needed and should be removed.”
633 #elif defined(X_DUAL_STEPPER_DRIVERS)
634 #error “X_DUAL_STEPPER_DRIVERS is no longer needed and should be removed.”
635 #elif defined(Y_DUAL_STEPPER_DRIVERS)
636 #error “Y_DUAL_STEPPER_DRIVERS is no longer needed and should be removed.”

Apparently in Marlin 2.0.9.3 or before it changed to use NUM_Z_STEPPER_DRIVERS, but that is also not currently used. Searching the Issues or Release notes, I have not yet found the correct answer to this. Anyone seen the answer to this?

-------- Marlin-2.0.9.3\Marlin\Configuration_adv.h
676. #define NUM_Z_STEPPER_DRIVERS 1 // (1-4) Z options change based on how many

I did set these in configuration.h . Not sure I need the E1 or Z2 set here or both. I initially was going to put both Z motors on the one stepper, but for some reason it was not working. I ran one motor on it to make sure the wiring was correct to make sure. I visually checked the wiring & they are wired the
#define X_DRIVER_TYPE TMC2209
#define Y_DRIVER_TYPE TMC2209
#define Z_DRIVER_TYPE TMC2209

#define Z2_DRIVER_TYPE TMC2209

#define E0_DRIVER_TYPE TMC2209
#define E1_DRIVER_TYPE TMC2209

#define DEFAULT_AXIS_STEPS_PER_UNIT { 160, 160, 400, 432, 400 } // TMC2209 X,Y,Z, E0 & E1
#define DEFAULT_MAX_FEEDRATE { 300, 300, 25, 17, 25 }
#define DEFAULT_MAX_ACCELERATION { 1500, 1500, 120, 10000, 120 }

[Edit] I just found this in the file Marlin-2.1.1\Marlin\src\pins\pins_postprocess.h
To me this still doesn’t seem clarify what I need to set in the 2 configurarion files.
/**

  • Auto-Assignment for Dual X, Dual Y, Multi-Z Steppers
  • By default X2 is assigned to the next open E plug
  • on the board, then in order, Y2, Z2, Z3. These can be
  • overridden in Configuration.h or Configuration_adv.h.
    */

[Edit 2] Looking thru the example configuration files, I found this one that I will try tomorrow unless another idea comes up before then. It does not look like I need to change anything in configuration_adv.h
Configurations-release-2.1.1\config\examples\Creality\CR-10S\BigTreeTech SKR 2.0 TMC2209\Configuration.h
#define Z2_DRIVER_TYPE TMC2209

I have the same problem than you. I dont know how to configure two stepper drivers for z axis in the new version of marlin (2.1). If yo find the solution could you reply me? Thanks :smiley:

Hi all,

Hello, i have dual y motors that run independently of each other and both have their own end stops.

i did the following:

#define Y_DUAL_ENDSTOPS
#if ENABLED(Y_DUAL_ENDSTOPS)
#define Y2_USE_ENDSTOP E1DIAG
#define Y2_ENDSTOP_ADJUSTMENT 0
#endif
#endif

When i do an m119 everything is neatly “open” except y2 “triggers”
i have attached configuration files.

Configuration.h

Configuration_adv.h

Pins MKS Robin Nano V3

I have 1 z 1 x 2 y
Board is a Robin Nano V3