Sfoglia il codice sorgente

Clean on trigger instead of split_first_move flag

Scott Lahteine 7 anni fa
parent
commit
3b30cc90f1
4 ha cambiato i file con 2 aggiunte e 6 eliminazioni
  1. 0
    2
      Marlin/Marlin_main.cpp
  2. 1
    3
      Marlin/planner.cpp
  3. 0
    1
      Marlin/planner.h
  4. 1
    0
      Marlin/stepper.cpp

+ 0
- 2
Marlin/Marlin_main.cpp Vedi File

@@ -1719,7 +1719,6 @@ static void setup_for_endstop_or_probe_move() {
1719 1719
   saved_feedrate_percentage = feedrate_percentage;
1720 1720
   feedrate_percentage = 100;
1721 1721
   refresh_cmd_timeout();
1722
-  planner.split_first_move = false; 
1723 1722
 }
1724 1723
 
1725 1724
 static void clean_up_after_endstop_or_probe_move() {
@@ -1729,7 +1728,6 @@ static void clean_up_after_endstop_or_probe_move() {
1729 1728
   feedrate_mm_s = saved_feedrate_mm_s;
1730 1729
   feedrate_percentage = saved_feedrate_percentage;
1731 1730
   refresh_cmd_timeout();
1732
-  planner.split_first_move = true; 
1733 1731
 }
1734 1732
 
1735 1733
 #if HAS_BED_PROBE

+ 1
- 3
Marlin/planner.cpp Vedi File

@@ -92,8 +92,6 @@ float Planner::max_feedrate_mm_s[XYZE_N], // Max speeds in mm per second
92 92
   uint8_t Planner::last_extruder = 0;     // Respond to extruder change
93 93
 #endif
94 94
 
95
-bool Planner::split_first_move = true;
96
-
97 95
 int16_t Planner::flow_percentage[EXTRUDERS] = ARRAY_BY_EXTRUDERS1(100); // Extrusion factor for each extruder
98 96
 
99 97
 float Planner::e_factor[EXTRUDERS],               // The flow percentage and volumetric multiplier combine to scale E movement
@@ -1441,7 +1439,7 @@ void Planner::_buffer_line(const float &a, const float &b, const float &c, const
1441 1439
     position[E_AXIS] = target[E_AXIS];
1442 1440
 
1443 1441
   // Always split the first move into two (if not homing or probing)
1444
-  if (!blocks_queued() && split_first_move) {
1442
+  if (!blocks_queued()) {
1445 1443
     #define _BETWEEN(A) (position[A##_AXIS] + target[A##_AXIS]) >> 1
1446 1444
     const int32_t between[XYZE] = { _BETWEEN(X), _BETWEEN(Y), _BETWEEN(Z), _BETWEEN(E) };
1447 1445
     DISABLE_STEPPER_DRIVER_INTERRUPT();

+ 0
- 1
Marlin/planner.h Vedi File

@@ -161,7 +161,6 @@ class Planner {
161 161
                  travel_acceleration,  // Travel acceleration mm/s^2  DEFAULT ACCELERATION for all NON printing moves. M204 MXXXX
162 162
                  max_jerk[XYZE],       // The largest speed change requiring no acceleration
163 163
                  min_travel_feedrate_mm_s;
164
-    static bool split_first_move;
165 164
 
166 165
     #if HAS_LEVELING
167 166
       static bool leveling_active;          // Flag that bed leveling is enabled

+ 1
- 0
Marlin/stepper.cpp Vedi File

@@ -1255,6 +1255,7 @@ void Stepper::endstop_triggered(AxisEnum axis) {
1255 1255
   #endif // !COREXY && !COREXZ && !COREYZ
1256 1256
 
1257 1257
   kill_current_block();
1258
+  cleaning_buffer_counter = -(BLOCK_BUFFER_SIZE - 1); // Ignore remaining blocks
1258 1259
 }
1259 1260
 
1260 1261
 void Stepper::report_positions() {

Loading…
Annulla
Salva