Browse Source

Merge Temp Sanity Checks (PR#2514)

Richard Wackerbarth 10 years ago
parent
commit
960de3411b
1 changed files with 16 additions and 2 deletions
  1. 16
    2
      Marlin/SanityCheck.h

+ 16
- 2
Marlin/SanityCheck.h View File

51
   #endif
51
   #endif
52
 
52
 
53
   /**
53
   /**
54
-   * Options only for EXTRUDERS == 1
54
+   * Options only for EXTRUDERS > 1
55
    */
55
    */
56
   #if EXTRUDERS > 1
56
   #if EXTRUDERS > 1
57
 
57
 
281
   #endif
281
   #endif
282
 
282
 
283
   /**
283
   /**
284
-   * Test required HEATER defines
284
+   * Test required HEATER and TEMP_SENSOR defines
285
    */
285
    */
286
   #if EXTRUDERS > 3
286
   #if EXTRUDERS > 3
287
     #if !HAS_HEATER_3
287
     #if !HAS_HEATER_3
288
       #error HEATER_3_PIN not defined for this board.
288
       #error HEATER_3_PIN not defined for this board.
289
+    #elif TEMP_SENSOR_3 == 0
290
+      #error TEMP_SENSOR_3 is required with 4 EXTRUDERS.
289
     #endif
291
     #endif
290
   #elif EXTRUDERS > 2
292
   #elif EXTRUDERS > 2
291
     #if !HAS_HEATER_2
293
     #if !HAS_HEATER_2
292
       #error HEATER_2_PIN not defined for this board.
294
       #error HEATER_2_PIN not defined for this board.
295
+    #elif TEMP_SENSOR_2 == 0
296
+      #error TEMP_SENSOR_2 is required with 3 or more EXTRUDERS.
293
     #endif
297
     #endif
294
   #elif EXTRUDERS > 1 || defined(HEATERS_PARALLEL)
298
   #elif EXTRUDERS > 1 || defined(HEATERS_PARALLEL)
295
     #if !HAS_HEATER_1
299
     #if !HAS_HEATER_1
296
       #error HEATER_1_PIN not defined for this board.
300
       #error HEATER_1_PIN not defined for this board.
297
     #endif
301
     #endif
298
   #endif
302
   #endif
303
+  #if TEMP_SENSOR_1 == 0
304
+    #if EXTRUDERS > 1
305
+      #error TEMP_SENSOR_1 is required with 2 or more EXTRUDERS.
306
+    #elif ENABLED(TEMP_SENSOR_1_AS_REDUNDANT)
307
+      #error TEMP_SENSOR_1 is required with TEMP_SENSOR_1_AS_REDUNDANT.
308
+    #endif
309
+  #endif
299
   #if !HAS_HEATER_0
310
   #if !HAS_HEATER_0
300
     #error HEATER_0_PIN not defined for this board.
311
     #error HEATER_0_PIN not defined for this board.
301
   #endif
312
   #endif
313
+  #if TEMP_SENSOR_0 == 0
314
+    #error TEMP_SENSOR_0 is required.
315
+  #endif
302
 
316
 
303
   /**
317
   /**
304
    * Warnings for old configurations
318
    * Warnings for old configurations

Loading…
Cancel
Save