Merge pull request from 3d-gussner/PFW-1174

PFW-1174: Add pause/resume for USB/host prints via LCD menu
This commit is contained in:
DRracer 2021-02-25 08:50:41 +01:00 committed by GitHub
commit 9ed713ab13
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 189 additions and 163 deletions

View file

@ -1826,8 +1826,7 @@ void loop()
}
#ifdef FANCHECK
if (fan_check_error && isPrintPaused)
{
if (fan_check_error && isPrintPaused && !IS_SD_PRINTING) {
KEEPALIVE_STATE(PAUSED_FOR_USER);
host_keepalive(); //prevent timeouts since usb processing is disabled until print is resumed. This is for a crude way of pausing a print on all hosts.
}
@ -3734,12 +3733,13 @@ There are reasons why some G Codes aren't in numerical order.
void process_commands()
{
#ifdef FANCHECK
if(fan_check_error == EFCE_DETECTED){
fan_check_error = EFCE_REPORTED;
// SERIAL_PROTOCOLLNRPGM(MSG_OCTOPRINT_PAUSED);
lcd_pause_print();
cmdqueue_serial_disabled = true;
}
if(fan_check_error == EFCE_DETECTED) {
fan_check_error = EFCE_REPORTED;
if (is_usb_printing)
lcd_pause_usb_print();
else
lcd_pause_print();
}
#endif
if (!buflen) return; //empty command
@ -8134,9 +8134,9 @@ Sigma_Exit:
/*!
### M602 - Resume print <a href="https://reprap.org/wiki/G-code#M602:_Resume_print">M602: Resume print</a>
*/
case 602: {
if (isPrintPaused)
lcd_resume_print();
case 602:
{
if (isPrintPaused) lcd_resume_print();
}
break;