SCREWS_TILT_CALCULATE

SCREWS_TILT_CALCULATE [DIRECTION=CW|CCW] [MAX_DEVIATION=<value>] [HORIZONTAL_MOVE_Z=<value>] [<probe_parameter>=<value>]

Invokes the Klipper native bed screws adjustment tool. It will command the nozzle to different locations (as defined by the [SCREWS_TILT_ADJUST] stanza in printer.cfg) probing the z height and calculate the number of knob turns to adjust the bed level.

When SCREWS_TILT_CALCULATE is used with the MAX_DEVIATION parameter it can be used to test ahead of printing that the bed is level to within the specified maximum deviation. The command will raise a gcode error if any difference in the screw height relative to the base screw height is greater than the value provided.

IMPORTANT: You MUST always do a G28 before using this command.

[SCREWS TILT ADJUST]

SCREWS_TILT_CALCULATE makes use of configuration stanza in printer.cfg to define the positions on the bed screw. These positions are measured from the probe position NOT the nozzle position. The z probe which is in the rear left corner of the print head should be over top the bed screw position when measured.

Below is an example for the Neptune 4 (standard)

[screws_tilt_adjust]
screw1_name: rear left screw
screw1: 55,180
screw2_name: rear right screw
screw2: 225,180
screw3_name: front right screw
screw3: 225,10
screw4_name: front left screw
screw4: 55,10
horizontal_move_z: 10
speed: 200
screw_thread: CW-M4 # Use CW for Clockwise and CCW for Counter Clockwise

See the Klipper docs for more.