mirror of
https://github.com/MarlinFirmware/Marlin.git
synced 2026-01-05 14:17:42 -07:00
Merge https://github.com/MarlinFirmware/Marlin into bugfix-2.1.x-February2
This commit is contained in:
commit
9881ac2632
22 changed files with 171 additions and 71 deletions
|
|
@ -1540,6 +1540,20 @@
|
|||
#define PROBE_DEPLOY_FEEDRATE (133*60) // (mm/min) Probe deploy speed
|
||||
#define PROBE_STOW_FEEDRATE (133*60) // (mm/min) Probe stow speed
|
||||
|
||||
/**
|
||||
* Magnetically Mounted Probe with a Servo mechanism
|
||||
* Probe Deploy and Stow both follow the same basic sequence:
|
||||
* - Rotate the SERVO to its Deployed angle
|
||||
* - Perform XYZ moves to deploy or stow the PROBE
|
||||
* - Rotate the SERVO to its Stowed angle
|
||||
*/
|
||||
//#define MAG_MOUNTED_PROBE_SERVO_NR 0 // Servo Number for this probe
|
||||
#ifdef MAG_MOUNTED_PROBE_SERVO_NR
|
||||
#define MAG_MOUNTED_PROBE_SERVO_ANGLES { 90, 0 } // Servo Angles for Deployed, Stowed
|
||||
#define MAG_MOUNTED_PRE_DEPLOY { PROBE_DEPLOY_FEEDRATE, { 15, 160, 30 } } // Safe position for servo activation
|
||||
#define MAG_MOUNTED_PRE_STOW { PROBE_DEPLOY_FEEDRATE, { 15, 160, 30 } } // Safe position for servo deactivation
|
||||
#endif
|
||||
|
||||
#define MAG_MOUNTED_DEPLOY_1 { PROBE_DEPLOY_FEEDRATE, { 245, 114, 30 } } // Move to side Dock & Attach probe
|
||||
#define MAG_MOUNTED_DEPLOY_2 { PROBE_DEPLOY_FEEDRATE, { 210, 114, 30 } } // Move probe off dock
|
||||
#define MAG_MOUNTED_DEPLOY_3 { PROBE_DEPLOY_FEEDRATE, { 0, 0, 0 } } // Extra move if needed
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@
|
|||
* here we define this default string as the date where the latest release
|
||||
* version was tagged.
|
||||
*/
|
||||
//#define STRING_DISTRIBUTION_DATE "2025-03-18"
|
||||
//#define STRING_DISTRIBUTION_DATE "2025-03-19"
|
||||
|
||||
/**
|
||||
* The protocol for communication to the host. Protocol indicates communication
|
||||
|
|
|
|||
|
|
@ -37,6 +37,7 @@
|
|||
* S<material>
|
||||
* H<hotend temp>
|
||||
* B<bed temp>
|
||||
* C<chamber temp>
|
||||
* F<fan speed>
|
||||
*/
|
||||
void GcodeSuite::M145() {
|
||||
|
|
@ -53,6 +54,10 @@ void GcodeSuite::M145() {
|
|||
if (parser.seenval('B'))
|
||||
mat.bed_temp = constrain(parser.value_int(), BED_MINTEMP, BED_MAX_TARGET);
|
||||
#endif
|
||||
#if HAS_HEATED_CHAMBER
|
||||
if (parser.seenval('C'))
|
||||
mat.chamber_temp = constrain(parser.value_int(), CHAMBER_MINTEMP, CHAMBER_MAX_TARGET);
|
||||
#endif
|
||||
#if HAS_FAN
|
||||
if (parser.seenval('F'))
|
||||
mat.fan_speed = constrain(parser.value_int(), 0, 255);
|
||||
|
|
|
|||
|
|
@ -39,9 +39,16 @@
|
|||
*/
|
||||
void GcodeSuite::M141() {
|
||||
if (DEBUGGING(DRYRUN)) return;
|
||||
// Accept 'I' if temperature presets are defined
|
||||
#if HAS_PREHEAT
|
||||
if (parser.seenval('I')) {
|
||||
const uint8_t index = parser.value_byte();
|
||||
thermalManager.setTargetChamber(ui.material_preset[_MIN(index, PREHEAT_COUNT - 1)].chamber_temp);
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
if (parser.seenval('S')) {
|
||||
thermalManager.setTargetChamber(parser.value_celsius());
|
||||
|
||||
#if ENABLED(PRINTJOB_TIMER_AUTOSTART)
|
||||
/**
|
||||
* Stop the timer at the end of print. Hotend, bed target, and chamber
|
||||
|
|
|
|||
|
|
@ -135,7 +135,10 @@
|
|||
#ifdef Z_PROBE_SERVO_NR
|
||||
#define HAS_Z_SERVO_PROBE 1
|
||||
#endif
|
||||
#if ANY(HAS_Z_SERVO_PROBE, SWITCHING_EXTRUDER, SWITCHING_NOZZLE)
|
||||
#ifdef MAG_MOUNTED_PROBE_SERVO_NR
|
||||
#define HAS_MAG_MOUNTED_SERVO_PROBE 1
|
||||
#endif
|
||||
#if ANY(HAS_Z_SERVO_PROBE, HAS_MAG_MOUNTED_SERVO_PROBE, SWITCHING_EXTRUDER, SWITCHING_NOZZLE)
|
||||
#define HAS_SERVO_ANGLES 1
|
||||
#endif
|
||||
#if !HAS_SERVO_ANGLES
|
||||
|
|
|
|||
|
|
@ -53,6 +53,10 @@
|
|||
#undef NUM_SERVOS
|
||||
#define NUM_SERVOS INCREMENT(Z_PROBE_SERVO_NR)
|
||||
#endif
|
||||
#if HAS_MAG_MOUNTED_SERVO_PROBE && NUM_SERVOS <= MAG_MOUNTED_PROBE_SERVO_NR
|
||||
#undef NUM_SERVOS
|
||||
#define NUM_SERVOS INCREMENT(MAG_MOUNTED_PROBE_SERVO_NR)
|
||||
#endif
|
||||
#if ENABLED(CHAMBER_VENT) && NUM_SERVOS <= CHAMBER_VENT_SERVO_NR
|
||||
#undef NUM_SERVOS
|
||||
#define NUM_SERVOS INCREMENT(CHAMBER_VENT_SERVO_NR)
|
||||
|
|
|
|||
|
|
@ -982,7 +982,7 @@ static_assert(NUM_SERVOS <= NUM_SERVO_PLUGS, "NUM_SERVOS (or some servo index) i
|
|||
/**
|
||||
* Servo deactivation depends on servo endstops, switching nozzle, or switching extruder
|
||||
*/
|
||||
#if ENABLED(DEACTIVATE_SERVOS_AFTER_MOVE) && NONE(HAS_Z_SERVO_PROBE, POLARGRAPH) && !defined(SWITCHING_NOZZLE_SERVO_NR) && !defined(SWITCHING_EXTRUDER_SERVO_NR) && !defined(SWITCHING_TOOLHEAD_SERVO_NR)
|
||||
#if ENABLED(DEACTIVATE_SERVOS_AFTER_MOVE) && NONE(HAS_Z_SERVO_PROBE, POLARGRAPH) && !defined(SWITCHING_NOZZLE_SERVO_NR) && !defined(SWITCHING_EXTRUDER_SERVO_NR) && !defined(SWITCHING_TOOLHEAD_SERVO_NR) && !defined(MAG_MOUNTED_PROBE_SERVO_NR)
|
||||
#error "Z_PROBE_SERVO_NR, switching nozzle, switching toolhead, switching extruder, or POLARGRAPH is required for DEACTIVATE_SERVOS_AFTER_MOVE."
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@
|
|||
* version was tagged.
|
||||
*/
|
||||
#ifndef STRING_DISTRIBUTION_DATE
|
||||
#define STRING_DISTRIBUTION_DATE "2025-03-18"
|
||||
#define STRING_DISTRIBUTION_DATE "2025-03-19"
|
||||
#endif
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -811,6 +811,9 @@ namespace ExtUI {
|
|||
#if HAS_HEATED_BED
|
||||
uint16_t getMaterial_preset_B(const uint16_t index) { return ui.material_preset[index].bed_temp; }
|
||||
#endif
|
||||
#if HAS_HEATED_CHAMBER
|
||||
uint16_t getMaterial_preset_C(const uint16_t index) { return ui.material_preset[index].chamber_temp; }
|
||||
#endif
|
||||
#endif
|
||||
|
||||
feedRate_t getFeedrate_mm_s() { return feedrate_mm_s; }
|
||||
|
|
|
|||
|
|
@ -214,6 +214,9 @@ namespace ExtUI {
|
|||
#if HAS_HEATED_BED
|
||||
uint16_t getMaterial_preset_B(const uint16_t);
|
||||
#endif
|
||||
#if HAS_HEATED_CHAMBER
|
||||
uint16_t getMaterial_preset_C(const uint16_t);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// IDEX Machine Mode
|
||||
|
|
|
|||
|
|
@ -155,6 +155,7 @@ namespace LanguageNarrow_en {
|
|||
LSTR MSG_PREHEAT_M_END_E = _UxGT("Preheat $ End ~");
|
||||
LSTR MSG_PREHEAT_M_ALL = _UxGT("Preheat $ All");
|
||||
LSTR MSG_PREHEAT_M_BEDONLY = _UxGT("Preheat $ Bed");
|
||||
LSTR MSG_PREHEAT_M_CHAMBER = _UxGT("Preheat $ Chmb");
|
||||
LSTR MSG_PREHEAT_M_SETTINGS = _UxGT("Preheat $ Conf");
|
||||
|
||||
LSTR MSG_PREHEAT_HOTEND = _UxGT("Preheat Hotend");
|
||||
|
|
@ -1109,6 +1110,8 @@ namespace LanguageWide_en {
|
|||
LSTR MSG_HOMING_FEEDRATE_Y = _UxGT("Y Homing Feedrate");
|
||||
LSTR MSG_HOMING_FEEDRATE_Z = _UxGT("Z Homing Feedrate");
|
||||
LSTR MSG_EEPROM_INITIALIZED = _UxGT("Default Settings Restored");
|
||||
LSTR MSG_PREHEAT_M_CHAMBER = _UxGT("Preheat $ Chamber");
|
||||
LSTR MSG_PREHEAT_M_SETTINGS = _UxGT("Preheat $ Config");
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -150,10 +150,10 @@ constexpr uint8_t epps = ENCODER_PULSES_PER_STEP;
|
|||
|
||||
void MarlinUI::apply_preheat(const uint8_t m, const uint8_t pmask, const uint8_t e/*=active_extruder*/) {
|
||||
const preheat_t &pre = material_preset[m];
|
||||
TERN_(HAS_HOTEND, if (TEST(pmask, PT_HOTEND)) thermalManager.setTargetHotend(pre.hotend_temp, e));
|
||||
TERN_(HAS_HEATED_BED, if (TEST(pmask, PT_BED)) thermalManager.setTargetBed(pre.bed_temp));
|
||||
//TERN_(HAS_HEATED_CHAMBER, if (TEST(pmask, PT_CHAMBER)) thermalManager.setTargetChamber(pre.chamber_temp));
|
||||
TERN_(HAS_FAN, if (TEST(pmask, PT_FAN)) thermalManager.set_fan_speed(0, pre.fan_speed));
|
||||
TERN_(HAS_HOTEND, if (TEST(pmask, PT_HOTEND)) thermalManager.setTargetHotend(pre.hotend_temp, e));
|
||||
TERN_(HAS_HEATED_BED, if (TEST(pmask, PT_BED)) thermalManager.setTargetBed(pre.bed_temp));
|
||||
TERN_(HAS_HEATED_CHAMBER, if (TEST(pmask, PT_CHAMBER)) thermalManager.setTargetChamber(pre.chamber_temp));
|
||||
TERN_(HAS_FAN, if (TEST(pmask, PT_FAN)) thermalManager.set_fan_speed(0, pre.fan_speed));
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -118,6 +118,9 @@ typedef bool (*statusResetFunc_t)();
|
|||
#if HAS_HEATED_BED
|
||||
celsius_t bed_temp;
|
||||
#endif
|
||||
#if HAS_HEATED_CHAMBER
|
||||
celsius_t chamber_temp;
|
||||
#endif
|
||||
#if HAS_FAN
|
||||
uint16_t fan_speed;
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -451,6 +451,9 @@ void menu_advanced_settings();
|
|||
#if HAS_HEATED_BED
|
||||
EDIT_ITEM(int3, MSG_BED, &ui.material_preset[m].bed_temp, BED_MINTEMP, BED_MAX_TARGET);
|
||||
#endif
|
||||
#if HAS_HEATED_CHAMBER
|
||||
EDIT_ITEM(int3, MSG_CHAMBER, &ui.material_preset[m].chamber_temp, CHAMBER_MINTEMP, CHAMBER_MAX_TARGET);
|
||||
#endif
|
||||
#if ENABLED(EEPROM_SETTINGS)
|
||||
ACTION_ITEM(MSG_STORE_EEPROM, ui.store_settings);
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -234,16 +234,6 @@ void menu_configuration();
|
|||
|
||||
#endif // CUSTOM_MENU_MAIN
|
||||
|
||||
#if ENABLED(ADVANCED_PAUSE_FEATURE)
|
||||
// This menu item is last with an encoder. Otherwise, somewhere in the middle.
|
||||
#if E_STEPPERS == 1 && DISABLED(FILAMENT_LOAD_UNLOAD_GCODES)
|
||||
#define FILAMENT_CHANGE_ITEM() YESNO_ITEM(MSG_FILAMENTCHANGE, menu_change_filament, nullptr, \
|
||||
GET_TEXT_F(MSG_FILAMENTCHANGE), (const char *)nullptr, F("?"))
|
||||
#else
|
||||
#define FILAMENT_CHANGE_ITEM() SUBMENU(MSG_FILAMENTCHANGE, menu_change_filament)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
void menu_main() {
|
||||
const bool busy = printingIsActive();
|
||||
#if HAS_MEDIA
|
||||
|
|
@ -348,7 +338,11 @@ void menu_main() {
|
|||
#endif
|
||||
|
||||
#if ENABLED(ADVANCED_PAUSE_FEATURE)
|
||||
FILAMENT_CHANGE_ITEM();
|
||||
#if E_STEPPERS == 1 && DISABLED(FILAMENT_LOAD_UNLOAD_GCODES)
|
||||
YESNO_ITEM(MSG_FILAMENTCHANGE, menu_change_filament, nullptr, GET_TEXT_F(MSG_FILAMENTCHANGE), (const char *)nullptr, F("?"));
|
||||
#else
|
||||
SUBMENU(MSG_FILAMENTCHANGE, menu_change_filament);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if HAS_TEMPERATURE
|
||||
|
|
@ -381,10 +375,6 @@ void menu_main() {
|
|||
}
|
||||
#endif
|
||||
|
||||
#if ENABLED(LCD_INFO_MENU)
|
||||
SUBMENU(MSG_INFO_MENU, menu_info);
|
||||
#endif
|
||||
|
||||
#if ENABLED(LED_CONTROL_MENU)
|
||||
SUBMENU(MSG_LIGHTS, menu_led);
|
||||
#elif ALL(CASE_LIGHT_MENU, CASELIGHT_USES_BRIGHTNESS)
|
||||
|
|
@ -412,7 +402,6 @@ void menu_main() {
|
|||
#endif
|
||||
|
||||
#if HAS_MEDIA && DISABLED(MEDIA_MENU_AT_TOP)
|
||||
// BEGIN MEDIA MENU
|
||||
if (card_detected) {
|
||||
if (!card_open) {
|
||||
#if ENABLED(MENU_ADDAUTOSTART)
|
||||
|
|
@ -449,7 +438,6 @@ void menu_main() {
|
|||
#endif
|
||||
#endif
|
||||
}
|
||||
// END MEDIA MENU
|
||||
#endif
|
||||
|
||||
#if HAS_SERVICE_INTERVALS
|
||||
|
|
@ -482,7 +470,26 @@ void menu_main() {
|
|||
#endif
|
||||
#endif
|
||||
|
||||
#if HAS_GAMES && DISABLED(LCD_INFO_MENU)
|
||||
#if HAS_MULTI_LANGUAGE
|
||||
SUBMENU(LANGUAGE, menu_language);
|
||||
#endif
|
||||
|
||||
#if ENABLED(HOST_SHUTDOWN_MENU_ITEM) && defined(SHUTDOWN_ACTION)
|
||||
SUBMENU(MSG_HOST_SHUTDOWN, []{
|
||||
MenuItem_confirm::select_screen(
|
||||
GET_TEXT_F(MSG_BUTTON_PROCEED), GET_TEXT_F(MSG_BUTTON_CANCEL),
|
||||
[]{ ui.return_to_status(); hostui.shutdown(); }, nullptr,
|
||||
GET_TEXT_F(MSG_HOST_SHUTDOWN), (const char *)nullptr, F("?")
|
||||
);
|
||||
});
|
||||
#endif
|
||||
|
||||
#if ENABLED(LCD_INFO_MENU)
|
||||
|
||||
SUBMENU(MSG_INFO_MENU, menu_info);
|
||||
|
||||
#elif HAS_GAMES
|
||||
|
||||
#if ENABLED(GAMES_EASTER_EGG)
|
||||
SKIP_ITEM();
|
||||
SKIP_ITEM();
|
||||
|
|
@ -504,20 +511,7 @@ void menu_main() {
|
|||
#endif
|
||||
);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if HAS_MULTI_LANGUAGE
|
||||
SUBMENU(LANGUAGE, menu_language);
|
||||
#endif
|
||||
|
||||
#if ENABLED(HOST_SHUTDOWN_MENU_ITEM) && defined(SHUTDOWN_ACTION)
|
||||
SUBMENU(MSG_HOST_SHUTDOWN, []{
|
||||
MenuItem_confirm::select_screen(
|
||||
GET_TEXT_F(MSG_BUTTON_PROCEED), GET_TEXT_F(MSG_BUTTON_CANCEL),
|
||||
[]{ ui.return_to_status(); hostui.shutdown(); }, nullptr,
|
||||
GET_TEXT_F(MSG_HOST_SHUTDOWN), (const char *)nullptr, F("?")
|
||||
);
|
||||
});
|
||||
#endif
|
||||
|
||||
END_MENU();
|
||||
|
|
|
|||
|
|
@ -45,53 +45,66 @@
|
|||
|
||||
#if HAS_PREHEAT
|
||||
|
||||
void Temperature::lcd_preheat(const uint8_t e, const int8_t indh, const int8_t indb) {
|
||||
UNUSED(e); UNUSED(indh); UNUSED(indb);
|
||||
/**
|
||||
* @fn Temperature::lcd_preheat
|
||||
* @brief Apply the "preheat" parameters for a material preset to the
|
||||
* hotend (or laser), bed, chamber, or all of the above.
|
||||
* @param m Material index
|
||||
* @param targets Bit mask of targets to "preheat" (or turn off)
|
||||
* @param e Extruder index (if needed)
|
||||
*/
|
||||
void Temperature::lcd_preheat(const uint8_t m, const uint8_t targets, const uint8_t e/*=0*/) {
|
||||
UNUSED(e);
|
||||
#if HAS_HOTEND
|
||||
if (indh >= 0 && ui.material_preset[indh].hotend_temp > 0)
|
||||
setTargetHotend(_MIN(thermalManager.hotend_max_target(e), ui.material_preset[indh].hotend_temp), e);
|
||||
if (targets & PreheatTarget::HOTEND) setTargetHotend(ui.material_preset[m].hotend_temp, e);
|
||||
#endif
|
||||
#if HAS_HEATED_BED
|
||||
if (indb >= 0 && ui.material_preset[indb].bed_temp > 0) setTargetBed(ui.material_preset[indb].bed_temp);
|
||||
if (targets & PreheatTarget::BED) setTargetBed(ui.material_preset[m].bed_temp);
|
||||
#endif
|
||||
#if HAS_HEATED_CHAMBER
|
||||
if (targets & PreheatTarget::CHAMBER) setTargetChamber(ui.material_preset[m].chamber_temp);
|
||||
#endif
|
||||
#if HAS_FAN
|
||||
if (indh >= 0) {
|
||||
if (targets & PreheatTarget::HOTEND) {
|
||||
const uint8_t fan_index = active_extruder < (FAN_COUNT) ? active_extruder : 0;
|
||||
if (true
|
||||
#if REDUNDANT_PART_COOLING_FAN
|
||||
&& fan_index != REDUNDANT_PART_COOLING_FAN
|
||||
#endif
|
||||
) set_fan_speed(fan_index, ui.material_preset[indh].fan_speed);
|
||||
) set_fan_speed(fan_index, ui.material_preset[m].fan_speed);
|
||||
}
|
||||
#endif
|
||||
ui.return_to_status();
|
||||
}
|
||||
|
||||
#if HAS_TEMP_HOTEND
|
||||
inline void _preheat_end(const uint8_t m, const uint8_t e) { thermalManager.lcd_preheat(e, m, -1); }
|
||||
void do_preheat_end_m() { _preheat_end(editable.int8, 0); }
|
||||
inline void _preheat_end(const uint8_t e, const uint8_t m) { thermalManager.lcd_preheat(m, PreheatTarget::HOTEND, e); }
|
||||
void do_preheat_end_m() { _preheat_end(0, editable.int8); }
|
||||
#endif
|
||||
#if HAS_HEATED_BED
|
||||
inline void _preheat_bed(const uint8_t m) { thermalManager.lcd_preheat(0, -1, m); }
|
||||
inline void _preheat_bed(const uint8_t m) { thermalManager.lcd_preheat(m, PreheatTarget::BED); }
|
||||
#endif
|
||||
#if HAS_HEATED_CHAMBER
|
||||
inline void _preheat_chamber(const uint8_t m) { thermalManager.lcd_preheat(m, PreheatTarget::CHAMBER); }
|
||||
#endif
|
||||
#if HAS_COOLER
|
||||
inline void _precool_laser(const uint8_t m, const uint8_t e) { thermalManager.lcd_preheat(e, m, -1); }
|
||||
void do_precool_laser_m() { _precool_laser(editable.int8, thermalManager.temp_cooler.target); }
|
||||
inline void _precool_laser(const uint8_t e, const uint8_t m) { thermalManager.lcd_preheat(m, PreheatTarget::HOTEND, e); }
|
||||
void do_precool_laser_m() { _precool_laser(thermalManager.temp_cooler.target, editable.int8); }
|
||||
#endif
|
||||
|
||||
#if HAS_TEMP_HOTEND && HAS_HEATED_BED
|
||||
inline void _preheat_both(const uint8_t m, const uint8_t e) { thermalManager.lcd_preheat(e, m, m); }
|
||||
#if HAS_TEMP_HOTEND && (HAS_HEATED_BED || HAS_HEATED_CHAMBER)
|
||||
inline void _preheat_all(const uint8_t e, const uint8_t m) { thermalManager.lcd_preheat(m, PreheatTarget::ALL, e); }
|
||||
|
||||
// Indexed "Preheat ABC" and "Heat Bed" items
|
||||
#define PREHEAT_ITEMS(M,E) do{ \
|
||||
ACTION_ITEM_N_f(E, ui.get_preheat_label(M), MSG_PREHEAT_M_H, []{ _preheat_both(M, MenuItemBase::itemIndex); }); \
|
||||
ACTION_ITEM_N_f(E, ui.get_preheat_label(M), MSG_PREHEAT_M_END_E, []{ _preheat_end(M, MenuItemBase::itemIndex); }); \
|
||||
ACTION_ITEM_N_f(E, ui.get_preheat_label(M), MSG_PREHEAT_M_H, []{ _preheat_all(MenuItemBase::itemIndex, M); }); \
|
||||
ACTION_ITEM_N_f(E, ui.get_preheat_label(M), MSG_PREHEAT_M_END_E, []{ _preheat_end(MenuItemBase::itemIndex, M); }); \
|
||||
}while(0)
|
||||
|
||||
#elif HAS_MULTI_HOTEND
|
||||
|
||||
// No heated bed, so just indexed "Preheat ABC" items
|
||||
#define PREHEAT_ITEMS(M,E) ACTION_ITEM_N_f(E, ui.get_preheat_label(M), MSG_PREHEAT_M_H, []{ _preheat_end(M, MenuItemBase::itemIndex); })
|
||||
#define PREHEAT_ITEMS(M,E) ACTION_ITEM_N_f(E, ui.get_preheat_label(M), MSG_PREHEAT_M_H, []{ _preheat_end(MenuItemBase::itemIndex, M); })
|
||||
|
||||
#endif
|
||||
|
||||
|
|
@ -107,8 +120,8 @@
|
|||
|
||||
#if HOTENDS == 1
|
||||
|
||||
#if HAS_HEATED_BED
|
||||
ACTION_ITEM_f(ui.get_preheat_label(m), MSG_PREHEAT_M, []{ _preheat_both(editable.int8, 0); });
|
||||
#if HAS_HEATED_BED || HAS_HEATED_CHAMBER
|
||||
ACTION_ITEM_f(ui.get_preheat_label(m), MSG_PREHEAT_M, []{ _preheat_all(0, editable.int8); });
|
||||
ACTION_ITEM_f(ui.get_preheat_label(m), MSG_PREHEAT_M_END, do_preheat_end_m);
|
||||
#else
|
||||
ACTION_ITEM_f(ui.get_preheat_label(m), MSG_PREHEAT_M, do_preheat_end_m);
|
||||
|
|
@ -129,6 +142,10 @@
|
|||
ACTION_ITEM_f(ui.get_preheat_label(m), MSG_PREHEAT_M_BEDONLY, []{ _preheat_bed(editable.int8); });
|
||||
#endif
|
||||
|
||||
#if HAS_HEATED_CHAMBER
|
||||
ACTION_ITEM_f(ui.get_preheat_label(m), MSG_PREHEAT_M_CHAMBER, []{ _preheat_chamber(editable.int8); });
|
||||
#endif
|
||||
|
||||
END_MENU();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@
|
|||
#include "../feature/host_actions.h" // for PROMPT_USER_CONTINUE
|
||||
#endif
|
||||
|
||||
#if HAS_Z_SERVO_PROBE
|
||||
#if HAS_Z_SERVO_PROBE || HAS_MAG_MOUNTED_SERVO_PROBE
|
||||
#include "servo.h"
|
||||
#endif
|
||||
|
||||
|
|
@ -272,6 +272,13 @@ xyz_pos_t Probe::offset; // Initialized by settings.load
|
|||
typedef struct { float fr_mm_min; xyz_pos_t where; } mag_probe_move_t;
|
||||
|
||||
inline void run_deploy_moves() {
|
||||
#ifdef MAG_MOUNTED_PRE_DEPLOY
|
||||
constexpr mag_probe_move_t pre_deploy = MAG_MOUNTED_PRE_DEPLOY;
|
||||
do_blocking_move_to(pre_deploy.where, MMM_TO_MMS(pre_deploy.fr_mm_min));
|
||||
#endif
|
||||
#if HAS_MAG_MOUNTED_SERVO_PROBE
|
||||
servo[MAG_MOUNTED_PROBE_SERVO_NR].move(servo_angles[MAG_MOUNTED_PROBE_SERVO_NR][0]);
|
||||
#endif
|
||||
#ifdef MAG_MOUNTED_DEPLOY_1
|
||||
constexpr mag_probe_move_t deploy_1 = MAG_MOUNTED_DEPLOY_1;
|
||||
do_blocking_move_to(deploy_1.where, MMM_TO_MMS(deploy_1.fr_mm_min));
|
||||
|
|
@ -292,9 +299,19 @@ xyz_pos_t Probe::offset; // Initialized by settings.load
|
|||
constexpr mag_probe_move_t deploy_5 = MAG_MOUNTED_DEPLOY_5;
|
||||
do_blocking_move_to(deploy_5.where, MMM_TO_MMS(deploy_5.fr_mm_min));
|
||||
#endif
|
||||
#if HAS_MAG_MOUNTED_SERVO_PROBE
|
||||
servo[MAG_MOUNTED_PROBE_SERVO_NR].move(servo_angles[MAG_MOUNTED_PROBE_SERVO_NR][1]);
|
||||
#endif
|
||||
}
|
||||
|
||||
inline void run_stow_moves() {
|
||||
#ifdef MAG_MOUNTED_PRE_STOW
|
||||
constexpr mag_probe_move_t pre_stow = MAG_MOUNTED_PRE_STOW;
|
||||
do_blocking_move_to(pre_stow.where, MMM_TO_MMS(pre_stow.fr_mm_min));
|
||||
#endif
|
||||
#if HAS_MAG_MOUNTED_SERVO_PROBE
|
||||
servo[MAG_MOUNTED_PROBE_SERVO_NR].move(servo_angles[MAG_MOUNTED_PROBE_SERVO_NR][0]);
|
||||
#endif
|
||||
#ifdef MAG_MOUNTED_STOW_1
|
||||
constexpr mag_probe_move_t stow_1 = MAG_MOUNTED_STOW_1;
|
||||
do_blocking_move_to(stow_1.where, MMM_TO_MMS(stow_1.fr_mm_min));
|
||||
|
|
@ -315,6 +332,9 @@ xyz_pos_t Probe::offset; // Initialized by settings.load
|
|||
constexpr mag_probe_move_t stow_5 = MAG_MOUNTED_STOW_5;
|
||||
do_blocking_move_to(stow_5.where, MMM_TO_MMS(stow_5.fr_mm_min));
|
||||
#endif
|
||||
#if HAS_MAG_MOUNTED_SERVO_PROBE
|
||||
servo[MAG_MOUNTED_PROBE_SERVO_NR].move(servo_angles[MAG_MOUNTED_PROBE_SERVO_NR][1]);
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif // MAG_MOUNTED_PROBE
|
||||
|
|
@ -541,7 +561,7 @@ bool Probe::set_deployed(const bool deploy, const bool no_return/*=false*/) {
|
|||
#if ENABLED(PROBE_TRIGGERED_WHEN_STOWED_TEST)
|
||||
|
||||
// Only deploy/stow if needed
|
||||
if (PROBE_TRIGGERED() == deploy) {
|
||||
if (PROBE_TRIGGERED() == deploy || !deploy) {
|
||||
if (!deploy) endstops.enable_z_probe(false); // Switch off triggered when stowed probes early
|
||||
// otherwise an Allen-Key probe can't be stowed.
|
||||
probe_specific_action(deploy);
|
||||
|
|
|
|||
|
|
@ -63,6 +63,9 @@
|
|||
#endif
|
||||
constexpr uint16_t sazp[] = Z_SERVO_ANGLES;
|
||||
static_assert(COUNT(sazp) == 2, "Z_SERVO_ANGLES needs 2 angles.");
|
||||
#elif defined(MAG_MOUNTED_PROBE_SERVO_ANGLES)
|
||||
constexpr uint16_t sazp[] = MAG_MOUNTED_PROBE_SERVO_ANGLES;
|
||||
static_assert(COUNT(sazp) == 2, "MAG_MOUNTED_PROBE_SERVO_ANGLES needs 2 angles.");
|
||||
#else
|
||||
constexpr uint16_t sazp[2] = { 0 };
|
||||
#endif
|
||||
|
|
@ -82,6 +85,9 @@
|
|||
#ifndef Z_PROBE_SERVO_NR
|
||||
#define Z_PROBE_SERVO_NR -1
|
||||
#endif
|
||||
#ifndef MAG_MOUNTED_PROBE_SERVO_NR
|
||||
#define MAG_MOUNTED_PROBE_SERVO_NR -1
|
||||
#endif
|
||||
|
||||
#define SASN(J,I) TERN(SWITCHING_NOZZLE_TWO_SERVOS, sasn[J][I], sasn[I])
|
||||
|
||||
|
|
@ -91,6 +97,7 @@
|
|||
: N == SWITCHING_NOZZLE_SERVO_NR ? SASN(0,I) \
|
||||
: N == SWITCHING_NOZZLE_E1_SERVO_NR ? SASN(1,I) \
|
||||
: N == Z_PROBE_SERVO_NR ? sazp[I] \
|
||||
: N == MAG_MOUNTED_PROBE_SERVO_NR ? sazp[I] \
|
||||
: 0 )
|
||||
|
||||
#if ENABLED(EDITABLE_SERVO_ANGLES)
|
||||
|
|
|
|||
|
|
@ -3564,13 +3564,17 @@ void MarlinSettings::reset() {
|
|||
#if HAS_HEATED_BED
|
||||
constexpr uint16_t bpre[] = { REPEAT2_S(1, INCREMENT(PREHEAT_COUNT), _PITEM, TEMP_BED) };
|
||||
#endif
|
||||
#if HAS_HEATED_CHAMBER
|
||||
constexpr uint16_t cpre[] = { REPEAT2_S(1, INCREMENT(PREHEAT_COUNT), _PITEM, TEMP_CHAMBER) };
|
||||
#endif
|
||||
#if HAS_FAN
|
||||
constexpr uint8_t fpre[] = { REPEAT2_S(1, INCREMENT(PREHEAT_COUNT), _PITEM, FAN_SPEED) };
|
||||
#endif
|
||||
for (uint8_t i = 0; i < PREHEAT_COUNT; ++i) {
|
||||
TERN_(HAS_HOTEND, ui.material_preset[i].hotend_temp = hpre[i]);
|
||||
TERN_(HAS_HEATED_BED, ui.material_preset[i].bed_temp = bpre[i]);
|
||||
TERN_(HAS_FAN, ui.material_preset[i].fan_speed = fpre[i]);
|
||||
TERN_(HAS_HOTEND, ui.material_preset[i].hotend_temp = hpre[i]);
|
||||
TERN_(HAS_HEATED_BED, ui.material_preset[i].bed_temp = bpre[i]);
|
||||
TERN_(HAS_HEATED_CHAMBER, ui.material_preset[i].chamber_temp = cpre[i]);
|
||||
TERN_(HAS_FAN, ui.material_preset[i].fan_speed = fpre[i]);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -599,6 +599,15 @@ typedef struct { raw_adc_t raw_min, raw_max; celsius_t mintemp, maxtemp; } temp_
|
|||
#define HAS_FAN_LOGIC 1
|
||||
#endif
|
||||
|
||||
#if HAS_MARLINUI_MENU && HAS_TEMPERATURE && HAS_PREHEAT
|
||||
enum PreheatTarget : uint8_t {
|
||||
HOTEND = (1 << 0),
|
||||
BED = (1 << 1),
|
||||
CHAMBER = (1 << 2),
|
||||
ALL = 0xFF
|
||||
};
|
||||
#endif
|
||||
|
||||
class Temperature {
|
||||
|
||||
public:
|
||||
|
|
@ -1335,7 +1344,8 @@ class Temperature {
|
|||
#endif
|
||||
|
||||
#if HAS_MARLINUI_MENU && HAS_TEMPERATURE && HAS_PREHEAT
|
||||
static void lcd_preheat(const uint8_t e, const int8_t indh, const int8_t indb);
|
||||
// Apply the "preheat" parameters for a material preset to the hotend (or laser), bed, chamber, or all of the above
|
||||
static void lcd_preheat(const uint8_t m, const uint8_t targets, const uint8_t e=0);
|
||||
#endif
|
||||
|
||||
private:
|
||||
|
|
|
|||
|
|
@ -320,13 +320,13 @@
|
|||
#if ENABLED(REPRAPWORLD_GRAPHICAL_LCD)
|
||||
|
||||
#define LCD_PINS_RS 49 // CS chip select /SS chip slave select
|
||||
#define LCD_PINS_ENABLE 51 // SID (MOSI)
|
||||
#define LCD_PINS_EN 51 // SID (MOSI)
|
||||
#define LCD_PINS_D4 52 // SCK (CLK) clock
|
||||
|
||||
#elif ALL(IS_NEWPANEL, PANEL_ONE)
|
||||
|
||||
#define LCD_PINS_RS 40
|
||||
#define LCD_PINS_ENABLE 42
|
||||
#define LCD_PINS_EN 42
|
||||
#define LCD_PINS_D4 65
|
||||
#define LCD_PINS_D5 66
|
||||
#define LCD_PINS_D6 44
|
||||
|
|
@ -337,7 +337,7 @@
|
|||
#if ENABLED(CR10_STOCKDISPLAY)
|
||||
|
||||
#define LCD_PINS_RS 27
|
||||
#define LCD_PINS_ENABLE 29
|
||||
#define LCD_PINS_EN 29
|
||||
#define LCD_PINS_D4 25
|
||||
|
||||
#if !IS_NEWPANEL
|
||||
|
|
@ -347,7 +347,7 @@
|
|||
#elif ENABLED(ZONESTAR_LCD)
|
||||
|
||||
#define LCD_PINS_RS 64
|
||||
#define LCD_PINS_ENABLE 44
|
||||
#define LCD_PINS_EN 44
|
||||
#define LCD_PINS_D4 63
|
||||
#define LCD_PINS_D5 40
|
||||
#define LCD_PINS_D6 42
|
||||
|
|
@ -365,7 +365,7 @@
|
|||
#define DOGLCD_A0 LCD_PINS_DC
|
||||
#else
|
||||
#define LCD_PINS_RS 16
|
||||
#define LCD_PINS_ENABLE 17
|
||||
#define LCD_PINS_EN 17
|
||||
#define LCD_PINS_D4 23
|
||||
#define LCD_PINS_D5 25
|
||||
#define LCD_PINS_D6 27
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ exec_test $1 $2 "Azteeg X5GT Example Configuration" "$3"
|
|||
restore_configs
|
||||
opt_set MOTHERBOARD BOARD_SMOOTHIEBOARD \
|
||||
EXTRUDERS 2 TEMP_SENSOR_0 -5 TEMP_SENSOR_1 -4 TEMP_SENSOR_BED 5 TEMP_0_CS_PIN P1_29 \
|
||||
GRID_MAX_POINTS_X 16 \
|
||||
MAG_MOUNTED_PROBE_SERVO_NR 0 GRID_MAX_POINTS_X 16 \
|
||||
NOZZLE_CLEAN_START_POINT "{ { 10, 10, 3 }, { 10, 10, 3 } }" \
|
||||
NOZZLE_CLEAN_END_POINT "{ { 10, 20, 3 }, { 10, 20, 3 } }"
|
||||
opt_enable TFTGLCD_PANEL_SPI SDSUPPORT ADAPTIVE_FAN_SLOWING REPORT_ADAPTIVE_FAN_SLOWING TEMP_TUNING_MAINTAIN_FAN \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue