Browse Source

Follow up fixes to #12884 (#12940)

Marcio Teixeira 5 years ago
parent
commit
f4c16e683b
2 changed files with 6 additions and 2 deletions
  1. 1
    1
      Marlin/src/feature/tmc_util.h
  2. 5
    1
      Marlin/src/lcd/extensible_ui/ui_api.cpp

+ 1
- 1
Marlin/src/feature/tmc_util.h View File

160
 
160
 
161
     #if STEALTHCHOP_ENABLED
161
     #if STEALTHCHOP_ENABLED
162
       inline void refresh_stepping_mode() { en_spreadCycle(!this->stored.stealthChop_enabled); }
162
       inline void refresh_stepping_mode() { en_spreadCycle(!this->stored.stealthChop_enabled); }
163
-      inline bool get_stealthChop_status() { !this->en_spreadCycle(); }
163
+      inline bool get_stealthChop_status() { return !this->en_spreadCycle(); }
164
     #endif
164
     #endif
165
 
165
 
166
     #if HAS_LCD_MENU
166
     #if HAS_LCD_MENU

+ 5
- 1
Marlin/src/lcd/extensible_ui/ui_api.cpp View File

71
   #include "../../module/printcounter.h"
71
   #include "../../module/printcounter.h"
72
 #endif
72
 #endif
73
 
73
 
74
+#if HAS_TRINAMIC && HAS_LCD_MENU
75
+  #include "../../feature/tmc_util.h"
76
+#endif
77
+
74
 #include "ui_api.h"
78
 #include "ui_api.h"
75
 
79
 
76
 #if ENABLED(BACKLASH_GCODE)
80
 #if ENABLED(BACKLASH_GCODE)
699
     SET_INPUT_PULLUP(SD_DETECT_PIN);
703
     SET_INPUT_PULLUP(SD_DETECT_PIN);
700
   #endif
704
   #endif
701
 
705
 
702
-  #if HAS_TRINAMIC
706
+  #if HAS_TRINAMIC && HAS_LCD_MENU
703
     init_tmc_section();
707
     init_tmc_section();
704
   #endif
708
   #endif
705
 
709
 

Loading…
Cancel
Save