Browse Source

Fix undefined/unused, Touch UI (#17874)

Marcio T 4 years ago
parent
commit
2a959cde6f
No account linked to committer's email address

+ 1
- 0
Marlin/src/lcd/dogm/ultralcd_DOGM.cpp View File

123
           custom_start_bmp
123
           custom_start_bmp
124
         #endif
124
         #endif
125
       ;
125
       ;
126
+      TERN(CUSTOM_BOOTSCREEN_ANIMATED,,UNUSED(frame));
126
 
127
 
127
       u8g.drawBitmapP(left, top, CUSTOM_BOOTSCREEN_BMP_BYTEWIDTH, CUSTOM_BOOTSCREEN_BMPHEIGHT, bmp);
128
       u8g.drawBitmapP(left, top, CUSTOM_BOOTSCREEN_BMP_BYTEWIDTH, CUSTOM_BOOTSCREEN_BMPHEIGHT, bmp);
128
 
129
 

+ 4
- 1
Marlin/src/lcd/extui/lib/ftdi_eve_touch_ui/ftdi_eve_lib/basic/spi.cpp View File

32
     #ifdef CLCD_SPI_BUS
32
     #ifdef CLCD_SPI_BUS
33
       SPIClass EVE_SPI(CLCD_SPI_BUS);
33
       SPIClass EVE_SPI(CLCD_SPI_BUS);
34
     #endif
34
     #endif
35
-    SPISettings SPI::spi_settings(SPI_FREQUENCY, MSBFIRST, SPI_MODE0);
35
+    #ifndef CLCD_HW_SPI_SPEED
36
+      #define CLCD_HW_SPI_SPEED 8000000 >> SPI_SPEED
37
+    #endif
38
+    SPISettings SPI::spi_settings(CLCD_HW_SPI_SPEED, MSBFIRST, SPI_MODE0);
36
   #endif
39
   #endif
37
 
40
 
38
   void SPI::spi_init() {
41
   void SPI::spi_init() {

+ 3
- 1
Marlin/src/lcd/extui/lib/ftdi_eve_touch_ui/screens/base_screen.cpp View File

78
 }
78
 }
79
 
79
 
80
 void BaseScreen::reset_menu_timeout() {
80
 void BaseScreen::reset_menu_timeout() {
81
-  TERN_(LCD_TIMEOUT_TO_STATUS, last_interaction = millis());
81
+  #if LCD_TIMEOUT_TO_STATUS
82
+    last_interaction = millis();
83
+  #endif
82
 }
84
 }
83
 
85
 
84
 #if LCD_TIMEOUT_TO_STATUS
86
 #if LCD_TIMEOUT_TO_STATUS

+ 1
- 1
Marlin/src/lcd/extui/lib/ftdi_eve_touch_ui/screens/endstop_state_screen.cpp View File

96
   #else
96
   #else
97
     PIN_DISABLED(1, 4, GET_TEXT_F(MSG_RUNOUT_1), FIL_RUNOUT)
97
     PIN_DISABLED(1, 4, GET_TEXT_F(MSG_RUNOUT_1), FIL_RUNOUT)
98
   #endif
98
   #endif
99
-  #if ENABLED(FILAMENT_RUNOUT_SENSOR) && PIN_EXISTS(FIL_RUNOUT2)
99
+  #if ENABLED(FILAMENT_RUNOUT_SENSOR) && PIN_EXISTS(FIL_RUNOUT2) && EXTRUDERS > 1
100
     PIN_ENABLED (3, 4, GET_TEXT_F(MSG_RUNOUT_2), FIL_RUNOUT2, FIL_RUNOUT_INVERTING)
100
     PIN_ENABLED (3, 4, GET_TEXT_F(MSG_RUNOUT_2), FIL_RUNOUT2, FIL_RUNOUT_INVERTING)
101
   #else
101
   #else
102
     PIN_DISABLED(3, 4, GET_TEXT_F(MSG_RUNOUT_2), FIL_RUNOUT2)
102
     PIN_DISABLED(3, 4, GET_TEXT_F(MSG_RUNOUT_2), FIL_RUNOUT2)

+ 1
- 4
Marlin/src/lcd/extui/ui_api.cpp View File

54
 #include "../../module/printcounter.h"
54
 #include "../../module/printcounter.h"
55
 #include "../../libs/duration_t.h"
55
 #include "../../libs/duration_t.h"
56
 #include "../../HAL/shared/Delay.h"
56
 #include "../../HAL/shared/Delay.h"
57
+#include "../../sd/cardreader.h"
57
 
58
 
58
 #if ENABLED(PRINTCOUNTER)
59
 #if ENABLED(PRINTCOUNTER)
59
   #include "../../core/utility.h"
60
   #include "../../core/utility.h"
68
   #include "../../feature/e_parser.h"
69
   #include "../../feature/e_parser.h"
69
 #endif
70
 #endif
70
 
71
 
71
-#if ENABLED(SDSUPPORT)
72
-  #include "../../sd/cardreader.h"
73
-#endif
74
-
75
 #if HAS_TRINAMIC_CONFIG
72
 #if HAS_TRINAMIC_CONFIG
76
   #include "../../feature/tmc_util.h"
73
   #include "../../feature/tmc_util.h"
77
   #include "../../module/stepper/indirection.h"
74
   #include "../../module/stepper/indirection.h"

+ 2
- 0
Marlin/src/module/motion.cpp View File

1514
       // retrace by the amount computed in mmDelta.
1514
       // retrace by the amount computed in mmDelta.
1515
       do_homing_move(axis, mmDelta, get_homing_bump_feedrate(axis));
1515
       do_homing_move(axis, mmDelta, get_homing_bump_feedrate(axis));
1516
     }
1516
     }
1517
+  #else
1518
+    UNUSED(axis);
1517
   #endif
1519
   #endif
1518
 }
1520
 }
1519
 
1521
 

+ 2
- 1
Marlin/src/sd/cardreader.h View File

23
 
23
 
24
 #include "../inc/MarlinConfig.h"
24
 #include "../inc/MarlinConfig.h"
25
 
25
 
26
+#define IFSD(A,B) TERN(SDSUPPORT,A,B)
27
+
26
 #if ENABLED(SDSUPPORT)
28
 #if ENABLED(SDSUPPORT)
27
 
29
 
28
 #if BOTH(SDCARD_SORT_ALPHA, SDSORT_DYNAMIC_RAM)
30
 #if BOTH(SDCARD_SORT_ALPHA, SDSORT_DYNAMIC_RAM)
30
 #endif
32
 #endif
31
 
33
 
32
 #define SD_ORDER(N,C) (TERN(SDCARD_RATHERRECENTFIRST, C - 1 - (N), N))
34
 #define SD_ORDER(N,C) (TERN(SDCARD_RATHERRECENTFIRST, C - 1 - (N), N))
33
-#define IFSD(A,B) TERN(SDSUPPORT,A,B)
34
 
35
 
35
 #define MAX_DIR_DEPTH     10       // Maximum folder depth
36
 #define MAX_DIR_DEPTH     10       // Maximum folder depth
36
 #define MAXDIRNAMELENGTH   8       // DOS folder name size
37
 #define MAXDIRNAMELENGTH   8       // DOS folder name size

Loading…
Cancel
Save