This commit is contained in:
Andrew 2026-02-27 20:43:33 -06:00 committed by GitHub
commit 9742e7b57e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
28 changed files with 433 additions and 330 deletions

View file

@ -79,6 +79,8 @@
#include "lcd/dwin/creality/dwin.h"
#elif ENABLED(DWIN_CREALITY_LCD_JYERSUI)
#include "lcd/dwin/jyersui/dwin.h"
#elif ENABLED(DWIN_LCD_PROUI)
#include "lcd/extui/ui_api.h"
#elif ENABLED(SOVOL_SV06_RTS)
#include "lcd/sovol_rts/sovol_rts.h"
#endif
@ -1658,13 +1660,13 @@ void setup() {
SERIAL_ECHO_TERNARY(err, "BL24CXX Check ", "failed", "succeeded", "!\n");
#endif
#if ENABLED(DWIN_CREALITY_LCD)
#if HAS_DWIN_E3V2_BASIC
SETUP_RUN(dwinInitScreen());
#elif ENABLED(SOVOL_SV06_RTS)
SETUP_RUN(rts.init());
#endif
#if HAS_SERVICE_INTERVALS && DISABLED(DWIN_CREALITY_LCD)
#if HAS_SERVICE_INTERVALS && !HAS_DWIN_E3V2_BASIC
SETUP_RUN(ui.reset_status(true)); // Show service messages or keep current status
#endif

View file

@ -875,7 +875,8 @@ G29_TYPE GcodeSuite::G29() {
else {
bedlevel.set_grid(abl.gridSpacing, abl.probe_position_lf);
COPY(bedlevel.z_values, abl.z_values);
TERN_(IS_KINEMATIC, bedlevel.extrapolate_unprobed_bed_level());
if (parser.boolval('K')) bedlevel.extrapolate_unprobed_bed_level();
else if (ENABLED(DWIN_LCD_PROUI) || ENABLED(IS_KINEMATIC)) bedlevel.extrapolate_unprobed_bed_level();
bedlevel.refresh_bed_level();
bedlevel.print_leveling_grid();
@ -1011,7 +1012,7 @@ G29_TYPE GcodeSuite::G29() {
// Restore state after probing
if (!faux) motion.restore_feedrate_and_scaling();
TERN_(HAS_BED_PROBE, probe.move_z_after_probing());
TERN_(Z_AFTER_PROBING, probe.move_z_after_probing());
#ifdef EVENT_GCODE_AFTER_G29
if (DEBUGGING(LEVELING)) DEBUG_ECHOLNPGM("After G29 G-code: ", EVENT_GCODE_AFTER_G29);

View file

@ -91,8 +91,7 @@ void GcodeSuite::G29() {
TERN_(FULL_REPORT_TO_HOST_FEATURE, motion.set_and_report_grblstate(M_PROBE));
int8_t ix, iy;
ix = iy = 0;
int8_t ix = 0, iy = 0;
switch (state) {
case MeshReport:
@ -174,6 +173,11 @@ void GcodeSuite::G29() {
// Save Z for the previous mesh position
bedlevel.set_zigzag_z(mbl_probe_index - 1, motion.position.z);
TERN_(EXTENSIBLE_UI, ExtUI::onMeshUpdate(ix, iy, motion.position.z));
#if ENABLED(DWIN_LCD_PROUI)
dwinPointUpdate(_MIN(mbl_probe_index, GRID_MAX_POINTS), int(GRID_MAX_POINTS), motion.position.z);
#elif ENABLED(EXTENSIBLE_UI)
ExtUI::onMeshUpdate(ix, iy, motion.position.z)
#endif
motion.set_soft_endstop_loose(false);
}
// If there's another point to sample, move there with optional lift.

View file

@ -58,7 +58,14 @@
void GcodeSuite::M48() {
if (motion.homing_needed_error()) return;
#if ALL(DWIN_LCD_PROUI, ADVANCED_PAUSE_FEATURE)
dwinPopupPause(GET_TEXT_F(MSG_M48_TEST));
#endif
if (motion.homing_needed_error()) {
TERN_(DWIN_LCD_PROUI, hmiReturnScreen());
return;
}
const int8_t verbose_level = parser.byteval('V', 1);
if (!WITHIN(verbose_level, 0, 4)) {
@ -286,6 +293,8 @@ void GcodeSuite::M48() {
TERN_(HAS_PTC, ptc.set_enabled(true));
motion.report_position();
TERN_(DWIN_LCD_PROUI, hmiReturnScreen());
}
#endif // Z_MIN_PROBE_REPEATABILITY_TEST

View file

@ -315,7 +315,7 @@ void GcodeSuite::dwell(const millis_t time) {
#endif
}
TERN_(HAS_DWIN_E3V2_BASIC, dwinLevelingDone());
TERN_(DWIN_CREALITY_LCD, dwinLevelingDone());
TERN_(EXTENSIBLE_UI, ExtUI::onLevelingDone());
}

View file

@ -62,14 +62,14 @@ void GcodeSuite::M0_M1() {
#endif
}
#elif ENABLED(DWIN_LCD_PROUI) // ExtUI with icon, string, button title
#elif ENABLED(DWIN_LCD_PROUI) // ProUI with icon, string, button title
if (parser.string_arg)
ExtUI::onUserConfirmRequired(ICON_Continue_1, parser.string_arg, GET_TEXT_F(MSG_USERWAIT));
else
ExtUI::onUserConfirmRequired(ICON_Stop_1, GET_TEXT_F(MSG_STOPPED), GET_TEXT_F(MSG_USERWAIT));
#elif ENABLED(EXTENSIBLE_UI)
#elif ENABLED(EXTENSIBLE_UI) // ExtUI with icon, string, button title
if (parser.string_arg)
ExtUI::onUserConfirmRequired(parser.string_arg); // String in an SRAM buffer

View file

@ -146,6 +146,7 @@
#define ICON_ProbeOffsetZ ICON_StepZ
#define ICON_PIDNozzle ICON_HotendTemp
#define ICON_PIDBed ICON_BedTemp
#define ICON_PIDChamber ICON_PrintSize
#define ICON_FWRetract ICON_StepE
#define ICON_FWRetLength ICON_StepE
#define ICON_FWRetSpeed ICON_Setspeed

View file

@ -437,7 +437,7 @@ void popupPauseOrStop() {
}
#if HAS_HOTEND || HAS_HEATED_BED || HAS_HEATED_CHAMBER
void dwinPopupTemperature(const int_fast8_t heater_id, const uint8_t state) {
void dwinPopupTemperature(const heater_id_t heater_id, const uint8_t state) {
hmiSaveProcessID(ID_WaitResponse);
if (hmiIsChinese()) {
DWINUI::clearMainArea();
@ -456,20 +456,22 @@ void popupPauseOrStop() {
else {
// Chinese "Temp Error"
}
DWINUI::drawIconWB(ICON_Confirm_C, 86, 280);
dwinUpdateLCD();
}
else {
FSTR_P heaterstr = nullptr;
if (TERN0(HAS_HEATED_BED, heater_id == H_BED)) heaterstr = F("Bed");
else if (TERN0(HAS_HEATED_CHAMBER, heater_id == H_CHAMBER)) heaterstr = F("Chamber");
if (TERN0(HAS_HEATED_CHAMBER, heater_id == H_CHAMBER)) heaterstr = F("Chamber");
else if (TERN0(HAS_HEATED_BED, heater_id == H_BED)) heaterstr = F("Bed");
else if (TERN0(HAS_HOTEND, heater_id >= 0)) heaterstr = F("Nozzle");
FSTR_P errorstr;
uint8_t icon;
switch (state) {
case 0: errorstr = GET_TEXT_F(DGUS_MSG_TEMP_TOO_LOW); icon = ICON_TempTooLow; break;
case 1: errorstr = GET_TEXT_F(DGUS_MSG_TEMP_TOO_HIGH); icon = ICON_TempTooHigh; break;
default: errorstr = GET_TEXT_F(MSG_ERR_HEATING_FAILED); icon = ICON_Temperature; break; // May be thermal runaway, temp malfunction, etc.
default: errorstr = GET_TEXT_F(MSG_ERR_HEATING_FAILED); icon = ICON_Info_1; break; // May be thermal runaway, temp malfunction, etc.
}
dwinShowPopup(icon, heaterstr, errorstr, BTN_Continue);
dwinPopupContinue(icon, heaterstr, errorstr);
}
}
#endif
@ -1027,7 +1029,7 @@ void drawPrintFileMenu() {
checkkey = ID_Menu;
if (card.isMounted()) {
if (SET_MENU(fileMenu, MSG_MEDIA_MENU, nr_sd_menu_items() + 1)) {
BACK_ITEM(gotoMainMenu);
menuItemAdd(ICON_Back, GET_TEXT_F(MSG_EXIT_TO_MAIN_MENU), onDrawMenuItem, gotoMainMenu);
for (uint8_t i = 0; i < nr_sd_menu_items(); ++i)
menuItemAdd(onDrawFileName, onClickSDItem);
}
@ -1242,16 +1244,13 @@ void drawMainArea() {
#if ENABLED(PROUI_ITEM_PLOT)
case ID_PlotProcess:
switch (hmiValue.tempControl) {
#if ENABLED(PIDTEMP)
case PIDTEMP_START: drawHPlot(); break;
#endif
#if ENABLED(PIDTEMPBED)
case PIDTEMPBED_START: drawBPlot(); break;
#endif
#if ENABLED(PIDTEMPCHAMBER)
case PIDTEMPCHAMBER_START: drawCPlot(); break;
#endif
} break;
TERN_(PIDTEMP, case PID_STARTED:)
TERN_(MPCTEMP, case MPC_STARTED:) drawHotendPlot(); break;
OPTCODE(PIDTEMPBED, case PID_BED_STARTED: drawBedPlot(); break)
OPTCODE(PIDTEMPCHAMBER, case PID_CHAMBER_STARTED: drawChamberPlot(); break)
default: break;
}
break;
#endif
case ID_Popup: popupDraw(); break;
#if HAS_LOCKSCREEN
@ -1319,16 +1318,16 @@ void eachMomentUpdate() {
#endif
#if PROUI_TUNING_GRAPH
if (checkkey == ID_PIDProcess) {
TERN_(PIDTEMP, if (hmiValue.tempControl == PIDTEMP_START) plot.update(thermalManager.wholeDegHotend(0)));
TERN_(PIDTEMPBED, if (hmiValue.tempControl == PIDTEMPBED_START) plot.update(thermalManager.wholeDegBed()));
TERN_(PIDTEMPCHAMBER, if (hmiValue.tempControl == PIDTEMPCHAMBER_START) plot.update(thermalManager.wholeDegChamber()));
TERN_(PIDTEMP, if (hmiValue.tempControl == PID_STARTED) plot.update(thermalManager.wholeDegHotend(0)));
TERN_(PIDTEMPBED, if (hmiValue.tempControl == PID_BED_STARTED) plot.update(thermalManager.wholeDegBed()));
TERN_(PIDTEMPCHAMBER, if (hmiValue.tempControl == PID_CHAMBER_STARTED) plot.update(thermalManager.wholeDegChamber()));
}
TERN_(MPCTEMP, if (checkkey == ID_MPCProcess) plot.update(thermalManager.wholeDegHotend(0)));
#if ENABLED(PROUI_ITEM_PLOT)
if (checkkey == ID_PlotProcess) {
TERN_(PIDTEMP, if (hmiValue.tempControl == PIDTEMP_START) { plot.update(thermalManager.wholeDegHotend(0)); })
TERN_(PIDTEMPBED, if (hmiValue.tempControl == PIDTEMPBED_START) { plot.update(thermalManager.wholeDegBed()); })
TERN_(PIDTEMPCHAMBER, if (hmiValue.tempControl == PIDTEMPCHAMBER_START) { plot.update(thermalManager.wholeDegChamber()); })
TERN_(PIDTEMP, if (hmiValue.tempControl == PID_STARTED) { plot.update(thermalManager.wholeDegHotend(0)); })
TERN_(PIDTEMPBED, if (hmiValue.tempControl == PID_BED_STARTED) { plot.update(thermalManager.wholeDegBed()); })
TERN_(PIDTEMPCHAMBER, if (hmiValue.tempControl == PID_CHAMBER_STARTED) { plot.update(thermalManager.wholeDegChamber()); })
TERN_(MPCTEMP, if (hmiValue.tempControl == MPC_STARTED) { plot.update(thermalManager.wholeDegHotend(0)); })
if (hmiFlag.abort_flag || hmiFlag.pause_flag || print_job_timer.isPaused()) {
hmiReturnScreen();
@ -1427,8 +1426,8 @@ void eachMomentUpdate() {
}
else {
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 70, GET_TEXT_F(MSG_OUTAGE_RECOVERY));
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 147, F("It looks like the last"));
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 167, F("file was interrupted."));
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 147, GET_TEXT_F(MSG_OUTAGE_RECOVERY2));
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 167, GET_TEXT_F(MSG_OUTAGE_RECOVERY3));
DWINUI::drawButton(BTN_Cancel, 26, 280);
DWINUI::drawButton(BTN_Continue, 146, 280);
}
@ -1569,11 +1568,16 @@ void dwinLevelingDone() {
}
#if HAS_MESH
void dwinMeshUpdate(const int8_t cpos, const int8_t tpos, const float zval) {
ui.set_status(
&MString<32>(GET_TEXT_F(MSG_PROBING_POINT), ' ', cpos, '/', tpos, F(" Z="), p_float_t(zval, 2))
);
void dwinMeshUpdate(const int8_t xpos, const int8_t ypos, const float zval) {
ui.set_status(TS("X:", p_float_t(xpos, 1), " Y:", p_float_t(ypos, 1), " Z:", p_float_t(zval, 3)));
}
#if ENABLED(MESH_BED_LEVELING)
void dwinPointUpdate(const int8_t cpos, const int8_t tpos, const float zval) {
ui.set_status(
TS(GET_TEXT_F(MSG_PROBING_POINT), F(" "), cpos, F("/"), tpos, F(" Z="), p_float_t(zval, 2))
);
}
#endif
#endif
// PID/MPC process
@ -1593,34 +1597,34 @@ void dwinLevelingDone() {
#if ENABLED(MPC_AUTOTUNE)
case MPC_STARTED:
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 70, GET_TEXT_F(MSG_MPC_AUTOTUNE));
DWINUI::drawString(hmiData.colorPopupTxt, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, F("MPC target: Celsius"));
DWINUI::drawString(hmiData.colorPopupTxt, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, GET_TEXT_F(MSG_MPC_TARGET));
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 92, GET_TEXT_F(MSG_PID_FOR_NOZZLE));
_maxtemp = thermalManager.hotend_maxtemp[0];
_target = 200;
break;
#endif
#if ENABLED(PIDTEMP)
case PIDTEMP_START:
case PID_STARTED:
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 70, GET_TEXT_F(MSG_PID_AUTOTUNE));
DWINUI::drawString(hmiData.colorPopupTxt, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, F("PID target: Celsius"));
DWINUI::drawString(hmiData.colorPopupTxt, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, GET_TEXT_F(MSG_PID_TARGET));
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 92, GET_TEXT_F(MSG_PID_FOR_NOZZLE));
_maxtemp = thermalManager.hotend_maxtemp[0];
_target = hmiData.hotendPIDT;
break;
#endif
#if ENABLED(PIDTEMPBED)
case PIDTEMPBED_START:
case PID_BED_STARTED:
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 70, GET_TEXT_F(MSG_PID_AUTOTUNE));
DWINUI::drawString(hmiData.colorPopupTxt, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, F("PID target: Celsius"));
DWINUI::drawString(hmiData.colorPopupTxt, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, GET_TEXT_F(MSG_PID_TARGET));
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 92, GET_TEXT_F(MSG_PID_FOR_BED));
_maxtemp = BED_MAXTEMP;
_target = hmiData.bedPIDT;
break;
#endif
#if ENABLED(PIDTEMPCHAMBER)
case PIDTEMPCHAMBER_START:
case PID_CHAMBER_STARTED:
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 70, GET_TEXT_F(MSG_PID_AUTOTUNE));
DWINUI::drawString(hmiData.colorPopupTxt, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, F("PID target: Celsius"));
DWINUI::drawString(hmiData.colorPopupTxt, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, GET_TEXT_F(MSG_PID_TARGET));
DWINUI::drawCenteredString(hmiData.colorPopupTxt, 92, GET_TEXT_F(MSG_PID_FOR_CHAMBER));
_maxtemp = CHAMBER_MAXTEMP;
_target = hmiData.chamberPIDT;
@ -1646,7 +1650,7 @@ void dwinLevelingDone() {
#if ENABLED(MPCTEMP)
case MPC_STARTED:
#elif ENABLED(PIDTEMP)
case PIDTEMP_START:
case PID_STARTED:
#endif
title.showCaption(GET_TEXT_F(MSG_HOTEND_TEMP_GRAPH));
DWINUI::drawCenteredString(3, hmiData.colorPopupTxt, 75, GET_TEXT_F(MSG_TEMP_NOZZLE));
@ -1654,7 +1658,7 @@ void dwinLevelingDone() {
_target = thermalManager.degTargetHotend(0);
break;
#if ENABLED(PIDTEMPBED)
case PIDTEMPBED_START:
case PID_BED_STARTED:
title.showCaption(GET_TEXT_F(MSG_BED_TEMP_GRAPH));
DWINUI::drawCenteredString(3, hmiData.colorPopupTxt, 75, GET_TEXT_F(MSG_TEMP_BED));
_maxtemp = BED_MAX_TARGET;
@ -1662,7 +1666,7 @@ void dwinLevelingDone() {
break;
#endif
#if ENABLED(PIDTEMPCHAMBER)
case PIDTEMPCHAMBER_START:
case PID_CHAMBER_STARTED:
title.showCaption(GET_TEXT_F(MSG_CHAMBER_TEMP_GRAPH));
DWINUI::drawCenteredString(3, hmiData.colorPopupTxt, 75, GET_TEXT_F(MSG_TEMP_CHAMBER));
_maxtemp = CHAMBER_MAX_TARGET;
@ -1672,22 +1676,18 @@ void dwinLevelingDone() {
default: break;
}
dwinDrawString(false, 2, hmiData.colorPopupTxt, hmiData.colorPopupBg, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, F("Target: Celsius"));
dwinDrawString(false, 2, hmiData.colorPopupTxt, hmiData.colorPopupBg, gfrm.x, gfrm.y - DWINUI::fontHeight() - 4, GET_TEXT_F(MSG_TARGET));
plot.draw(gfrm, _maxtemp, _target);
DWINUI::drawInt(false, 2, hmiData.colorStatusTxt, hmiData.colorPopupBg, 3, gfrm.x + 80, gfrm.y - DWINUI::fontHeight() - 4, _target);
DWINUI::drawButton(BTN_Continue, 86, 305);
}
void drawHPlot() {
TERN_(PIDTEMP, dwinDrawPlot(PIDTEMP_START));
void drawHotendPlot() {
TERN_(PIDTEMP, dwinDrawPlot(PID_STARTED));
TERN_(MPCTEMP, dwinDrawPlot(MPC_STARTED));
}
void drawBPlot() {
TERN_(PIDTEMPBED, dwinDrawPlot(PIDTEMPBED_START));
}
void drawCPlot() {
TERN_(PIDTEMPCHAMBER, dwinDrawPlot(PIDTEMPCHAMBER_START));
}
TERN_(PIDTEMPBED, void drawBedPlot() { dwinDrawPlot(PID_BED_STARTED); })
TERN_(PIDTEMPCHAMBER, void drawChamberPlot() { dwinDrawPlot(PID_CHAMBER_STARTED); })
#endif // PROUI_ITEM_PLOT
@ -1715,7 +1715,7 @@ void dwinLevelingDone() {
hmiValue.tempControl = result;
switch (result) {
#if ENABLED(PIDTEMP)
case PIDTEMP_START:
case PID_STARTED:
hmiSaveProcessID(ID_PIDProcess);
#if PROUI_TUNING_GRAPH
dwinDrawPIDMPCPopup();
@ -1725,28 +1725,36 @@ void dwinLevelingDone() {
break;
#endif
#if ENABLED(PIDTEMPBED)
case PIDTEMPBED_START:
case PID_BED_STARTED:
hmiSaveProcessID(ID_PIDProcess);
#if PROUI_TUNING_GRAPH
dwinDrawPIDMPCPopup();
#else
dwinDrawPopup(ICON_TempTooHigh, GET_TEXT_F(MSG_PID_AUTOTUNE), GET_TEXT_F(MSG_PID_FOR_BED));
#endif
break;
#endif
#if ENABLED(PIDTEMPCHAMBER)
case PIDTEMPCHAMBER_START:
case PID_CHAMBER_STARTED:
hmiSaveProcessID(ID_PIDProcess);
#if PROUI_TUNING_GRAPH
dwinDrawPIDMPCPopup();
#else
dwinDrawPopup(ICON_TempTooHigh, GET_TEXT_F(MSG_PID_AUTOTUNE), GET_TEXT_F(MSG_PID_FOR_CHAMBER));
#endif
break;
#endif
case PID_BAD_HEATER_ID:
checkkey = last_checkkey;
dwinPopupConfirm(ICON_TempTooLow, GET_TEXT_F(MSG_PID_AUTOTUNE_FAILED), GET_TEXT_F(MSG_PID_BAD_HEATER_ID));
dwinPopupContinue(ICON_TempTooLow, GET_TEXT_F(MSG_PID_AUTOTUNE_FAILED), GET_TEXT_F(MSG_PID_BAD_HEATER_ID));
break;
case PID_TUNING_TIMEOUT:
checkkey = last_checkkey;
dwinPopupConfirm(ICON_TempTooHigh, GET_TEXT_F(MSG_ERROR), GET_TEXT_F(MSG_PID_TIMEOUT));
dwinPopupContinue(ICON_TempTooHigh, GET_TEXT_F(MSG_ERROR), GET_TEXT_F(MSG_PID_TIMEOUT));
break;
case PID_TEMP_TOO_HIGH:
checkkey = last_checkkey;
dwinPopupConfirm(ICON_TempTooHigh, GET_TEXT_F(MSG_PID_AUTOTUNE_FAILED), GET_TEXT_F(DGUS_MSG_TEMP_TOO_HIGH));
dwinPopupContinue(ICON_TempTooHigh, GET_TEXT_F(MSG_PID_AUTOTUNE_FAILED), GET_TEXT_F(DGUS_MSG_TEMP_TOO_HIGH));
break;
case AUTOTUNE_DONE:
checkkey = last_checkkey;
@ -1771,17 +1779,17 @@ void dwinLevelingDone() {
#if PROUI_TUNING_GRAPH
dwinDrawPIDMPCPopup();
#else
dwinDrawPopup(ICON_TempTooHigh, GET_TEXT_F(MSG_MPC_AUTOTUNE), F("for Nozzle is running."));
dwinDrawPopup(ICON_TempTooHigh, GET_TEXT_F(MSG_MPC_AUTOTUNE), GET_TEXT_F(MSG_PID_FOR_NOZZLE));
#endif
break;
case MPC_TEMP_ERROR:
checkkey = last_checkkey;
dwinPopupConfirm(ICON_TempTooHigh, GET_TEXT_F(MSG_PID_AUTOTUNE_FAILED), F(STR_MPC_TEMPERATURE_ERROR));
dwinPopupContinue(ICON_TempTooHigh, GET_TEXT_F(MSG_PID_AUTOTUNE_FAILED), F(STR_MPC_TEMPERATURE_ERROR));
ui.reset_alert_level();
break;
case MPC_INTERRUPTED:
checkkey = last_checkkey;
dwinPopupConfirm(ICON_TempTooHigh, GET_TEXT_F(MSG_ERROR), F(STR_MPC_AUTOTUNE_INTERRUPTED));
dwinPopupContinue(ICON_TempTooHigh, GET_TEXT_F(MSG_ERROR), F(STR_MPC_AUTOTUNE_INTERRUPTED));
ui.reset_alert_level();
break;
case AUTOTUNE_DONE:
@ -1791,6 +1799,7 @@ void dwinLevelingDone() {
break;
default:
checkkey = last_checkkey;
dwinPopupConfirm(ICON_Info_0, GET_TEXT_F(MSG_ERROR), GET_TEXT_F(MSG_STOPPING));
ui.reset_alert_level();
break;
}
@ -1850,7 +1859,7 @@ void dwinPrintAborted() {
#if HAS_FILAMENT_SENSOR
// Filament Runout process
void dwinFilamentRunout(const uint8_t extruder) { LCD_MESSAGE(MSG_RUNOUT_SENSOR); }
void dwinFilamentRunout() { LCD_MESSAGE(MSG_RUNOUT_SENSOR); }
#endif
void dwinSetColorDefaults() {
@ -1874,13 +1883,14 @@ void dwinSetColorDefaults() {
hmiData.colorCoordinate = defColorCoordinate;
}
static_assert(ExtUI::eeprom_data_size >= sizeof(hmi_data_t), "Insufficient space in EEPROM for UI parameters");
static_assert(EXTUI_EEPROM_DATA_SIZE >= sizeof(hmi_data_t), "Insufficient space in EEPROM for UI parameters");
void dwinSetDataDefaults() {
dwinSetColorDefaults();
DWINUI::setColors(hmiData.colorText, hmiData.colorBackground, hmiData.colorStatusBg);
TERN_(PIDTEMP, hmiData.hotendPIDT = DEF_HOTENDPIDT);
TERN_(PIDTEMPBED, hmiData.bedPIDT = DEF_BEDPIDT);
TERN_(PIDTEMPCHAMBER, hmiData.chamberPIDT = DEF_CHAMBERPIDT);
TERN_(HAS_PID_HEATING, hmiData.pidCycles = DEF_PIDCYCLES);
#if ENABLED(PREVENT_COLD_EXTRUSION)
hmiData.extMinT = EXTRUDE_MINTEMP;
@ -1995,18 +2005,6 @@ void dwinRedrawScreen() {
#if ENABLED(ADVANCED_PAUSE_FEATURE)
void dwinPopupPause(FSTR_P const fmsg, uint8_t button/*=0*/) {
hmiSaveProcessID(button ? ID_WaitResponse : ID_NothingToDo);
dwinShowPopup(ICON_Pause_1, GET_TEXT_F(MSG_ADVANCED_PAUSE), fmsg, button);
}
void drawPopupFilamentPurge() {
dwinDrawPopup(ICON_AutoLeveling, GET_TEXT_F(MSG_ADVANCED_PAUSE), GET_TEXT_F(MSG_FILAMENT_CHANGE_PURGE_CONTINUE));
DWINUI::drawButton(BTN_Purge, 26, 280);
DWINUI::drawButton(BTN_Continue, 146, 280);
drawSelectHighlight(true);
}
void onClickFilamentPurge() {
if (hmiFlag.select_flag)
pause_menu_response = PAUSE_RESPONSE_EXTRUDE_MORE; // "Purge More" button
@ -2026,7 +2024,7 @@ void dwinRedrawScreen() {
#if HAS_MESH
void _dwinMeshViewer() {
if (!leveling_is_valid())
dwinPopupContinue(ICON_Leveling_1, GET_TEXT_F(MSG_MESH_VIEWER), GET_TEXT_F(MSG_NO_VALID_MESH));
dwinPopupConfirm(ICON_Leveling_1, GET_TEXT_F(MSG_MESH_VIEWER), GET_TEXT_F(MSG_NO_VALID_MESH));
else {
hmiSaveProcessID(ID_WaitResponse);
meshViewer.draw();
@ -2532,10 +2530,13 @@ void setFlow() { setPIntOnClick(FLOW_EDIT_MIN, FLOW_EDIT_MAX, []{ planner.refres
void trammingwizard() {
if (hmiData.fullManualTramming) {
LCD_MESSAGE_F("Disable manual tramming");
LCD_MESSAGE(MSG_DISABLE_MANUAL_TRAMMING);
return;
}
bed_mesh_t zval = {0};
LCD_MESSAGE(MSG_TRAMMING_WIZARD_START);
DWINUI::clearMainArea();
static bed_mesh_t zval = {};
probe.stow();
zval[0][0] = tram(0);
checkkey = ID_NothingToDo;
meshViewer.drawMesh(zval, 2, 2);
@ -2546,8 +2547,8 @@ void setFlow() { setPIntOnClick(FLOW_EDIT_MIN, FLOW_EDIT_MAX, []{ planner.refres
zval[0][1] = tram(3);
meshViewer.drawMesh(zval, 2, 2);
DWINUI::drawCenteredString(140, F("Calculating average"));
DWINUI::drawCenteredString(160, F("and relative heights"));
DWINUI::drawCenteredString(140, GET_TEXT_F(MSG_CALCULATING_AVERAGE));
DWINUI::drawCenteredString(160, GET_TEXT_F(MSG_AND_RELATIVE_HEIGHTS));
safe_delay(1000);
float avg = 0.0f;
for (uint8_t x = 0; x < 2; ++x) for (uint8_t y = 0; y < 2; ++y) avg += zval[x][y];
@ -2561,8 +2562,8 @@ void setFlow() { setPIntOnClick(FLOW_EDIT_MIN, FLOW_EDIT_MAX, []{ planner.refres
#endif
if (ABS(meshViewer.max - meshViewer.min) < BED_TRAMMING_PROBE_TOLERANCE) {
DWINUI::drawCenteredString(140, F("Corners leveled"));
DWINUI::drawCenteredString(160, F("Tolerance achieved!"));
DWINUI::drawCenteredString(140, GET_TEXT_F(MSG_CORNERS_LEVELED));
DWINUI::drawCenteredString(160, GET_TEXT_F(MSG_TOLERANCE_ACHIEVED));
}
else {
uint8_t p = 0;
@ -2584,9 +2585,9 @@ void setFlow() { setPIntOnClick(FLOW_EDIT_MIN, FLOW_EDIT_MAX, []{ planner.refres
case 0b11 : plabel = GET_TEXT_F(MSG_TRAM_BR); break;
default : plabel = F(""); break;
}
DWINUI::drawCenteredString(120, F("Corners not leveled"));
DWINUI::drawCenteredString(140, F("Knob adjustment required"));
DWINUI::drawCenteredString(COLOR_GREEN, 160, s ? F("Lower") : F("Raise"));
DWINUI::drawCenteredString(120, GET_TEXT_F(MSG_CORNERS_NOT_LEVELED));
DWINUI::drawCenteredString(140, GET_TEXT_F(MSG_KNOB_ADJUSTMENT_REQUIRED));
DWINUI::drawCenteredString(COLOR_GREEN, 160, s ? GET_TEXT_F(MSG_LOWER) : GET_TEXT_F(MSG_RAISE));
DWINUI::drawCenteredString(COLOR_GREEN, 180, plabel);
}
DWINUI::drawButton(BTN_Continue, 86, 305);
@ -3193,8 +3194,11 @@ void drawPrepareMenu() {
#endif
MENU_ITEM(ICON_Cool, MSG_COOLDOWN, onDrawCooldown, doCoolDown);
#if ALL(PROUI_TUNING_GRAPH, PROUI_ITEM_PLOT)
MENU_ITEM(ICON_PIDNozzle, MSG_HOTEND_TEMP_GRAPH, onDrawMenuItem, drawHPlot);
MENU_ITEM(ICON_PIDBed, MSG_BED_TEMP_GRAPH, onDrawMenuItem, drawBPlot);
#if ANY(PIDTEMP, MPCTEMP)
MENU_ITEM(ICON_PIDNozzle, MSG_HOTEND_TEMP_GRAPH, onDrawMenuItem, drawHotendPlot);
#endif
TERN_(PIDTEMPBED, MENU_ITEM(ICON_PIDBed, MSG_BED_TEMP_GRAPH, onDrawMenuItem, drawBedPlot));
TERN_(PIDTEMPCHAMBER, MENU_ITEM(ICON_PIDChamber, MSG_CHAMBER_TEMP_GRAPH, onDrawMenuItem, drawChamberPlot));
#endif
MENU_ITEM(ICON_Language, MSG_UI_LANGUAGE, onDrawLanguage, setLanguage);
}
@ -3371,7 +3375,7 @@ void drawMoveMenu() {
#endif
}
updateMenu(moveMenu);
if (!motion.all_axes_trusted()) LCD_MESSAGE_F("WARNING: Current position unknown. Home axes.");
if (!motion.all_axes_trusted()) LCD_MESSAGE(MSG_POSITION_UNKNOWN);
}
#if HAS_HOME_OFFSET
@ -3581,8 +3585,11 @@ void drawTuneMenu() {
EDIT_ITEM(ICON_RemainTime, MSG_SCREEN_TIMEOUT, onDrawPIntMenu, setTimer, &ui.backlight_timeout_minutes);
#endif
#if ALL(PROUI_TUNING_GRAPH, PROUI_ITEM_PLOT)
MENU_ITEM(ICON_PIDNozzle, MSG_HOTEND_TEMP_GRAPH, onDrawMenuItem, drawHPlot);
MENU_ITEM(ICON_PIDBed, MSG_BED_TEMP_GRAPH, onDrawMenuItem, drawBPlot);
#if ANY(PIDTEMP, MPCTEMP)
MENU_ITEM(ICON_PIDNozzle, MSG_HOTEND_TEMP_GRAPH, onDrawMenuItem, drawHotendPlot);
#endif
TERN_(PIDTEMPBED, MENU_ITEM(ICON_PIDBed, MSG_BED_TEMP_GRAPH, onDrawMenuItem, drawBedPlot));
TERN_(PIDTEMPCHAMBER, MENU_ITEM(ICON_PIDChamber, MSG_CHAMBER_TEMP_GRAPH, onDrawMenuItem, drawChamberPlot));
#endif
#if ENABLED(CASE_LIGHT_MENU)
EDIT_ITEM(ICON_CaseLight, MSG_CASE_LIGHT, onDrawChkbMenu, setCaseLight, &caselight.on);
@ -4217,7 +4224,7 @@ void drawMaxAccelMenu() {
if (SET_MENU_F(chamberPIDMenu, STR_CHAMBER_PID " Settings", items)) {
BACK_ITEM(drawAdvancedSettingsMenu);
#if ENABLED(PID_AUTOTUNE_MENU)
MENU_ITEM_F(ICON_PIDChamber, STR_CHAMBER_PID, onDrawMenuItem,chamberPID);
MENU_ITEM_F(ICON_PIDChamber, STR_CHAMBER_PID, onDrawMenuItem, chamberPID);
EDIT_ITEM(ICON_Temperature, MSG_TEMPERATURE, onDrawPIntMenu, setChamberPIDT, &hmiData.chamberPIDT);
EDIT_ITEM(ICON_PIDCycles, MSG_PID_CYCLE, onDrawPIntMenu, setPIDCycles, &hmiData.pidCycles);
#endif
@ -4250,7 +4257,7 @@ void drawMaxAccelMenu() {
EDIT_ITEM(ICON_Zoffset, MSG_BABYSTEP_PROBE_Z, onDrawPFloat2Menu, setZOffset, &BABY_Z_VAR);
}
updateMenu(zOffsetWizMenu);
if (!motion.axis_is_trusted(Z_AXIS)) LCD_MESSAGE_F("WARNING: Z position unknown, move Z to home");
if (!motion.axis_is_trusted(Z_AXIS)) LCD_MESSAGE(MSG_POSITION_UNKNOWN_Z);
}
#endif
@ -4374,7 +4381,17 @@ void drawMaxAccelMenu() {
#endif // AUTO_BED_LEVELING_UBL
#if HAS_MESH
#if ENABLED(AUTO_BED_LEVELING_3POINT)
#define TITLE_MSG MSG_3POINT_LEVELING
#elif ENABLED(AUTO_BED_LEVELING_LINEAR)
#define TITLE_MSG MSG_LINEAR_LEVELING
#elif ENABLED(AUTO_BED_LEVELING_BILINEAR)
#define TITLE_MSG MSG_BILINEAR_LEVELING
#elif ENABLED(AUTO_BED_LEVELING_UBL)
#define TITLE_MSG MSG_UBL_LEVELING
#else
#define TITLE_MSG MSG_MESH_LEVELING
#endif
void drawMeshSetMenu() {
constexpr uint8_t items = (1
+ ENABLED(PREHEAT_BEFORE_LEVELING)
@ -4386,7 +4403,7 @@ void drawMaxAccelMenu() {
+ ENABLED(USE_GRID_MESHVIEWER)
);
checkkey = ID_Menu;
if (SET_MENU(meshMenu, MSG_MESH_LEVELING, items)) {
if (SET_MENU(meshMenu, TITLE_MSG, items)) {
BACK_ITEM(drawAdvancedSettingsMenu);
#if ENABLED(PREHEAT_BEFORE_LEVELING)
EDIT_ITEM(ICON_Temperature, MSG_UBL_SET_TEMP_BED, onDrawPIntMenu, setBedLevT, &hmiData.bedLevT);
@ -4418,7 +4435,10 @@ void drawMaxAccelMenu() {
#if ENABLED(PROUI_MESH_EDIT)
void drawEditMeshMenu() {
if (!leveling_is_valid()) { LCD_MESSAGE(MSG_UBL_MESH_INVALID); return; }
if (!leveling_is_valid()) {
LCD_MESSAGE(MSG_UBL_MESH_INVALID);
return dwinPopupConfirm(ICON_Leveling_1, GET_TEXT_F(MSG_NO_VALID_MESH), GET_TEXT_F(MSG_UBL_LOAD_MESH));
}
set_bed_leveling_enabled(false);
checkkey = ID_Menu;
if (SET_MENU(editMeshMenu, MSG_EDIT_MESH, 4)) {

View file

@ -74,18 +74,12 @@ enum processID : uint8_t {
#if ANY(HAS_PID_HEATING, MPC_AUTOTUNE)
enum TempControl {
enum tempcontrol_t : uint8_t {
AUTOTUNE_DONE,
#if HAS_PID_HEATING
#if ENABLED(PIDTEMP)
PIDTEMP_START,
#endif
#if ENABLED(PIDTEMPBED)
PIDTEMPBED_START,
#endif
#if ENABLED(PIDTEMPCHAMBER)
PIDTEMPCHAMBER_START,
#endif
OPTITEM(PIDTEMP, PID_STARTED)
OPTITEM(PIDTEMPBED, PID_BED_STARTED)
OPTITEM(PIDTEMPCHAMBER, PID_CHAMBER_STARTED)
PID_BAD_HEATER_ID,
PID_TEMP_TOO_HIGH,
PID_TUNING_TIMEOUT,
@ -95,11 +89,8 @@ enum processID : uint8_t {
MPC_TEMP_ERROR,
MPC_INTERRUPTED,
#endif
TEMPCONTROL_COUNT
};
typedef bits_t(TEMPCONTROL_COUNT) tempcontrol_t;
#endif
#define DWIN_CHINESE 123
@ -186,7 +177,7 @@ typedef struct {
typedef struct {
rgb_t color; // Color
#if ANY(HAS_PID_HEATING, MPCTEMP)
#if ANY(HAS_PID_HEATING, MPC_AUTOTUNE)
tempcontrol_t tempControl = AUTOTUNE_DONE;
#endif
uint8_t select = 0; // Auxiliary selector variable
@ -285,10 +276,12 @@ void updateVariable();
void dwinInitScreen();
void dwinHandleScreen();
void dwinCheckStatusMessage();
void dwinDrawStatusMessage();
void dwinHomingStart();
void dwinHomingDone();
#if HAS_MESH
void dwinMeshUpdate(const int8_t cpos, const int8_t tpos, const float zval);
void dwinMeshUpdate(const int8_t xpos, const int8_t ypos, const float zval);
void dwinPointUpdate(const int8_t cpos, const int8_t tpos, const float zval);
#endif
void dwinLevelingStart();
void dwinLevelingDone();
@ -298,7 +291,7 @@ void dwinPrintResume();
void dwinPrintFinished();
void dwinPrintAborted();
#if HAS_FILAMENT_SENSOR
void dwinFilamentRunout(const uint8_t extruder);
void dwinFilamentRunout();
#endif
void dwinPrintHeader(const char * const cstr=nullptr);
void dwinSetColorDefaults();
@ -308,8 +301,6 @@ void dwinSetDataDefaults();
void dwinRebootScreen();
#if ENABLED(ADVANCED_PAUSE_FEATURE)
void dwinPopupPause(FSTR_P const fmsg, uint8_t button=0);
void drawPopupFilamentPurge();
void gotoFilamentPurge();
#endif
@ -327,8 +318,13 @@ void dwinRebootScreen();
#endif
#if ALL(PROUI_TUNING_GRAPH, PROUI_ITEM_PLOT)
void dwinDrawPlot(tempcontrol_t result);
void drawHPlot();
void drawBPlot();
void drawHotendPlot();
#if ENABLED(PIDTEMPBED)
void drawBedPlot();
#endif
#if ENABLED(PIDTEMPCHAMBER)
void drawChamberPlot();
#endif
#endif
// Menu drawing functions

View file

@ -91,25 +91,22 @@
#ifdef Z_AFTER_HOMING
#define DEF_Z_AFTER_HOMING Z_AFTER_HOMING
#else
#define DEF_Z_AFTER_HOMING 0
#elif ALL(INDIVIDUAL_AXIS_HOMING_SUBMENU, MESH_BED_LEVELING)
#define DEF_Z_AFTER_HOMING 10
#endif
#ifdef PREHEAT_1_TEMP_HOTEND
#define DEF_HOTENDPIDT PREHEAT_1_TEMP_HOTEND
#else
#define DEF_HOTENDPIDT 195
#ifndef PREHEAT_1_TEMP_HOTEND
#define PREHEAT_1_TEMP_HOTEND 195
#endif
#ifdef PREHEAT_1_TEMP_BED
#define DEF_BEDPIDT PREHEAT_1_TEMP_BED
#else
#define DEF_BEDPIDT 60
#ifndef PREHEAT_1_TEMP_BED
#define PREHEAT_1_TEMP_BED 60
#endif
#ifdef PREHEAT_1_TEMP_CHAMBER
#define DEF_CHAMBERPIDT PREHEAT_1_TEMP_CHAMBER
#else
#define DEF_CHAMBERPIDT 0
#ifndef PREHEAT_1_TEMP_CHAMBER
#define PREHEAT_1_TEMP_CHAMBER 35
#endif
#define DEF_HOTENDPIDT PREHEAT_1_TEMP_HOTEND
#define DEF_BEDPIDT PREHEAT_1_TEMP_BED
#define DEF_CHAMBERPIDT PREHEAT_1_TEMP_CHAMBER
#define DEF_PIDCYCLES 5
/**

View file

@ -55,12 +55,6 @@ void drawSelectHighlight(const bool sel, const uint16_t ypos) {
dwinDrawRectangle(0, c2, 144, ypos - 2, 247, ypos + 39);
}
void dwinPopupContinue(const uint8_t icon, FSTR_P const fmsg1, FSTR_P const fmsg2) {
hmiSaveProcessID(ID_WaitResponse);
dwinDrawPopup(icon, fmsg1, fmsg2, BTN_Continue); // Button Continue
dwinUpdateLCD();
}
void dwinPopupConfirmCancel(const uint8_t icon, FSTR_P const fmsg2) {
dwinDrawPopup(ICON_BLTouch, F("Please confirm"), fmsg2);
DWINUI::drawButton(BTN_Confirm, 26, 280);
@ -93,4 +87,18 @@ void hmiPopup() {
}
}
#if ENABLED(ADVANCED_PAUSE_FEATURE)
void dwinPopupPause(FSTR_P const fmsg, uint8_t button/*=0*/) {
hmiSaveProcessID(button ? ID_WaitResponse : ID_NothingToDo);
dwinShowPopup(ICON_Pause_1, GET_TEXT_F(MSG_ADVANCED_PAUSE), fmsg, button);
}
void drawPopupFilamentPurge() {
dwinDrawPopup(ICON_AutoLeveling, GET_TEXT_F(MSG_ADVANCED_PAUSE), GET_TEXT_F(MSG_FILAMENT_CHANGE_PURGE_CONTINUE));
DWINUI::drawButton(BTN_Purge, 26, 280);
DWINUI::drawButton(BTN_Continue, 146, 280);
drawSelectHighlight(true);
}
#endif // ADVANCED_PAUSE_FEATURE
#endif // DWIN_LCD_PROUI

View file

@ -29,7 +29,6 @@
* Date: 2022/02/28
*/
#include "dwinui.h"
#include "dwin.h"
typedef void (*popupDrawFunc_t)();
@ -39,10 +38,13 @@ extern popupDrawFunc_t popupDraw;
void drawSelectHighlight(const bool sel, const uint16_t ypos);
inline void drawSelectHighlight(const bool sel) { drawSelectHighlight(sel, 280); };
void dwinPopupContinue(const uint8_t icon, FSTR_P const fmsg1, FSTR_P const fmsg2);
void dwinPopupConfirmCancel(const uint8_t icon, FSTR_P const fmsg2);
void gotoPopup(const popupDrawFunc_t fnDraw, const popupClickFunc_t fnClick=nullptr, const popupChangeFunc_t fnChange=nullptr);
void hmiPopup();
#if ENABLED(ADVANCED_PAUSE_FEATURE)
void dwinPopupPause(FSTR_P const fmsg, uint8_t button=0);
void drawPopupFilamentPurge();
#endif
inline void drawPopupBkgd() {
dwinDrawRectangle(1, hmiData.colorPopupBg, 14, 60, 258, 330);
@ -74,6 +76,13 @@ void dwinShowPopup(const uint8_t icon, T amsg1=nullptr, U amsg2=nullptr, uint8_t
template<typename T, typename U>
void dwinPopupConfirm(const uint8_t icon, T amsg1, U amsg2) {
hmiSaveProcessID(ID_WaitResponse);
dwinDrawPopup(icon, amsg1, amsg2, BTN_Confirm); // Button Confirm
dwinDrawPopup(icon, amsg1, amsg2, BTN_Confirm); // Button Confirm
dwinUpdateLCD();
}
template<typename T, typename U>
void dwinPopupContinue(const uint8_t icon, T amsg1, U amsg2) {
hmiSaveProcessID(ID_WaitResponse);
dwinDrawPopup(icon, amsg1, amsg2, BTN_Continue); // Button Continue
dwinUpdateLCD();
}

View file

@ -43,7 +43,7 @@
#include "../../../inc/MarlinConfigPre.h"
#if ENABLED(DWIN_LCD_PROUI)
#if ALL(DWIN_LCD_PROUI, EXTENSIBLE_UI)
#include "dwin_popup.h"
@ -58,10 +58,13 @@
#include "../../../feature/powerloss.h"
#endif
#if HAS_MESH
#include "../../../feature/bedlevel/bedlevel.h"
#include "meshviewer.h"
#endif
namespace ExtUI {
void onStartup() { dwinInitScreen(); }
void onIdle() {}
void onPrinterKilled(FSTR_P const error, FSTR_P const component) {}
@ -80,22 +83,22 @@ namespace ExtUI {
}
void onPlayTone(const uint16_t frequency, const uint16_t duration/*=0*/) {}
void onPrintTimerStarted() {}
void onPrintTimerPaused() {}
void onPrintTimerStopped() {}
#if HAS_FILAMENT_SENSOR
void onFilamentRunout(const extruder_t extruder) {
dwinFilamentRunout(extruder);
void onFilamentRunout(const extruder_t) {
dwinFilamentRunout();
}
#endif
void onUserConfirmRequired(const char * const cstr) {
// TODO: A version of this method that takes an icon and button title,
// or implement some kind of ExtUI enum.
onUserConfirmRequired(ICON_Continue_1, cstr, GET_TEXT_F(MSG_USERWAIT));
dwinPopupConfirm(ICON_Continue_1, cstr, GET_TEXT_F(MSG_USERWAIT));
}
// For fancy LCDs include an icon ID, message, and translated button title
void onUserConfirmRequired(const int icon, const char * const cstr, FSTR_P const fBtn) {
dwinPopupConfirm(icon, cstr, fBtn);
@ -103,8 +106,12 @@ namespace ExtUI {
void onUserConfirmRequired(const int icon, FSTR_P const fstr, FSTR_P const fBtn) {
dwinPopupConfirm(icon, fstr, fBtn);
}
void onStatusChanged(const char * const) { dwinCheckStatusMessage(); }
void onUserContinue(const char * const cstr) {
dwinPopupContinue(ICON_Continue_1, cstr, GET_TEXT_F(MSG_ADVANCED_PAUSE_WAITING));
}
void onUserContinue(FSTR_P const fstr) {
dwinPopupContinue(ICON_Continue_1, FTOP(fstr), GET_TEXT_F(MSG_ADVANCED_PAUSE_WAITING));
}
#if ENABLED(ADVANCED_PAUSE_FEATURE)
void onPauseMode(const PauseMessage message, const PauseMode mode/*=PAUSE_MODE_SAME*/, const uint8_t extruder/*=motion.extruder*/) {
@ -127,6 +134,12 @@ namespace ExtUI {
}
#endif
void onStatusChanged(const char * const msg) {
UNUSED(msg);
dwinCheckStatusMessage();
dwinDrawStatusMessage();
}
void onHomingStart() { dwinHomingStart(); }
void onHomingDone() { dwinHomingDone(); }
@ -144,12 +157,12 @@ namespace ExtUI {
// Called after loading or resetting stored settings
}
void onSettingsStored(const bool success) {
void onSettingsStored(const bool) {
// Called after the entire EEPROM has been written,
// whether successful or not.
}
void onSettingsLoaded(const bool success) {
void onSettingsLoaded(const bool) {
// Called after the entire EEPROM has been read,
// whether successful or not.
}
@ -164,14 +177,15 @@ namespace ExtUI {
#if HAS_MESH
void onMeshUpdate(const int8_t xpos, const int8_t ypos, const float zval) {
const int16_t idx = ypos * (GRID_MAX_POINTS_X) + xpos;
dwinMeshUpdate(_MIN(idx, GRID_MAX_POINTS), int(GRID_MAX_POINTS), zval);
dwinRedrawScreen();
dwinMeshUpdate(xpos, ypos, zval);
}
void onMeshUpdate(const int8_t xpos, const int8_t ypos, const probe_state_t state) {
// Called to indicate a special condition
}
void onMeshUpdate(const xy_int8_t xypos, const float zval) {
// Called to indicate a special condition
meshViewer.drawMeshPoint(xypos.x, xypos.y, zval);
}
#endif
#if ENABLED(PREVENT_COLD_EXTRUSION)
@ -179,7 +193,7 @@ namespace ExtUI {
#endif
#if ENABLED(POWER_LOSS_RECOVERY)
void onSetPowerLoss(const bool onoff) {
void onSetPowerLoss(const bool) {
// Called when power-loss is enabled/disabled
}
void onPowerLoss() {
@ -194,39 +208,26 @@ namespace ExtUI {
#if HAS_PID_HEATING
void onPIDTuning(const pidresult_t rst) {
// Called for temperature PID tuning result
switch (rst) {
default: break;
#if ENABLED(PIDTEMP)
case PID_STARTED: dwinPIDTuning(PIDTEMP_START); break;
#endif
#if ENABLED(PIDTEMPBED)
case PID_BED_STARTED: dwinPIDTuning(PIDTEMPBED_START); break;
#endif
#if ENABLED(PIDTEMPCHAMBER)
case PID_CHAMBER_STARTED: dwinPIDTuning(PIDTEMPCHAMBER_START); break;
#endif
case PID_BAD_HEATER_ID: dwinPIDTuning(tempcontrol_t(PID_BAD_HEATER_ID)); break;
case PID_TEMP_TOO_HIGH: dwinPIDTuning(tempcontrol_t(PID_TEMP_TOO_HIGH)); break;
case PID_TUNING_TIMEOUT: dwinPIDTuning(tempcontrol_t(PID_TUNING_TIMEOUT)); break;
case PID_DONE: dwinPIDTuning(AUTOTUNE_DONE); break;
if (rst == PID_DONE) {
dwinPIDTuning(AUTOTUNE_DONE);
}
else {
dwinPIDTuning(tempcontrol_t(rst));
}
}
void onStartM303(const int count, const heater_id_t hid, const celsius_t temp) {
dwinStartM303(count, hid, temp);
}
#endif
#if ENABLED(MPC_AUTOTUNE)
void onMPCTuning(const mpcresult_t rst) {
// Called for temperature MPC tuning result
switch (rst) {
case MPC_STARTED: dwinMPCTuning(MPC_STARTED); break;
case MPC_TEMP_ERROR: dwinMPCTuning(MPC_TEMP_ERROR); break;
case MPC_INTERRUPTED: dwinMPCTuning(MPC_INTERRUPTED); break;
case MPC_DONE: dwinMPCTuning(AUTOTUNE_DONE); break;
if (rst == MPC_DONE) {
dwinMPCTuning(AUTOTUNE_DONE);
}
else {
dwinMPCTuning(tempcontrol_t(rst));
}
}
#endif
@ -237,11 +238,26 @@ namespace ExtUI {
void onSteppersDisabled() {}
void onSteppersEnabled() {}
/** void onAxisDisabled(const axis_t a) {
AxisEnum axis;
switch (a) {
TERN_(HAS_X_AXIS, case X:)
default: axis = X_AXIS;
OPTCODE(HAS_Y_AXIS, case Y: axis = Y_AXIS)
OPTCODE(HAS_Z_AXIS, case Z: axis = Z_AXIS)
OPTCODE(HAS_I_AXIS, case I: axis = I_AXIS)
OPTCODE(HAS_J_AXIS, case J: axis = J_AXIS)
OPTCODE(HAS_K_AXIS, case K: axis = K_AXIS)
OPTCODE(HAS_U_AXIS, case U: axis = U_AXIS)
OPTCODE(HAS_V_AXIS, case V: axis = V_AXIS)
OPTCODE(HAS_W_AXIS, case W: axis = W_AXIS)
}
motion.set_axis_untrusted((AxisEnum)axis); // MRISCOC workaround: https://github.com/MarlinFirmware/Marlin/issues/23095
}*/
void onAxisDisabled(const axis_t axis) {
motion.set_axis_untrusted((AxisEnum)axis); // MRISCOC workaround: https://github.com/MarlinFirmware/Marlin/issues/23095
}
void onAxisEnabled(const axis_t) {}
} // ExtUI
#endif // DWIN_LCD_PROUI
#endif // DWIN_LCD_PROUI && EXTENSIBLE_UI

View file

@ -220,6 +220,9 @@ namespace ExtUI {
case MPC_STARTED:
StatusScreen::setStatusMessage(GET_TEXT_F(MSG_MPC_AUTOTUNE));
break;
case MPC_TEMP_ERROR: break;
case MPC_INTERRUPTED: break;
case MPC_DONE: break;
}
GOTO_SCREEN(StatusScreen);
}

View file

@ -102,38 +102,6 @@ namespace ExtUI {
set_lcd_error(error, component);
}
#if HAS_PID_HEATING
void onPIDTuning(const pidresult_t rst) {
// Called for temperature PID tuning result
//SERIAL_ECHOLNPGM("OnPIDTuning:", rst);
switch (rst) {
case PID_STARTED:
case PID_BED_STARTED:
case PID_CHAMBER_STARTED:
set_lcd_error(GET_TEXT_F(MSG_PID_AUTOTUNE));
break;
case PID_BAD_HEATER_ID:
set_lcd_error(GET_TEXT_F(MSG_PID_BAD_HEATER_ID));
break;
case PID_TEMP_TOO_HIGH:
set_lcd_error(GET_TEXT_F(MSG_PID_TEMP_TOO_HIGH));
break;
case PID_TUNING_TIMEOUT:
set_lcd_error(GET_TEXT_F(MSG_PID_TIMEOUT));
break;
case PID_DONE:
set_lcd_error(GET_TEXT_F(MSG_PID_AUTOTUNE_DONE));
break;
}
}
void onStartM303(const int count, const heater_id_t hid, const celsius_t temp) {
// Called by M303 to update the UI
}
#endif
void onPrintTimerStarted() { write_to_lcd(F("{SYS:BUILD}")); }
void onPrintTimerPaused() {}
void onPrintTimerStopped() { write_to_lcd(F("{TQ:100}")); }
@ -207,9 +175,47 @@ namespace ExtUI {
}
#endif
#if HAS_PID_HEATING
void onPIDTuning(const pidresult_t rst) {
// Called for temperature PID tuning result
//SERIAL_ECHOLNPGM("OnPIDTuning:", rst);
switch (rst) {
case PID_STARTED:
case PID_BED_STARTED:
case PID_CHAMBER_STARTED:
set_lcd_error(GET_TEXT_F(MSG_PID_AUTOTUNE));
break;
case PID_BAD_HEATER_ID:
set_lcd_error(GET_TEXT_F(MSG_PID_BAD_HEATER_ID));
break;
case PID_TEMP_TOO_HIGH:
set_lcd_error(GET_TEXT_F(MSG_PID_TEMP_TOO_HIGH));
break;
case PID_TUNING_TIMEOUT:
set_lcd_error(GET_TEXT_F(MSG_PID_TIMEOUT));
break;
case PID_DONE:
set_lcd_error(GET_TEXT_F(MSG_PID_AUTOTUNE_DONE));
break;
}
}
void onStartM303(const int count, const heater_id_t hid, const celsius_t temp) {
// Called by M303 to update the UI
}
#endif // HAS_PID_HEATING
#if ENABLED(MPC_AUTOTUNE)
void onMPCTuning(const mpcresult_t rst) {
// Called for temperature PID tuning result
// Called for temperature MPC tuning result
switch (rst) {
case MPC_STARTED: break;
case MPC_TEMP_ERROR: break;
case MPC_INTERRUPTED: break;
case MPC_DONE: break;
}
}
#endif

View file

@ -524,8 +524,10 @@ namespace ExtUI {
void onFilamentRunout(const extruder_t extruder);
void onUserConfirmRequired(const char * const msg);
void onUserConfirmRequired(const char * const cstr);
void onUserConfirmRequired(FSTR_P const fstr);
void onUserContinue(const char * const cstr);
void onUserContinue(FSTR_P const fstr);
// For fancy LCDs include an icon ID, message, and translated button title
void onUserConfirmRequired(const int icon, const char * const cstr, FSTR_P const fBtn);

View file

@ -690,8 +690,6 @@ namespace LanguageNarrow_de {
LSTR MSG_LOCKSCREEN = _UxGT("Bildschirm sperren"); // Lock Screen
LSTR MSG_LOCKSCREEN_LOCKED = _UxGT("Drucker ist gesperrt,"); // Printer is Locked,
LSTR MSG_LOCKSCREEN_UNLOCK = _UxGT("Scrollen zum Entsper."); // Scroll to unlock.
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Auf Neustart warten"); // Please wait for reboot.
LSTR MSG_PLEASE_PREHEAT = _UxGT("Bitte vorheizen"); // Please Preheat
LSTR MSG_FILAMENT_CHANGE_PURGE_CONTINUE = _UxGT("Löschen o. fortfah.?"); // Purge or Continue?
LSTR MSG_EXTRUDER_MIN_TEMP = _UxGT("Extruder Min Temp."); // Extruder Min Temp.
LSTR MSG_FANCHECK = _UxGT("Lüftergeschw. prüfen"); // Fan Tacho Check

View file

@ -575,7 +575,6 @@ namespace LanguageNarrow_en {
LSTR MSG_HOME_OFFSET_X = _UxGT("Home Offset X");
LSTR MSG_HOME_OFFSET_Y = _UxGT("Home Offset Y");
LSTR MSG_HOME_OFFSET_Z = _UxGT("Home Offset Z");
LSTR MSG_TRAMMING_WIZARD = _UxGT("Tramming Wizard");
LSTR MSG_SELECT_ORIGIN = _UxGT("Select Origin");
LSTR MSG_LAST_VALUE_SP = _UxGT("Last value ");
LSTR MSG_CUTTER_FREQUENCY = _UxGT("Frequency");
@ -717,13 +716,32 @@ namespace LanguageNarrow_en {
LSTR MSG_COLORS_GREEN = _UxGT("Green");
LSTR MSG_COLORS_BLUE = _UxGT("Blue");
LSTR MSG_COLORS_WHITE = _UxGT("White");
LSTR MSG_SCREEN_BACKGROUND = _UxGT("Screen Background");
LSTR MSG_CURSOR = _UxGT("Cursor");
LSTR MSG_TITLE_BACKGROUND = _UxGT("Title Background");
LSTR MSG_TITLE_TEXT = _UxGT("Title Text");
LSTR MSG_TEXT = _UxGT("Text");
LSTR MSG_SELECTED = _UxGT("Selected");
LSTR MSG_SPLIT_LINE = _UxGT("Split Line");
LSTR MSG_HIGHLIGHT = _UxGT("Highlight");
LSTR MSG_STATUS_BACKGROUND = _UxGT("Status Background");
LSTR MSG_STATUS_TEXT = _UxGT("Status Text");
LSTR MSG_POPUP_BACKGROUND = _UxGT("Popup Background");
LSTR MSG_POPUP_TEXT = _UxGT("Popup Text");
LSTR MSG_ALERT_BACKGROUND = _UxGT("Alert Background");
LSTR MSG_ALERT_TEXT = _UxGT("Alert Text");
LSTR MSG_PERCENT_TEXT = _UxGT("Percent Text");
LSTR MSG_BAR_FILL = _UxGT("Bar Fill");
LSTR MSG_INDICATOR_VALUE = _UxGT("Indicator value");
LSTR MSG_COORDINATE_VALUE = _UxGT("Coordinate value");
LSTR MSG_LOWER = _UxGT("Lower");
LSTR MSG_RAISE = _UxGT("Raise");
LSTR MSG_EXIT_TO_MAIN_MENU = _UxGT("Exit to Main Menu");
LSTR MSG_UI_LANGUAGE = _UxGT("UI Language");
LSTR MSG_SOUND_ENABLE = _UxGT("Enable sound");
LSTR MSG_LOCKSCREEN = _UxGT("Lock Screen");
LSTR MSG_LOCKSCREEN_LOCKED = _UxGT("Printer is Locked,");
LSTR MSG_LOCKSCREEN_UNLOCK = _UxGT("Scroll to unlock.");
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Please wait for reboot.");
LSTR MSG_PLEASE_PREHEAT = _UxGT("Please Preheat");
LSTR MSG_FILAMENT_CHANGE_PURGE_CONTINUE = _UxGT("Purge or Continue?");
LSTR MSG_EXTRUDER_MIN_TEMP = _UxGT("Extruder Min Temp.");
LSTR MSG_FANCHECK = _UxGT("Fan Tacho Check");
@ -807,7 +825,10 @@ namespace LanguageNarrow_en {
LSTR MSG_CUTTER = _UxGT("Cutter");
LSTR MSG_FLOW_PERCENTAGE = _UxGT("Set Flowrate Percentage");
LSTR MSG_TIMEOUT = _UxGT("Timeout");
LSTR MSG_PID_FOR_NOZZLE = _UxGT("for Nozzle is running.");
LSTR MSG_HOTEND_TEMP_GRAPH = _UxGT("Hotend Temp Graph");
LSTR MSG_BED_TEMP_GRAPH = _UxGT("Bed Temp Graph");
LSTR MSG_CHAMBER_TEMP_GRAPH = _UxGT("Chamber Temp Graph");
LSTR MSG_PID_FOR_NOZZLE = _UxGT("for NOZZLE is running.");
LSTR MSG_PID_FOR_BED = _UxGT("for BED is running.");
LSTR MSG_PID_FOR_CHAMBER = _UxGT("for CHAMBER is running.");
LSTR MSG_TEMP_NOZZLE = _UxGT("Nozzle Temperature");
@ -848,8 +869,6 @@ namespace LanguageNarrow_en {
LSTR MSG_ADVANCE_TAU = _UxGT("Advance Tau");
LSTR MSG_ADVANCE_TAU_E = _UxGT("Advance Tau *");
LSTR MSG_NLE_ON = _UxGT("NLE enabled");
LSTR MSG_HOTEND_TEMP_GRAPH = _UxGT("Hotend Temp Graph");
LSTR MSG_BED_TEMP_GRAPH = _UxGT("Bed Temp Graph");
LSTR MSG_EEPROM_INITIALIZED = _UxGT("EEPROM Initialized");
LSTR MSG_ERR_EEPROM_CORRUPT = _UxGT("Err: EEPROM Corrupt");
LSTR MSG_HAS_PREVIEW = _UxGT("Has preview");
@ -1071,6 +1090,23 @@ namespace LanguageNarrow_en {
namespace LanguageWide_en {
using namespace LanguageNarrow_en;
#if LCD_WIDTH > 20 || HAS_DWIN_E3V2
// ProUI
LSTR MSG_DISABLE_MANUAL_TRAMMING = _UxGT("Disable manual tramming");
LSTR MSG_TRAMMING_WIZARD = _UxGT("Tramming Wizard");
LSTR MSG_TRAMMING_WIZARD_START = _UxGT("Tramming Wizard Start");
LSTR MSG_CORNERS_LEVELED = _UxGT("Corners leveled");
LSTR MSG_CORNERS_NOT_LEVELED = _UxGT("Corners not leveled");
LSTR MSG_KNOB_ADJUSTMENT_REQUIRED = _UxGT("Knob adjustment required");
LSTR MSG_PROBE_FOR_Z_VALUE = _UxGT("Probe for Z Value");
LSTR MSG_ZERO_CURRENT_POINT = _UxGT("Zero Current Point");
LSTR MSG_CALCULATING_AVERAGE = _UxGT("Calculating average");
LSTR MSG_AND_RELATIVE_HEIGHTS = _UxGT("and relative heights");
LSTR MSG_TOLERANCE_ACHIEVED = _UxGT("Tolerance achieved!");
LSTR MSG_POSITION_UNKNOWN = _UxGT("WARNING: Current position unknown. Home axes.");
LSTR MSG_POSITION_UNKNOWN_Z = _UxGT("WARNING: Z position unknown, move Z to home");
LSTR MSG_OUTAGE_RECOVERY2 = _UxGT("It looks like the last");
LSTR MSG_OUTAGE_RECOVERY3 = _UxGT("file was interrupted.");
LSTR MSG_PREHEAT_1_END = _UxGT("Preheat ") PREHEAT_1_LABEL _UxGT(" Hotend");
LSTR MSG_PREHEAT_1_END_E = _UxGT("Preheat ") PREHEAT_1_LABEL _UxGT(" Hotend ~");
LSTR MSG_PREHEAT_1_SETTINGS = _UxGT("Preheat ") PREHEAT_1_LABEL _UxGT(" Settings");
@ -1080,6 +1116,7 @@ namespace LanguageWide_en {
LSTR MSG_MEDIA_MENU = _UxGT("Select from ") MEDIA_TYPE_EN;
LSTR MSG_NO_MEDIA = _UxGT("No ") MEDIA_TYPE_EN _UxGT(" Found");
LSTR MSG_INFO_PRINT_COUNT = _UxGT("Print Count");
LSTR MSG_INFO_PRINT_COUNT_RESET = _UxGT("Reset Print Count");
LSTR MSG_INFO_PRINT_TIME = _UxGT("Print Time");
LSTR MSG_INFO_PRINT_LONGEST = _UxGT("Longest Job Time");
LSTR MSG_INFO_PRINT_FILAMENT = _UxGT("Extruded Total");
@ -1089,10 +1126,13 @@ namespace LanguageWide_en {
LSTR MSG_HOST_START_PRINT = _UxGT("Start Host Print");
LSTR MSG_END_LOOPS = _UxGT("End Repeat Loops");
LSTR MSG_CONTINUE_PRINT_JOB = _UxGT("Continue Print Job");
LSTR MSG_TURN_OFF = _UxGT("Turn off the printer");
LSTR MSG_PLEASE_PREHEAT = _UxGT("Please preheat the hot end.");
LSTR MSG_MEDIA_NOT_INSERTED = _UxGT("No media inserted.");
LSTR MSG_INFO_PRINT_COUNT_RESET = _UxGT("Reset Print Count");
LSTR MSG_TURN_OFF = _UxGT("Turn off printer");
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Please wait for reboot.");
LSTR MSG_PLEASE_PREHEAT = _UxGT("Please preheat hot end.");
LSTR MSG_MPC_TARGET = _UxGT("MPC target: Celsius");
LSTR MSG_PID_TARGET = _UxGT("PID target: Celsius");
LSTR MSG_TARGET = _UxGT("Target: Celsius");
LSTR MSG_MEDIA_NOT_INSERTED = MEDIA_TYPE_EN _UxGT(" not inserted.");
LSTR MSG_HOMING_FEEDRATE_N = _UxGT("@ Homing Feedrate");
LSTR MSG_PREHEAT_1_CHAMBER = _UxGT("Preheat ") PREHEAT_1_LABEL _UxGT(" Chamber");
LSTR MSG_PREHEAT_M_CHAMBER = _UxGT("Preheat $ Chamber");

View file

@ -699,8 +699,6 @@ namespace LanguageNarrow_it {
LSTR MSG_LOCKSCREEN = _UxGT("Blocca schermo"); // Lock Screen
LSTR MSG_LOCKSCREEN_LOCKED = _UxGT("Stamp. bloccata,"); // Printer is Locked,
LSTR MSG_LOCKSCREEN_UNLOCK = _UxGT("Scroll x sbloccare."); // Scroll to unlock.
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Attendere fino al riavvio."); // Please wait for reboot.
LSTR MSG_PLEASE_PREHEAT = _UxGT("Prerisc. ugello."); // Please Preheat
LSTR MSG_FILAMENT_CHANGE_PURGE_CONTINUE = _UxGT("Spurga o continua?"); // Purge or Continue?
LSTR MSG_EXTRUDER_MIN_TEMP = _UxGT("Temp.min estrusore"); // Extruder Min Temp.
LSTR MSG_FANCHECK = _UxGT("Verif.tacho vent."); // Fan Tacho Check
@ -822,6 +820,7 @@ namespace LanguageNarrow_it {
LSTR MSG_NLE_ON = _UxGT("NLE abilitato"); // NLE enabled
LSTR MSG_HOTEND_TEMP_GRAPH = _UxGT("Grafico temp.ugello"); // Hotend Temp Graph
LSTR MSG_BED_TEMP_GRAPH = _UxGT("Grafico temp.piatto"); // Bed Temp Graph
LSTR MSG_CHAMBER_TEMP_GRAPH = _UxGT("Grafico temp.camera"); // Chamber Temp Graph
LSTR MSG_EEPROM_INITIALIZED = _UxGT("EEPROM inizializzata"); // EEPROM Initialized
LSTR MSG_ERR_EEPROM_CORRUPT = _UxGT("Err: EEPROM corrotta"); // Err: EEPROM Corrupt
LSTR MSG_HAS_PREVIEW = _UxGT("Ha anteprima"); // Has preview

View file

@ -699,8 +699,6 @@ namespace LanguageNarrow_sk {
LSTR MSG_LOCKSCREEN = _UxGT("Uzamknúť obrazovku"); // Lock Screen
LSTR MSG_LOCKSCREEN_LOCKED = _UxGT("Tlačiareň je uzamknutá,"); // Printer is Locked,
LSTR MSG_LOCKSCREEN_UNLOCK = _UxGT("potiahnite pre odomknutie."); // Scroll to unlock.
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Prosím čakajte do reštartu."); // Please wait for reboot.
LSTR MSG_PLEASE_PREHEAT = _UxGT("Prosím zahrejte"); // Please Preheat
LSTR MSG_FILAMENT_CHANGE_PURGE_CONTINUE = _UxGT("Vytlač. alebo pokrač.?"); // Purge or Continue?
LSTR MSG_EXTRUDER_MIN_TEMP = _UxGT("Min. tepl. extrud."); // Extruder Min Temp.
LSTR MSG_FANCHECK = _UxGT("Kontrola rýchl."); // Fan Tacho Check
@ -787,8 +785,9 @@ namespace LanguageWide_sk {
LSTR MSG_END_LOOPS = _UxGT("Ukončiť opak. sluč."); // End Repeat Loops
LSTR MSG_CONTINUE_PRINT_JOB = _UxGT("Pokračovať v úlohe"); // Continue Print Job
LSTR MSG_TURN_OFF = _UxGT("Vypnite tlačiareň"); // Turn off the printer
LSTR MSG_PLEASE_PREHEAT = _UxGT("Prosím zahrejte hotend."); // Please preheat the hot end.
LSTR MSG_MEDIA_NOT_INSERTED = _UxGT("Nie je vložená karta."); // No media inserted.
LSTR MSG_PLEASE_PREHEAT = _UxGT("Prosím zahrejte hotend."); // Please preheat the hot end
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Prosím čakajte do reštartu."); // Please wait for reboot
LSTR MSG_MEDIA_NOT_INSERTED = _UxGT("Nie je vložená karta."); // No media inserted
LSTR MSG_INFO_PRINT_COUNT_RESET = _UxGT("Vynulovať počítadlo"); // Reset Print Count
#endif
}

View file

@ -692,8 +692,6 @@ namespace LanguageNarrow_tr {
LSTR MSG_LOCKSCREEN = _UxGT("Kilit Ekranı"); // Lock Screen
LSTR MSG_LOCKSCREEN_LOCKED = _UxGT("Yazıcı Kilitlendi,"); // Printer is Locked,
LSTR MSG_LOCKSCREEN_UNLOCK = _UxGT("Açmak için kaydırın."); // Scroll to unlock.
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Y.Başlatma bekleyin."); // Please wait for reboot.
LSTR MSG_PLEASE_PREHEAT = _UxGT("Ön Isıtma Lütfen"); // Please Preheat
LSTR MSG_FILAMENT_CHANGE_PURGE_CONTINUE = _UxGT("Temizle veya Devam?"); // Purge or Continue?
LSTR MSG_EXTRUDER_MIN_TEMP = _UxGT("Ekstruder Min Isı"); // Extruder Min Temp.
LSTR MSG_FANCHECK = _UxGT("Fan Takosu Kontrolü"); // Fan Tacho Check
@ -862,8 +860,9 @@ namespace LanguageWide_tr {
LSTR MSG_END_LOOPS = _UxGT("Tekrr Döngüler Bitir"); // End Repeat Loops
LSTR MSG_CONTINUE_PRINT_JOB = _UxGT("Yazdırmaya Devam Et"); // Continue Print Job
LSTR MSG_TURN_OFF = _UxGT("Yazıcıyı kapat"); // Turn off the printer
LSTR MSG_PLEASE_PREHEAT = _UxGT("Lütfen önce hotend'i ısıtın."); // Please preheat the hot end.
LSTR MSG_MEDIA_NOT_INSERTED = _UxGT("Ortam yerleştirilmedi."); // No media inserted.
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Y.Başlatma bekleyin."); // Please wait for reboot
LSTR MSG_PLEASE_PREHEAT = _UxGT("Lütfen önce hotend'i ısıtın."); // Please preheat the hot end
LSTR MSG_MEDIA_NOT_INSERTED = _UxGT("Ortam yerleştirilmedi."); // No media inserted
LSTR MSG_INFO_PRINT_COUNT_RESET = _UxGT("Baskı Sayısını Sıfırla"); // Reset Print Count
#endif
}

View file

@ -623,8 +623,6 @@ namespace LanguageNarrow_uk {
LSTR MSG_UI_LANGUAGE = _UxGT("Мова"); // UI Language
LSTR MSG_SOUND_ENABLE = _UxGT("Дозволити звук"); // Enable sound
LSTR MSG_LOCKSCREEN = _UxGT("Блокувати екран"); // Lock Screen
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Перезавантаж..."); // Please wait for reboot.
LSTR MSG_PLEASE_PREHEAT = _UxGT("Нагрійте хотенд"); // Please Preheat
LSTR MSG_BAD_PAGE = _UxGT("Погана сторінка"); // Bad page index
LSTR MSG_BAD_PAGE_SPEED = _UxGT("Погана швидк. стор."); // Bad page speed
LSTR MSG_EDIT_PASSWORD = _UxGT("Редагувати пароль"); // Edit Password
@ -739,11 +737,12 @@ namespace LanguageWide_uk {
LSTR MSG_HOTEND_IDLE_TIMEOUT = _UxGT("Час простою хотенду"); // Hotend Idle Timeout
LSTR MSG_COLORS_SELECT = _UxGT("Обрати кольори"); // Select Colors
LSTR MSG_COLORS_APPLIED = _UxGT("Кольори застосовані"); // Colors applied
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Перезавантаження..."); // Please wait for reboot.
LSTR MSG_PLEASE_WAIT_REBOOT = _UxGT("Перезавантаження..."); // Please wait for reboot
LSTR MSG_PLEASE_PREHEAT = _UxGT("Нагрійте хотенд"); // Please Preheat
LSTR MSG_BAD_PAGE_SPEED = _UxGT("Погана швидкість стор."); // Bad page speed
LSTR MSG_PROBE_WIZARD_PROBING = _UxGT("Зондув. контрольної точки Z"); // Probing Z Reference
LSTR MSG_PROBE_WIZARD_MOVING = _UxGT("Рух до точки зондування"); // Moving to Probing Pos
LSTR MSG_MEDIA_NOT_INSERTED = _UxGT("Носій не вставлений"); // No media inserted.
LSTR MSG_MEDIA_NOT_INSERTED = _UxGT("Носій не вставлений"); // No media inserted
#endif
}

View file

@ -50,7 +50,7 @@
#if ENABLED(DWIN_CREALITY_LCD)
#include "dwin/creality/dwin.h"
#elif ENABLED(DWIN_LCD_PROUI)
#include "dwin/proui/dwin.h"
#include "dwin/proui/dwin_popup.h"
#endif
#if ALL(HAS_STATUS_MESSAGE, IS_DWIN_MARLINUI)

View file

@ -399,7 +399,7 @@ FORCE_INLINE void probe_specific_action(const bool deploy) {
TERN_(HOST_PROMPT_SUPPORT, hostui.continue_prompt(ds_fstr));
#if ENABLED(DWIN_LCD_PROUI)
ExtUI::onUserConfirmRequired(ICON_BLTouch, ds_fstr, FPSTR(CONTINUE_STR));
ExtUI::onUserContinue(ds_fstr);
#elif ENABLED(EXTENSIBLE_UI)
ExtUI::onUserConfirmRequired(ds_fstr);
#endif

View file

@ -1666,9 +1666,9 @@ void MarlinSettings::postprocess() {
//
#if ENABLED(EXTENSIBLE_UI)
{
_FIELD_TEST(extui_data);
char extui_data[ExtUI::eeprom_data_size] = { 0 };
ExtUI::onStoreSettings(extui_data);
_FIELD_TEST(extui_data);
EEPROM_WRITE(extui_data);
}
#endif
@ -3182,95 +3182,82 @@ void MarlinSettings::postprocess() {
void MarlinSettings::store_mesh(const int8_t slot) {
#if ENABLED(AUTO_BED_LEVELING_UBL)
const int16_t a = calc_num_meshes();
if (!WITHIN(slot, 0, a - 1)) {
ubl_invalid_slot(a);
DEBUG_ECHOLNPGM("E2END=", persistentStore.capacity() - 1, " meshes_end=", meshes_end, " slot=", slot);
DEBUG_EOL();
return;
}
const int16_t a = calc_num_meshes();
if (!WITHIN(slot, 0, a - 1)) {
ubl_invalid_slot(a);
DEBUG_ECHOLNPGM("E2END=", persistentStore.capacity() - 1, " meshes_end=", meshes_end, " slot=", slot);
DEBUG_EOL();
return;
}
int pos = mesh_slot_offset(slot);
uint16_t crc = 0;
#if ENABLED(OPTIMIZED_MESH_STORAGE)
int16_t z_mesh_store[GRID_MAX_POINTS_X][GRID_MAX_POINTS_Y];
bedlevel.set_store_from_mesh(bedlevel.z_values, z_mesh_store);
uint8_t * const src = (uint8_t*)&z_mesh_store;
#else
uint8_t * const src = (uint8_t*)&bedlevel.z_values;
#endif
// Write crc to MAT along with other data, or just tack on to the beginning or end
persistentStore.access_start();
const bool status = persistentStore.write_data(pos, src, MESH_STORE_SIZE, &crc);
persistentStore.access_finish();
if (status) SERIAL_ECHOLNPGM("?Unable to save mesh data.");
else DEBUG_ECHOLNPGM("Mesh saved in slot ", slot);
int pos = mesh_slot_offset(slot);
uint16_t crc = 0;
#if ENABLED(OPTIMIZED_MESH_STORAGE)
int16_t z_mesh_store[GRID_MAX_POINTS_X][GRID_MAX_POINTS_Y];
bedlevel.set_store_from_mesh(bedlevel.z_values, z_mesh_store);
uint8_t * const src = (uint8_t*)&z_mesh_store;
#else
// Other mesh types
uint8_t * const src = (uint8_t*)&bedlevel.z_values;
#endif
// Write crc to MAT along with other data, or just tack on to the beginning or end
persistentStore.access_start();
const bool status = persistentStore.write_data(pos, src, MESH_STORE_SIZE, &crc);
persistentStore.access_finish();
if (status) SERIAL_ECHOLNPGM("?Unable to save mesh data.");
else DEBUG_ECHOLNPGM("Mesh saved in slot ", slot);
}
void MarlinSettings::load_mesh(const int8_t slot, void * const into/*=nullptr*/) {
#if ENABLED(AUTO_BED_LEVELING_UBL)
const int16_t a = settings.calc_num_meshes();
const int16_t a = settings.calc_num_meshes();
if (!WITHIN(slot, 0, a - 1)) {
ubl_invalid_slot(a);
return;
}
int pos = mesh_slot_offset(slot);
uint16_t crc = 0;
#if ENABLED(OPTIMIZED_MESH_STORAGE)
int16_t z_mesh_store[GRID_MAX_POINTS_X][GRID_MAX_POINTS_Y];
uint8_t * const dest = (uint8_t*)&z_mesh_store;
#else
uint8_t * const dest = into ? (uint8_t*)into : (uint8_t*)&bedlevel.z_values;
#endif
persistentStore.access_start();
uint16_t status = persistentStore.read_data(pos, dest, MESH_STORE_SIZE, &crc);
persistentStore.access_finish();
#if ENABLED(OPTIMIZED_MESH_STORAGE)
if (into) {
float z_values[GRID_MAX_POINTS_X][GRID_MAX_POINTS_Y];
bedlevel.set_mesh_from_store(z_mesh_store, z_values);
memcpy(into, z_values, sizeof(z_values));
}
else
bedlevel.set_mesh_from_store(z_mesh_store, bedlevel.z_values);
#endif
#if ENABLED(DWIN_LCD_PROUI)
status = !bedLevelTools.meshValidate();
if (status) {
bedlevel.invalidate();
LCD_MESSAGE(MSG_UBL_MESH_INVALID);
}
else
ui.status_printf(0, GET_TEXT_F(MSG_MESH_LOADED), bedlevel.storage_slot);
#endif
if (status) SERIAL_ECHOLNPGM("?Unable to load mesh data.");
else DEBUG_ECHOLNPGM("Mesh loaded from slot ", slot);
EEPROM_FINISH();
if (!WITHIN(slot, 0, a - 1)) {
ubl_invalid_slot(a);
return;
}
int pos = mesh_slot_offset(slot);
uint16_t crc = 0;
#if ENABLED(OPTIMIZED_MESH_STORAGE)
int16_t z_mesh_store[GRID_MAX_POINTS_X][GRID_MAX_POINTS_Y];
uint8_t * const dest = (uint8_t*)&z_mesh_store;
#else
// Other mesh types
uint8_t * const dest = into ? (uint8_t*)into : (uint8_t*)&bedlevel.z_values;
#endif
persistentStore.access_start();
uint16_t status = persistentStore.read_data(pos, dest, MESH_STORE_SIZE, &crc);
persistentStore.access_finish();
#if ENABLED(OPTIMIZED_MESH_STORAGE)
if (into) {
float z_values[GRID_MAX_POINTS_X][GRID_MAX_POINTS_Y];
bedlevel.set_mesh_from_store(z_mesh_store, z_values);
memcpy(into, z_values, sizeof(z_values));
}
else
bedlevel.set_mesh_from_store(z_mesh_store, bedlevel.z_values);
#endif
#if ENABLED(DWIN_LCD_PROUI)
status = !bedLevelTools.meshValidate();
if (status) {
bedlevel.invalidate();
LCD_MESSAGE(MSG_UBL_MESH_INVALID);
}
else
ui.status_printf(0, GET_TEXT_F(MSG_MESH_LOADED), bedlevel.storage_slot);
#endif
if (status) SERIAL_ECHOLNPGM("?Unable to load mesh data.");
else DEBUG_ECHOLNPGM("Mesh loaded from slot ", slot);
EEPROM_FINISH();
}
//void MarlinSettings::delete_mesh() { return; }

View file

@ -599,6 +599,7 @@ void Stepper::enable_axis(const AxisEnum axis) {
*/
bool Stepper::disable_axis(const AxisEnum axis) {
mark_axis_disabled(axis);
TERN_(EXTENSIBLE_UI, ExtUI::onAxisDisabled(ExtUI::axis_to_axis_t(axis)));
// This scheme prevents shared steppers being disabled. It should consider several axes at once
// and keep a count of how many times each ENA pin has been set.
@ -612,7 +613,6 @@ bool Stepper::disable_axis(const AxisEnum axis) {
MAIN_AXIS_MAP(_CASE_DISABLE)
default: break;
}
TERN_(EXTENSIBLE_UI, ExtUI::onAxisDisabled(ExtUI::axis_to_axis_t(axis)));
}
return can_disable;

View file

@ -242,7 +242,7 @@
#define BEEPER_PIN EXP1_01_PIN
#endif
#elif ENABLED(DWIN_CREALITY_LCD)
#elif ENABLED(HAS_DWIN_E3V2)
// DWIN ENCODER LCD
#define BTN_ENC EXP1_05_PIN

View file

@ -25,16 +25,24 @@ opt_enable DWIN_MARLINUI_LANDSCAPE LCD_ENDSTOP_TEST AUTO_BED_LEVELING_UBL BLTOUC
MARLIN_BRICKOUT MARLIN_INVADERS MARLIN_SNAKE GAMES_EASTER_EGG
exec_test $1 $2 "Ender-3 V2 - MarlinUI (Games, UBL+BLTOUCH, MPCTEMP, LCD_ENDSTOP_TEST)" "$3"
use_example_configs "Creality/Ender-3 V2/CrealityV422/CrealityUI"
opt_disable DWIN_CREALITY_LCD
opt_enable DWIN_LCD_PROUI PID_EDIT_MENU PID_AUTOTUNE_MENU
opt_add NO_AUTO_ASSIGN_WARNING
opt_set BOOTSCREEN_TIMEOUT 1100
exec_test $1 $2 "Ender-3 V2 - ProUI (Default)" "$3"
use_example_configs "Creality/Ender-3 S1/STM32F1"
opt_disable DWIN_CREALITY_LCD Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN AUTO_BED_LEVELING_BILINEAR CANCEL_OBJECTS FWRETRACT EVENT_GCODE_SD_ABORT
opt_enable DWIN_LCD_PROUI INDIVIDUAL_AXIS_HOMING_SUBMENU PID_AUTOTUNE_MENU PID_EDIT_MENU \
SET_PROGRESS_MANUALLY SET_PROGRESS_PERCENT STATUS_MESSAGE_SCROLLING \
SOUND_MENU_ITEM PRINTCOUNTER NOZZLE_PARK_FEATURE ADVANCED_PAUSE_FEATURE FILAMENT_RUNOUT_SENSOR \
BLTOUCH Z_SAFE_HOMING AUTO_BED_LEVELING_UBL MESH_EDIT_MENU LCD_BED_TRAMMING LIN_ADVANCE \
LIMITED_MAX_FR_EDITING LIMITED_MAX_ACCEL_EDITING LIMITED_JERK_EDITING BAUD_RATE_GCODE \
CASE_LIGHT_ENABLE CASE_LIGHT_MENU CASE_LIGHT_NO_BRIGHTNESS NONLINEAR_EXTRUSION
opt_set PREHEAT_3_LABEL '"CUSTOM"' PREHEAT_3_TEMP_HOTEND 240 PREHEAT_3_TEMP_BED 60 PREHEAT_3_FAN_SPEED 128 BOOTSCREEN_TIMEOUT 1100 CASE_LIGHT_PIN 4
exec_test $1 $2 "Ender-3 S1 - ProUI (PIDTEMP)" "$3"
LIMITED_MAX_FR_EDITING LIMITED_MAX_ACCEL_EDITING LIMITED_JERK_EDITING BAUD_RATE_GCODE BED_TRAMMING_USE_PROBE BED_TRAMMING_INCLUDE_CENTER \
CASE_LIGHT_ENABLE CASE_LIGHT_MENU CASE_LIGHT_NO_BRIGHTNESS NONLINEAR_EXTRUSION BABYSTEP_ZPROBE_OFFSET EMERGENCY_PARSER
opt_set PREHEAT_3_LABEL '"CUSTOM"' PREHEAT_3_TEMP_HOTEND 240 PREHEAT_3_TEMP_BED 60 PREHEAT_3_FAN_SPEED 128 BOOTSCREEN_TIMEOUT 1100 CASE_LIGHT_PIN 4 \
LCD_BACKLIGHT_TIMEOUT_MINS 10
exec_test $1 $2 "Ender-3 S1 - ProUI (UBL+PIDTEMP)" "$3"
restore_configs
opt_set MOTHERBOARD BOARD_CREALITY_V452 SERIAL_PORT 1