Hi, I’m finishing the mount of my LR3 and started testing the motors, and the Z motors are out of sync. I’m using an MKS Gen L 2.1 that has the pins X, Y, Z, E0, and E1. I have one motor plugged into the Z stepper and works pretty well, however, the one into the E1 is out of sync. If I move 10mm, it goes to 30mm. If I change the motor steppers order, then the one that was in the E1 and now in the Z moves correctly, and the other will show the problem. Thus, I believe the problem lies in the firmware configuration for the E1 stepper. However, I’m not able to find a solution.
I’m building Marlin from scratch, based on the firmware provided for the SKR Pro 2209 (because this is my stepper drive) and on the Ramps firmware (because it uses the same processor mega2560).
I suggest getting the config.h from the closest matching V1 firmware and your own config.h open in a text editor that allows a side-by-side comparison. I know Notepad++ has a compare plug-in that I’ve used for this in the past.
Look for steps per mm settings for the second Z motor in the V1 and set yours to match.
Yeah, I already did that using the VSCode… Unfortunately, the parts that seem to affect my problem are still the same as the original config.h from V1.
Im going to ask some really basic questions, because I haven’t see it adressed.
I gather you are using an MKS Gen L 2 board. What drivers are you using? Have you verified that rhe microstepping jumpers are set the same for all 5 channels? If you have (for example) one set at 16X and another at 4X that would give you 4X the movement on one motor as oppsed to the other. Since Z2 is on the E1 driver, sometimes those microstepping jumpers are not equipped from new.
Have you checked grub screws? It’s almost a running gag around here but it really does cause a.lot of problems… Edit: Ok, I see you have checked. Good! It never hurts to be sure,
Are all 5 drivers the same model? A4988 drivers and DRV8825 drivers react differently to having all jumpers installed. A4988 drivers cap at 16X microstep, while DRV8825 drivers cap ar 32X. Not sure with TMC drivers.
If you are using TMC drivers, are they all configured for UART or jumpered? The MKS Gen L v1.0 that I used to use didn’t have the option, but I thought the newer faster boards did.
Rarher than pouring over the configuration files, this seems to me to be more of a hardware thing. If both Z motors move on command, ans in the correct direction, microstepping seems much more likely to me than configuration. I dont think Marlin allows 2 motors on the same axis to have different steps/mm. (Could ve wrong, but even if it does, I doubt that it would be something you could do by accident.)
Hi Dan, thanks for your answer. I have checked all the things you mentioned and the problem still. I’m using MKS2209 drivers. However, I found the solution on reddit and I will post It here.
I changed my steppers to:
#define X_DRIVER_TYPE TMC2209
#define Y_DRIVER_TYPE TMC2209
#define Z_DRIVER_TYPE TMC2209
#define Z2_DRIVER_TYPE TMC2209 // I changed E1 to Z2
#define E0_DRIVER_TYPE TMC2209 // I have not tested the Y motors, so if they are out of sync I will change this driver for Y2.
Compiling Marlin will raise an error because Z2 is not defined in the pins. So I had to change the pins file for my board: pins_MKS_GEN_L_21.h and include the following lines: