Browse Source

Apply SERIAL_FLUSH macro

Scott Lahteine 7 years ago
parent
commit
241e55ef3b

+ 3
- 3
Marlin/src/feature/bedlevel/ubl/ubl_G29.cpp View File

767
           const float measured_z = probe_pt(rawx, rawy, stow_probe, g29_verbose_level); // TODO: Needs error handling
767
           const float measured_z = probe_pt(rawx, rawy, stow_probe, g29_verbose_level); // TODO: Needs error handling
768
           z_values[location.x_index][location.y_index] = measured_z;
768
           z_values[location.x_index][location.y_index] = measured_z;
769
         }
769
         }
770
-        MYSERIAL0.flush(); // Prevent host M105 buffer overrun.
770
+        SERIAL_FLUSH(); // Prevent host M105 buffer overrun.
771
       } while (location.x_index >= 0 && --max_iterations);
771
       } while (location.x_index >= 0 && --max_iterations);
772
 
772
 
773
       STOW_PROBE();
773
       STOW_PROBE();
905
           SERIAL_PROTOCOL_F(z_values[location.x_index][location.y_index], 6);
905
           SERIAL_PROTOCOL_F(z_values[location.x_index][location.y_index], 6);
906
           SERIAL_EOL();
906
           SERIAL_EOL();
907
         }
907
         }
908
-        MYSERIAL0.flush(); // Prevent host M105 buffer overrun.
908
+        SERIAL_FLUSH(); // Prevent host M105 buffer overrun.
909
       } while (location.x_index >= 0 && location.y_index >= 0);
909
       } while (location.x_index >= 0 && location.y_index >= 0);
910
 
910
 
911
       if (do_ubl_mesh_map) display_map(g29_map_type);  // show user where we're probing
911
       if (do_ubl_mesh_map) display_map(g29_map_type);  // show user where we're probing
1417
             do_blocking_move_to_z(h_offset + new_z); // Move the nozzle as the point is edited
1417
             do_blocking_move_to_z(h_offset + new_z); // Move the nozzle as the point is edited
1418
           #endif
1418
           #endif
1419
           idle();
1419
           idle();
1420
-          MYSERIAL0.flush(); // Prevent host M105 buffer overrun.
1420
+          SERIAL_FLUSH(); // Prevent host M105 buffer overrun.
1421
         } while (!is_lcd_clicked());
1421
         } while (!is_lcd_clicked());
1422
 
1422
 
1423
         if (!lcd_map_control) lcd_return_to_status();
1423
         if (!lcd_map_control) lcd_return_to_status();

+ 4
- 4
Marlin/src/gcode/bedlevel/G26.cpp View File

437
             SERIAL_EOL();
437
             SERIAL_EOL();
438
           }
438
           }
439
           idle();
439
           idle();
440
-          MYSERIAL0.flush(); // Prevent host M105 buffer overrun.
440
+          SERIAL_FLUSH(); // Prevent host M105 buffer overrun.
441
         }
441
         }
442
     #if ENABLED(ULTRA_LCD)
442
     #if ENABLED(ULTRA_LCD)
443
       }
443
       }
460
       SERIAL_EOL();
460
       SERIAL_EOL();
461
     }
461
     }
462
     idle();
462
     idle();
463
-    MYSERIAL0.flush(); // Prevent host M105 buffer overrun.
463
+    SERIAL_FLUSH(); // Prevent host M105 buffer overrun.
464
   }
464
   }
465
 
465
 
466
   #if ENABLED(ULTRA_LCD)
466
   #if ENABLED(ULTRA_LCD)
809
 
809
 
810
 
810
 
811
         print_line_from_here_to_there(rx, ry, g26_layer_height, xe, ye, g26_layer_height);
811
         print_line_from_here_to_there(rx, ry, g26_layer_height, xe, ye, g26_layer_height);
812
-        MYSERIAL0.flush(); // Prevent host M105 buffer overrun.
812
+        SERIAL_FLUSH(); // Prevent host M105 buffer overrun.
813
       }
813
       }
814
       if (look_for_lines_to_connect())
814
       if (look_for_lines_to_connect())
815
         goto LEAVE;
815
         goto LEAVE;
816
     }
816
     }
817
-    MYSERIAL0.flush(); // Prevent host M105 buffer overrun.
817
+    SERIAL_FLUSH(); // Prevent host M105 buffer overrun.
818
   } while (--g26_repeats && location.x_index >= 0 && location.y_index >= 0);
818
   } while (--g26_repeats && location.x_index >= 0 && location.y_index >= 0);
819
 
819
 
820
   LEAVE:
820
   LEAVE:

Loading…
Cancel
Save