Z Offset. Im going CRAZY!

Basic Information:

Printer Model: Ender 3v2
MCU / Printerboard: 4.2.2
Host / SBC: Pi 4
klippy.log (3.7 MB)

klippy.log

Describe your issue:

Hey guys, noob here

For the life of me I cant fiqure out what Im doing wrong. Ive read the Docs, guides, watched videos. It just doesnt play ball.

I have run the PROBE_CALIBRATE command (BLTOUCH) and dialed the head down using paper as my gauge. Accept the prompt and save the config. It restarts and I get

Klipper reports: ERROR

Option ‘z_offset’ in section ‘bltouch’ must be specified

Once the underlying issue is corrected, use the “RESTART”
command to reload the config and restart the host software.
Printer is halted.

The few times I have thought I got it correct the print starts with the head way to high.

Can someone please explain to me like Im a child what I am doing wrong?

Hello @IamDan !

How do you save the config?

Save_config in the console

I’m just a bit confused:
Sometimes you have y_offset in [bltouch], sometimes not. Do you delete it?

I’ve never touched the y offset. I’m starting to think I should have stayed with marlin :person_facepalming:

Should I delete the printer.cfg and start again?

Sorry, I meant z_offset.

Yes, I did delete it and replace it. Im basically clutching at straws and trying combinations of everything. Should the values at the bottom of my config (probe_calibrate results) be copied into the z_offset position? Do I leave z_offset at 0?

When you calibrate the probe and the z_offset, you should not do anything with the values in the config.
Klipper stores the actual value in an area below the config lines.

#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
...
...
#*#
#*# [bltouch]
#*# z_offset = 1.740
#*#
...
...

The problem is that after a PROBE_CALIBRATE it will comment out the bltouch z_offset, add its own value at the bottom and then proceed to complain that there is no z_offset value

Can you upload the complete

#*# <---------------------- SAVE_CONFIG ---------------------->

block?

#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
#*# [bed_mesh 60 Deg C]
#*# version = 1
#*# points =
#*# 	  0.240000, 0.055000, 0.022500, 0.047500, 0.102500
#*# 	  0.232500, 0.075000, 0.062500, 0.100000, 0.162500
#*# 	  0.187500, 0.042500, 0.042500, 0.077500, 0.135000
#*# 	  0.217500, 0.060000, 0.042500, 0.047500, 0.065000
#*# 	  0.187500, 0.050000, 0.047500, 0.060000, 0.090000
#*# x_count = 5
#*# y_count = 5
#*# mesh_x_pps = 2
#*# mesh_y_pps = 2
#*# algo = bicubic
#*# tension = 0.2
#*# min_x = 15.0
#*# max_x = 188.0
#*# min_y = 15.0
#*# max_y = 191.0


# Client variable macro for your printer.cfg
#[gcode_macro _CLIENT_VARIABLE]
#variable_use_custom_pos   : False ; use custom park coordinates for x,y [True/False]
#variable_custom_park_x    : 0.0   ; custom x position; value must be within your defined min and max of X
#variable_custom_park_y    : 0.0   ; custom y position; value must be within your defined min and max of Y
#variable_custom_park_dz   : 2.0   ; custom dz value; the value in mm to lift the nozzle when move to park position
#variable_retract          : 1.0   ; the value to retract while PAUSE
#variable_cancel_retract   : 5.0   ; the value to retract while CANCEL_PRINT
#variable_speed_retract    : 35.0  ; retract speed in mm/s
#variable_unretract        : 1.0   ; the value to unretract while RESUME
#variable_speed_unretract  : 35.0  ; unretract speed in mm/s
#variable_speed_hop        : 15.0  ; z move speed in mm/s
#variable_speed_move       : 100.0 ; move speed in mm/s
#variable_park_at_cancel   : False ; allow to move the toolhead to park while execute CANCEL_PRINT [True/False]
#variable_park_at_cancel_x : None  ; different park position during CANCEL_PRINT [None/Position as Float]; park_at_cancel must be True
#variable_park_at_cancel_y : None  ; different park position during CANCEL_PRINT [None/Position as Float]; park_at_cancel must be True
## !!! Caution [firmware_retraction] must be defined in the printer.cfg if you set use_fw_retract: True !!!
#variable_use_fw_retract   : False ; use fw_retraction instead of the manual version [True/False]
#variable_idle_timeout     : 0     ; time in sec until idle_timeout kicks in. Value 0 means that no value will be set or restored
#variable_runout_sensor    : ""    ; If a sensor is defined, it will be used to cancel the execution of RESUME in case no filament is detected.
##                                   Specify the config name of the runout sensor e.g "filament_switch_sensor runout". Hint use the same as in your printer.cfg
## !!! Custom macros, please use with care and review the section of the corresponding macro.
## These macros are for simple operations like setting a status LED. Please make sure your macro does not interfere with the basic macro functions.
## Only  single line commands are supported, please create a macro if you need more than one command.
#variable_user_pause_macro : ""    ; Everything inside the "" will be executed after the klipper base pause (PAUSE_BASE) function
#variable_user_resume_macro: ""    ; Everything inside the "" will be executed before the klipper base resume (RESUME_BASE) function
#variable_user_cancel_macro: ""    ; Everything inside the "" will be executed before the klipper base cancel (CANCEL_PRINT_BASE) function
#gcode:


[gcode_macro START_PRINT]
gcode:
    {% set BED_TEMP = params.BED_TEMP|default(60)|float %}
    {% set EXTRUDER_TEMP = params.EXTRUDER_TEMP|default(190)|float %}
    # Start bed heating
    M140 S{BED_TEMP}
    # Use absolute coordinates
    G90
    # Reset the G-Code Z offset (adjust Z offset if needed)
    SET_GCODE_OFFSET Z=0.0
    # Home the printer
    G28
    # Move the nozzle near the bed
    G1 Z5 F3000
    # Move the nozzle very close to the bed
    G1 Z0.15 F300
    # Wait for bed to reach temperature
    M190 S{BED_TEMP}
    # Set and wait for nozzle to reach temperature
    M109 S{EXTRUDER_TEMP}

[gcode_macro END_PRINT]
gcode:
    # Turn off bed, extruder, and fan
    M140 S0
    M104 S0
    M106 S0
    # Move nozzle away from print while retracting
    G91
    G1 X-2 Y-2 E-3 F300
    # Raise nozzle by 10mm
    G1 Z10 F3000
    G90
    # Disable steppers
    M84

#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
#*# [heater_bed]
#*# control = pid
#*# pid_kp = 69.463
#*# pid_ki = 1.209
#*# pid_kd = 997.664

#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*# [bltouch]
#*# z_offset = 2.500

Is it normal that if I run PROBE_CALIBRATE again that it will add a new block while keeping the old?

Issue is, you have multiple

#*# <---------------------- SAVE_CONFIG ---------------------->

blocks.

Only the first one is valid.
Also you have config code after the first

#*# <---------------------- SAVE_CONFIG ---------------------->

block. That’s not proper too.

Delete all lines that start with #*# - only those - and add this at the very end:

#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
#*# [bed_mesh 60 Deg C]
#*# version = 1
#*# points =
#*# 	  0.240000, 0.055000, 0.022500, 0.047500, 0.102500
#*# 	  0.232500, 0.075000, 0.062500, 0.100000, 0.162500
#*# 	  0.187500, 0.042500, 0.042500, 0.077500, 0.135000
#*# 	  0.217500, 0.060000, 0.042500, 0.047500, 0.065000
#*# 	  0.187500, 0.050000, 0.047500, 0.060000, 0.090000
#*# x_count = 5
#*# y_count = 5
#*# mesh_x_pps = 2
#*# mesh_y_pps = 2
#*# algo = bicubic
#*# tension = 0.2
#*# min_x = 15.0
#*# max_x = 188.0
#*# min_y = 15.0
#*# max_y = 191.0
#*#
#*# [heater_bed]
#*# control = pid
#*# pid_kp = 69.463
#*# pid_ki = 1.209
#*# pid_kd = 997.664
#*#
#*# [bltouch]
#*# z_offset = 2.500
1 Like

Thankyou! that appears to have cleared the error. Unfortunatly I start work in an hour and woont be able to test it for another 9 or so hours

1 Like

Have fun at work - take care.

Fun and work? HAHA

Thanks again I really do appreciate all your help

I just want to say thanks agin for your help. The first layers are going down nicely

1 Like

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