4

In the documentation of some commands of the Marlin firmware (like M112 - Emergency Stop), it says that the EMERGENCY_PARSER should be enabled to execute them instantaneously.

The thing is, I didn't find any information there of how to enable that EMERGENCY_PARSER or how it works.

Any help will be appreciated.

0scar
  • 37,708
  • 12
  • 68
  • 156
fsinisi90
  • 195
  • 2
  • 9

1 Answers1

6

The constant EMERGENCY_PARSER is located in the advanced printer configuration file Marlin/Configuration_adv.h:

// Enable an emergency-command parser to intercept certain commands as they
// enter the serial receive buffer, so they cannot be blocked.
// Currently handles M108, M112, M410
// Does not work on boards using AT90USB (USBCON) processors!
//#define EMERGENCY_PARSER

To enable the EMERGENCY_PARSER, you need to remove the // before #define EMERGENCY_PARSER and recompile the sources.

Normally your printer will execute a command until it is ready to accept a next instruction. Without the EMERGENCY_PARSER set, the printer finishes the instruction that it is executing at the moment, if set, the execution is interrupted and immediately sent and thus not waiting for a clear space in the buffer.

0scar
  • 37,708
  • 12
  • 68
  • 156