Merge branch 'AddMinimumTempForNozzleAsProbe' into CR-6Devel
This commit is contained in:
@@ -1067,6 +1067,10 @@
|
||||
//#define PROBING_STEPPERS_OFF // Turn steppers off (unless needed to hold position) when probing
|
||||
//#define DELAY_BEFORE_PROBING 200 // (ms) To prevent vibrations from triggering piezo sensors
|
||||
|
||||
// Require minimum nozzle or bed temperature for probing. Currently applies only to the first extruder.
|
||||
//#define PROBE_REQUIRES_MINTEMP_NOZZLE 150
|
||||
//#define PROBE_REQUIRES_MINTEMP_BED 50
|
||||
|
||||
// For Inverting Stepper Enable Pins (Active Low) use 0, Non Inverting (Active High) use 1
|
||||
// :{ 0:'Low', 1:'High' }
|
||||
#define X_ENABLE_ON 0
|
||||
@@ -1656,6 +1660,13 @@
|
||||
// For a purge/clean station mounted on the X axis
|
||||
//#define NOZZLE_CLEAN_NO_Y
|
||||
|
||||
//#define NOZZLE_CLEAN_MIN_TEMP
|
||||
#if ENABLED(NOZZLE_CLEAN_MIN_TEMP)
|
||||
#define NOZZLE_CLEAN_TEMP 170
|
||||
// Heat nozzle if temperature is too low. Default behavior is to skip cleaning.
|
||||
//#define NOZZLE_CLEAN_HEAT_LOWTEMP
|
||||
#endif
|
||||
|
||||
// Explicit wipe G-code script applies to a G12 with no arguments.
|
||||
//#define WIPE_SEQUENCE_COMMANDS "G1 X-17 Y25 Z10 F4000\nG1 Z1\nM114\nG1 X-17 Y25\nG1 X-17 Y95\nG1 X-17 Y25\nG1 X-17 Y95\nG1 X-17 Y25\nG1 X-17 Y95\nG1 X-17 Y25\nG1 X-17 Y95\nG1 X-17 Y25\nG1 X-17 Y95\nG1 X-17 Y25\nG1 X-17 Y95\nG1 Z15\nM400\nG0 X-10.0 Y-9.0"
|
||||
|
||||
|
||||
@@ -31,6 +31,10 @@ Nozzle nozzle;
|
||||
#include "../MarlinCore.h"
|
||||
#include "../module/motion.h"
|
||||
|
||||
#if ENABLED(NOZZLE_CLEAN_MIN_TEMP)
|
||||
#include "../module/temperature.h"
|
||||
#endif
|
||||
|
||||
#if ENABLED(NOZZLE_CLEAN_FEATURE)
|
||||
|
||||
/**
|
||||
@@ -153,6 +157,19 @@ Nozzle nozzle;
|
||||
|
||||
const uint8_t arrPos = ANY(SINGLENOZZLE, MIXING_EXTRUDER) ? 0 : active_extruder;
|
||||
|
||||
#if ENABLED(NOZZLE_CLEAN_MIN_TEMP) && NOZZLE_CLEAN_TEMP > 0
|
||||
if(thermalManager.degTargetHotend(arrPos) < NOZZLE_CLEAN_TEMP) {
|
||||
#if ENABLED(NOZZLE_CLEAN_HEAT_LOWTEMP)
|
||||
SERIAL_ECHOLNPGM("Nozzle too Cold - Heating");
|
||||
thermalManager.setTargetHotend(NOZZLE_CLEAN_TEMP, arrPos);
|
||||
thermalManager.wait_for_hotend(arrPos);
|
||||
#else
|
||||
SERIAL_ECHOLNPGM("Nozzle too cold - Skipping Wipe");
|
||||
return;
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
#if HAS_SOFTWARE_ENDSTOPS
|
||||
|
||||
#define LIMIT_AXIS(A) do{ \
|
||||
|
||||
@@ -348,6 +348,29 @@ bool Probe::set_deployed(const bool deploy) {
|
||||
constexpr bool deploy_stow_condition = true;
|
||||
#endif
|
||||
|
||||
#if defined(PROBE_REQUIRES_MINTEMP_NOZZLE) && (PROBE_REQUIRES_MINTEMP_NOZZLE) > 0 && HAS_TEMP_HOTEND
|
||||
#define WAIT_FOR_NOZZLE_HEAT 1
|
||||
bool setting_hotend = thermalManager.degTargetHotend(0) < (PROBE_REQUIRES_MINTEMP_NOZZLE);
|
||||
if (setting_hotend) {
|
||||
uint16_t hotendTemperature = (PROBE_REQUIRES_MINTEMP_NOZZLE);
|
||||
SERIAL_ECHOLNPAIR("Preheating hotend to ", hotendTemperature);
|
||||
thermalManager.setTargetHotend(hotendTemperature, 0);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(PROBE_REQUIRES_MINTEMP_BED) && (PROBE_REQUIRES_MINTEMP_BED) > 0 && HAS_HEATED_BED
|
||||
#define WAIT_FOR_BED_HEAT 1
|
||||
bool setting_bed = thermalManager.degBed() < (PROBE_REQUIRES_MINTEMP_BED);
|
||||
if (setting_bed) {
|
||||
uint16_t bedTemperature = (PROBE_REQUIRES_MINTEMP_BED);
|
||||
SERIAL_ECHOLNPAIR("Preheating bed to ", bedTemperature);
|
||||
thermalManager.setTargetBed(bedTemperature);
|
||||
}
|
||||
#endif
|
||||
|
||||
TERN_(WAIT_FOR_NOZZLE_HEAT, if (setting_hotend) thermalManager.wait_for_hotend(0));
|
||||
TERN_(WAIT_FOR_BED_HEAT, if (setting_bed) thermalManager.wait_for_bed_heating());
|
||||
|
||||
// For beds that fall when Z is powered off only raise for trusted Z
|
||||
#if ENABLED(UNKNOWN_Z_NO_RAISE)
|
||||
const bool unknown_condition = axis_is_trusted(Z_AXIS);
|
||||
|
||||
@@ -42,11 +42,12 @@ opt_enable REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER SDSUPPORT ADAPTIVE_FAN_
|
||||
NOZZLE_AS_PROBE AUTO_BED_LEVELING_BILINEAR G29_RETRY_AND_RECOVER Z_MIN_PROBE_REPEATABILITY_TEST DEBUG_LEVELING_FEATURE \
|
||||
BABYSTEPPING BABYSTEP_XY BABYSTEP_ZPROBE_OFFSET BABYSTEP_ZPROBE_GFX_OVERLAY \
|
||||
PRINTCOUNTER NOZZLE_PARK_FEATURE NOZZLE_CLEAN_FEATURE SLOW_PWM_HEATERS PIDTEMPBED EEPROM_SETTINGS INCH_MODE_SUPPORT TEMPERATURE_UNITS_SUPPORT \
|
||||
Z_SAFE_HOMING ADVANCED_PAUSE_FEATURE PARK_HEAD_ON_PAUSE \
|
||||
Z_SAFE_HOMING ADVANCED_PAUSE_FEATURE PARK_HEAD_ON_PAUSE NOZZLE_CLEAN_MIN_TEMP \
|
||||
HOST_KEEPALIVE_FEATURE HOST_ACTION_COMMANDS HOST_PROMPT_SUPPORT \
|
||||
LCD_INFO_MENU ARC_SUPPORT BEZIER_CURVE_SUPPORT EXTENDED_CAPABILITIES_REPORT AUTO_REPORT_TEMPERATURES SDCARD_SORT_ALPHA EMERGENCY_PARSER
|
||||
opt_set GRID_MAX_POINTS_X 16
|
||||
opt_set NOZZLE_TO_PROBE_OFFSET "{ 0, 0, 0 }"
|
||||
opt_set NOZZLE_CLEAN_TEMP 170
|
||||
exec_test $1 $2 "Re-ARM with NOZZLE_AS_PROBE and many features." "$3"
|
||||
|
||||
# clean up
|
||||
|
||||
@@ -22,6 +22,8 @@ opt_add TEMP_CHAMBER_PIN 3
|
||||
opt_add HEATER_CHAMBER_PIN 45
|
||||
opt_set GRID_MAX_POINTS_X 16
|
||||
opt_set FANMUX0_PIN 53
|
||||
opt_set PROBE_REQUIRES_MINTEMP_NOZZLE 150
|
||||
opt_set PROBE_REQUIRES_MINTEMP_BED 50
|
||||
opt_disable USE_WATCHDOG
|
||||
opt_enable REPRAP_DISCOUNT_SMART_CONTROLLER LCD_PROGRESS_BAR LCD_PROGRESS_BAR_TEST \
|
||||
FIX_MOUNTED_PROBE Z_SAFE_HOMING CODEPENDENT_XY_HOMING PIDTEMPBED PROBE_TEMP_COMPENSATION \
|
||||
|
||||
Reference in New Issue
Block a user