bigtreetech / bigtreetech/MicroProbe

SKR Pico and Microprobe Not Working

Open
#26 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
No language data
Stars
122
Forks
20
PR merge metrics
No merged PRs in 30d

Description

As described in other issues, I am having trouble getting the BTT Microprobe to work with the Pico. I have everything wired up correctly using the servos and probe ports on the board, have removed the jumped for sensorless z homing, and have made sure to add what I thought were the necessary values in to my printer.cfg and btt_microprobe.cfg files.

However, every time I try to run a home or a calibrate probe, it will deploy the probe and the bed will just continue going up crashing in to the nozzle.

probe_stow and probe_deploy both seem to work.

I'm at my wits end here honestly. I have tried 2 separate probes that I purchased to rule out the chance of me getting a dud probe or wiring it incorrectly and damaging it myself.

If anyone is able to help me out I would be super appreciative.

Here is my printer.cfg as it is right now.

`[include fluidd.cfg]
[virtual_sdcard]
[include btt_microprobe.cfg]
#path: /home/klipper/printer_data/gcodes
#on_error_gcode: CANCEL_PRINT

#####################################################################
# General Settings
#####################################################################

[mcu]
serial: /dev/ttyAMA0
restart_method: command

[printer]
kinematics: corexy
max_velocity: 1000
max_accel: 160000
max_z_velocity: 50
max_z_accel: 1000
max_accel_to_decel: 100000
square_corner_velocity: 18.0

[force_move]
enable_force_move: true

[respond]
default_type: echo
default_prefix:

#####################################################################
# X/Y/Z Stepper Settings
#####################################################################

[stepper_x]
step_pin: gpio11
dir_pin: gpio10
enable_pin: !gpio12
rotation_distance: 40
microsteps: 16
endstop_pin: tmc2209_stepper_x:virtual_endstop
position_min: -1
position_endstop: -1
position_max: 157
homing_speed: 50
homing_retract_dist: 0

[tmc2209 stepper_x]
uart_pin: gpio9
tx_pin: gpio8
uart_address: 0
run_current: 1.0
stealthchop_threshold: 0
diag_pin: ^gpio4
driver_SGTHRS: 90
interpolate: true

[stepper_y]
step_pin: gpio6
dir_pin: gpio5
enable_pin: !gpio7
microsteps: 16
rotation_distance: 40
#endstop_pin: ^gpio3
endstop_pin: tmc2209_stepper_y:virtual_endstop
homing_retract_dist: 0
position_min: 0
position_endstop: 174
position_max: 174
homing_speed: 50
homing_positive_dir: true

[tmc2209 stepper_y]
uart_pin: gpio9
tx_pin: gpio8
uart_address: 2
run_current: 1.0
stealthchop_threshold: 0
diag_pin: ^gpio3
driver_SGTHRS: 90
interpolate: true

[stepper_z]
step_pin: gpio19
dir_pin: gpio28
enable_pin: !gpio2
microsteps: 32
rotation_distance: 2
#endstop_pin: ^!gpio29
#position_endstop: -4.3
# endstop_pin: tmc2209_stepper_z:virtual_endstop ##### for using sensorless Z homing against the bed hitting the top frame
endstop_pin: probe:z_virtual_endstop ###### for using the BTT Microprobe for Z homing
position_min: -6
position_max: 156
homing_speed: 4

[tmc2209 stepper_z]
uart_pin: gpio9
tx_pin: gpio8
uart_address: 1
run_current: 0.8
#diag_pin: ^gpio25
#driver_SGTHRS: 105
stealthchop_threshold: 999999

#####################################################################
# Extruder Settings
#####################################################################

[extruder]
step_pin: gpio14
dir_pin: !gpio13
enable_pin: !gpio15
microsteps: 16
rotation_distance: 23.153
gear_ratio: 50:17
#gear_ratio: 80:20
full_steps_per_rotation: 200
nozzle_diameter: 0.4
filament_diameter: 1.75
heater_pin: gpio23
#sensor_type: EPCOS 100K B57560G104F
sensor_type: ATC Semitec 104NT-4-R025H42G
sensor_pin: gpio27
#control: pid
#pid_Kp: 22.2
#pid_Ki: 1.08
#pid_Kd: 114
min_temp: 0
max_temp: 300
max_extrude_cross_section:2
pressure_advance: 0.4
pressure_advance_smooth_time: 0.060
max_extrude_only_distance: 500
max_extrude_only_velocity: 240
max_extrude_only_accel: 4000
instantaneous_corner_velocity: 20

[tmc2209 extruder]
uart_pin: gpio9
tx_pin: gpio8
uart_address: 3
run_current: 1.0
stealthchop_threshold: 0

#####################################################################
# Bed Settings
#####################################################################

[heater_bed]
heater_pin: gpio21
sensor_type: EPCOS 100K B57560G104F
sensor_pin: gpio26
#control: pid
#pid_Kp: 54.027
#pid_Ki: 0.770
#pid_Kd: 948.182
min_temp: 0
max_temp: 130

[bed_screws]
screw1: 33, 25
screw2: 128, 25
screw3: 33, 135
screw4: 128, 135

[bed_mesh]
speed: 120
horizontal_move_z: 3
mesh_min: 10, 10
mesh_max: 150,150
probe_count: 5,5
fade_start: 1
fade_end: 10
fade_target: 0
algorithm: bicubic

#####################################################################
# Cooling Settings
#####################################################################

[multi_pin part_cooling]
pins: gpio17, gpio18

[fan]
pin: multi_pin:part_cooling

[heater_fan hotend_fan]
pin: gpio20
heater: extruder
heater_temp: 50.0

#####################################################################
# Sensor Settings
#####################################################################

[temperature_sensor skr_pico]
sensor_type: temperature_mcu
min_temp: 0
max_temp: 100

[temperature_sensor banana_pi]
sensor_type: temperature_host
min_temp: 10
max_temp: 100

#[mcu PIS]
#serial: /dev/serial/by-id/usb-Klipper_rp2040_E66160F4238C3D38-if00
#[mcu USB-ADXL345]
#serial: /dev/serial/by-id/usb-Klipper_stm32f103xe_37FFDA054B48373254491943-if00

#[adxl345]
#cs_pin: USB-ADXL345:PA4
#spi_bus:spi1

#[adxl345]
#cs_pin: PIS:gpio13
#spi_software_sclk_pin: PIS:gpio10
#spi_software_mosi_pin: PIS:gpio11
#spi_software_miso_pin: PIS:gpio12
#axes_map: x,-z,y

#[resonance_tester]
#accel_chip: adxl345
#probe_points:
# 75,75,20 # an example

#[filament_switch_sensor runout_sensor]
#switch_pin: ^gpio16
#pause_on_runout: True

# [filament_motion_sensor smart_sensor]
# switch_pin: ^gpio16
# detection_length: 2.5

[probe] # this must be in the printer.cfg to ensure "SAVE CONFIG" works. The auto-generated values can only be sent to the printer.cfg and not other .cfg files
pin: ^!gpio22
deactivate_on_each_sample: False # true for probing without retracting probe after every contact (this is faster). Must also uncomment next line when changing this to FALSE
# probe_with_touch_mode: true # uncomment this line if changing "deactivate_on_each_sample: " to TRUE
# stow_on_each_sample: false # change this to TRUE and uncomment if setting "deactivate_on_each_sample: " to TRUE
x_offset: 0.0
y_offset: 50.75
z_offset: 1.010 # this needs to be uncommented for the first calibration
speed: 4 # THIS IS THE Z SPEED WHILE PROBING
lift_speed: 30 # THIS IS THE Z SPEED AFTER PROBING
samples_tolerance: 0.01
activate_gcode:
Probe_Deploy
G4 P500
deactivate_gcode:
Probe_Stow

#####################################################################
# Macros
#####################################################################

[gcode_macro START_PRINT]
gcode:
{% set BED_TEMP = params.BED|default(60)|int %}
{% set EXTRUDER_TEMP = params.HOTEND|default(220)|int %}
CLEAR_PAUSE

{% if printer.heater_bed.temperature < (BED_TEMP-10) %}
M140 S{BED_TEMP-10}
{% endif %}

G90 ; use absolute coordinates
G92 E0 ; reset extruder

{% if "xyz" not in printer.toolhead.homed_axes %}
G28 ; home all axis
{% endif %}
G1 ; set units to millimeters

{% if printer.heater_bed.temperature < (BED_TEMP-10) %}
M190 S{BED_TEMP-10}
{% endif %}

M104 S{EXTRUDER_TEMP}
M190 S{BED_TEMP}
M109 S{EXTRUDER_TEMP}
DRAW_LINE SPEED=1800
G1 E-2 F900

[gcode_macro CANCEL_PRINT]
rename_existing: BASE_CANCEL_PRINT
gcode:
M220 S100 ; Reset Speed factor override percentage to default (100%)
M221 S100 ; Reset Extrude factor override percentage to default (100%)
G91 ; Set coordinates to relative
{% if printer.extruder.temperature >= 170 %}
G1 F1800 E-1 ; Retract filament 3 mm to prevent oozing
{% endif %}
;if all axis are homed, lift the hotend to leave room for hot filament to ooze and to keep it clear of the bed.
{% if printer.toolhead.homed_axes == "xyz" %}
G1 F1200 Z20 ; Move Z Axis up 10 mm to allow filament ooze freely
G90 ; Set coordinates to absolute
G1 X{ printer.toolhead.axis_minimum.x +10 } Y{ printer.toolhead.axis_maximum.y - 20 } F3600 ; Move Printer Head Out of Way
; M84 ; Disable stepper motors - don't so the gantry stays aligned
{% endif %}
;set part fan speed to zero.
M106 S0
M104 S{printer.extruder.temperature-20}
;bed and hotend are left at the print temps in case I want to restart.
CLEAR_PAUSE
BASE_CANCEL_PRINT

[gcode_macro END_PRINT]
gcode:

# Move nozzle away from print while retracting
G91 ;releative positioning
G1 E-2 F2700 ;Retract a bit
G1 E-2 Z0.2 F2400 ;Retract and raise Z
G1 X-3 Y-3 F3000 ;Wipe out
G1 Z10 F1800 ;Raise Z more

# Turn off bed, extruder, and fan
M140 S0
M104 S0
M106 S0

G90 ; Absolute Positioning
G1 X{ printer.toolhead.axis_minimum.x +10 } Y{ printer.toolhead.axis_maximum.y - 20 } F3600 ; Move Printer Head Out of Way

M84 X Y E ;Disable all steppers but Z

[gcode_macro DRAW_LINE]
gcode:
{% set SPEED = params.SPEED|default(900)|int %}
G92 E0 ;Reset Extruder
G1 Z2.0 F1800 ;Move Z Axis up
G1 X5.1 Y40 Z0.3 F5000 ;Move to start position
G1 X5.1 Y140.0 Z0.3 F{SPEED} E15 ;Draw the first line
G1 X5.4 Y140.0 Z0.3 F{SPEED} ;Move to side a little
G1 X5.4 Y40 Z0.3 F{SPEED}.0 E30 ;Draw the second line
G92 E0 ;Reset Extruder
G1 Z2.0 F3000 ;Move Z Axis up
G4 P2000

[gcode_macro WAIT_FOR_BED_TEMP]
gcode:
#Parameters
{% set s = params.S|float %}

{% if (s-20) > 0 %}
TEMPERATURE_WAIT SENSOR=heater_bed MINIMUM={s-20} MAXIMUM={s+1} ; Wait for bed temp (within 1 degree)
{% endif %}

[gcode_macro M109]
rename_existing: M99109
gcode:
#Parameters
{% set s = params.S|float %}

M104 {% for p in params %}{'%s%s' % (p, params[p])}{% endfor %} ; Set hotend temp
{% if s > 0 %}
TEMPERATURE_WAIT SENSOR=extruder MINIMUM={s-2} MAXIMUM={s+3} ; Wait for hotend temp (within 3 degree)
{% endif %}

[gcode_macro M190]
rename_existing: M99190
gcode:
#Parameters
{% set s = params.S|float %}

M140 {% for p in params %}{'%s%s' % (p, params[p])}{% endfor %} ; Set bed temp
{% if s > 0 %}
TEMPERATURE_WAIT SENSOR=heater_bed MINIMUM={s-2} MAXIMUM={s+3} ; Wait for bed temp (within 3 degree)
{% endif %}

[gcode_macro G28]
rename_existing: G280
gcode:
M80
SET_KINEMATIC_POSITION Z=0
G90
G1 Z3 F1200
SENSORLESS_HOME_X
SENSORLESS_HOME_Y
SENSORLESS_HOME_Z

[gcode_macro SENSORLESS_HOME_X]
gcode:
SENSORLESS_DELAY
# Home
G280 X
# Move away
G1 X{ printer.toolhead.axis_maximum.x/2 } F6000

[gcode_macro SENSORLESS_HOME_Y]
gcode:
SENSORLESS_DELAY
# Home
G280 Y
# Move away
G90
G1 Y{ printer.toolhead.axis_maximum.y/2 } F6000

[gcode_macro SENSORLESS_HOME_Z]
gcode:
G1 X75 Y24 F6000
SENSORLESS_DELAY
G280 Z
G1 Z12 F300 # Make sure we clear the toolhead
G1 X{ printer.toolhead.axis_minimum.x +5 } Y{ printer.toolhead.axis_maximum.y -25 } F6000

[gcode_macro SENSORLESS_DELAY]
gcode:
# Pause to ensure driver stall flag is clear
G4 P2000

[gcode_macro M80]
gcode:
SET_STEPPER_ENABLE STEPPER=stepper_x ENABLE=1
SET_STEPPER_ENABLE STEPPER=stepper_y ENABLE=1
SET_STEPPER_ENABLE STEPPER=stepper_z ENABLE=1

[gcode_macro MECHANICAL_GANTRY_CALIBRATION]
gcode:
G28
BED_MESH_CALIBRATE

[gcode_macro BED_PROBE]
gcode:
G28 ; todo query for homed
G90 ; absolute

G0 Z5 F720
G0 X30 Y40 F6000
PROBE

G0 Z5 F720
G0 X149 Y40 F6000
PROBE

G0 Z5 F720
G0 X30 Y139 F6000
PROBE

G0 Z5 F720
G0 X149 Y139 F6000
PROBE

[gcode_macro BED_PROBE_X]
gcode:
G90 ; absolute

G0 Z5 F720
G0 X30 Y25 F6000
PROBE

G0 Z5 F720
G0 X170 Y25 F6000
PROBE

G0 Z5 F720
G0 X30 Y165 F6000
PROBE

G0 Z5 F720
G0 X170 Y165 F6000
PROBE

# Home, get position, throw around toolhead, home again.
# If MCU stepper positions (first line in GET_POSITION) are greater than a full step different (your number of microsteps), then skipping occured.
# We only measure to a full step to accomodate for endstop variance.
# Example: TEST_SPEED SPEED=300 ACCEL=5000 ITERATIONS=10

[gcode_macro TEST_SPEED]
gcode:
# Speed
{% set speed = params.SPEED|default(printer.configfile.settings.printer.max_velocity)|int %}
# Iterations
{% set iterations = params.ITERATIONS|default(5)|int %}
# Acceleration
{% set accel = params.ACCEL|default(printer.configfile.settings.printer.max_accel)|int %}
# Bounding inset for large pattern (helps prevent slamming the toolhead into the sides after small skips, and helps to account for machines with imperfectly set dimensions)
{% set bound = params.BOUND|default(20)|int %}
# Size for small pattern box
{% set smallpatternsize = SMALLPATTERNSIZE|default(20)|int %}

# Large pattern
# Max positions, inset by BOUND
{% set x_min = printer.toolhead.axis_minimum.x + bound %}
{% set x_max = printer.toolhead.axis_maximum.x - bound %}
{% set y_min = printer.toolhead.axis_minimum.y + bound %}
{% set y_max = printer.toolhead.axis_maximum.y - bound %}

# Small pattern at center
# Find X/Y center point
{% set x_center = (printer.toolhead.axis_minimum.x|float + printer.toolhead.axis_maximum.x|float ) / 2 %}
{% set y_center = (printer.toolhead.axis_minimum.y|float + printer.toolhead.axis_maximum.y|float ) / 2 %}

# Set small pattern box around center point
{% set x_center_min = x_center - (smallpatternsize/2) %}
{% set x_center_max = x_center + (smallpatternsize/2) %}
{% set y_center_min = y_center - (smallpatternsize/2) %}
{% set y_center_max = y_center + (smallpatternsize/2) %}

# Save current gcode state (absolute/relative, etc)
SAVE_GCODE_STATE NAME=TEST_SPEED

# Output parameters to g-code terminal
{ action_respond_info("TEST_SPEED: starting %d iterations at speed %d, accel %d" % (iterations, speed, accel)) }

# Home and get position for comparison later:
G28
# QGL if not already QGLd (only if QGL section exists in config)
{% if printer.configfile.settings.quad_gantry_level %}
{% if printer.quad_gantry_level.applied == False %}
QUAD_GANTRY_LEVEL
G28 Z
{% endif %}
{% endif %}
# Move 50mm away from max position and home again (to help with hall effect endstop accuracy - https://github.com/AndrewEllis93/Print-Tuning-Guide/issues/24)
G90
G1 X{printer.toolhead.axis_maximum.x-50} Y{printer.toolhead.axis_maximum.y-50} F{30*60}
G28 X Y
G0 X{printer.toolhead.axis_maximum.x-1} Y{printer.toolhead.axis_maximum.y-1} F{30*60}
G4 P1000
GET_POSITION

# Go to starting position
G0 X{x_min} Y{y_min} Z10 F{speed*60}

# Set new limits
SET_VELOCITY_LIMIT VELOCITY={speed} ACCEL={accel} ACCEL_TO_DECEL={accel / 2}

{% for i in range(iterations) %}
# Large pattern
# Diagonals
G0 X{x_min} Y{y_min} F{speed*60}
G0 X{x_max} Y{y_max} F{speed*60}
G0 X{x_min} Y{y_min} F{speed*60}
G0 X{x_max} Y{y_min} F{speed*60}
G0 X{x_min} Y{y_max} F{speed*60}
G0 X{x_max} Y{y_min} F{speed*60}

# Box
G0 X{x_min} Y{y_min} F{speed*60}
G0 X{x_min} Y{y_max} F{speed*60}
G0 X{x_max} Y{y_max} F{speed*60}
G0 X{x_max} Y{y_min} F{speed*60}

# Small pattern
# Small diagonals
G0 X{x_center_min} Y{y_center_min} F{speed*60}
G0 X{x_center_max} Y{y_center_max} F{speed*60}
G0 X{x_center_min} Y{y_center_min} F{speed*60}
G0 X{x_center_max} Y{y_center_min} F{speed*60}
G0 X{x_center_min} Y{y_center_max} F{speed*60}
G0 X{x_center_max} Y{y_center_min} F{speed*60}

# Small box
G0 X{x_center_min} Y{y_center_min} F{speed*60}
G0 X{x_center_min} Y{y_center_max} F{speed*60}
G0 X{x_center_max} Y{y_center_max} F{speed*60}
G0 X{x_center_max} Y{y_center_min} F{speed*60}
{% endfor %}

# Restore max speed/accel/accel_to_decel to their configured values
SET_VELOCITY_LIMIT VELOCITY={printer.configfile.settings.printer.max_velocity} ACCEL={printer.configfile.settings.printer.max_accel} ACCEL_TO_DECEL={printer.configfile.settings.printer.max_accel_to_decel}

# Re-home and get position again for comparison:
G28
# Go to XY home positions (in case your homing override leaves it elsewhere)
G90
G0 X{printer.toolhead.axis_maximum.x-1} Y{printer.toolhead.axis_maximum.y-1} F{30*60}
G4 P1000
GET_POSITION

# Restore previous gcode state (absolute/relative, etc)
RESTORE_GCODE_STATE NAME=TEST_SPEED

#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
#*# [heater_bed]
#*# control = pid
#*# pid_kp = 68.865
#*# pid_ki = 1.041
#*# pid_kd = 1138.848
#*#
#*# [extruder]
#*# control = pid
#*# pid_kp = 23.449
#*# pid_ki = 2.299
#*# pid_kd = 59.795
#*#
#*# [input_shaper]
#*# shaper_type_x = mzv
#*# shaper_freq_x = 109.8
#*# shaper_type_y = zv
#*# shaper_freq_y = 81.2
#*#
#*# [stepper_z]
#*# position_endstop = 0.925
`

And here is my Microprobe file I have created and included at the beginning of printer.cfg as well.

`# Chinstrap777's BTT Microprobe v2 with "The 100 v1.1" printer and "BTT Microprobe Mount for 'The 100 v1.1' printer (v2.0)"
# Connected to "SERVOS" with the 3-wire connection and "PROBE" with the 2-wire connection on the BTT SKR Pico
# servos=gpio29 (yellow wire)
# probe=probe (white wire)

[output_pin probe_enable]
pin: gpio29
value: 0

[gcode_macro Probe_Deploy]
gcode:
SET_PIN PIN=probe_enable VALUE=1

[gcode_macro Probe_Stow]
gcode:
SET_PIN PIN=probe_enable VALUE=0

[safe_z_home]
home_xy_position: 75, 24 # Change coordinates to the center of your print bed
speed: 100
z_hop: 10 # Move up 10mm
z_hop_speed: 10

[gcode_macro AAA_PROBE_ACCURACY1]
description: CYD_SCREEN_MACRO
gcode:
G90
G1 Z20
G1 X75 Y24 F3000
PROBE_ACCURACY

[gcode_macro AAC_PROBE_CALIBRATE1]
description: CYD_SCREEN_MACRO
gcode:
G90
G0 Z20
G0 X75 Y24 F3000
G0 Z5
PROBE_CALIBRATE SPEED=1000
Z_OFFSET_APPLY_PROBE

[gcode_macro aab_screws_tilt_calculate1]
description: CYD_SCREEN_MACRO
gcode:
G28
SCREWS_TILT_CALCULATE`

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.