=============== Log rollover at Fri Mar 1 08:49:59 2024 =============== Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.11.0-122-ge6ef48cd' CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Start printer at Fri Mar 1 08:50:17 2024 (1709283017.5 37.1) Config error Traceback (most recent call last): File "/home/biqu/klipper/klippy/klippy.py", line 175, in _connect self._read_config() File "/home/biqu/klipper/klippy/klippy.py", line 134, in _read_config config = pconfig.read_main_config() File "/home/biqu/klipper/klippy/configfile.py", line 281, in read_main_config regular_config = self._build_config_wrapper(regular_data, filename) File "/home/biqu/klipper/klippy/configfile.py", line 268, in _build_config_wrapper self._parse_config(data, filename, fileconfig, set()) File "/home/biqu/klipper/klippy/configfile.py", line 256, in _parse_config self._resolve_include(filename, include_spec, fileconfig, File "/home/biqu/klipper/klippy/configfile.py", line 229, in _resolve_include raise error("Include file '%s' does not exist" % (include_glob,)) configparser.Error: Include file '/home/biqu/printer_data/config/generic-bigtreetech-xxx.cfg' does not exist webhooks client 281472853317904: New connection webhooks client 281472853317904: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} webhooks client 281472853317904: Disconnected Restarting printer Start printer at Fri Mar 1 08:51:56 2024 (1709283116.3 123.2) Config error Traceback (most recent call last): File "/home/biqu/klipper/klippy/klippy.py", line 175, in _connect self._read_config() File "/home/biqu/klipper/klippy/klippy.py", line 134, in _read_config config = pconfig.read_main_config() File "/home/biqu/klipper/klippy/configfile.py", line 281, in read_main_config regular_config = self._build_config_wrapper(regular_data, filename) File "/home/biqu/klipper/klippy/configfile.py", line 268, in _build_config_wrapper self._parse_config(data, filename, fileconfig, set()) File "/home/biqu/klipper/klippy/configfile.py", line 256, in _parse_config self._resolve_include(filename, include_spec, fileconfig, File "/home/biqu/klipper/klippy/configfile.py", line 229, in _resolve_include raise error("Include file '%s' does not exist" % (include_glob,)) configparser.Error: Include file '/home/biqu/printer_data/config/generic-bigtreetech-xxx.cfg' does not exist webhooks client 281472853317904: New connection webhooks client 281472853317904: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} webhooks client 281472853317904: Disconnected Restarting printer Start printer at Fri Mar 1 08:53:30 2024 (1709283210.5 217.4) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281472846822032: New connection webhooks client 281472846822032: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' Unable to issue reset command on MCU 'mcu' webhooks client 281472846822032: Disconnected Restarting printer Start printer at Fri Mar 1 08:53:59 2024 (1709283239.0 245.9) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281472846868096: New connection webhooks client 281472846868096: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.11.0-122-ge6ef48cd' CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Start printer at Fri Mar 1 08:50:03 2024 (1709283003.4 23.1) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281473838695520: New connection webhooks client 281473838695520: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' Unable to issue reset command on MCU 'mcu' webhooks client 281473838695520: Disconnected Restarting printer Start printer at Fri Mar 1 08:50:39 2024 (1709283039.6 59.3) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS1 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473840074656: New connection webhooks client 281473840074656: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473840074656: Disconnected Restarting printer Start printer at Fri Mar 1 08:51:03 2024 (1709283063.3 83.0) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS2 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473846177456: New connection webhooks client 281473846177456: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473846177456: Disconnected Restarting printer Start printer at Fri Mar 1 08:57:58 2024 (1709283478.6 92.7) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS2 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473838920992: New connection webhooks client 281473838920992: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473838920992: Disconnected Restarting printer Start printer at Fri Mar 1 08:58:18 2024 (1709283498.6 112.7) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS3 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473846176112: New connection webhooks client 281473846176112: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473846176112: Disconnected Restarting printer Start printer at Fri Mar 1 08:58:32 2024 (1709283512.8 126.8) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS4 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473838267456: New connection webhooks client 281473838267456: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473838267456: Disconnected Restarting printer Start printer at Fri Mar 1 08:58:44 2024 (1709283524.1 138.2) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS5 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473846174000: New connection webhooks client 281473846174000: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.12.0-114-ga77d0790' Branch: master Remote: origin Tracked URL: https://github.com/Klipper3d/klipper CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Building C code module c_helper.so Start printer at Fri Mar 1 08:59:46 2024 (1709283586.5 200.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable':True, 'call':params.MACRO|default("PAUSE")}}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% if params.LAYER is defined %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': True, 'layer':params.LAYER|int, 'call':params.MACRO|default("PAUSE")}}" {% else %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer':0, 'call':"PAUSE"}}" {% endif %} [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = {'enable':False, 'call':"PAUSE"} variable_pause_at_layer = {'enable':False, 'layer':0, 'call':"PAUSE"} gcode = {% if pause_next_layer.enable %} {action_respond_info("%s, forced by pause_next_layer" % pause_next_layer.call)} {pause_next_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{'enable': False, 'call':"PAUSE"}}" {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} {action_respond_info("%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer))} {pause_at_layer.call} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{'enable': False, 'layer': 0, 'call':"PAUSE"}}" {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = False if not macro_found else False if client.use_custom_pos is not defined else True if client.use_custom_pos|lower == 'true' else False %} {% set custom_park_x = 0.0 if not macro_found else client.custom_park_x|default(0.0) %} {% set custom_park_y = 0.0 if not macro_found else client.custom_park_y|default(0.0) %} {% set park_dz = 2.0 if not macro_found else client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = 900 if not macro_found else client.speed_hop|default(15) * 60 %} {% set sp_move = velocity * 60 if not macro_found else client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} {action_respond_info("Printer not homed")} {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set use_fw_retract = False if not macro_found else False if client.use_fw_retract is not defined else True if client.use_fw_retract|lower == 'true' and printer.firmware_retraction is defined else False %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.unretract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_unretract|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.extruder.can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set macro_found = True if printer['gcode_macro _CLIENT_VARIABLE'] is defined else False %} {% set client = printer['gcode_macro _CLIENT_VARIABLE'] %} {% set length = (params.LENGTH|float) if params.LENGTH is defined else 1.0 if not macro_found else client.retract|default(1.0) %} {% set speed = params.SPEED if params.SPEED is defined else 35 if not macro_found else client.speed_retract|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS5 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473678245024: New connection webhooks client 281473678245024: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') MCU error during connect Traceback (most recent call last): File "/home/biqu/klipper/klippy/mcu.py", line 768, in _mcu_identify self._serial.connect_uart(self._serialport, self._baud, rts) File "/home/biqu/klipper/klippy/serialhdl.py", line 182, in connect_uart self._error("Unable to connect") File "/home/biqu/klipper/klippy/serialhdl.py", line 61, in _error raise error(self.warn_prefix + (msg % params)) serialhdl.error: mcu 'mcu': Unable to connect During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/biqu/klipper/klippy/klippy.py", line 176, in _connect self.send_event("klippy:mcu_identify") File "/home/biqu/klipper/klippy/klippy.py", line 263, in send_event return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/klippy.py", line 263, in return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/mcu.py", line 773, in _mcu_identify raise error(str(e)) mcu.error: mcu 'mcu': Unable to connect Build file /home/biqu/klipper/klippy/../.config(3117): Fri Mar 3 11:18:09 2023 ========= Last MCU build config ========= CONFIG_LOW_LEVEL_OPTIONS=y # CONFIG_MACH_AVR is not set # CONFIG_MACH_ATSAM is not set # CONFIG_MACH_ATSAMD is not set # CONFIG_MACH_LPC176X is not set CONFIG_MACH_STM32=y # CONFIG_MACH_HC32F460 is not set # CONFIG_MACH_RP2040 is not set # CONFIG_MACH_PRU is not set # CONFIG_MACH_AR100 is not set # CONFIG_MACH_LINUX is not set # CONFIG_MACH_SIMU is not set CONFIG_BOARD_DIRECTORY="stm32" CONFIG_MCU="stm32g0b1xx" CONFIG_CLOCK_FREQ=64000000 CONFIG_USBSERIAL=y CONFIG_FLASH_SIZE=0x20000 CONFIG_FLASH_BOOT_ADDRESS=0x8000000 CONFIG_RAM_START=0x20000000 CONFIG_RAM_SIZE=0x24000 CONFIG_STACK_SIZE=512 CONFIG_FLASH_APPLICATION_ADDRESS=0x8000000 CONFIG_STM32_SELECT=y # CONFIG_MACH_STM32F103 is not set # CONFIG_MACH_STM32F207 is not set # CONFIG_MACH_STM32F401 is not set # CONFIG_MACH_STM32F405 is not set # CONFIG_MACH_STM32F407 is not set # CONFIG_MACH_STM32F429 is not set # CONFIG_MACH_STM32F446 is not set # CONFIG_MACH_STM32F031 is not set # CONFIG_MACH_STM32F042 is not set # CONFIG_MACH_STM32F070 is not set # CONFIG_MACH_STM32F072 is not set # CONFIG_MACH_STM32G070 is not set # CONFIG_MACH_STM32G071 is not set # CONFIG_MACH_STM32G0B0 is not set CONFIG_MACH_STM32G0B1=y # CONFIG_MACH_STM32G431 is not set # CONFIG_MACH_STM32H723 is not set # CONFIG_MACH_STM32H743 is not set # CONFIG_MACH_STM32H750 is not set # CONFIG_MACH_STM32L412 is not set CONFIG_MACH_STM32G0=y CONFIG_MACH_STM32G0Bx=y CONFIG_HAVE_STM32_USBFS=y CONFIG_HAVE_STM32_FDCANBUS=y CONFIG_HAVE_STM32_USBCANBUS=y CONFIG_STM32_DFU_ROM_ADDRESS=0x1fff0000 # CONFIG_STM32_FLASH_START_2000 is not set CONFIG_STM32_FLASH_START_0000=y CONFIG_STM32_CLOCK_REF_8M=y # CONFIG_STM32_CLOCK_REF_12M is not set # CONFIG_STM32_CLOCK_REF_16M is not set # CONFIG_STM32_CLOCK_REF_20M is not set # CONFIG_STM32_CLOCK_REF_25M is not set # CONFIG_STM32_CLOCK_REF_INTERNAL is not set CONFIG_CLOCK_REF_FREQ=8000000 CONFIG_STM32F0_TRIM=16 CONFIG_STM32_USB_PA11_PA12=y # CONFIG_STM32_SERIAL_USART1 is not set # CONFIG_STM32_SERIAL_USART1_ALT_PB7_PB6 is not set # CONFIG_STM32_SERIAL_USART2 is not set # CONFIG_STM32_SERIAL_USART2_ALT_PD6_PD5 is not set # CONFIG_STM32_SERIAL_USART3 is not set # CONFIG_STM32_SERIAL_USART3_ALT_PD9_PD8 is not set # CONFIG_STM32_CANBUS_PA11_PA12 is not set # CONFIG_STM32_CANBUS_PA11_PB9 is not set # CONFIG_STM32_MMENU_CANBUS_PB8_PB9 is not set # CONFIG_STM32_MMENU_CANBUS_PB12_PB13 is not set # CONFIG_STM32_MMENU_CANBUS_PD0_PD1 is not set # CONFIG_STM32_MMENU_CANBUS_PB0_PB1 is not set # CONFIG_STM32_MMENU_CANBUS_PD12_PD13 is not set # CONFIG_STM32_MMENU_CANBUS_PC2_PC3 is not set # CONFIG_STM32_USBCANBUS_PA11_PA12 is not set CONFIG_USB=y CONFIG_USB_VENDOR_ID=0x1d50 CONFIG_USB_DEVICE_ID=0x614e CONFIG_USB_SERIAL_NUMBER_CHIPID=y CONFIG_USB_SERIAL_NUMBER="12345" # # USB ids # # end of USB ids CONFIG_CANBUS_FREQUENCY=500000 CONFIG_INITIAL_PINS="" CONFIG_HAVE_GPIO=y CONFIG_HAVE_GPIO_ADC=y CONFIG_HAVE_GPIO_SPI=y CONFIG_HAVE_GPIO_I2C=y CONFIG_HAVE_GPIO_HARD_PWM=y CONFIG_HAVE_GPIO_BITBANGING=y CONFIG_HAVE_STRICT_TIMING=y CONFIG_HAVE_CHIPID=y CONFIG_HAVE_STEPPER_BOTH_EDGE=y CONFIG_HAVE_BOOTLOADER_REQUEST=y CONFIG_INLINE_STEPPER_HACK=y ======================= No build file /home/biqu/klipper/klippy/../out/klipper.dict No build file /home/biqu/klipper/klippy/../out/klipper.elf Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.12.0-114-ga77d0790' Branch: master Remote: origin Tracked URL: https://github.com/Klipper3d/klipper CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Start printer at Fri Mar 1 09:01:26 2024 (1709283686.1 300.2) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS5 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473750082944: New connection webhooks client 281473750082944: Client info {'program': 'Moonraker', 'version': 'v0.8.0-23-g18f5ff4'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473750082944: Disconnected mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473758040608: New connection webhooks client 281473758040608: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') MCU error during connect Traceback (most recent call last): File "/home/biqu/klipper/klippy/mcu.py", line 768, in _mcu_identify self._serial.connect_uart(self._serialport, self._baud, rts) File "/home/biqu/klipper/klippy/serialhdl.py", line 182, in connect_uart self._error("Unable to connect") File "/home/biqu/klipper/klippy/serialhdl.py", line 61, in _error raise error(self.warn_prefix + (msg % params)) serialhdl.error: mcu 'mcu': Unable to connect During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/biqu/klipper/klippy/klippy.py", line 176, in _connect self.send_event("klippy:mcu_identify") File "/home/biqu/klipper/klippy/klippy.py", line 263, in send_event return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/klippy.py", line 263, in return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/mcu.py", line 773, in _mcu_identify raise error(str(e)) mcu.error: mcu 'mcu': Unable to connect Build file /home/biqu/klipper/klippy/../.config(3117): Fri Mar 3 11:18:09 2023 ========= Last MCU build config ========= CONFIG_LOW_LEVEL_OPTIONS=y # CONFIG_MACH_AVR is not set # CONFIG_MACH_ATSAM is not set # CONFIG_MACH_ATSAMD is not set # CONFIG_MACH_LPC176X is not set CONFIG_MACH_STM32=y # CONFIG_MACH_HC32F460 is not set # CONFIG_MACH_RP2040 is not set # CONFIG_MACH_PRU is not set # CONFIG_MACH_AR100 is not set # CONFIG_MACH_LINUX is not set # CONFIG_MACH_SIMU is not set CONFIG_BOARD_DIRECTORY="stm32" CONFIG_MCU="stm32g0b1xx" CONFIG_CLOCK_FREQ=64000000 CONFIG_USBSERIAL=y CONFIG_FLASH_SIZE=0x20000 CONFIG_FLASH_BOOT_ADDRESS=0x8000000 CONFIG_RAM_START=0x20000000 CONFIG_RAM_SIZE=0x24000 CONFIG_STACK_SIZE=512 CONFIG_FLASH_APPLICATION_ADDRESS=0x8000000 CONFIG_STM32_SELECT=y # CONFIG_MACH_STM32F103 is not set # CONFIG_MACH_STM32F207 is not set # CONFIG_MACH_STM32F401 is not set # CONFIG_MACH_STM32F405 is not set # CONFIG_MACH_STM32F407 is not set # CONFIG_MACH_STM32F429 is not set # CONFIG_MACH_STM32F446 is not set # CONFIG_MACH_STM32F031 is not set # CONFIG_MACH_STM32F042 is not set # CONFIG_MACH_STM32F070 is not set # CONFIG_MACH_STM32F072 is not set # CONFIG_MACH_STM32G070 is not set # CONFIG_MACH_STM32G071 is not set # CONFIG_MACH_STM32G0B0 is not set CONFIG_MACH_STM32G0B1=y # CONFIG_MACH_STM32G431 is not set # CONFIG_MACH_STM32H723 is not set # CONFIG_MACH_STM32H743 is not set # CONFIG_MACH_STM32H750 is not set # CONFIG_MACH_STM32L412 is not set CONFIG_MACH_STM32G0=y CONFIG_MACH_STM32G0Bx=y CONFIG_HAVE_STM32_USBFS=y CONFIG_HAVE_STM32_FDCANBUS=y CONFIG_HAVE_STM32_USBCANBUS=y CONFIG_STM32_DFU_ROM_ADDRESS=0x1fff0000 # CONFIG_STM32_FLASH_START_2000 is not set CONFIG_STM32_FLASH_START_0000=y CONFIG_STM32_CLOCK_REF_8M=y # CONFIG_STM32_CLOCK_REF_12M is not set # CONFIG_STM32_CLOCK_REF_16M is not set # CONFIG_STM32_CLOCK_REF_20M is not set # CONFIG_STM32_CLOCK_REF_25M is not set # CONFIG_STM32_CLOCK_REF_INTERNAL is not set CONFIG_CLOCK_REF_FREQ=8000000 CONFIG_STM32F0_TRIM=16 CONFIG_STM32_USB_PA11_PA12=y # CONFIG_STM32_SERIAL_USART1 is not set # CONFIG_STM32_SERIAL_USART1_ALT_PB7_PB6 is not set # CONFIG_STM32_SERIAL_USART2 is not set # CONFIG_STM32_SERIAL_USART2_ALT_PD6_PD5 is not set # CONFIG_STM32_SERIAL_USART3 is not set # CONFIG_STM32_SERIAL_USART3_ALT_PD9_PD8 is not set # CONFIG_STM32_CANBUS_PA11_PA12 is not set # CONFIG_STM32_CANBUS_PA11_PB9 is not set # CONFIG_STM32_MMENU_CANBUS_PB8_PB9 is not set # CONFIG_STM32_MMENU_CANBUS_PB12_PB13 is not set # CONFIG_STM32_MMENU_CANBUS_PD0_PD1 is not set # CONFIG_STM32_MMENU_CANBUS_PB0_PB1 is not set # CONFIG_STM32_MMENU_CANBUS_PD12_PD13 is not set # CONFIG_STM32_MMENU_CANBUS_PC2_PC3 is not set # CONFIG_STM32_USBCANBUS_PA11_PA12 is not set CONFIG_USB=y CONFIG_USB_VENDOR_ID=0x1d50 CONFIG_USB_DEVICE_ID=0x614e CONFIG_USB_SERIAL_NUMBER_CHIPID=y CONFIG_USB_SERIAL_NUMBER="12345" # # USB ids # # end of USB ids CONFIG_CANBUS_FREQUENCY=500000 CONFIG_INITIAL_PINS="" CONFIG_HAVE_GPIO=y CONFIG_HAVE_GPIO_ADC=y CONFIG_HAVE_GPIO_SPI=y CONFIG_HAVE_GPIO_I2C=y CONFIG_HAVE_GPIO_HARD_PWM=y CONFIG_HAVE_GPIO_BITBANGING=y CONFIG_HAVE_STRICT_TIMING=y CONFIG_HAVE_CHIPID=y CONFIG_HAVE_STEPPER_BOTH_EDGE=y CONFIG_HAVE_BOOTLOADER_REQUEST=y CONFIG_INLINE_STEPPER_HACK=y ======================= No build file /home/biqu/klipper/klippy/../out/klipper.dict No build file /home/biqu/klipper/klippy/../out/klipper.elf Unable to issue reset command on MCU 'mcu' webhooks client 281473758040608: Disconnected Restarting printer Start printer at Fri Mar 1 09:08:12 2024 (1709284092.9 707.0) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS5 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473751955824: New connection webhooks client 281473751955824: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473751955824: Disconnected Restarting printer Start printer at Fri Mar 1 09:08:25 2024 (1709284105.4 719.4) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281473751542032: New connection webhooks client 281473751542032: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' Unable to issue reset command on MCU 'mcu' webhooks client 281473751542032: Disconnected Restarting printer Start printer at Fri Mar 1 09:08:36 2024 (1709284116.5 730.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS2 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473749850720: New connection webhooks client 281473749850720: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') MCU error during connect Traceback (most recent call last): File "/home/biqu/klipper/klippy/mcu.py", line 768, in _mcu_identify self._serial.connect_uart(self._serialport, self._baud, rts) File "/home/biqu/klipper/klippy/serialhdl.py", line 182, in connect_uart self._error("Unable to connect") File "/home/biqu/klipper/klippy/serialhdl.py", line 61, in _error raise error(self.warn_prefix + (msg % params)) serialhdl.error: mcu 'mcu': Unable to connect During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/biqu/klipper/klippy/klippy.py", line 176, in _connect self.send_event("klippy:mcu_identify") File "/home/biqu/klipper/klippy/klippy.py", line 263, in send_event return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/klippy.py", line 263, in return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/mcu.py", line 773, in _mcu_identify raise error(str(e)) mcu.error: mcu 'mcu': Unable to connect Build file /home/biqu/klipper/klippy/../.config(3117): Fri Mar 3 11:18:09 2023 ========= Last MCU build config ========= CONFIG_LOW_LEVEL_OPTIONS=y # CONFIG_MACH_AVR is not set # CONFIG_MACH_ATSAM is not set # CONFIG_MACH_ATSAMD is not set # CONFIG_MACH_LPC176X is not set CONFIG_MACH_STM32=y # CONFIG_MACH_HC32F460 is not set # CONFIG_MACH_RP2040 is not set # CONFIG_MACH_PRU is not set # CONFIG_MACH_AR100 is not set # CONFIG_MACH_LINUX is not set # CONFIG_MACH_SIMU is not set CONFIG_BOARD_DIRECTORY="stm32" CONFIG_MCU="stm32g0b1xx" CONFIG_CLOCK_FREQ=64000000 CONFIG_USBSERIAL=y CONFIG_FLASH_SIZE=0x20000 CONFIG_FLASH_BOOT_ADDRESS=0x8000000 CONFIG_RAM_START=0x20000000 CONFIG_RAM_SIZE=0x24000 CONFIG_STACK_SIZE=512 CONFIG_FLASH_APPLICATION_ADDRESS=0x8000000 CONFIG_STM32_SELECT=y # CONFIG_MACH_STM32F103 is not set # CONFIG_MACH_STM32F207 is not set # CONFIG_MACH_STM32F401 is not set # CONFIG_MACH_STM32F405 is not set # CONFIG_MACH_STM32F407 is not set # CONFIG_MACH_STM32F429 is not set # CONFIG_MACH_STM32F446 is not set # CONFIG_MACH_STM32F031 is not set # CONFIG_MACH_STM32F042 is not set # CONFIG_MACH_STM32F070 is not set # CONFIG_MACH_STM32F072 is not set # CONFIG_MACH_STM32G070 is not set # CONFIG_MACH_STM32G071 is not set # CONFIG_MACH_STM32G0B0 is not set CONFIG_MACH_STM32G0B1=y # CONFIG_MACH_STM32G431 is not set # CONFIG_MACH_STM32H723 is not set # CONFIG_MACH_STM32H743 is not set # CONFIG_MACH_STM32H750 is not set # CONFIG_MACH_STM32L412 is not set CONFIG_MACH_STM32G0=y CONFIG_MACH_STM32G0Bx=y CONFIG_HAVE_STM32_USBFS=y CONFIG_HAVE_STM32_FDCANBUS=y CONFIG_HAVE_STM32_USBCANBUS=y CONFIG_STM32_DFU_ROM_ADDRESS=0x1fff0000 # CONFIG_STM32_FLASH_START_2000 is not set CONFIG_STM32_FLASH_START_0000=y CONFIG_STM32_CLOCK_REF_8M=y # CONFIG_STM32_CLOCK_REF_12M is not set # CONFIG_STM32_CLOCK_REF_16M is not set # CONFIG_STM32_CLOCK_REF_20M is not set # CONFIG_STM32_CLOCK_REF_25M is not set # CONFIG_STM32_CLOCK_REF_INTERNAL is not set CONFIG_CLOCK_REF_FREQ=8000000 CONFIG_STM32F0_TRIM=16 CONFIG_STM32_USB_PA11_PA12=y # CONFIG_STM32_SERIAL_USART1 is not set # CONFIG_STM32_SERIAL_USART1_ALT_PB7_PB6 is not set # CONFIG_STM32_SERIAL_USART2 is not set # CONFIG_STM32_SERIAL_USART2_ALT_PD6_PD5 is not set # CONFIG_STM32_SERIAL_USART3 is not set # CONFIG_STM32_SERIAL_USART3_ALT_PD9_PD8 is not set # CONFIG_STM32_CANBUS_PA11_PA12 is not set # CONFIG_STM32_CANBUS_PA11_PB9 is not set # CONFIG_STM32_MMENU_CANBUS_PB8_PB9 is not set # CONFIG_STM32_MMENU_CANBUS_PB12_PB13 is not set # CONFIG_STM32_MMENU_CANBUS_PD0_PD1 is not set # CONFIG_STM32_MMENU_CANBUS_PB0_PB1 is not set # CONFIG_STM32_MMENU_CANBUS_PD12_PD13 is not set # CONFIG_STM32_MMENU_CANBUS_PC2_PC3 is not set # CONFIG_STM32_USBCANBUS_PA11_PA12 is not set CONFIG_USB=y CONFIG_USB_VENDOR_ID=0x1d50 CONFIG_USB_DEVICE_ID=0x614e CONFIG_USB_SERIAL_NUMBER_CHIPID=y CONFIG_USB_SERIAL_NUMBER="12345" # # USB ids # # end of USB ids CONFIG_CANBUS_FREQUENCY=500000 CONFIG_INITIAL_PINS="" CONFIG_HAVE_GPIO=y CONFIG_HAVE_GPIO_ADC=y CONFIG_HAVE_GPIO_SPI=y CONFIG_HAVE_GPIO_I2C=y CONFIG_HAVE_GPIO_HARD_PWM=y CONFIG_HAVE_GPIO_BITBANGING=y CONFIG_HAVE_STRICT_TIMING=y CONFIG_HAVE_CHIPID=y CONFIG_HAVE_STEPPER_BOTH_EDGE=y CONFIG_HAVE_BOOTLOADER_REQUEST=y CONFIG_INLINE_STEPPER_HACK=y ======================= No build file /home/biqu/klipper/klippy/../out/klipper.dict No build file /home/biqu/klipper/klippy/../out/klipper.elf Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.12.0-114-ga77d0790' Branch: master Remote: origin Tracked URL: https://github.com/Klipper3d/klipper CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Start printer at Fri Mar 1 08:50:03 2024 (1709283003.5 25.2) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS2 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281472835036304: New connection webhooks client 281472835036304: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') MCU error during connect Traceback (most recent call last): File "/home/biqu/klipper/klippy/mcu.py", line 768, in _mcu_identify self._serial.connect_uart(self._serialport, self._baud, rts) File "/home/biqu/klipper/klippy/serialhdl.py", line 182, in connect_uart self._error("Unable to connect") File "/home/biqu/klipper/klippy/serialhdl.py", line 61, in _error raise error(self.warn_prefix + (msg % params)) serialhdl.error: mcu 'mcu': Unable to connect During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/biqu/klipper/klippy/klippy.py", line 176, in _connect self.send_event("klippy:mcu_identify") File "/home/biqu/klipper/klippy/klippy.py", line 263, in send_event return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/klippy.py", line 263, in return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/mcu.py", line 773, in _mcu_identify raise error(str(e)) mcu.error: mcu 'mcu': Unable to connect Build file /home/biqu/klipper/klippy/../.config(3117): Fri Mar 3 11:18:09 2023 ========= Last MCU build config ========= CONFIG_LOW_LEVEL_OPTIONS=y # CONFIG_MACH_AVR is not set # CONFIG_MACH_ATSAM is not set # CONFIG_MACH_ATSAMD is not set # CONFIG_MACH_LPC176X is not set CONFIG_MACH_STM32=y # CONFIG_MACH_HC32F460 is not set # CONFIG_MACH_RP2040 is not set # CONFIG_MACH_PRU is not set # CONFIG_MACH_AR100 is not set # CONFIG_MACH_LINUX is not set # CONFIG_MACH_SIMU is not set CONFIG_BOARD_DIRECTORY="stm32" CONFIG_MCU="stm32g0b1xx" CONFIG_CLOCK_FREQ=64000000 CONFIG_USBSERIAL=y CONFIG_FLASH_SIZE=0x20000 CONFIG_FLASH_BOOT_ADDRESS=0x8000000 CONFIG_RAM_START=0x20000000 CONFIG_RAM_SIZE=0x24000 CONFIG_STACK_SIZE=512 CONFIG_FLASH_APPLICATION_ADDRESS=0x8000000 CONFIG_STM32_SELECT=y # CONFIG_MACH_STM32F103 is not set # CONFIG_MACH_STM32F207 is not set # CONFIG_MACH_STM32F401 is not set # CONFIG_MACH_STM32F405 is not set # CONFIG_MACH_STM32F407 is not set # CONFIG_MACH_STM32F429 is not set # CONFIG_MACH_STM32F446 is not set # CONFIG_MACH_STM32F031 is not set # CONFIG_MACH_STM32F042 is not set # CONFIG_MACH_STM32F070 is not set # CONFIG_MACH_STM32F072 is not set # CONFIG_MACH_STM32G070 is not set # CONFIG_MACH_STM32G071 is not set # CONFIG_MACH_STM32G0B0 is not set CONFIG_MACH_STM32G0B1=y # CONFIG_MACH_STM32G431 is not set # CONFIG_MACH_STM32H723 is not set # CONFIG_MACH_STM32H743 is not set # CONFIG_MACH_STM32H750 is not set # CONFIG_MACH_STM32L412 is not set CONFIG_MACH_STM32G0=y CONFIG_MACH_STM32G0Bx=y CONFIG_HAVE_STM32_USBFS=y CONFIG_HAVE_STM32_FDCANBUS=y CONFIG_HAVE_STM32_USBCANBUS=y CONFIG_STM32_DFU_ROM_ADDRESS=0x1fff0000 # CONFIG_STM32_FLASH_START_2000 is not set CONFIG_STM32_FLASH_START_0000=y CONFIG_STM32_CLOCK_REF_8M=y # CONFIG_STM32_CLOCK_REF_12M is not set # CONFIG_STM32_CLOCK_REF_16M is not set # CONFIG_STM32_CLOCK_REF_20M is not set # CONFIG_STM32_CLOCK_REF_25M is not set # CONFIG_STM32_CLOCK_REF_INTERNAL is not set CONFIG_CLOCK_REF_FREQ=8000000 CONFIG_STM32F0_TRIM=16 CONFIG_STM32_USB_PA11_PA12=y # CONFIG_STM32_SERIAL_USART1 is not set # CONFIG_STM32_SERIAL_USART1_ALT_PB7_PB6 is not set # CONFIG_STM32_SERIAL_USART2 is not set # CONFIG_STM32_SERIAL_USART2_ALT_PD6_PD5 is not set # CONFIG_STM32_SERIAL_USART3 is not set # CONFIG_STM32_SERIAL_USART3_ALT_PD9_PD8 is not set # CONFIG_STM32_CANBUS_PA11_PA12 is not set # CONFIG_STM32_CANBUS_PA11_PB9 is not set # CONFIG_STM32_MMENU_CANBUS_PB8_PB9 is not set # CONFIG_STM32_MMENU_CANBUS_PB12_PB13 is not set # CONFIG_STM32_MMENU_CANBUS_PD0_PD1 is not set # CONFIG_STM32_MMENU_CANBUS_PB0_PB1 is not set # CONFIG_STM32_MMENU_CANBUS_PD12_PD13 is not set # CONFIG_STM32_MMENU_CANBUS_PC2_PC3 is not set # CONFIG_STM32_USBCANBUS_PA11_PA12 is not set CONFIG_USB=y CONFIG_USB_VENDOR_ID=0x1d50 CONFIG_USB_DEVICE_ID=0x614e CONFIG_USB_SERIAL_NUMBER_CHIPID=y CONFIG_USB_SERIAL_NUMBER="12345" # # USB ids # # end of USB ids CONFIG_CANBUS_FREQUENCY=500000 CONFIG_INITIAL_PINS="" CONFIG_HAVE_GPIO=y CONFIG_HAVE_GPIO_ADC=y CONFIG_HAVE_GPIO_SPI=y CONFIG_HAVE_GPIO_I2C=y CONFIG_HAVE_GPIO_HARD_PWM=y CONFIG_HAVE_GPIO_BITBANGING=y CONFIG_HAVE_STRICT_TIMING=y CONFIG_HAVE_CHIPID=y CONFIG_HAVE_STEPPER_BOTH_EDGE=y CONFIG_HAVE_BOOTLOADER_REQUEST=y CONFIG_INLINE_STEPPER_HACK=y ======================= No build file /home/biqu/klipper/klippy/../out/klipper.dict No build file /home/biqu/klipper/klippy/../out/klipper.elf Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.12.0-114-ga77d0790' Branch: master Remote: origin Tracked URL: https://github.com/Klipper3d/klipper CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Start printer at Fri Mar 1 08:50:03 2024 (1709283003.7 23.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS2 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473370817680: New connection webhooks client 281473370817680: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473370817680: Disconnected Restarting printer Start printer at Fri Mar 1 08:50:28 2024 (1709283028.3 48.2) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281473370981088: New connection webhooks client 281473370981088: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' Unable to issue reset command on MCU 'mcu' webhooks client 281473370981088: Disconnected Restarting printer Start printer at Fri Mar 1 08:50:54 2024 (1709283054.4 74.2) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS1 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473370942480: New connection webhooks client 281473370942480: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} Unable to issue reset command on MCU 'mcu' webhooks client 281473370942480: Disconnected Restarting printer Start printer at Fri Mar 1 08:50:59 2024 (1709283059.7 79.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS1 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473370751280: New connection webhooks client 281473370751280: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473370751280: Disconnected Restarting printer Start printer at Fri Mar 1 09:55:09 2024 (1709286909.2 89.7) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS2 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473371232768: New connection webhooks client 281473371232768: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} Unable to issue reset command on MCU 'mcu' webhooks client 281473371232768: Disconnected Restarting printer Start printer at Fri Mar 1 09:55:16 2024 (1709286916.1 96.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS2 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473371827888: New connection webhooks client 281473371827888: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473371827888: Disconnected Restarting printer Start printer at Fri Mar 1 09:55:26 2024 (1709286926.2 106.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS3 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473371490960: New connection webhooks client 281473371490960: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473371490960: Disconnected Restarting printer Start printer at Fri Mar 1 09:55:37 2024 (1709286937.1 117.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS4 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473372478672: New connection webhooks client 281473372478672: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473372478672: Disconnected Restarting printer Start printer at Fri Mar 1 09:55:52 2024 (1709286952.2 132.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS5 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') webhooks client 281473370888800: New connection webhooks client 281473370888800: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: Could not configure port: (5, 'Input/output error') Unable to issue reset command on MCU 'mcu' webhooks client 281473370888800: Disconnected Restarting printer Start printer at Fri Mar 1 09:56:01 2024 (1709286961.5 141.9) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281473371073696: New connection webhooks client 281473371073696: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' MCU error during connect Traceback (most recent call last): File "/home/biqu/klipper/klippy/mcu.py", line 768, in _mcu_identify self._serial.connect_uart(self._serialport, self._baud, rts) File "/home/biqu/klipper/klippy/serialhdl.py", line 182, in connect_uart self._error("Unable to connect") File "/home/biqu/klipper/klippy/serialhdl.py", line 61, in _error raise error(self.warn_prefix + (msg % params)) serialhdl.error: mcu 'mcu': Unable to connect During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/biqu/klipper/klippy/klippy.py", line 176, in _connect self.send_event("klippy:mcu_identify") File "/home/biqu/klipper/klippy/klippy.py", line 263, in send_event return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/klippy.py", line 263, in return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/mcu.py", line 773, in _mcu_identify raise error(str(e)) mcu.error: mcu 'mcu': Unable to connect Build file /home/biqu/klipper/klippy/../.config(2859): Fri Mar 1 09:28:41 2024 ========= Last MCU build config ========= CONFIG_LOW_LEVEL_OPTIONS=y # CONFIG_MACH_AVR is not set # CONFIG_MACH_ATSAM is not set # CONFIG_MACH_ATSAMD is not set # CONFIG_MACH_LPC176X is not set CONFIG_MACH_STM32=y # CONFIG_MACH_HC32F460 is not set # CONFIG_MACH_RP2040 is not set # CONFIG_MACH_PRU is not set # CONFIG_MACH_AR100 is not set # CONFIG_MACH_LINUX is not set # CONFIG_MACH_SIMU is not set CONFIG_BOARD_DIRECTORY="stm32" CONFIG_MCU="stm32f401xc" CONFIG_CLOCK_FREQ=84000000 CONFIG_SERIAL=y CONFIG_FLASH_SIZE=0x40000 CONFIG_FLASH_BOOT_ADDRESS=0x8000000 CONFIG_RAM_START=0x20000000 CONFIG_RAM_SIZE=0x10000 CONFIG_STACK_SIZE=512 CONFIG_FLASH_APPLICATION_ADDRESS=0x8008000 CONFIG_STM32_SELECT=y # CONFIG_MACH_STM32F103 is not set # CONFIG_MACH_STM32F207 is not set CONFIG_MACH_STM32F401=y # CONFIG_MACH_STM32F405 is not set # CONFIG_MACH_STM32F407 is not set # CONFIG_MACH_STM32F429 is not set # CONFIG_MACH_STM32F446 is not set # CONFIG_MACH_STM32F765 is not set # CONFIG_MACH_STM32F031 is not set # CONFIG_MACH_STM32F042 is not set # CONFIG_MACH_STM32F070 is not set # CONFIG_MACH_STM32F072 is not set # CONFIG_MACH_STM32G070 is not set # CONFIG_MACH_STM32G071 is not set # CONFIG_MACH_STM32G0B0 is not set # CONFIG_MACH_STM32G0B1 is not set # CONFIG_MACH_STM32G431 is not set # CONFIG_MACH_STM32H723 is not set # CONFIG_MACH_STM32H743 is not set # CONFIG_MACH_STM32H750 is not set # CONFIG_MACH_STM32L412 is not set # CONFIG_MACH_N32G452 is not set # CONFIG_MACH_N32G455 is not set CONFIG_MACH_STM32F4=y CONFIG_HAVE_STM32_USBOTG=y CONFIG_STM32_DFU_ROM_ADDRESS=0 CONFIG_STM32_FLASH_START_8000=y # CONFIG_STM32_FLASH_START_10000 is not set # CONFIG_STM32_FLASH_START_4000 is not set # CONFIG_STM32_FLASH_START_0000 is not set CONFIG_STM32_CLOCK_REF_8M=y # CONFIG_STM32_CLOCK_REF_12M is not set # CONFIG_STM32_CLOCK_REF_16M is not set # CONFIG_STM32_CLOCK_REF_20M is not set # CONFIG_STM32_CLOCK_REF_24M is not set # CONFIG_STM32_CLOCK_REF_25M is not set # CONFIG_STM32_CLOCK_REF_INTERNAL is not set CONFIG_CLOCK_REF_FREQ=8000000 CONFIG_STM32F0_TRIM=16 # CONFIG_STM32_USB_PA11_PA12 is not set # CONFIG_STM32_SERIAL_USART1 is not set # CONFIG_STM32_SERIAL_USART1_ALT_PB7_PB6 is not set CONFIG_STM32_SERIAL_USART2=y # CONFIG_STM32_SERIAL_USART2_ALT_PD6_PD5 is not set CONFIG_SERIAL_BAUD=250000 CONFIG_USB_VENDOR_ID=0x1d50 CONFIG_USB_DEVICE_ID=0x614e CONFIG_USB_SERIAL_NUMBER="12345" CONFIG_WANT_GPIO_BITBANGING=y CONFIG_WANT_DISPLAYS=y CONFIG_WANT_SENSORS=y CONFIG_WANT_LIS2DW=y CONFIG_WANT_SOFTWARE_I2C=y CONFIG_WANT_SOFTWARE_SPI=y CONFIG_NEED_SENSOR_BULK=y CONFIG_CANBUS_FREQUENCY=1000000 CONFIG_INITIAL_PINS="" CONFIG_HAVE_GPIO=y CONFIG_HAVE_GPIO_ADC=y CONFIG_HAVE_GPIO_SPI=y CONFIG_HAVE_GPIO_SDIO=y CONFIG_HAVE_GPIO_I2C=y CONFIG_HAVE_GPIO_HARD_PWM=y CONFIG_HAVE_STRICT_TIMING=y CONFIG_HAVE_CHIPID=y CONFIG_HAVE_STEPPER_BOTH_EDGE=y CONFIG_HAVE_BOOTLOADER_REQUEST=y CONFIG_INLINE_STEPPER_HACK=y ======================= Build file /home/biqu/klipper/klippy/../out/klipper.dict(8390): Fri Mar 1 09:29:50 2024 Last MCU build version: v0.12.0-114-ga77d0790 Last MCU build tools: gcc: (15:8-2019-q3-1+b1) 8.3.1 20190703 (release) [gcc-8-branch revision 273027] binutils: (2.35.2-2+14+b2) 2.35.2 Last MCU build config: ADC_MAX=4095 BUS_PINS_i2c1=PB6,PB7 BUS_PINS_i2c1a=PB8,PB9 BUS_PINS_i2c2=PB10,PB11 BUS_PINS_i2c3=PA8,PC9 BUS_PINS_sdio=PC12,PD2,PC8,PC9,PC10,PC11 BUS_PINS_spi1=PA6,PA7,PA5 BUS_PINS_spi1a=PB4,PB5,PB3 BUS_PINS_spi2=PB14,PB15,PB13 BUS_PINS_spi2a=PC2,PC3,PB10 BUS_PINS_spi3=PB4,PB5,PB3 BUS_PINS_spi3a=PC11,PC12,PC10 BUS_PINS_spi4=PE13,PE14,PE12 CLOCK_FREQ=84000000 MCU=stm32f401xc PWM_MAX=255 RECEIVE_WINDOW=192 RESERVE_PINS_crystal=PH0,PH1 RESERVE_PINS_serial=PA3,PA2 SERIAL_BAUD=250000 STATS_SUMSQ_BASE=256 STEPPER_BOTH_EDGE=1 Build file /home/biqu/klipper/klippy/../out/klipper.elf(958292): Fri Mar 1 09:30:06 2024 Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.12.0-114-ga77d0790' Branch: master Remote: origin Tracked URL: https://github.com/Klipper3d/klipper CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Start printer at Fri Mar 1 08:50:03 2024 (1709283003.7 23.8) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281473026783936: New connection webhooks client 281473026783936: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.12.0-114-ga77d0790' Branch: master Remote: origin Tracked URL: https://github.com/Klipper3d/klipper CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Start printer at Fri Mar 1 08:50:03 2024 (1709283003.5 24.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281472836170848: New connection webhooks client 281472836170848: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' MCU error during connect Traceback (most recent call last): File "/home/biqu/klipper/klippy/mcu.py", line 768, in _mcu_identify self._serial.connect_uart(self._serialport, self._baud, rts) File "/home/biqu/klipper/klippy/serialhdl.py", line 182, in connect_uart self._error("Unable to connect") File "/home/biqu/klipper/klippy/serialhdl.py", line 61, in _error raise error(self.warn_prefix + (msg % params)) serialhdl.error: mcu 'mcu': Unable to connect During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/biqu/klipper/klippy/klippy.py", line 176, in _connect self.send_event("klippy:mcu_identify") File "/home/biqu/klipper/klippy/klippy.py", line 263, in send_event return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/klippy.py", line 263, in return [cb(*params) for cb in self.event_handlers.get(event, [])] File "/home/biqu/klipper/klippy/mcu.py", line 773, in _mcu_identify raise error(str(e)) mcu.error: mcu 'mcu': Unable to connect Build file /home/biqu/klipper/klippy/../.config(2859): Fri Mar 1 09:28:41 2024 ========= Last MCU build config ========= CONFIG_LOW_LEVEL_OPTIONS=y # CONFIG_MACH_AVR is not set # CONFIG_MACH_ATSAM is not set # CONFIG_MACH_ATSAMD is not set # CONFIG_MACH_LPC176X is not set CONFIG_MACH_STM32=y # CONFIG_MACH_HC32F460 is not set # CONFIG_MACH_RP2040 is not set # CONFIG_MACH_PRU is not set # CONFIG_MACH_AR100 is not set # CONFIG_MACH_LINUX is not set # CONFIG_MACH_SIMU is not set CONFIG_BOARD_DIRECTORY="stm32" CONFIG_MCU="stm32f401xc" CONFIG_CLOCK_FREQ=84000000 CONFIG_SERIAL=y CONFIG_FLASH_SIZE=0x40000 CONFIG_FLASH_BOOT_ADDRESS=0x8000000 CONFIG_RAM_START=0x20000000 CONFIG_RAM_SIZE=0x10000 CONFIG_STACK_SIZE=512 CONFIG_FLASH_APPLICATION_ADDRESS=0x8008000 CONFIG_STM32_SELECT=y # CONFIG_MACH_STM32F103 is not set # CONFIG_MACH_STM32F207 is not set CONFIG_MACH_STM32F401=y # CONFIG_MACH_STM32F405 is not set # CONFIG_MACH_STM32F407 is not set # CONFIG_MACH_STM32F429 is not set # CONFIG_MACH_STM32F446 is not set # CONFIG_MACH_STM32F765 is not set # CONFIG_MACH_STM32F031 is not set # CONFIG_MACH_STM32F042 is not set # CONFIG_MACH_STM32F070 is not set # CONFIG_MACH_STM32F072 is not set # CONFIG_MACH_STM32G070 is not set # CONFIG_MACH_STM32G071 is not set # CONFIG_MACH_STM32G0B0 is not set # CONFIG_MACH_STM32G0B1 is not set # CONFIG_MACH_STM32G431 is not set # CONFIG_MACH_STM32H723 is not set # CONFIG_MACH_STM32H743 is not set # CONFIG_MACH_STM32H750 is not set # CONFIG_MACH_STM32L412 is not set # CONFIG_MACH_N32G452 is not set # CONFIG_MACH_N32G455 is not set CONFIG_MACH_STM32F4=y CONFIG_HAVE_STM32_USBOTG=y CONFIG_STM32_DFU_ROM_ADDRESS=0 CONFIG_STM32_FLASH_START_8000=y # CONFIG_STM32_FLASH_START_10000 is not set # CONFIG_STM32_FLASH_START_4000 is not set # CONFIG_STM32_FLASH_START_0000 is not set CONFIG_STM32_CLOCK_REF_8M=y # CONFIG_STM32_CLOCK_REF_12M is not set # CONFIG_STM32_CLOCK_REF_16M is not set # CONFIG_STM32_CLOCK_REF_20M is not set # CONFIG_STM32_CLOCK_REF_24M is not set # CONFIG_STM32_CLOCK_REF_25M is not set # CONFIG_STM32_CLOCK_REF_INTERNAL is not set CONFIG_CLOCK_REF_FREQ=8000000 CONFIG_STM32F0_TRIM=16 # CONFIG_STM32_USB_PA11_PA12 is not set # CONFIG_STM32_SERIAL_USART1 is not set # CONFIG_STM32_SERIAL_USART1_ALT_PB7_PB6 is not set CONFIG_STM32_SERIAL_USART2=y # CONFIG_STM32_SERIAL_USART2_ALT_PD6_PD5 is not set CONFIG_SERIAL_BAUD=250000 CONFIG_USB_VENDOR_ID=0x1d50 CONFIG_USB_DEVICE_ID=0x614e CONFIG_USB_SERIAL_NUMBER="12345" CONFIG_WANT_GPIO_BITBANGING=y CONFIG_WANT_DISPLAYS=y CONFIG_WANT_SENSORS=y CONFIG_WANT_LIS2DW=y CONFIG_WANT_SOFTWARE_I2C=y CONFIG_WANT_SOFTWARE_SPI=y CONFIG_NEED_SENSOR_BULK=y CONFIG_CANBUS_FREQUENCY=1000000 CONFIG_INITIAL_PINS="" CONFIG_HAVE_GPIO=y CONFIG_HAVE_GPIO_ADC=y CONFIG_HAVE_GPIO_SPI=y CONFIG_HAVE_GPIO_SDIO=y CONFIG_HAVE_GPIO_I2C=y CONFIG_HAVE_GPIO_HARD_PWM=y CONFIG_HAVE_STRICT_TIMING=y CONFIG_HAVE_CHIPID=y CONFIG_HAVE_STEPPER_BOTH_EDGE=y CONFIG_HAVE_BOOTLOADER_REQUEST=y CONFIG_INLINE_STEPPER_HACK=y ======================= Build file /home/biqu/klipper/klippy/../out/klipper.dict(8390): Fri Mar 1 10:07:30 2024 Last MCU build version: v0.12.0-114-ga77d0790 Last MCU build tools: gcc: (15:8-2019-q3-1+b1) 8.3.1 20190703 (release) [gcc-8-branch revision 273027] binutils: (2.35.2-2+14+b2) 2.35.2 Last MCU build config: ADC_MAX=4095 BUS_PINS_i2c1=PB6,PB7 BUS_PINS_i2c1a=PB8,PB9 BUS_PINS_i2c2=PB10,PB11 BUS_PINS_i2c3=PA8,PC9 BUS_PINS_sdio=PC12,PD2,PC8,PC9,PC10,PC11 BUS_PINS_spi1=PA6,PA7,PA5 BUS_PINS_spi1a=PB4,PB5,PB3 BUS_PINS_spi2=PB14,PB15,PB13 BUS_PINS_spi2a=PC2,PC3,PB10 BUS_PINS_spi3=PB4,PB5,PB3 BUS_PINS_spi3a=PC11,PC12,PC10 BUS_PINS_spi4=PE13,PE14,PE12 CLOCK_FREQ=84000000 MCU=stm32f401xc PWM_MAX=255 RECEIVE_WINDOW=192 RESERVE_PINS_crystal=PH0,PH1 RESERVE_PINS_serial=PA3,PA2 SERIAL_BAUD=250000 STATS_SUMSQ_BASE=256 STEPPER_BOTH_EDGE=1 Build file /home/biqu/klipper/klippy/../out/klipper.elf(958292): Fri Mar 1 10:07:46 2024 Starting Klippy... Args: ['/home/biqu/klipper/klippy/klippy.py', '/home/biqu/printer_data/config/printer.cfg', '-I', '/home/biqu/printer_data/comms/klippy.serial', '-l', '/home/biqu/printer_data/logs/klippy.log', '-a', '/home/biqu/printer_data/comms/klippy.sock'] Git version: 'v0.12.0-114-ga77d0790' Branch: master Remote: origin Tracked URL: https://github.com/Klipper3d/klipper CPU: 4 core ? Python: '3.9.2 (default, Feb 28 2021, 17:03:44) \n[GCC 10.2.1 20210110]' Start printer at Fri Mar 1 08:50:03 2024 (1709283003.6 24.0) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281472858125456: New connection webhooks client 281472858125456: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' Unable to issue reset command on MCU 'mcu' webhooks client 281472858125456: Disconnected Restarting printer Start printer at Fri Mar 1 08:51:09 2024 (1709283069.3 89.6) ===== Config file ===== [virtual_sdcard] path = /home/biqu/printer_data/gcodes/ on_error_gcode = CANCEL_PRINT [pause_resume] [display_status] [respond] [gcode_macro CANCEL_PRINT] description = Cancel the actual running print rename_existing = CANCEL_PRINT_BASE gcode = TURN_OFF_HEATERS CANCEL_PRINT_BASE [gcode_macro PAUSE] description = Pause the actual running print rename_existing = PAUSE_BASE gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% set x_park = printer.toolhead.axis_maximum.x|float - 5.0 %} {% set y_park = printer.toolhead.axis_maximum.y|float - 5.0 %} {% set max_z = printer.toolhead.axis_maximum.z|float %} {% set act_z = printer.toolhead.position.z|float %} {% if act_z < (max_z - 2.0) %} {% set z_safe = 2.0 %} {% else %} {% set z_safe = max_z - act_z %} {% endif %} PAUSE_BASE G91 {% if printer.extruder.can_extrude|lower == 'true' %} G1 E-{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} {% if "xyz" in printer.toolhead.homed_axes %} G1 Z{z_safe} F900 G90 G1 X{x_park} Y{y_park} F6000 {% else %} {action_respond_info("Printer not homed")} {% endif %} variable_extrude = 1.0 [gcode_macro RESUME] description = Resume the actual running print rename_existing = RESUME_BASE variable_last_extruder_temp = {'restore': False, 'temp': 0} variable_restore_idle_timeout = 0 variable_idle_state = False gcode = {% set E = printer["gcode_macro PAUSE"].extrude|float %} {% if 'VELOCITY' in params|upper %} {% set get_params = ('VELOCITY=' + params.VELOCITY) %} {%else %} {% set get_params = "" %} {% endif %} {% if printer.extruder.can_extrude|lower == 'true' %} G91 G1 E{E} F2100 {% else %} {action_respond_info("Extruder not hot enough")} {% endif %} RESUME_BASE {get_params} [gcode_macro SET_PAUSE_NEXT_LAYER] description = Enable a pause if the next layer is reached gcode = {% set pause_next_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_next_layer %} {% set ENABLE = params.ENABLE|default(1)|int != 0 %} {% set MACRO = params.MACRO|default(pause_next_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_next_layer VALUE="{{ 'enable': ENABLE, 'call': MACRO }}" [gcode_macro SET_PAUSE_AT_LAYER] description = Enable/disable a pause if a given layer number is reached gcode = {% set pause_at_layer = printer['gcode_macro SET_PRINT_STATS_INFO'].pause_at_layer %} {% set ENABLE = params.ENABLE|int != 0 if params.ENABLE is defined else params.LAYER is defined %} {% set LAYER = params.LAYER|default(pause_at_layer.layer)|int %} {% set MACRO = params.MACRO|default(pause_at_layer.call, True) %} SET_GCODE_VARIABLE MACRO=SET_PRINT_STATS_INFO VARIABLE=pause_at_layer VALUE="{{ 'enable': ENABLE, 'layer': LAYER, 'call': MACRO }}" [gcode_macro SET_PRINT_STATS_INFO] rename_existing = SET_PRINT_STATS_INFO_BASE description = Overwrite, to get pause_next_layer and pause_at_layer feature variable_pause_next_layer = { 'enable': False, 'call': "PAUSE" } variable_pause_at_layer = { 'enable': False, 'layer': 0, 'call': "PAUSE" } gcode = {% if pause_next_layer.enable %} RESPOND TYPE=echo MSG='{"%s, forced by pause_next_layer" % pause_next_layer.call}' {pause_next_layer.call} SET_PAUSE_NEXT_LAYER ENABLE=0 {% elif pause_at_layer.enable and params.CURRENT_LAYER is defined and params.CURRENT_LAYER|int == pause_at_layer.layer %} RESPOND TYPE=echo MSG='{"%s, forced by pause_at_layer [%d]" % (pause_at_layer.call, pause_at_layer.layer)}' {pause_at_layer.call} SET_PAUSE_AT_LAYER ENABLE=0 {% endif %} SET_PRINT_STATS_INFO_BASE {rawparams} [gcode_macro _TOOLHEAD_PARK_PAUSE_CANCEL] description = Helper: park toolhead used in PAUSE and CANCEL_PRINT gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set velocity = printer.configfile.settings.pause_resume.recover_velocity %} {% set use_custom = client.use_custom_pos|default(false)|lower == 'true' %} {% set custom_park_x = client.custom_park_x|default(0.0) %} {% set custom_park_y = client.custom_park_y|default(0.0) %} {% set park_dz = client.custom_park_dz|default(2.0)|abs %} {% set sp_hop = client.speed_hop|default(15) * 60 %} {% set sp_move = client.speed_move|default(velocity) * 60 %} {% set origin = printer.gcode_move.homing_origin %} {% set act = printer.gcode_move.gcode_position %} {% set max = printer.toolhead.axis_maximum %} {% set cone = printer.toolhead.cone_start_z|default(max.z) %} {% set round_bed = True if printer.configfile.settings.printer.kinematics is in ['delta','polar','rotary_delta','winch'] else False %} {% set z_min = params.Z_MIN|default(0)|float %} {% set z_park = [[(act.z + park_dz), z_min]|max, (max.z - origin.z)]|min %} {% set x_park = params.X if params.X is defined else custom_park_x if use_custom else 0.0 if round_bed else (max.x - 5.0) %} {% set y_park = params.Y if params.Y is defined else custom_park_y if use_custom else (max.y - 5.0) if round_bed and z_park < cone else 0.0 if round_bed else (max.y - 5.0) %} _CLIENT_RETRACT {% if "xyz" in printer.toolhead.homed_axes %} G90 G1 Z{z_park} F{sp_hop} G1 X{x_park} Y{y_park} F{sp_move} {% if not printer.gcode_move.absolute_coordinates %} G91 {% endif %} {% else %} RESPOND TYPE=echo MSG='Printer not homed' {% endif %} [gcode_macro _CLIENT_EXTRUDE] description = Extrudes, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set use_fw_retract = (client.use_fw_retract|default(false)|lower == 'true') and (printer.firmware_retraction is defined) %} {% set length = params.LENGTH|default(client.unretract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_unretract)|default(35) %} {% set absolute_extrude = printer.gcode_move.absolute_extrude %} {% if printer.toolhead.extruder != '' %} {% if printer[printer.toolhead.extruder].can_extrude %} {% if use_fw_retract %} {% if length < 0 %} G10 {% else %} G11 {% endif %} {% else %} M83 G1 E{length} F{(speed|float|abs) * 60} {% if absolute_extrude %} M82 {% endif %} {% endif %} {% else %} RESPOND TYPE=echo MSG='{"\"%s\" not hot enough" % printer.toolhead.extruder}' {% endif %} {% endif %} [gcode_macro _CLIENT_RETRACT] description = Retracts, if the extruder is hot enough gcode = {% set client = printer['gcode_macro _CLIENT_VARIABLE']|default({}) %} {% set length = params.LENGTH|default(client.retract)|default(1.0)|float %} {% set speed = params.SPEED|default(client.speed_retract)|default(35) %} _CLIENT_EXTRUDE LENGTH=-{length|float|abs} SPEED={speed|float|abs} [exclude_object] [mcu] serial = /dev/ttyS0 restart_method = command [led LED_Light] white_pin = PB9 initial_white = 1.0 [printer] kinematics = cartesian max_velocity = 500 max_accel = 3000 max_z_velocity = 15 max_z_accel = 100 square_corner_velocity = 5 [stepper_x] step_pin = !PC12 dir_pin = PB3 enable_pin = !PD2 microsteps = 16 rotation_distance = 40 endstop_pin = PA13 position_endstop = -6.0 position_min = -6 position_max = 235 homing_speed = 50 [stepper_y] step_pin = PC11 dir_pin = PA15 enable_pin = !PC10 microsteps = 16 rotation_distance = 40 endstop_pin = PB8 position_endstop = 0 position_max = 235 homing_speed = 50 [stepper_z] step_pin = PC7 dir_pin = !PC9 enable_pin = !PC8 rotation_distance = 8 microsteps = 16 position_min = -2 position_max = 280 endstop_pin = probe:z_virtual_endstop homing_speed = 5.0 [extruder] max_extrude_only_distance = 100.0 step_pin = PB10 dir_pin = PB1 enable_pin = !PC6 microsteps = 16 nozzle_diameter = 0.400 filament_diameter = 1.750 heater_pin = PA6 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC1 min_temp = 0 max_temp = 250 rotation_distance = 6.9 control = pid pid_kp = 30.356 pid_ki = 1.857 pid_kd = 124.081 [heater_bed] heater_pin = PA5 sensor_type = EPCOS 100K B57560G104F sensor_pin = PC0 pwm_cycle_time = 0.020 max_temp = 110 min_temp = 0 control = pid pid_kp = 64.230 pid_ki = 0.723 pid_kd = 1425.905 [heater_fan hotend_fan] pin = PB0 heater = extruder heater_temp = 50.0 [fan] pin = PA7 [force_move] enable_force_move = True [safe_z_home] home_xy_position = 117.5, 117.5 z_hop = 10 [probe] pin = ^PA8 speed = 5 lift_speed = 15 samples = 1 x_offset = -28 y_offset = 20 z_offset = 1.075 [filament_switch_sensor filament_sensor] pause_on_runout = true switch_pin = PB4 [bed_mesh] speed = 300 horizontal_move_z = 5.0 mesh_min = 30,30 mesh_max = 205,205 probe_count = 6,6 algorithm = bicubic fade_start = 1 fade_end = 10 fade_target = 0 [input_shaper] shaper_type_y = mzv shaper_freq_y = 38.2 shaper_type_x = ei shaper_freq_x = 79.6 [temperature_sensor raspberry_pi] sensor_type = temperature_host [temperature_sensor mcu_temp] sensor_type = temperature_mcu sensor_temperature1 = 25 sensor_adc1 = 0.210317 [gcode_macro M420] description = Load the current mesh gcode = BED_MESH_PROFILE LOAD=default [gcode_macro G29] description = creates automated homing and bed mesh gcode = G28 BED_MESH_CALIBRATE DATA_SAVE [bed_mesh default] version = 1 points = 0.020000, 0.105000, 0.127500, 0.070000 -0.067500, 0.025000, 0.077500, 0.037500 -0.117500, -0.020000, 0.042500, 0.005000 -0.195000, -0.072500, 0.007500, -0.002500 tension = 0.2 min_x = 45.0 algo = bicubic y_count = 4 mesh_y_pps = 2 min_y = 20.0 x_count = 4 max_y = 200.0 mesh_x_pps = 2 max_x = 199.97 ======================= Extruder max_extrude_ratio=0.266081 mcu 'mcu': Starting serial connect mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' webhooks client 281472858289008: New connection webhooks client 281472858289008: Client info {'program': 'Moonraker', 'version': 'v0.8.0-318-g9813011'} mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0' mcu 'mcu': Unable to open serial port: [Errno 13] could not open port /dev/ttyS0: [Errno 13] Permission denied: '/dev/ttyS0'