<p>I was getting the same issue/error code, but for my Y2 axis:</p>
<p><code>TMC2208 or TMC2209 on Y2 requires Y2_HARDWARE_SERIAL or Y2_SERIAL_(RX|TX)_PIN</code></p>
<p>I'm running Marlin 2.0, on an MKS Gen L V2.1 with TMC2209 (BigTreeTech v1.2) drivers. I have X, Y, Y2 (Running on E1 driver) and E0 for a custom scientific instrument (that is not a 3D printer, but it uses the same firmware and G-Code to move about so it is all the same). I initially tried to get this all going on the MKS Gen L V1, however, it only has UART for 4 Drivers (see the video by <a href="https://www.youtube.com/watch?v=dOJbSrWVu_Q" rel="nofollow noreferrer">Teaching Tech</a>). You can not get 5 drivers controlled by UART moving on this V1.0 board. For this reason, I moved over to the MKS Gen L V2.1. If this V1 board is all you have, I guess you could leave one driver as an A4988 or DRV8825 and accept the loss of the upgrade to the TMC2209 for one axis. This was the firmware that won't ask for Serial Pins, which is where most of this issue comes from.</p>
<p><strong>SOLUTION:</strong></p>
<p>The above solution by 'Jiří Maier' mostly fixed my problem. There are a few things to note and modify though:</p>
<p>In <code>configuration.h</code>, <code>#define EXTRUDERS 1</code> defines the number of extruders. This is important here I think (I'm 85% on this). This value will push the 'extruder' down onto the next available stepper driver, which will be E0. Therefore I moved my Y2 driver to E1 as E0 was 'occupied' by the extruder.</p>
<p>In <code>configuration.h</code>, make sure the <code>DRIVER_TYPE</code> axes are all set correctly to the number of drivers you actually have. For example, I am using a driver for X, Y, Z, Y2, and an extra one E0 (for pumping liquids), so 5 total. Here, Y2 will replace the E1 driver, so E1 is commented out. Therefore, all used drivers have the TMC2209 commented in here. Everything else should be commented out.</p>
<p><a href="https://i.sstatic.net/OAOtA.png" rel="nofollow noreferrer" title="Screenshot of Marlin 2.0 Firmware, in Configuration.h section. Search for 'X_DRIVER_TYPE'"><img src="https://i.sstatic.net/OAOtA.png" alt="Screen shot of Marlin 2.0 Firmware, in Configuration.h section. Search for 'X_DRIVER_TYPE'" title="Screenshot of Marlin 2.0 Firmware, in Configuration.h section. Search for 'X_DRIVER_TYPE'" /></a></p>
<p>After this then you can assign the pins as mentioned by Jiří Maier.</p>
<p>In the <code>pins_MKS_GEN_L_V21</code> file I changed all starts of the code for <code>E1_SERIAL_TX_PIN</code> to <code>Y2_SERIAL_TX_PIN</code>, like below:</p>
<pre><code>#ifndef Y2_SERIAL_TX_PIN                           
  #define Y2_SERIAL_TX_PIN                    20    
#endif
#ifndef Y2_SERIAL_RX_PIN                    
  #define Y2_SERIAL_RX_PIN                    12    
#endif
</code></pre>
<p>Similarly, in the <code>pins_RAMPS</code> file I changed the <code>E1_STEP_PIN</code> to <code>Y2_STEP_PIN</code> and so on, see the image below.</p>
<pre><code>#define Y2_STEP_PIN                           36                          
#define Y2_DIR_PIN                            34    
#define Y2_ENABLE_PIN                         30    
#ifndef Y2_CS_PIN                   
  #define Y2_CS_PIN                           44
</code></pre>

CC BY-SA 4.0
2023-01-25T03:21:46.387Z
2023-01-25T04:21:38.543Z
2023-01-25T04:21:38.543Z
Quadslunth
<p>Your question is missing important information, but I can try to figure out something. You didn't say what kind of firmware it is. I assume it is Marlin.</p>
<p>Your problem is that there are no Tx Rx pins specified for Z2 (because there is X, Y, Z, E0, E1 by default on the MKS Gen L board)</p>
<p>I assume you want to use the E1 driver for the Z2 instead of a second extruder. In that case, you have to tell the firmware that you want to use that driver for Z2.</p>
<p>Search the source code for file &quot;pins_MKS_GEN_L_V21.h&quot;
There should be E1_SERIAL_TX_PIN and E1_SERIAL_RX_PIN defined.
Rename them to Z2_SERIAL_TX_PIN and Z2_SERIAL_RX_PIN.</p>
<p><a href="https://i.sstatic.net/mqMKc.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/mqMKc.png" alt="driver uart pins" /></a></p>
<p>In &quot;pins_RAMPS.h&quot; file, find a block of a few lines that starts &quot;E1_STEP_PIN&quot;, and rename E1 to Z2 for all those lines.</p>
<p><a href="https://i.sstatic.net/2MBBK.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/2MBBK.png" alt="driver pins" /></a></p>
<p>It may (or may not) work now. If it doesn't, please somehow post those configuration files.</p>

CC BY-SA 4.0
2021-04-20T15:45:02.607Z
BTW: do you really want to have two independent drivers for Z? You can just connect two Z steppers to a single driver.
Jiří Maier
CC BY-SA 4.0
2021-04-24T21:04:53.130Z
Thank you so much for your response. unfortunately, I tried what you send and the motor still gets hot and now it developed noise!
I'm sorry for the inconvenience but I don't know how to share the files, so in the following link I uploaded the configureation.h, configuration_adv.h, pins_RAMPS.h, and pins_MKS_GEN_L_V21.h files.
https://drive.google.com/drive/folders/1V8Yw628a-RnjJeKxWd4wU0pyVEelkrGe?usp=sharing
Rayan
CC BY-SA 4.0
2021-04-19T23:33:16.920Z
2021-04-19T23:33:16.920Z
Jiří Maier
<p>I am getting this error when I try to enable the Z2 driver for MKS Gen L V2.1
Could anyone help?</p>
<p>Error &quot;TMC2208 or TMC2209 on Z2 requires Z2_HARDWARE_SERIAL or Z2_SERIAL_(RX|TX)_PIN.</p>

<stepper-driver><mks><tmc2209>
Error "TMC2208 or TMC2209 on Z2 requires Z2_HARDWARE_SERIAL or Z2_SERIAL_(RX|TX)_PIN
Rayan
# Error "TMC2208 or TMC2209 on Z2 requires Z2_HARDWARE_SERIAL or Z2_SERIAL_(RX|TX)_PIN

(Asked by: username_0 on 2021-04-19)

I am getting this error when I try to enable the Z2 driver for MKS Gen L V2.1
Could anyone help?

Error "TMC2208 or TMC2209 on Z2 requires Z2\_HARDWARE\_SERIAL or Z2\_SERIAL\_(RX|TX)\_PIN.

**Tags:** stepper-driver, mks, tmc2209

---

## 2 answers

### Answer by username_1 on 2023-01-25. Score: 1

I was getting the same issue/error code, but for my Y2 axis:
TMC2208 or TMC2209 on Y2 requires Y2_HARDWARE_SERIAL or Y2_SERIAL_(RX|TX)_PIN
I'm running Marlin 2.0, on an MKS Gen L V2.1 with TMC2209 (BigTreeTech v1.2) drivers. I have X, Y, Y2 (Running on E1 driver) and E0 for a custom scientific instrument (that is not a 3D printer, but it uses the same firmware and G-Code to move about so it is all the same). I initially tried to get this all going on the MKS Gen L V1, however, it only has UART for 4 Drivers (see the video by Teaching Tech). You can not get 5 drivers controlled by UART moving on this V1.0 board. For this reason, I moved over to the MKS Gen L V2.1. If this V1 board is all you have, I guess you could leave one driver as an A4988 or DRV8825 and accept the loss of the upgrade to the TMC2209 for one axis. This was the firmware that won't ask for Serial Pins, which is where most of this issue comes from.
SOLUTION:
The above solution by 'Jiří Maier' mostly fixed my problem. There are a few things to note and modify though:
In configuration.h, #define EXTRUDERS 1 defines the number of extruders. This is important here I think (I'm 85% on this). This value will push the 'extruder' down onto the next available stepper driver, which will be E0. Therefore I moved my Y2 driver to E1 as E0 was 'occupied' by the extruder.
In configuration.h, make sure the DRIVER_TYPE axes are all set correctly to the number of drivers you actually have. For example, I am using a driver for X, Y, Z, Y2, and an extra one E0 (for pumping liquids), so 5 total. Here, Y2 will replace the E1 driver, so E1 is commented out. Therefore, all used drivers have the TMC2209 commented in here. Everything else should be commented out.

After this then you can assign the pins as mentioned by Jiří Maier.
In the pins_MKS_GEN_L_V21 file I changed all starts of the code for E1_SERIAL_TX_PIN to Y2_SERIAL_TX_PIN, like below:
#ifndef Y2_SERIAL_TX_PIN                           
  #define Y2_SERIAL_TX_PIN                    20    
#endif
#ifndef Y2_SERIAL_RX_PIN                    
  #define Y2_SERIAL_RX_PIN                    12    
#endif

Similarly, in the pins_RAMPS file I changed the E1_STEP_PIN to Y2_STEP_PIN and so on, see the image below.
#define Y2_STEP_PIN                           36                          
#define Y2_DIR_PIN                            34    
#define Y2_ENABLE_PIN                         30    
#ifndef Y2_CS_PIN                   
  #define Y2_CS_PIN                           44


---

### Answer by username_2 on 2021-04-19. Score: 1

Your question is missing important information, but I can try to figure out something. You didn't say what kind of firmware it is. I assume it is Marlin.

Your problem is that there are no Tx Rx pins specified for Z2 (because there is X, Y, Z, E0, E1 by default on the MKS Gen L board)

I assume you want to use the E1 driver for the Z2 instead of a second extruder. In that case, you have to tell the firmware that you want to use that driver for Z2.

Search the source code for file "pins\_MKS\_GEN\_L\_V21.h"
There should be E1\_SERIAL\_TX\_PIN and E1\_SERIAL\_RX\_PIN defined.
Rename them to Z2\_SERIAL\_TX\_PIN and Z2\_SERIAL\_RX\_PIN.

[![driver uart pins](https://i.sstatic.net/mqMKc.png)](https://i.sstatic.net/mqMKc.png)

In "pins\_RAMPS.h" file, find a block of a few lines that starts "E1\_STEP\_PIN", and rename E1 to Z2 for all those lines.

[![driver pins](https://i.sstatic.net/2MBBK.png)](https://i.sstatic.net/2MBBK.png)

It may (or may not) work now. If it doesn't, please somehow post those configuration files.

> **Comments:**
> **username_2**: BTW: do you really want to have two independent drivers for Z? You can just connect two Z steppers to a single driver.  
> **username_0**: Thank you so much for your response. unfortunately, I tried what you send and the motor still gets hot and now it developed noise! I'm sorry for the inconvenience but I don't know how to share the files, so in the following link I uploaded the configureation.h, configuration_adv.h, pins_RAMPS.h, and pins_MKS_GEN_L_V21.h files. https://drive.google.com/drive/folders/1V8Yw628a-RnjJeKxWd4wU0pyVEelkrGe?usp=sharing  

---

