Extruder pin used as a Stepper pin

Basic Information:

Printer Model: Experimental trident printer
MCU / Printerboard: Manta E3EZ
Host / SBC CB1 (no emmc)
klippy.log klippy.log (448.9 KB)

Klipper config:

#########################################
#PRINTER CONFIGURATION
#########################################

[printer]
kinematics: corexy
max_velocity: 300
max_accel: 3000
max_z_velocity: 5
max_z_accel: 100

#########################################
#MCU CONFIGURATION
#########################################

[mcu]
serial: /dev/serial/by-id/usb-Klipper_stm32g0b1xx_hurakan-if00

#########################################
#STEPPERS CONFIGURATION
#########################################

[stepper_x]
step_pin: PA14
dir_pin: !PA10
enable_pin: !PA13
microsteps: 16
rotation_distance: 40
endstop_pin: ^PC4
position_endstop: 0
position_max: 235
homing_speed: 50

[stepper_y]
step_pin: PC8
dir_pin: !PA15
enable_pin: !PC14
microsteps: 16
rotation_distance: 40
endstop_pin: ^PB0
position_endstop: 0
position_max: 235
homing_speed: 50

[stepper_z]
step_pin: PD2
dir_pin: PD4
enable_pin: !PD3
microsteps: 16
rotation_distance: 8
endstop_pin: ^PC6
position_endstop: 0
position_max: 270

[extruder_z1]
step_pin: PB7
dir_pin: PB6
enable_pin: !PB4
microsteps: 16
nrotation_distance: 8
endstop_pin: ^PC6
position_endstop: 0
position_max: 270

#########################################
#STEPPERS CONFIGURATION
#########################################

[tmc2209 stepper_x]
uart_pin: PB8
#diag_pin: PC4
run_current: 0.800
stealthchop_threshold: 999999

[tmc2209 stepper_y]
uart_pin: PC9
##diag_pin: PB0
run_current: 0.800
stealthchop_threshold: 999999

[tmc2209 stepper_z]
uart_pin: PD0
#diag_pin: PC6
run_current: 0.650
stealthchop_threshold: 999999

[tmc2209 stepper_z1]
uart_pin: PB5
#diag_pin: PC6
run_current: 0.800
stealthchop_threshold: 999999

[tmc2209 extruder]
uart_pin: PD1
run_current: 0.800
stealthchop_threshold: 999999

#########################################
#EXTRUDER CONFIGURATION
#########################################

[extruder]
step_pin: PD5
dir_pin: !PD6
enable_pin: !PB3
microsteps: 16
rotation_distance: 33.500
nozzle_diameter: 0.400
filament_diameter: 1.750
heater_pin: PB11 #HE0
sensor_type: EPCOS 100K B57560G104F
sensor_pin: PA4 #TH0
control: pid
pid_Kp: 21.527
pid_Ki: 1.063
pid_Kd: 108.982
min_temp: -100
max_temp: 250

#########################################
#HEATER BED CONFIGURATION
#########################################

[heater_bed]
heater_pin: PB2 #HB
sensor_type: EPCOS 100K B57560G104F #Generic 3950
sensor_pin: PA3 #TB
control: watermark
min_temp: -100
max_temp: 130

#########################################
#FANS CONFIGURATION
#########################################

[fan]
pin: PA8

[temperature_fan MCU]
pin: PB15
control: watermark
max_delta: 1
sensor_type: temperature_host
min_temp: 0
max_temp: 100 i
target_temp: 45

Describe your issue:

Hello, I am trying to change the E1 EZ2209 driver to drive another Z axis stepper instead of the extruder motor. It seems like Klipper is recognizing that the E1 driver is only an extruder driver.

Is it possible to change the stepper type in the config so that Klipper can drive the E1 stepper as a regular stepper not an extruder stepper

The ā€œroleā€ a certain pin has is only determined by the configuration section you are using the pin in. Klipper is almost fully agnostic of the board, its markings or intended functionality and only goes by the usage in the printer.cfg file (with some sanity checks to avoid apparently impossible combinations).

The config that Klipper is ā€œseeingā€ is printed in the log, with the most recent ones at the end.
Obviously a section [extruder_z1] as currently used, does not make any sense.

Define your [stepper_*] and [extruder] sections as needed and make sure that every stepper section has a matching [tmc2209 *] section, with * being the exact same name as used for the corresponding stepper.

1 Like

Thank you very much Sineos for this error correction.

I have corrected the issue but I am still getting a Klipper error message: Option ā€˜position_endstopā€™ is not valid in section ā€˜stepper_z1ā€™

For the step_pin and dir_pin I have just copied the pins from previous [extruder1] . I am still not sure if it was the right way to do itā€¦

Screenshot 2024-10-14 193938
![Screenshot 2024-10-14 193845|690x237]

Here is my most recent klippy log if needed:
klippy.log (723.6 KB)

Refer to Manta-E3EZ/Firmware/Klipper/generic-bigtreetech-manta-e3ez.cfg at master Ā· bigtreetech/Manta-E3EZ Ā· GitHub for a general config of this board and its corresponding pins here Manta-E3EZ/Hardware/BIGTREETECH Manta E3EZ V1.0-PIN.png at master Ā· bigtreetech/Manta-E3EZ Ā· GitHub.

This board has 5 driver slots and you can assign them as you like. For example:

[stepper_x]
step_pin: PA14
dir_pin: !PA10
enable_pin: !PA13
... # rest of the settings

[tmc2209 stepper_x]
uart_pin: PB8

The uart_pin: PB8 tells you that it is the first driver slot, commonly used for the X axis and the [stepper_x] section tells Klipper that you expect it to be your X-axis.

If you rather would like to connect your extruder to the first driver slot, you could do:

[extruder]
step_pin: PA14
dir_pin: !PA10
enable_pin: !PA13
... # rest of the settings for the extruder

[tmc2209 extruder]
uart_pin: PB8

Now you have told Klipper to use the first slot as extruder and of course you would have to connect your extruder to this slot then.

Only the first [stepper_z] may have the axis defining information like

endstop_pin: ...
position_endstop: ...
position_max: ...

as obviously your z-axis can only have ā€œone truthā€ regarding the information how far to travel or when to stop.

1 Like

Thank you very much Sineos :smiley: this has solved my issue
I only had to remove these lines from the config:

endstop_pin: ...
position_endstop: ...
position_max: ...

The code now looks like this

[stepper_z]
step_pin: PD2
dir_pin: PD4
enable_pin: !PD3
microsteps: 16
rotation_distance: 8
endstop_pin: ^PC6
position_endstop: 0
position_max: 270

[stepper_z1]
step_pin: PB7
dir_pin: PB6
enable_pin: !PB4
microsteps: 16
rotation_distance: 8

[tmc2209 stepper_z1]
uart_pin: PB5
#diag_pin: PC6
run_current: 0.650
stealthchop_threshold: 999999

All the axis are well configured and move alrightā€¦ :relieved:

It was my first time on the klipper discourse forum and I am pleasantly surprised of itā€¦

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.