Gcode override max_z_velocity

I’ve installed klipper on to my raspberry to control a skr 1.3. I followed the Configuration reference, and it seems to be working fine, but when it executes the “G1 z15.0 f6000” the z steppers stall. If I change it to “G1 z15.0 f200” it works fine. I assume that the gcode is overriding the max_z_velocity that is set to 25. This specific gcode runned fine in this printer before klipper, so I know is not it. What am I missing?

This file contains common pin mappings for the BIGTREETECH SKR V1.3

board. To use this config, the firmware should be compiled for the

LPC1768.

See docs/Config_Reference.md for a description of parameters.

[stepper_x]
step_pin: P2.2
dir_pin: !P2.6
enable_pin: !P2.1
microsteps: 16
rotation_distance: 80
endstop_pin: !P1.29 # P1.28 for X-max
position_endstop: 0
position_min: 0
position_max: 200
homing_speed: 50
full_steps_per_rotation: 400

[stepper_y]
step_pin: P0.19
dir_pin: !P0.20
enable_pin: !P2.8
microsteps: 16
rotation_distance: 80
endstop_pin: !P1.27 # P1.26 for Y-max
position_endstop: 0
position_min: 0
position_max: 200
homing_speed: 50
full_steps_per_rotation: 400

[stepper_z]
step_pin: P0.22
dir_pin: P2.11
enable_pin: !P0.21
microsteps: 16
rotation_distance: 4
endstop_pin: !P1.25 # P1.24 for Z-max
position_endstop: 0
position_max: 300
full_steps_per_rotation: 400

[stepper_z1]
step_pin: P0.1
dir_pin: P0.0
enable_pin: !P0.10
microsteps: 16
rotation_distance: 4
full_steps_per_rotation: 400
#endstop_pin: P1.24
#position_endstop: 0.5
#position_max: 400
#…

[extruder]
step_pin: P2.13
dir_pin: P0.11
enable_pin: !P2.12
microsteps: 16
rotation_distance: 15.5
nozzle_diameter: 0.400
filament_diameter: 1.750
heater_pin: P2.7
sensor_type: EPCOS 100K B57560G104F
sensor_pin: P0.24
control: pid
pid_Kp: 22.2
pid_Ki: 1.08
pid_Kd: 114
min_temp: 0
max_temp: 260
full_steps_per_rotation: 400
max_extrude_only_distance: 50

[heater_bed]
heater_pin: P2.5
sensor_type: ATC Semitec 104GT-2
sensor_pin: P0.23
control: watermark
min_temp: 0
max_temp: 130

[fan]
pin: P2.3

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

[printer]
kinematics: cartesian
max_velocity: 200
max_accel: 2000
max_z_velocity: 25
max_z_accel: 100

########################################

TMC2208 configuration

########################################

For TMC2208 UART

1) Remove all of the jumpers below the stepper drivers

2) Place jumpers on the red pin headers labeled XUART (XUART, YUART etc.)

[tmc2208 stepper_x]
uart_pin: P1.17
run_current: 0.800
stealthchop_threshold: 999999

[tmc2208 stepper_y]
uart_pin: P1.15
run_current: 0.800
stealthchop_threshold: 999999

[tmc2208 stepper_z]
uart_pin: P1.10
run_current: 0.650
stealthchop_threshold: 999999

[tmc2208 stepper_z1]
uart_pin: P1.1
run_current: 0.650
stealthchop_threshold: 999999

[tmc2208 extruder]
uart_pin: P1.8
run_current: 0.800
stealthchop_threshold: 999999

########################################

TMC2130 configuration

########################################

For TMC SPI

1) Place jumpers on all the red pin headers under the stepper drivers

2) Remove jumpers from the red pin headers labeled XUART (XUART, YUART etc.)

#[tmc2130 stepper_x]
#cs_pin: P1.17
#spi_software_miso_pin: P0.5
#spi_software_mosi_pin: P4.28
#spi_software_sclk_pin: P0.4
##diag1_pin: P1.29
#run_current: 0.800
#stealthchop_threshold: 999999

#[tmc2130 stepper_y]
#cs_pin: P1.15
#spi_software_miso_pin: P0.5
#spi_software_mosi_pin: P4.28
#spi_software_sclk_pin: P0.4
##diag1_pin: P1.27
#run_current: 0.800
#stealthchop_threshold: 999999

#[tmc2130 stepper_z]
#cs_pin: P1.10
#spi_software_miso_pin: P0.5
#spi_software_mosi_pin: P4.28
#spi_software_sclk_pin: P0.4
##diag1_pin: P1.25
#run_current: 0.650
#stealthchop_threshold: 999999

#[tmc2130 extruder]
#cs_pin: P1.8
#spi_software_miso_pin: P0.5
#spi_software_mosi_pin: P4.28
#spi_software_sclk_pin: P0.4
##diag1_pin: P1.28
#run_current: 0.800
#stealthchop_threshold: 999999

#[tmc2130 extruder1]
#cs_pin: P1.1
#spi_software_miso_pin: P0.5
#spi_software_mosi_pin: P4.28
#spi_software_sclk_pin: P0.4
##diag1_pin: P1.26
#run_current: 0.800
#stealthchop_threshold: 999999

########################################

EXP1 / EXP2 (display) pins

########################################

[board_pins]
aliases:
# EXP1 header
EXP1_1=P1.30, EXP1_3=P1.18, EXP1_5=P1.20, EXP1_7=P1.22, EXP1_9=,
EXP1_2=P0.28, EXP1_4=P1.19, EXP1_6=P1.21, EXP1_8=P1.23, EXP1_10=<5V>,
# EXP2 header
EXP2_1=P0.17, EXP2_3=P3.26, EXP2_5=P3.25, EXP2_7=P1.31, EXP2_9=,
EXP2_2=P0.15, EXP2_4=P0.16, EXP2_6=P0.18, EXP2_8=, EXP2_10=
# Pins EXP2_1, EXP2_6, EXP2_2 are also MISO, MOSI, SCK of bus “ssp0”

See the sample-lcd.cfg file for definitions of common LCD displays.

Klipper does limit z velocity. F200 is only 3.33mm/s, so it’s not surprising that it works. You simply need to further reduce max_z_velocity to 10 or 15.

That solved it, thanks a lot.
But this problem brought me another question. Since this problem was occurring after the z homing, and it skipped a lot of steps going up, when it came down would ignore the endstop and crash horrible into the build plate. I don’t have any homing sensor, just a old fashion switch, is there any way to insure that the hot end never goes below the endstop?

Klipper only monitors endstops during homing, so the only way to prevent this is to make sure the motor doesn’t skip steps. As long as you use a max_z_velocity that doesn’t skip steps you shouldn’t have this problem.

Thanks again, you saved me a lot of time.