Scott Lahteine 7 лет назад
Родитель
Сommit
053b1371c7
2 измененных файлов: 3 добавлений и 13 удалений
  1. 1
    7
      Marlin/src/gcode/parser.cpp
  2. 2
    6
      Marlin/src/gcode/parser.h

+ 1
- 7
Marlin/src/gcode/parser.cpp Просмотреть файл

@@ -225,13 +225,7 @@ void GCodeParser::parse(char *p) {
225 225
       #endif
226 226
 
227 227
       #if ENABLED(FASTER_GCODE_PARSER)
228
-      {
229
-        set(code, has_num ? p : NULL            // Set parameter exists and pointer (NULL for no number)
230
-          #if ENABLED(DEBUG_GCODE_PARSER)
231
-            , debug
232
-          #endif
233
-        );
234
-      }
228
+        set(code, has_num ? p : NULL);          // Set parameter exists and pointer (NULL for no number)
235 229
       #endif
236 230
     }
237 231
     else if (!string_arg) {                     // Not A-Z? First time, keep as the string_arg

+ 2
- 6
Marlin/src/gcode/parser.h Просмотреть файл

@@ -98,17 +98,13 @@ public:
98 98
   #if ENABLED(FASTER_GCODE_PARSER)
99 99
 
100 100
     // Set the flag and pointer for a parameter
101
-    static void set(const char c, char * const ptr
102
-      #if ENABLED(DEBUG_GCODE_PARSER)
103
-        , const bool debug=false
104
-      #endif
105
-    ) {
101
+    static void set(const char c, char * const ptr) {
106 102
       const uint8_t ind = LETTER_OFF(c);
107 103
       if (ind >= COUNT(param)) return;           // Only A-Z
108 104
       SBI(codebits[PARAM_IND(ind)], PARAM_BIT(ind));        // parameter exists
109 105
       param[ind] = ptr ? ptr - command_ptr : 0;  // parameter offset or 0
110 106
       #if ENABLED(DEBUG_GCODE_PARSER)
111
-        if (debug) {
107
+        if (codenum == 800) {
112 108
           SERIAL_ECHOPAIR("Set bit ", (int)PARAM_BIT(ind));
113 109
           SERIAL_ECHOPAIR(" of index ", (int)PARAM_IND(ind));
114 110
           SERIAL_ECHOLNPAIR(" | param = ", (int)param[ind]);

Загрузка…
Отмена
Сохранить