Browse Source

Fix SPI_ENDSTOPS compile error (#14906)

Giuliano Zaro 6 years ago
parent
commit
a7f1021265
1 changed files with 6 additions and 1 deletions
  1. 6
    1
      Marlin/src/Marlin.cpp

+ 6
- 1
Marlin/src/Marlin.cpp View File

@@ -661,9 +661,14 @@ void idle(
661 661
 ) {
662 662
 
663 663
   #if ENABLED(SPI_ENDSTOPS)
664
-    if (endstops.tmc_spi_homing.any && ELAPSED(millis(), sg_guard_period))
664
+    if (endstops.tmc_spi_homing.any
665
+      #if ENABLED(IMPROVE_HOMING_RELIABILITY)
666
+        && ELAPSED(millis(), sg_guard_period)
667
+      #endif
668
+    ) {
665 669
       for (uint8_t i = 4; i--;) // Read SGT 4 times per idle loop
666 670
         if (endstops.tmc_spi_homing_check()) break;
671
+    }
667 672
   #endif
668 673
 
669 674
   #if ENABLED(MAX7219_DEBUG)

Loading…
Cancel
Save