|
@@ -150,7 +150,7 @@ void GCodeParser::parse(char *p) {
|
150
|
150
|
#endif
|
151
|
151
|
|
152
|
152
|
// Only use string_arg for these M codes
|
153
|
|
- if (letter == 'M') switch (codenum) { case 23: case 28: case 30: case 117: case 118: case 928: string_arg = p; return; default: break; }
|
|
153
|
+ if (letter == 'M') switch (codenum) { case 23: case 28: case 30: case 117: case 928: string_arg = p; return; default: break; }
|
154
|
154
|
|
155
|
155
|
#if ENABLED(DEBUG_GCODE_PARSER)
|
156
|
156
|
const bool debug = codenum == 800;
|
|
@@ -162,6 +162,7 @@ void GCodeParser::parse(char *p) {
|
162
|
162
|
* Most codes ignore 'string_arg', but those that want a string will get the right pointer.
|
163
|
163
|
* The following loop assigns the first "parameter" having no numeric value to 'string_arg'.
|
164
|
164
|
* This allows M0/M1 with expire time to work: "M0 S5 You Win!"
|
|
165
|
+ * For 'M118' you must use 'E1' and 'A1' rather than just 'E' or 'A'
|
165
|
166
|
*/
|
166
|
167
|
string_arg = NULL;
|
167
|
168
|
while (char code = *p++) { // Get the next parameter. A NUL ends the loop
|