Merge pull request #685 from mkbel/add_safety_timer_notice
Show full screen blocking notification message after heater turned off
This commit is contained in:
commit
2a57325bd5
5 changed files with 18 additions and 4 deletions
|
@ -7120,7 +7120,9 @@ void handle_status_leds(void) {
|
|||
|
||||
#ifdef SAFETYTIMER
|
||||
/**
|
||||
* @brief Turn off heating after 15 minutes of inactivity
|
||||
* @brief Turn off heating after 30 minutes of inactivity
|
||||
*
|
||||
* Full screen blocking notification message is shown after heater turning off.
|
||||
*/
|
||||
static void handleSafetyTimer()
|
||||
{
|
||||
|
@ -7137,10 +7139,11 @@ static void handleSafetyTimer()
|
|||
{
|
||||
safetyTimer.start();
|
||||
}
|
||||
else if (safetyTimer.expired(1800000ul)) //30 minutes
|
||||
else if (safetyTimer.expired(1800000ul))
|
||||
{
|
||||
setTargetBed(0);
|
||||
setTargetHotend(0, 0);
|
||||
lcd_show_fullscreen_message_and_wait_P(MSG_BED_HEATING_SAFETY_DISABLED);
|
||||
}
|
||||
}
|
||||
#endif //SAFETYTIMER
|
||||
|
|
|
@ -170,6 +170,13 @@ const char * const MSG_BED_HEATING_LANG_TABLE[LANG_NUM] PROGMEM = {
|
|||
MSG_BED_HEATING_CZ
|
||||
};
|
||||
|
||||
const char MSG_BED_HEATING_SAFETY_DISABLED_EN[] PROGMEM = "Heating disabled by safety timer.";
|
||||
const char MSG_BED_HEATING_SAFETY_DISABLED_CZ[] PROGMEM = "Zahrivani preruseno bezpecnostnim casovacem.";
|
||||
const char * const MSG_BED_HEATING_SAFETY_DISABLED_LANG_TABLE[LANG_NUM] PROGMEM = {
|
||||
MSG_BED_HEATING_SAFETY_DISABLED_EN,
|
||||
MSG_BED_HEATING_SAFETY_DISABLED_CZ
|
||||
};
|
||||
|
||||
const char MSG_BED_LEVELING_FAILED_POINT_HIGH_EN[] PROGMEM = "Bed leveling failed. Sensor triggered too high. Waiting for reset.";
|
||||
const char MSG_BED_LEVELING_FAILED_POINT_HIGH_CZ[] PROGMEM = "Kalibrace Z selhala. Sensor sepnul prilis vysoko. Cekam na reset.";
|
||||
const char * const MSG_BED_LEVELING_FAILED_POINT_HIGH_LANG_TABLE[LANG_NUM] PROGMEM = {
|
||||
|
|
|
@ -76,6 +76,8 @@ extern const char* const MSG_BED_DONE_LANG_TABLE[LANG_NUM];
|
|||
#define MSG_BED_DONE LANG_TABLE_SELECT(MSG_BED_DONE_LANG_TABLE)
|
||||
extern const char* const MSG_BED_HEATING_LANG_TABLE[LANG_NUM];
|
||||
#define MSG_BED_HEATING LANG_TABLE_SELECT(MSG_BED_HEATING_LANG_TABLE)
|
||||
extern const char* const MSG_BED_HEATING_SAFETY_DISABLED_LANG_TABLE[LANG_NUM];
|
||||
#define MSG_BED_HEATING_SAFETY_DISABLED LANG_TABLE_SELECT(MSG_BED_HEATING_SAFETY_DISABLED_LANG_TABLE)
|
||||
extern const char* const MSG_BED_LEVELING_FAILED_POINT_HIGH_LANG_TABLE[LANG_NUM];
|
||||
#define MSG_BED_LEVELING_FAILED_POINT_HIGH LANG_TABLE_SELECT(MSG_BED_LEVELING_FAILED_POINT_HIGH_LANG_TABLE)
|
||||
extern const char* const MSG_BED_LEVELING_FAILED_POINT_LOW_LANG_TABLE[LANG_NUM];
|
||||
|
|
|
@ -132,6 +132,7 @@
|
|||
#define MSG_HEATING "Zahrivani"
|
||||
#define MSG_HEATING_COMPLETE "Zahrivani OK."
|
||||
#define MSG_BED_HEATING "Zahrivani bed"
|
||||
#define MSG_BED_HEATING_SAFETY_DISABLED "Zahrivani preruseno bezpecnostnim casovacem."
|
||||
#define MSG_BED_DONE "Bed OK."
|
||||
#define MSG_ERR_KILLED "Printer halted. kill() called!"
|
||||
#define MSG_ERR_STOPPED "Printer stopped due to errors. Fix the error and use M999 to restart. (Temperature is reset. Set it after restarting)"
|
||||
|
@ -414,4 +415,4 @@
|
|||
#define MSG_CHANGED_PRINTER "Varovani: doslo ke zmene typu tiskarny."
|
||||
#define MSG_CHANGED_BOTH "Varovani: doslo ke zmene typu tiskarny a motherboardu."
|
||||
#define MSG_WAITING_TEMP_PINDA "Cekani na zchladnuti PINDA"
|
||||
#define MSG_TEMP_CAL_FAILED "Teplotni kalibrace selhala"
|
||||
#define MSG_TEMP_CAL_FAILED "Teplotni kalibrace selhala"
|
||||
|
|
|
@ -131,6 +131,7 @@
|
|||
#define MSG_HEATING "Heating"
|
||||
#define(length=20) MSG_HEATING_COMPLETE "Heating done."
|
||||
#define MSG_BED_HEATING "Bed Heating"
|
||||
#define MSG_BED_HEATING_SAFETY_DISABLED "Heating disabled by safety timer."
|
||||
#define MSG_BED_DONE "Bed done"
|
||||
#define MSG_ERR_KILLED "Printer halted. kill() called!"
|
||||
#define MSG_ERR_STOPPED "Printer stopped due to errors. Fix the error and use M999 to restart. (Temperature is reset. Set it after restarting)"
|
||||
|
@ -422,4 +423,4 @@
|
|||
#define(length=20, lines=4) MSG_CHANGED_PRINTER "Warning: printer type changed."
|
||||
#define(length=20, lines=4) MSG_CHANGED_BOTH "Warning: both printer type and motherboard type changed."
|
||||
#define(length=20, lines=3) MSG_WAITING_TEMP_PINDA "Waiting for PINDA probe cooling"
|
||||
#define(length=20, lines=8) MSG_TEMP_CAL_FAILED "Temperature calibration failed"
|
||||
#define(length=20, lines=8) MSG_TEMP_CAL_FAILED "Temperature calibration failed"
|
||||
|
|
Loading…
Reference in a new issue