Browse Source

Regression: Endstops Core compatibility (#10823)

Co-Authored-By: ejtagle <ejtagle@hotmail.com>
Scott Lahteine 7 years ago
parent
commit
3e3789da85
No account linked to committer's email address

+ 1
- 0
Marlin/src/core/macros.h View File

71
 #define TEST(n,b) !!((n)&_BV(b))
71
 #define TEST(n,b) !!((n)&_BV(b))
72
 #define SBI(n,b) (n |= _BV(b))
72
 #define SBI(n,b) (n |= _BV(b))
73
 #define CBI(n,b) (n &= ~_BV(b))
73
 #define CBI(n,b) (n &= ~_BV(b))
74
+#define SET_BIT(N,B,TF) do{ if (TF) SBI(N,B); else CBI(N,B); }while(0)
74
 
75
 
75
 #define _BV32(b) (1UL << (b))
76
 #define _BV32(b) (1UL << (b))
76
 #define TEST32(n,b) !!((n)&_BV32(b))
77
 #define TEST32(n,b) !!((n)&_BV32(b))

+ 29
- 84
Marlin/src/module/endstops.cpp View File

37
 #endif
37
 #endif
38
 
38
 
39
 #if HAS_BED_PROBE
39
 #if HAS_BED_PROBE
40
-  #define ENDSTOPS_ENABLED  (endstops.enabled || endstops.z_probe_enabled)
40
+  #define ENDSTOPS_ENABLED  (enabled || z_probe_enabled)
41
 #else
41
 #else
42
-  #define ENDSTOPS_ENABLED  endstops.enabled
42
+  #define ENDSTOPS_ENABLED  enabled
43
 #endif
43
 #endif
44
 
44
 
45
 Endstops endstops;
45
 Endstops endstops;
223
 } // Endstops::init
223
 } // Endstops::init
224
 
224
 
225
 // Called from ISR. A change was detected. Find out what happened!
225
 // Called from ISR. A change was detected. Find out what happened!
226
-void Endstops::check_possible_change() { if (ENDSTOPS_ENABLED) endstops.update(); }
226
+void Endstops::check_possible_change() { if (ENDSTOPS_ENABLED) update(); }
227
 
227
 
228
 // Called from ISR: Poll endstop state if required
228
 // Called from ISR: Poll endstop state if required
229
 void Endstops::poll() {
229
 void Endstops::poll() {
230
 
230
 
231
   #if ENABLED(PINS_DEBUGGING)
231
   #if ENABLED(PINS_DEBUGGING)
232
-    endstops.run_monitor();  // report changes in endstop status
232
+    run_monitor();  // report changes in endstop status
233
   #endif
233
   #endif
234
 
234
 
235
   #if DISABLED(ENDSTOP_INTERRUPTS_FEATURE) || ENABLED(ENDSTOP_NOISE_FILTER)
235
   #if DISABLED(ENDSTOP_INTERRUPTS_FEATURE) || ENABLED(ENDSTOP_NOISE_FILTER)
236
-    if (ENDSTOPS_ENABLED) endstops.update();
236
+    if (ENDSTOPS_ENABLED) update();
237
   #endif
237
   #endif
238
 }
238
 }
239
 
239
 
241
   enabled_globally = enabled = onoff;
241
   enabled_globally = enabled = onoff;
242
 
242
 
243
   #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
243
   #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
244
-    if (onoff) endstops.update(); // If enabling, update state now
244
+    if (onoff) update(); // If enabling, update state now
245
   #endif
245
   #endif
246
 }
246
 }
247
 
247
 
250
   enabled = onoff;
250
   enabled = onoff;
251
 
251
 
252
   #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
252
   #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
253
-    if (onoff) endstops.update(); // If enabling, update state now
253
+    if (onoff) update(); // If enabling, update state now
254
   #endif
254
   #endif
255
 }
255
 }
256
 
256
 
257
-
258
 // Disable / Enable endstops based on ENSTOPS_ONLY_FOR_HOMING and global enable
257
 // Disable / Enable endstops based on ENSTOPS_ONLY_FOR_HOMING and global enable
259
 void Endstops::not_homing() {
258
 void Endstops::not_homing() {
260
   enabled = enabled_globally;
259
   enabled = enabled_globally;
261
 
260
 
262
   #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
261
   #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
263
-    if (enabled) endstops.update(); // If enabling, update state now
262
+    if (enabled) update(); // If enabling, update state now
264
   #endif
263
   #endif
265
 }
264
 }
266
 
265
 
269
   hit_state = 0;
268
   hit_state = 0;
270
 
269
 
271
   #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
270
   #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
272
-    if (enabled) endstops.update(); // If enabling, update state now
271
+    if (enabled) update(); // If enabling, update state now
273
   #endif
272
   #endif
274
 }
273
 }
275
 
274
 
279
     z_probe_enabled = onoff;
278
     z_probe_enabled = onoff;
280
 
279
 
281
     #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
280
     #if ENABLED(ENDSTOP_INTERRUPTS_FEATURE)
282
-      if (enabled) endstops.update(); // If enabling, update state now
281
+      if (enabled) update(); // If enabling, update state now
283
     #endif
282
     #endif
284
   }
283
   }
285
 #endif
284
 #endif
417
     if (G38_move) UPDATE_ENDSTOP_BIT(Z, MIN_PROBE);
416
     if (G38_move) UPDATE_ENDSTOP_BIT(Z, MIN_PROBE);
418
   #endif
417
   #endif
419
 
418
 
420
-  /**
421
-   * Define conditions for checking endstops
422
-   */
423
-
424
-  #if IS_CORE
425
-    #define S_(N) stepper.movement_non_null(CORE_AXIS_##N)
426
-    #define D_(N) stepper.motor_direction(CORE_AXIS_##N)
419
+  // With Dual X, endstops are only checked in the homing direction for the active extruder
420
+  #if ENABLED(DUAL_X_CARRIAGE)
421
+    #define E0_ACTIVE stepper.movement_extruder() == 0
422
+    #define X_MIN_TEST ((X_HOME_DIR < 0 && E0_ACTIVE) || (X2_HOME_DIR < 0 && !E0_ACTIVE))
423
+    #define X_MAX_TEST ((X_HOME_DIR > 0 && E0_ACTIVE) || (X2_HOME_DIR > 0 && !E0_ACTIVE))
424
+  #else
425
+    #define X_MIN_TEST true
426
+    #define X_MAX_TEST true
427
   #endif
427
   #endif
428
 
428
 
429
+  // Use HEAD for core axes, AXIS for others
429
   #if CORE_IS_XY || CORE_IS_XZ
430
   #if CORE_IS_XY || CORE_IS_XZ
430
-    /**
431
-     * Head direction in -X axis for CoreXY and CoreXZ bots.
432
-     *
433
-     * If steps differ, both axes are moving.
434
-     * If DeltaA == -DeltaB, the movement is only in the 2nd axis (Y or Z, handled below)
435
-     * If DeltaA ==  DeltaB, the movement is only in the 1st axis (X)
436
-     */
437
-    #if ENABLED(COREXY) || ENABLED(COREXZ)
438
-      #define X_CMP ==
439
-    #else
440
-      #define X_CMP !=
441
-    #endif
442
-    #define X_MOVE_TEST ( S_(1) != S_(2) || (S_(1) > 0 && D_(1) X_CMP D_(2)) )
443
     #define X_AXIS_HEAD X_HEAD
431
     #define X_AXIS_HEAD X_HEAD
444
   #else
432
   #else
445
-    #define X_MOVE_TEST stepper.movement_non_null(X_AXIS)
446
     #define X_AXIS_HEAD X_AXIS
433
     #define X_AXIS_HEAD X_AXIS
447
   #endif
434
   #endif
448
-
449
   #if CORE_IS_XY || CORE_IS_YZ
435
   #if CORE_IS_XY || CORE_IS_YZ
450
-    /**
451
-     * Head direction in -Y axis for CoreXY / CoreYZ bots.
452
-     *
453
-     * If steps differ, both axes are moving
454
-     * If DeltaA ==  DeltaB, the movement is only in the 1st axis (X or Y)
455
-     * If DeltaA == -DeltaB, the movement is only in the 2nd axis (Y or Z)
456
-     */
457
-    #if ENABLED(COREYX) || ENABLED(COREYZ)
458
-      #define Y_CMP ==
459
-    #else
460
-      #define Y_CMP !=
461
-    #endif
462
-    #define Y_MOVE_TEST ( S_(1) != S_(2) || (S_(1) > 0 && D_(1) Y_CMP D_(2)) )
463
     #define Y_AXIS_HEAD Y_HEAD
436
     #define Y_AXIS_HEAD Y_HEAD
464
   #else
437
   #else
465
-    #define Y_MOVE_TEST stepper.movement_non_null(Y_AXIS)
466
     #define Y_AXIS_HEAD Y_AXIS
438
     #define Y_AXIS_HEAD Y_AXIS
467
   #endif
439
   #endif
468
-
469
   #if CORE_IS_XZ || CORE_IS_YZ
440
   #if CORE_IS_XZ || CORE_IS_YZ
470
-    /**
471
-     * Head direction in -Z axis for CoreXZ or CoreYZ bots.
472
-     *
473
-     * If steps differ, both axes are moving
474
-     * If DeltaA ==  DeltaB, the movement is only in the 1st axis (X or Y, already handled above)
475
-     * If DeltaA == -DeltaB, the movement is only in the 2nd axis (Z)
476
-     */
477
-    #if ENABLED(COREZX) || ENABLED(COREZY)
478
-      #define Z_CMP ==
479
-    #else
480
-      #define Z_CMP !=
481
-    #endif
482
-    #define Z_MOVE_TEST ( S_(1) != S_(2) || (S_(1) > 0 && D_(1) Z_CMP D_(2)) )
483
     #define Z_AXIS_HEAD Z_HEAD
441
     #define Z_AXIS_HEAD Z_HEAD
484
   #else
442
   #else
485
-    #define Z_MOVE_TEST stepper.movement_non_null(Z_AXIS)
486
     #define Z_AXIS_HEAD Z_AXIS
443
     #define Z_AXIS_HEAD Z_AXIS
487
   #endif
444
   #endif
488
 
445
 
489
-  // With Dual X, endstops are only checked in the homing direction for the active extruder
490
-  #if ENABLED(DUAL_X_CARRIAGE)
491
-    #define E0_ACTIVE stepper.movement_extruder() == 0
492
-    #define X_MIN_TEST ((X_HOME_DIR < 0 && E0_ACTIVE) || (X2_HOME_DIR < 0 && !E0_ACTIVE))
493
-    #define X_MAX_TEST ((X_HOME_DIR > 0 && E0_ACTIVE) || (X2_HOME_DIR > 0 && !E0_ACTIVE))
494
-  #else
495
-    #define X_MIN_TEST true
496
-    #define X_MAX_TEST true
497
-  #endif
498
-
499
   /**
446
   /**
500
    * Check and update endstops according to conditions
447
    * Check and update endstops according to conditions
501
    */
448
    */
502
-  if (X_MOVE_TEST) {
449
+  if (stepper.axis_is_moving(X_AXIS)) {
503
     if (stepper.motor_direction(X_AXIS_HEAD)) { // -direction
450
     if (stepper.motor_direction(X_AXIS_HEAD)) { // -direction
504
       #if HAS_X_MIN
451
       #if HAS_X_MIN
505
         #if ENABLED(X_DUAL_ENDSTOPS)
452
         #if ENABLED(X_DUAL_ENDSTOPS)
530
     }
477
     }
531
   }
478
   }
532
 
479
 
533
-  if (Y_MOVE_TEST) {
480
+  if (stepper.axis_is_moving(Y_AXIS)) {
534
     if (stepper.motor_direction(Y_AXIS_HEAD)) { // -direction
481
     if (stepper.motor_direction(Y_AXIS_HEAD)) { // -direction
535
       #if HAS_Y_MIN
482
       #if HAS_Y_MIN
536
         #if ENABLED(Y_DUAL_ENDSTOPS)
483
         #if ENABLED(Y_DUAL_ENDSTOPS)
561
     }
508
     }
562
   }
509
   }
563
 
510
 
564
-  if (Z_MOVE_TEST) {
511
+  if (stepper.axis_is_moving(Z_AXIS)) {
565
     if (stepper.motor_direction(Z_AXIS_HEAD)) { // Z -direction. Gantry down, bed up.
512
     if (stepper.motor_direction(Z_AXIS_HEAD)) { // Z -direction. Gantry down, bed up.
566
       #if HAS_Z_MIN
513
       #if HAS_Z_MIN
567
         #if ENABLED(Z_DUAL_ENDSTOPS)
514
         #if ENABLED(Z_DUAL_ENDSTOPS)
582
 
529
 
583
       // When closing the gap check the enabled probe
530
       // When closing the gap check the enabled probe
584
       #if ENABLED(Z_MIN_PROBE_ENDSTOP)
531
       #if ENABLED(Z_MIN_PROBE_ENDSTOP)
585
-        if (z_probe_enabled) {
586
-          UPDATE_ENDSTOP_BIT(Z, MIN_PROBE);
587
-        }
532
+        if (z_probe_enabled) UPDATE_ENDSTOP_BIT(Z, MIN_PROBE);
588
       #endif
533
       #endif
589
     }
534
     }
590
     else { // Z +direction. Gantry up, bed down.
535
     else { // Z +direction. Gantry up, bed down.
660
     // If G38 command is active check Z_MIN_PROBE for ALL movement
605
     // If G38 command is active check Z_MIN_PROBE for ALL movement
661
     if (G38_move) {
606
     if (G38_move) {
662
       if (TEST_ENDSTOP(_ENDSTOP(Z, MIN_PROBE))) {
607
       if (TEST_ENDSTOP(_ENDSTOP(Z, MIN_PROBE))) {
663
-        if      (stepper.movement_non_null(_AXIS(X))) { _ENDSTOP_HIT(X, MIN); planner.endstop_triggered(_AXIS(X)); }
664
-        else if (stepper.movement_non_null(_AXIS(Y))) { _ENDSTOP_HIT(Y, MIN); planner.endstop_triggered(_AXIS(Y)); }
665
-        else if (stepper.movement_non_null(_AXIS(Z))) { _ENDSTOP_HIT(Z, MIN); planner.endstop_triggered(_AXIS(Z)); }
608
+        if      (stepper.axis_is_moving(_AXIS(X))) { _ENDSTOP_HIT(X, MIN); planner.endstop_triggered(_AXIS(X)); }
609
+        else if (stepper.axis_is_moving(_AXIS(Y))) { _ENDSTOP_HIT(Y, MIN); planner.endstop_triggered(_AXIS(Y)); }
610
+        else if (stepper.axis_is_moving(_AXIS(Z))) { _ENDSTOP_HIT(Z, MIN); planner.endstop_triggered(_AXIS(Z)); }
666
         G38_endstop_hit = true;
611
         G38_endstop_hit = true;
667
       }
612
       }
668
     }
613
     }
669
   #endif
614
   #endif
670
 
615
 
671
   // Now, we must signal, after validation, if an endstop limit is pressed or not
616
   // Now, we must signal, after validation, if an endstop limit is pressed or not
672
-  if (X_MOVE_TEST) {
617
+  if (stepper.axis_is_moving(X_AXIS)) {
673
     if (stepper.motor_direction(X_AXIS_HEAD)) { // -direction
618
     if (stepper.motor_direction(X_AXIS_HEAD)) { // -direction
674
       #if HAS_X_MIN
619
       #if HAS_X_MIN
675
         #if ENABLED(X_DUAL_ENDSTOPS)
620
         #if ENABLED(X_DUAL_ENDSTOPS)
690
     }
635
     }
691
   }
636
   }
692
 
637
 
693
-  if (Y_MOVE_TEST) {
638
+  if (stepper.axis_is_moving(Y_AXIS)) {
694
     if (stepper.motor_direction(Y_AXIS_HEAD)) { // -direction
639
     if (stepper.motor_direction(Y_AXIS_HEAD)) { // -direction
695
       #if HAS_Y_MIN
640
       #if HAS_Y_MIN
696
         #if ENABLED(Y_DUAL_ENDSTOPS)
641
         #if ENABLED(Y_DUAL_ENDSTOPS)
711
     }
656
     }
712
   }
657
   }
713
 
658
 
714
-  if (Z_MOVE_TEST) {
659
+  if (stepper.axis_is_moving(Z_AXIS)) {
715
     if (stepper.motor_direction(Z_AXIS_HEAD)) { // Z -direction. Gantry down, bed up.
660
     if (stepper.motor_direction(Z_AXIS_HEAD)) { // Z -direction. Gantry down, bed up.
716
       #if HAS_Z_MIN
661
       #if HAS_Z_MIN
717
         #if ENABLED(Z_DUAL_ENDSTOPS)
662
         #if ENABLED(Z_DUAL_ENDSTOPS)

+ 73
- 6
Marlin/src/module/stepper.cpp View File

96
 
96
 
97
 // private:
97
 // private:
98
 
98
 
99
-uint8_t Stepper::last_direction_bits = 0,       // The next stepping-bits to be output
100
-        Stepper::last_movement_extruder = 0xFF; // Last movement extruder, as computed when the last movement was fetched from planner
101
-bool Stepper::abort_current_block,              // Signals to the stepper that current block should be aborted
102
-     Stepper::last_movement_non_null[NUM_AXIS]; // Last Movement in the given direction is not null, as computed when the last movement was fetched from planner
99
+uint8_t Stepper::last_direction_bits = 0,
100
+        Stepper::last_movement_extruder = 0xFF,
101
+        Stepper::axis_did_move;
102
+bool Stepper::abort_current_block;
103
 
103
 
104
 #if ENABLED(X_DUAL_ENDSTOPS)
104
 #if ENABLED(X_DUAL_ENDSTOPS)
105
   bool Stepper::locked_x_motor = false, Stepper::locked_x2_motor = false;
105
   bool Stepper::locked_x_motor = false, Stepper::locked_x2_motor = false;
1566
           return interval; // No more queued movements!
1566
           return interval; // No more queued movements!
1567
       }
1567
       }
1568
 
1568
 
1569
-      // Compute movement direction for proper endstop handling
1570
-      LOOP_NA(i) last_movement_non_null[i] = !!current_block->steps[i];
1569
+      // Flag all moving axes for proper endstop handling
1570
+
1571
+      #if IS_CORE
1572
+        // Define conditions for checking endstops
1573
+        #define S_(N) current_block->steps[CORE_AXIS_##N]
1574
+        #define D_(N) motor_direction(CORE_AXIS_##N)
1575
+      #endif
1576
+
1577
+      #if CORE_IS_XY || CORE_IS_XZ
1578
+        /**
1579
+         * Head direction in -X axis for CoreXY and CoreXZ bots.
1580
+         *
1581
+         * If steps differ, both axes are moving.
1582
+         * If DeltaA == -DeltaB, the movement is only in the 2nd axis (Y or Z, handled below)
1583
+         * If DeltaA ==  DeltaB, the movement is only in the 1st axis (X)
1584
+         */
1585
+        #if ENABLED(COREXY) || ENABLED(COREXZ)
1586
+          #define X_CMP ==
1587
+        #else
1588
+          #define X_CMP !=
1589
+        #endif
1590
+        #define X_MOVE_TEST ( S_(1) != S_(2) || (S_(1) > 0 && D_(1) X_CMP D_(2)) )
1591
+      #else
1592
+        #define X_MOVE_TEST !!current_block->steps[X_AXIS]
1593
+      #endif
1594
+
1595
+      #if CORE_IS_XY || CORE_IS_YZ
1596
+        /**
1597
+         * Head direction in -Y axis for CoreXY / CoreYZ bots.
1598
+         *
1599
+         * If steps differ, both axes are moving
1600
+         * If DeltaA ==  DeltaB, the movement is only in the 1st axis (X or Y)
1601
+         * If DeltaA == -DeltaB, the movement is only in the 2nd axis (Y or Z)
1602
+         */
1603
+        #if ENABLED(COREYX) || ENABLED(COREYZ)
1604
+          #define Y_CMP ==
1605
+        #else
1606
+          #define Y_CMP !=
1607
+        #endif
1608
+        #define Y_MOVE_TEST ( S_(1) != S_(2) || (S_(1) > 0 && D_(1) Y_CMP D_(2)) )
1609
+      #else
1610
+        #define Y_MOVE_TEST !!current_block->steps[Y_AXIS]
1611
+      #endif
1612
+
1613
+      #if CORE_IS_XZ || CORE_IS_YZ
1614
+        /**
1615
+         * Head direction in -Z axis for CoreXZ or CoreYZ bots.
1616
+         *
1617
+         * If steps differ, both axes are moving
1618
+         * If DeltaA ==  DeltaB, the movement is only in the 1st axis (X or Y, already handled above)
1619
+         * If DeltaA == -DeltaB, the movement is only in the 2nd axis (Z)
1620
+         */
1621
+        #if ENABLED(COREZX) || ENABLED(COREZY)
1622
+          #define Z_CMP ==
1623
+        #else
1624
+          #define Z_CMP !=
1625
+        #endif
1626
+        #define Z_MOVE_TEST ( S_(1) != S_(2) || (S_(1) > 0 && D_(1) Z_CMP D_(2)) )
1627
+      #else
1628
+        #define Z_MOVE_TEST !!current_block->steps[Z_AXIS]
1629
+      #endif
1630
+
1631
+      SET_BIT(axis_did_move, X_AXIS, X_MOVE_TEST);
1632
+      SET_BIT(axis_did_move, Y_AXIS, Y_MOVE_TEST);
1633
+      SET_BIT(axis_did_move, Z_AXIS, Z_MOVE_TEST);
1634
+      SET_BIT(axis_did_move, E_AXIS, !!current_block->steps[E_AXIS]);
1635
+      SET_BIT(axis_did_move, X_HEAD, !!current_block->steps[X_HEAD]);
1636
+      SET_BIT(axis_did_move, Y_HEAD, !!current_block->steps[Y_HEAD]);
1637
+      SET_BIT(axis_did_move, Z_HEAD, !!current_block->steps[Z_HEAD]);
1571
 
1638
 
1572
       // Initialize the trapezoid generator from the current block.
1639
       // Initialize the trapezoid generator from the current block.
1573
       #if ENABLED(LIN_ADVANCE)
1640
       #if ENABLED(LIN_ADVANCE)

+ 6
- 7
Marlin/src/module/stepper.h View File

75
 
75
 
76
   private:
76
   private:
77
 
77
 
78
-    static uint8_t last_direction_bits,           // The next stepping-bits to be output
79
-                   last_movement_extruder;        // Last movement extruder, as computed when the last movement was fetched from planner
80
-    static bool abort_current_block,              // Signals to the stepper that current block should be aborted
81
-                last_movement_non_null[NUM_AXIS]; // Last Movement in the given direction is not null, as computed when the last movement was fetched from planner
78
+    static uint8_t last_direction_bits,     // The next stepping-bits to be output
79
+                   last_movement_extruder,  // Last movement extruder, as computed when the last movement was fetched from planner
80
+                   axis_did_move;           // Last Movement in the given direction is not null, as computed when the last movement was fetched from planner
81
+    static bool abort_current_block;        // Signals to the stepper that current block should be aborted
82
 
82
 
83
     #if ENABLED(X_DUAL_ENDSTOPS)
83
     #if ENABLED(X_DUAL_ENDSTOPS)
84
       static bool locked_x_motor, locked_x2_motor;
84
       static bool locked_x_motor, locked_x2_motor;
198
     FORCE_INLINE static bool motor_direction(const AxisEnum axis) { return TEST(last_direction_bits, axis); }
198
     FORCE_INLINE static bool motor_direction(const AxisEnum axis) { return TEST(last_direction_bits, axis); }
199
 
199
 
200
     // The last movement direction was not null on the specified axis. Note that motor direction is not necessarily the same.
200
     // The last movement direction was not null on the specified axis. Note that motor direction is not necessarily the same.
201
-    FORCE_INLINE static bool movement_non_null(const AxisEnum axis) { return last_movement_non_null[axis]; }
201
+    FORCE_INLINE static bool axis_is_moving(const AxisEnum axis) { return TEST(axis_did_move, axis); }
202
 
202
 
203
     // The extruder associated to the last movement
203
     // The extruder associated to the last movement
204
     FORCE_INLINE static uint8_t movement_extruder() { return last_movement_extruder; }
204
     FORCE_INLINE static uint8_t movement_extruder() { return last_movement_extruder; }
326
         }
326
         }
327
         if (timer < 100) { // (20kHz - this should never happen)
327
         if (timer < 100) { // (20kHz - this should never happen)
328
           timer = 100;
328
           timer = 100;
329
-          SERIAL_ECHOPGM(MSG_STEPPER_TOO_HIGH);
330
-          SERIAL_ECHOLN(step_rate);
329
+          SERIAL_ECHOLNPAIR(MSG_STEPPER_TOO_HIGH, step_rate);
331
         }
330
         }
332
       #endif
331
       #endif
333
 
332
 

Loading…
Cancel
Save