Procházet zdrojové kódy

Fix a compile warning, etc. (#12955)

Ludy před 6 roky
rodič
revize
acf266fe78

+ 1
- 0
Marlin/src/gcode/motion/G2_G3.cpp Zobrazit soubor

@@ -184,6 +184,7 @@ void plan_arc(
184 184
     raw[q_axis] = center_Q + r_Q;
185 185
     #if ENABLED(AUTO_BED_LEVELING_UBL)
186 186
       raw[l_axis] = start_L;
187
+      UNUSED(linear_per_segment);
187 188
     #else
188 189
       raw[l_axis] += linear_per_segment;
189 190
     #endif

+ 3
- 7
Marlin/src/gcode/sdcard/M20-M30_M32-M34_M524_M928.cpp Zobrazit soubor

@@ -179,13 +179,9 @@ void GcodeSuite::M28() {
179 179
 
180 180
   #if ENABLED(FAST_FILE_TRANSFER)
181 181
 
182
-    const int16_t port =
183
-      #if NUM_SERIAL > 1
184
-        command_queue_port[cmd_queue_index_r]
185
-      #else
186
-        0
187
-      #endif
188
-    ;
182
+    #if NUM_SERIAL > 1
183
+      const int16_t port = command_queue_port[cmd_queue_index_r];
184
+    #endif
189 185
 
190 186
     bool binary_mode = false;
191 187
     char *p = parser.string_arg;

+ 1
- 1
Marlin/src/gcode/temperature/M106_M107.cpp Zobrazit soubor

@@ -48,7 +48,7 @@ void GcodeSuite::M106() {
48 48
   if (p < MIN(EXTRUDERS, FAN_COUNT)) {
49 49
 
50 50
     #if ENABLED(EXTRA_FAN_SPEED)
51
-      const int16_t t = parser.intval('T');
51
+      const uint16_t t = parser.intval('T');
52 52
       if (t > 0) return thermalManager.set_temp_fan_speed(p, t);
53 53
     #endif
54 54
 

+ 2
- 2
Marlin/src/lcd/menu/menu_bed_leveling.cpp Zobrazit soubor

@@ -210,8 +210,8 @@
210 210
     static uint8_t xind, yind; // =0
211 211
     START_MENU();
212 212
     MENU_BACK(MSG_BED_LEVELING);
213
-    MENU_ITEM_EDIT(int8, MSG_MESH_X, &xind, 0, GRID_MAX_POINTS_X - 1);
214
-    MENU_ITEM_EDIT(int8, MSG_MESH_Y, &yind, 0, GRID_MAX_POINTS_Y - 1);
213
+    MENU_ITEM_EDIT(uint8, MSG_MESH_X, &xind, 0, GRID_MAX_POINTS_X - 1);
214
+    MENU_ITEM_EDIT(uint8, MSG_MESH_Y, &yind, 0, GRID_MAX_POINTS_Y - 1);
215 215
     MENU_MULTIPLIER_ITEM_EDIT_CALLBACK(float43, MSG_MESH_EDIT_Z, &Z_VALUES(xind, yind), -(LCD_PROBE_Z_RANGE) * 0.5, (LCD_PROBE_Z_RANGE) * 0.5, refresh_planner);
216 216
     END_MENU();
217 217
   }

+ 1
- 1
Marlin/src/module/temperature.cpp Zobrazit soubor

@@ -111,7 +111,7 @@ int16_t Temperature::current_temperature_raw[HOTENDS], // = { 0 }
111 111
   #if ENABLED(EXTRA_FAN_SPEED)
112 112
     uint8_t Temperature::old_fan_speed[FAN_COUNT], Temperature::new_fan_speed[FAN_COUNT];
113 113
 
114
-    void Temperature::set_temp_fan_speed(const uint8_t fan, const int16_t tmp_temp) {
114
+    void Temperature::set_temp_fan_speed(const uint8_t fan, const uint16_t tmp_temp) {
115 115
       switch (tmp_temp) {
116 116
         case 1:
117 117
           set_fan_speed(fan, old_fan_speed[fan]);

+ 1
- 1
Marlin/src/module/temperature.h Zobrazit soubor

@@ -346,7 +346,7 @@ class Temperature {
346 346
 
347 347
       #if ENABLED(EXTRA_FAN_SPEED)
348 348
         static uint8_t old_fan_speed[FAN_COUNT], new_fan_speed[FAN_COUNT];
349
-        static void set_temp_fan_speed(const uint8_t fan, const int16_t tmp_temp);
349
+        static void set_temp_fan_speed(const uint8_t fan, const uint16_t tmp_temp);
350 350
       #endif
351 351
 
352 352
       #if HAS_LCD_MENU

Loading…
Zrušit
Uložit