Browse Source

Merge pull request #5691 from AnHardt/fix5677

Fix M110 without leading N
Scott Lahteine 7 years ago
parent
commit
d3cb1a86be
3 changed files with 7 additions and 7 deletions
  1. 5
    5
      Marlin/Marlin_main.cpp
  2. 1
    1
      Marlin/cardreader.cpp
  3. 1
    1
      Marlin/servo.cpp

+ 5
- 5
Marlin/Marlin_main.cpp View File

330
 /**
330
 /**
331
  * GCode line number handling. Hosts may opt to include line numbers when
331
  * GCode line number handling. Hosts may opt to include line numbers when
332
  * sending commands to Marlin, and lines will be checked for sequentiality.
332
  * sending commands to Marlin, and lines will be checked for sequentiality.
333
- * M110 S<int> sets the current line number.
333
+ * M110 N<int> sets the current line number.
334
  */
334
  */
335
 static long gcode_N, gcode_LastN, Stopped_gcode_LastN = 0;
335
 static long gcode_N, gcode_LastN, Stopped_gcode_LastN = 0;
336
 
336
 
629
 
629
 
630
 #ifdef CHDK
630
 #ifdef CHDK
631
   millis_t chdkHigh = 0;
631
   millis_t chdkHigh = 0;
632
-  boolean chdkActive = false;
632
+  bool chdkActive = false;
633
 #endif
633
 #endif
634
 
634
 
635
 #if ENABLED(PID_EXTRUSION_SCALING)
635
 #if ENABLED(PID_EXTRUSION_SCALING)
966
 
966
 
967
 inline void get_serial_commands() {
967
 inline void get_serial_commands() {
968
   static char serial_line_buffer[MAX_CMD_SIZE];
968
   static char serial_line_buffer[MAX_CMD_SIZE];
969
-  static boolean serial_comment_mode = false;
969
+  static bool serial_comment_mode = false;
970
 
970
 
971
   // If the command buffer is empty for too long,
971
   // If the command buffer is empty for too long,
972
   // send "wait" to indicate Marlin is still waiting.
972
   // send "wait" to indicate Marlin is still waiting.
1006
 
1006
 
1007
       if (npos) {
1007
       if (npos) {
1008
 
1008
 
1009
-        boolean M110 = strstr_P(command, PSTR("M110")) != NULL;
1009
+        bool M110 = strstr_P(command, PSTR("M110")) != NULL;
1010
 
1010
 
1011
         if (M110) {
1011
         if (M110) {
1012
           char* n2pos = strchr(command + 4, 'N');
1012
           char* n2pos = strchr(command + 4, 'N');
5680
  * M110: Set Current Line Number
5680
  * M110: Set Current Line Number
5681
  */
5681
  */
5682
 inline void gcode_M110() {
5682
 inline void gcode_M110() {
5683
-  if (code_seen('N')) gcode_N = code_value_long();
5683
+  if (code_seen('N')) gcode_LastN = code_value_long();
5684
 }
5684
 }
5685
 
5685
 
5686
 /**
5686
 /**

+ 1
- 1
Marlin/cardreader.cpp View File

81
       createFilename(lfilename, p);
81
       createFilename(lfilename, p);
82
 
82
 
83
       // Allocate enough stack space for the full path to a folder, trailing slash, and nul
83
       // Allocate enough stack space for the full path to a folder, trailing slash, and nul
84
-      boolean prepend_is_empty = (prepend[0] == '\0');
84
+      bool prepend_is_empty = (prepend[0] == '\0');
85
       int len = (prepend_is_empty ? 1 : strlen(prepend)) + strlen(lfilename) + 1 + 1;
85
       int len = (prepend_is_empty ? 1 : strlen(prepend)) + strlen(lfilename) + 1 + 1;
86
       char path[len];
86
       char path[len];
87
 
87
 

+ 1
- 1
Marlin/servo.cpp View File

227
   #endif
227
   #endif
228
 }
228
 }
229
 
229
 
230
-static boolean isTimerActive(timer16_Sequence_t timer) {
230
+static bool isTimerActive(timer16_Sequence_t timer) {
231
   // returns true if any servo is active on this timer
231
   // returns true if any servo is active on this timer
232
   for (uint8_t channel = 0; channel < SERVOS_PER_TIMER; channel++) {
232
   for (uint8_t channel = 0; channel < SERVOS_PER_TIMER; channel++) {
233
     if (SERVO(timer, channel).Pin.isActive)
233
     if (SERVO(timer, channel).Pin.isActive)

Loading…
Cancel
Save