ソースを参照

Merge pull request #1651 from thinkyhead/config_testing

Configuration sanity-checking
Scott Lahteine 10年前
コミット
4afe50b920
33個のファイルの変更1081行の追加4323行の削除
  1. 405
    0
      Marlin/Conditionals.h
  2. 9
    144
      Marlin/Configuration.h
  3. 47
    244
      Marlin/Configuration_adv.h
  4. 25
    31
      Marlin/Marlin.h
  5. 27
    75
      Marlin/Marlin_main.cpp
  6. 254
    0
      Marlin/SanityCheck.h
  7. 2
    3
      Marlin/Sd2PinMap.h
  8. 18
    159
      Marlin/configurator/config/Configuration.h
  9. 10
    211
      Marlin/configurator/config/Configuration_adv.h
  10. 17
    171
      Marlin/example_configurations/Felix/Configuration.h
  11. 17
    170
      Marlin/example_configurations/Felix/Configuration_DUAL.h
  12. 11
    186
      Marlin/example_configurations/Felix/Configuration_adv.h
  13. 18
    153
      Marlin/example_configurations/Hephestos/Configuration.h
  14. 10
    201
      Marlin/example_configurations/Hephestos/Configuration_adv.h
  15. 18
    153
      Marlin/example_configurations/K8200/Configuration.h
  16. 11
    206
      Marlin/example_configurations/K8200/Configuration_adv.h
  17. 18
    153
      Marlin/example_configurations/SCARA/Configuration.h
  18. 11
    197
      Marlin/example_configurations/SCARA/Configuration_adv.h
  19. 18
    153
      Marlin/example_configurations/WITBOX/Configuration.h
  20. 10
    201
      Marlin/example_configurations/WITBOX/Configuration_adv.h
  21. 18
    153
      Marlin/example_configurations/delta/generic/Configuration.h
  22. 9
    207
      Marlin/example_configurations/delta/generic/Configuration_adv.h
  23. 18
    153
      Marlin/example_configurations/delta/kossel_mini/Configuration.h
  24. 9
    207
      Marlin/example_configurations/delta/kossel_mini/Configuration_adv.h
  25. 18
    153
      Marlin/example_configurations/makibox/Configuration.h
  26. 10
    190
      Marlin/example_configurations/makibox/Configuration_adv.h
  27. 18
    153
      Marlin/example_configurations/tvrrug/Round2/Configuration.h
  28. 10
    186
      Marlin/example_configurations/tvrrug/Round2/Configuration_adv.h
  29. 0
    2
      Marlin/language.h
  30. 0
    2
      Marlin/pins.h
  31. 3
    88
      Marlin/temperature.cpp
  32. 0
    5
      Marlin/ultralcd.cpp
  33. 12
    13
      Marlin/ultralcd.h

+ 405
- 0
Marlin/Conditionals.h ファイルの表示

@@ -0,0 +1,405 @@
1
+/**
2
+ * Conditionals.h
3
+ * Defines that depend on configuration but are not editable.
4
+ */
5
+#ifndef CONDITIONALS_H
6
+
7
+#ifndef CONFIGURATION_LCD // Get the LCD defines which are needed first
8
+
9
+  #define CONFIGURATION_LCD
10
+
11
+  #if defined(MAKRPANEL)
12
+    #define DOGLCD
13
+    #define SDSUPPORT
14
+    #define DEFAULT_LCD_CONTRAST 17
15
+    #define ULTIPANEL
16
+    #define NEWPANEL
17
+  #endif
18
+
19
+  #if defined(miniVIKI) || defined(VIKI2)
20
+    #define ULTRA_LCD  //general LCD support, also 16x2
21
+    #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
22
+    #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
23
+
24
+    #ifdef miniVIKI
25
+      #define DEFAULT_LCD_CONTRAST 95
26
+    #else
27
+      #define DEFAULT_LCD_CONTRAST 40
28
+    #endif
29
+
30
+    #define ENCODER_PULSES_PER_STEP 4
31
+    #define ENCODER_STEPS_PER_MENU_ITEM 1
32
+  #endif
33
+
34
+  #ifdef PANEL_ONE
35
+    #define SDSUPPORT
36
+    #define ULTIMAKERCONTROLLER
37
+  #endif
38
+
39
+  #ifdef REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER
40
+    #define DOGLCD
41
+    #define U8GLIB_ST7920
42
+    #define REPRAP_DISCOUNT_SMART_CONTROLLER
43
+  #endif
44
+
45
+  #if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
46
+    #define ULTIPANEL
47
+    #define NEWPANEL
48
+  #endif
49
+
50
+  #ifdef REPRAPWORLD_KEYPAD
51
+    #define ULTIPANEL
52
+    #define NEWPANEL
53
+  #endif
54
+
55
+  #ifdef RA_CONTROL_PANEL
56
+    #define LCD_I2C_TYPE_PCA8574
57
+    #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
58
+    #define ULTIPANEL
59
+    #define NEWPANEL
60
+  #endif
61
+
62
+  /**
63
+   * I2C PANELS
64
+   */
65
+
66
+  #ifdef LCD_I2C_SAINSMART_YWROBOT
67
+    // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
68
+    // Make sure it is placed in the Arduino libraries directory.
69
+    #define LCD_I2C_TYPE_PCF8575
70
+    #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
71
+    #define ULTIPANEL
72
+    #define NEWPANEL
73
+  #endif
74
+
75
+  // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
76
+  #ifdef LCD_I2C_PANELOLU2
77
+    // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
78
+    // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
79
+    // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
80
+    // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
81
+    //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
82
+    #define LCD_I2C_TYPE_MCP23017
83
+    #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
84
+    #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
85
+
86
+    #ifndef ENCODER_PULSES_PER_STEP
87
+      #define ENCODER_PULSES_PER_STEP 4
88
+    #endif
89
+
90
+    #ifndef ENCODER_STEPS_PER_MENU_ITEM
91
+      #define ENCODER_STEPS_PER_MENU_ITEM 1
92
+    #endif
93
+
94
+    #ifdef LCD_USE_I2C_BUZZER
95
+      #define LCD_FEEDBACK_FREQUENCY_HZ 1000
96
+      #define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
97
+    #endif
98
+
99
+    #define ULTIPANEL
100
+    #define NEWPANEL
101
+  #endif
102
+
103
+  // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
104
+  #ifdef LCD_I2C_VIKI
105
+    // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
106
+    // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
107
+    // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
108
+    //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
109
+    #define LCD_I2C_TYPE_MCP23017
110
+    #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
111
+    #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
112
+    #define ULTIPANEL
113
+    #define NEWPANEL
114
+  #endif
115
+
116
+  // Shift register panels
117
+  // ---------------------
118
+  // 2 wire Non-latching LCD SR from:
119
+  // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection
120
+
121
+  #ifdef SAV_3DLCD
122
+     #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
123
+     #define ULTIPANEL
124
+     #define NEWPANEL
125
+  #endif
126
+
127
+
128
+  #ifdef ULTIPANEL
129
+    #define NEWPANEL  //enable this if you have a click-encoder panel
130
+    #define SDSUPPORT
131
+    #define ULTRA_LCD
132
+    #ifdef DOGLCD // Change number of lines to match the DOG graphic display
133
+      #define LCD_WIDTH 22
134
+      #define LCD_HEIGHT 5
135
+    #else
136
+      #define LCD_WIDTH 20
137
+      #define LCD_HEIGHT 4
138
+    #endif
139
+  #else //no panel but just LCD
140
+    #ifdef ULTRA_LCD
141
+    #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
142
+      #define LCD_WIDTH 22
143
+      #define LCD_HEIGHT 5
144
+    #else
145
+      #define LCD_WIDTH 16
146
+      #define LCD_HEIGHT 2
147
+    #endif
148
+    #endif
149
+  #endif
150
+
151
+  /**
152
+   * Default LCD contrast for dogm-like LCD displays
153
+   */
154
+  #if defined(DOGLCD) && !defined(DEFAULT_LCD_CONTRAST)
155
+    #define DEFAULT_LCD_CONTRAST 32
156
+  #endif
157
+
158
+#else // CONFIGURATION_LCD
159
+
160
+  #define CONDITIONALS_H
161
+
162
+  #ifndef AT90USB
163
+    #define HardwareSerial_h // trick to disable the standard HWserial
164
+  #endif
165
+
166
+  #if (ARDUINO >= 100)
167
+    #include "Arduino.h"
168
+  #else
169
+    #include "WProgram.h"
170
+  #endif
171
+
172
+  #include "pins.h"
173
+
174
+  /**
175
+   * ENDSTOPPULLUPS
176
+   */
177
+  #ifdef ENDSTOPPULLUPS
178
+    #ifndef DISABLE_MAX_ENDSTOPS
179
+      #define ENDSTOPPULLUP_XMAX
180
+      #define ENDSTOPPULLUP_YMAX
181
+      #define ENDSTOPPULLUP_ZMAX
182
+    #endif
183
+    #ifndef DISABLE_MIN_ENDSTOPS
184
+      #define ENDSTOPPULLUP_XMIN
185
+      #define ENDSTOPPULLUP_YMIN
186
+      #define ENDSTOPPULLUP_ZMIN
187
+    #endif
188
+  #endif
189
+
190
+  /**
191
+   * Axis lengths
192
+   */
193
+  #define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
194
+  #define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
195
+  #define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
196
+
197
+  /**
198
+   * SCARA
199
+   */
200
+  #ifdef SCARA
201
+    #undef SLOWDOWN
202
+    #define QUICK_HOME //SCARA needs Quickhome
203
+  #endif
204
+
205
+  /**
206
+   * AUTOSET LOCATIONS OF LIMIT SWITCHES
207
+   * Added by ZetaPhoenix 09-15-2012
208
+   */
209
+  #ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
210
+    #define X_HOME_POS MANUAL_X_HOME_POS
211
+    #define Y_HOME_POS MANUAL_Y_HOME_POS
212
+    #define Z_HOME_POS MANUAL_Z_HOME_POS
213
+  #else //!MANUAL_HOME_POSITIONS – Use home switch positions based on homing direction and travel limits
214
+    #ifdef BED_CENTER_AT_0_0
215
+      #define X_HOME_POS X_MAX_LENGTH * X_HOME_DIR * 0.5
216
+      #define Y_HOME_POS Y_MAX_LENGTH * Y_HOME_DIR * 0.5
217
+    #else
218
+      #define X_HOME_POS (X_HOME_DIR < 0 ? X_MIN_POS : X_MAX_POS)
219
+      #define Y_HOME_POS (Y_HOME_DIR < 0 ? Y_MIN_POS : Y_MAX_POS)
220
+    #endif
221
+    #define Z_HOME_POS (Z_HOME_DIR < 0 ? Z_MIN_POS : Z_MAX_POS)
222
+  #endif //!MANUAL_HOME_POSITIONS
223
+
224
+  /**
225
+   * Auto Bed Leveling
226
+   */
227
+  #ifdef ENABLE_AUTO_BED_LEVELING
228
+    // Boundaries for probing based on set limits
229
+    #define MIN_PROBE_X (max(X_MIN_POS, X_MIN_POS + X_PROBE_OFFSET_FROM_EXTRUDER))
230
+    #define MAX_PROBE_X (min(X_MAX_POS, X_MAX_POS + X_PROBE_OFFSET_FROM_EXTRUDER))
231
+    #define MIN_PROBE_Y (max(Y_MIN_POS, Y_MIN_POS + Y_PROBE_OFFSET_FROM_EXTRUDER))
232
+    #define MAX_PROBE_Y (min(Y_MAX_POS, Y_MAX_POS + Y_PROBE_OFFSET_FROM_EXTRUDER))
233
+  #endif
234
+
235
+  /**
236
+   * MAX_STEP_FREQUENCY differs for TOSHIBA
237
+   */
238
+  #ifdef CONFIG_STEPPERS_TOSHIBA
239
+    #define MAX_STEP_FREQUENCY 10000 // Max step frequency for Toshiba Stepper Controllers
240
+  #else
241
+    #define MAX_STEP_FREQUENCY 40000 // Max step frequency for Ultimaker (5000 pps / half step)
242
+  #endif
243
+
244
+  // MS1 MS2 Stepper Driver Microstepping mode table
245
+  #define MICROSTEP1 LOW,LOW
246
+  #define MICROSTEP2 HIGH,LOW
247
+  #define MICROSTEP4 LOW,HIGH
248
+  #define MICROSTEP8 HIGH,HIGH
249
+  #define MICROSTEP16 HIGH,HIGH
250
+
251
+  /**
252
+   * Advance calculated values
253
+   */
254
+  #ifdef ADVANCE
255
+    #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
256
+    #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS] / EXTRUSION_AREA)
257
+  #endif
258
+
259
+  #ifdef ULTIPANEL
260
+   #undef SDCARDDETECTINVERTED
261
+  #endif
262
+
263
+  // Power Signal Control Definitions
264
+  // By default use ATX definition
265
+  #ifndef POWER_SUPPLY
266
+    #define POWER_SUPPLY 1
267
+  #endif
268
+  // 1 = ATX
269
+  #if (POWER_SUPPLY == 1)
270
+    #define PS_ON_AWAKE  LOW
271
+    #define PS_ON_ASLEEP HIGH
272
+  #endif
273
+  // 2 = X-Box 360 203W
274
+  #if (POWER_SUPPLY == 2)
275
+    #define PS_ON_AWAKE  HIGH
276
+    #define PS_ON_ASLEEP LOW
277
+  #endif
278
+
279
+  /**
280
+   * Temp Sensor defines
281
+   */
282
+  #if TEMP_SENSOR_0 == -2
283
+    #define HEATER_0_USES_MAX6675
284
+  #elif TEMP_SENSOR_0 == -1
285
+    #define HEATER_0_USES_AD595
286
+  #elif TEMP_SENSOR_0 == 0
287
+    #undef HEATER_0_MINTEMP
288
+    #undef HEATER_0_MAXTEMP
289
+  #elif TEMP_SENSOR_0 > 0
290
+    #define THERMISTORHEATER_0 TEMP_SENSOR_0
291
+    #define HEATER_0_USES_THERMISTOR
292
+  #endif
293
+
294
+  #if TEMP_SENSOR_1 == -1
295
+    #define HEATER_1_USES_AD595
296
+  #elif TEMP_SENSOR_1 == 0
297
+    #undef HEATER_1_MINTEMP
298
+    #undef HEATER_1_MAXTEMP
299
+  #elif TEMP_SENSOR_1 > 0
300
+    #define THERMISTORHEATER_1 TEMP_SENSOR_1
301
+    #define HEATER_1_USES_THERMISTOR
302
+  #endif
303
+
304
+  #if TEMP_SENSOR_2 == -1
305
+    #define HEATER_2_USES_AD595
306
+  #elif TEMP_SENSOR_2 == 0
307
+    #undef HEATER_2_MINTEMP
308
+    #undef HEATER_2_MAXTEMP
309
+  #elif TEMP_SENSOR_2 > 0
310
+    #define THERMISTORHEATER_2 TEMP_SENSOR_2
311
+    #define HEATER_2_USES_THERMISTOR
312
+  #endif
313
+
314
+  #if TEMP_SENSOR_3 == -1
315
+    #define HEATER_3_USES_AD595
316
+  #elif TEMP_SENSOR_3 == 0
317
+    #undef HEATER_3_MINTEMP
318
+    #undef HEATER_3_MAXTEMP
319
+  #elif TEMP_SENSOR_3 > 0
320
+    #define THERMISTORHEATER_3 TEMP_SENSOR_3
321
+    #define HEATER_3_USES_THERMISTOR
322
+  #endif
323
+
324
+  #if TEMP_SENSOR_BED == -1
325
+    #define BED_USES_AD595
326
+  #elif TEMP_SENSOR_BED == 0
327
+    #undef BED_MINTEMP
328
+    #undef BED_MAXTEMP
329
+  #elif TEMP_SENSOR_BED > 0
330
+    #define THERMISTORBED TEMP_SENSOR_BED
331
+    #define BED_USES_THERMISTOR
332
+  #endif
333
+
334
+  /**
335
+   * ARRAY_BY_EXTRUDERS based on EXTRUDERS
336
+   */
337
+  #if EXTRUDERS > 3
338
+    #define ARRAY_BY_EXTRUDERS(v1, v2, v3, v4) { v1, v2, v3, v4 }
339
+  #elif EXTRUDERS > 2
340
+    #define ARRAY_BY_EXTRUDERS(v1, v2, v3, v4) { v1, v2, v3 }
341
+  #elif EXTRUDERS > 1
342
+    #define ARRAY_BY_EXTRUDERS(v1, v2, v3, v4) { v1, v2 }
343
+  #else
344
+    #define ARRAY_BY_EXTRUDERS(v1, v2, v3, v4) { v1 }
345
+  #endif
346
+
347
+  /**
348
+   * Shorthand for pin tests, for temperature.cpp
349
+   */
350
+  #define HAS_TEMP_0 (defined(TEMP_0_PIN) && TEMP_0_PIN >= 0)
351
+  #define HAS_TEMP_1 (defined(TEMP_1_PIN) && TEMP_1_PIN >= 0)
352
+  #define HAS_TEMP_2 (defined(TEMP_2_PIN) && TEMP_2_PIN >= 0)
353
+  #define HAS_TEMP_3 (defined(TEMP_3_PIN) && TEMP_3_PIN >= 0)
354
+  #define HAS_TEMP_BED (defined(TEMP_BED_PIN) && TEMP_BED_PIN >= 0)
355
+  #define HAS_FILAMENT_SENSOR (defined(FILAMENT_SENSOR) && defined(FILWIDTH_PIN) && FILWIDTH_PIN >= 0)
356
+  #define HAS_HEATER_0 (defined(HEATER_0_PIN) && HEATER_0_PIN >= 0)
357
+  #define HAS_HEATER_1 (defined(HEATER_1_PIN) && HEATER_1_PIN >= 0)
358
+  #define HAS_HEATER_2 (defined(HEATER_2_PIN) && HEATER_2_PIN >= 0)
359
+  #define HAS_HEATER_3 (defined(HEATER_3_PIN) && HEATER_3_PIN >= 0)
360
+  #define HAS_HEATER_BED (defined(HEATER_BED_PIN) && HEATER_BED_PIN >= 0)
361
+  #define HAS_AUTO_FAN_0 (defined(EXTRUDER_0_AUTO_FAN_PIN) && EXTRUDER_0_AUTO_FAN_PIN >= 0)
362
+  #define HAS_AUTO_FAN_1 (defined(EXTRUDER_1_AUTO_FAN_PIN) && EXTRUDER_1_AUTO_FAN_PIN >= 0)
363
+  #define HAS_AUTO_FAN_2 (defined(EXTRUDER_2_AUTO_FAN_PIN) && EXTRUDER_2_AUTO_FAN_PIN >= 0)
364
+  #define HAS_AUTO_FAN_3 (defined(EXTRUDER_3_AUTO_FAN_PIN) && EXTRUDER_3_AUTO_FAN_PIN >= 0)
365
+  #define HAS_AUTO_FAN HAS_AUTO_FAN_0 || HAS_AUTO_FAN_1 || HAS_AUTO_FAN_2 || HAS_AUTO_FAN_3
366
+  #define HAS_FAN (defined(FAN_PIN) && FAN_PIN >= 0)
367
+
368
+  /**
369
+   * Helper Macros for heaters and extruder fan
370
+   */
371
+  #define WRITE_HEATER_0P(v) WRITE(HEATER_0_PIN, v)
372
+  #if EXTRUDERS > 1 || defined(HEATERS_PARALLEL)
373
+    #define WRITE_HEATER_1(v) WRITE(HEATER_1_PIN, v)
374
+    #if EXTRUDERS > 2
375
+      #define WRITE_HEATER_2(v) WRITE(HEATER_2_PIN, v)
376
+      #if EXTRUDERS > 3
377
+        #define WRITE_HEATER_3(v) WRITE(HEATER_3_PIN, v)
378
+      #endif
379
+    #endif
380
+  #endif
381
+  #ifdef HEATERS_PARALLEL
382
+    #define WRITE_HEATER_0(v) { WRITE_HEATER_0P(v); WRITE_HEATER_1(v); }
383
+  #else
384
+    #define WRITE_HEATER_0(v) WRITE_HEATER_0P(v)
385
+  #endif
386
+  #if HAS_HEATER_BED
387
+    #define WRITE_HEATER_BED(v) WRITE(HEATER_BED_PIN, v)
388
+  #endif
389
+  #if HAS_FAN
390
+    #define WRITE_FAN(v) WRITE(FAN_PIN, v)
391
+  #endif
392
+
393
+  /**
394
+   * Sampling period of the temperature routine
395
+   * This override comes originally from temperature.cpp
396
+   * The Configuration.h option is basically ignored.
397
+   */
398
+  #ifdef PID_dT
399
+    #undef PID_dT
400
+  #endif
401
+  #define PID_dT ((OVERSAMPLENR * 12.0)/(F_CPU / 64.0 / 256.0))
402
+
403
+
404
+#endif //CONFIGURATION_LCD
405
+#endif //CONDITIONALS_H

+ 9
- 144
Marlin/Configuration.h ファイルの表示

@@ -360,10 +360,6 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
360 360
 #define Y_MAX_POS 200
361 361
 #define Z_MAX_POS 200
362 362
 
363
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
364
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
365
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
366
-
367 363
 //===========================================================================
368 364
 //============================= Filament Runout Sensor ======================
369 365
 //===========================================================================
@@ -624,112 +620,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
624 620
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
625 621
 //#define RA_CONTROL_PANEL
626 622
 
627
-//automatic expansion
628
-#if defined (MAKRPANEL)
629
- #define DOGLCD
630
- #define SDSUPPORT
631
- #define ULTIPANEL
632
- #define NEWPANEL
633
- #define DEFAULT_LCD_CONTRAST 17
634
-#endif
635
-
636
-#if defined(miniVIKI) || defined(VIKI2)
637
- #define ULTRA_LCD  //general LCD support, also 16x2
638
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
639
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
640
- 
641
-  #ifdef miniVIKI
642
-   #define DEFAULT_LCD_CONTRAST 95
643
-  #else
644
-   #define DEFAULT_LCD_CONTRAST 40
645
-  #endif
646
-  
647
- #define ENCODER_PULSES_PER_STEP 4
648
- #define ENCODER_STEPS_PER_MENU_ITEM 1
649
-#endif
650
-
651
-#if defined (PANEL_ONE)
652
- #define SDSUPPORT
653
- #define ULTIMAKERCONTROLLER
654
-#endif
655
-
656
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
657
- #define DOGLCD
658
- #define U8GLIB_ST7920
659
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
660
-#endif
661
-
662
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
663
- #define ULTIPANEL
664
- #define NEWPANEL
665
-#endif
666
-
667
-#if defined(REPRAPWORLD_KEYPAD)
668
-  #define NEWPANEL
669
-  #define ULTIPANEL
670
-#endif
671
-#if defined(RA_CONTROL_PANEL)
672
- #define ULTIPANEL
673
- #define NEWPANEL
674
- #define LCD_I2C_TYPE_PCA8574
675
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
676
-#endif
677
-
678
-//I2C PANELS
623
+/**
624
+ * I2C Panels
625
+ */
679 626
 
680 627
 //#define LCD_I2C_SAINSMART_YWROBOT
681
-#ifdef LCD_I2C_SAINSMART_YWROBOT
682
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
683
-  // Make sure it is placed in the Arduino libraries directory.
684
-  #define LCD_I2C_TYPE_PCF8575
685
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
686
-  #define NEWPANEL
687
-  #define ULTIPANEL
688
-#endif
689 628
 
690 629
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
691 630
 //#define LCD_I2C_PANELOLU2
692
-#ifdef LCD_I2C_PANELOLU2
693
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
694
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
695
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
696
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
697
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
698
-  #define LCD_I2C_TYPE_MCP23017
699
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
700
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
701
-  #define NEWPANEL
702
-  #define ULTIPANEL
703
-
704
-  #ifndef ENCODER_PULSES_PER_STEP
705
-	#define ENCODER_PULSES_PER_STEP 4
706
-  #endif
707
-
708
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
709
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
710
-  #endif
711
-
712
-
713
-  #ifdef LCD_USE_I2C_BUZZER
714
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
715
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
716
-  #endif
717
-
718
-#endif
719 631
 
720 632
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
721 633
 //#define LCD_I2C_VIKI
722
-#ifdef LCD_I2C_VIKI
723
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
724
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
725
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
726
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
727
-  #define LCD_I2C_TYPE_MCP23017
728
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
729
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
730
-  #define NEWPANEL
731
-  #define ULTIPANEL
732
-#endif
733 634
 
734 635
 // Shift register panels
735 636
 // ---------------------
@@ -737,51 +638,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
737 638
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
738 639
 
739 640
 //#define SAV_3DLCD
740
-#ifdef SAV_3DLCD
741
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
742
-   #define NEWPANEL
743
-   #define ULTIPANEL
744
-#endif
745
-
746
-
747
-#ifdef ULTIPANEL
748
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
749
-  #define SDSUPPORT
750
-  #define ULTRA_LCD
751
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
752
-    #define LCD_WIDTH 22
753
-    #define LCD_HEIGHT 5
754
-  #else
755
-    #define LCD_WIDTH 20
756
-    #define LCD_HEIGHT 4
757
-  #endif
758
-#else //no panel but just LCD
759
-  #ifdef ULTRA_LCD
760
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
761
-    #define LCD_WIDTH 22
762
-    #define LCD_HEIGHT 5
763
-  #else
764
-    #define LCD_WIDTH 16
765
-    #define LCD_HEIGHT 2
766
-  #endif
767
-  #endif
768
-#endif
769
-
770
-// default LCD contrast for dogm-like LCD displays
771
-#ifdef DOGLCD
772
-# ifndef DEFAULT_LCD_CONTRAST
773
-#  define DEFAULT_LCD_CONTRAST 32
774
-# endif
775
-#endif
776 641
 
777 642
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
778 643
 //#define FAST_PWM_FAN
779 644
 
780
-// Temperature status LEDs that display the hotend and bet temperature.
781
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
782
-// Otherwise the RED led is on. There is 1C hysteresis.
783
-//#define TEMP_STAT_LEDS
784
-
785 645
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
786 646
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
787 647
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -793,6 +653,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
793 653
 // at zero value, there are 128 effective control positions.
794 654
 #define SOFT_PWM_SCALE 0
795 655
 
656
+// Temperature status LEDs that display the hotend and bet temperature.
657
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
658
+// Otherwise the RED led is on. There is 1C hysteresis.
659
+//#define TEMP_STAT_LEDS
660
+
796 661
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
797 662
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
798 663
 // #define PHOTOGRAPH_PIN     23
@@ -864,4 +729,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
864 729
 #include "Configuration_adv.h"
865 730
 #include "thermistortables.h"
866 731
 
867
-#endif //__CONFIGURATION_H
732
+#endif //CONFIGURATION_H

+ 47
- 244
Marlin/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,67 +100,53 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers.
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
172 112
 // allowing faster printing speeds.
173 113
 //#define DUAL_X_CARRIAGE
174 114
 #ifdef DUAL_X_CARRIAGE
175
-// Configuration for second X-carriage
176
-// Note: the first x-carriage is defined as the x-carriage which homes to the minimum endstop;
177
-// the second x-carriage always homes to the maximum endstop.
178
-#define X2_MIN_POS 80     // set minimum to ensure second x-carriage doesn't hit the parked first X-carriage
179
-#define X2_MAX_POS 353    // set maximum to the distance between toolheads when both heads are homed
180
-#define X2_HOME_DIR 1     // the second X-carriage always homes to the maximum endstop position
181
-#define X2_HOME_POS X2_MAX_POS // default home position is the maximum carriage position
182
-    // However: In this mode the EXTRUDER_OFFSET_X value for the second extruder provides a software
183
-    // override for X2_HOME_POS. This also allow recalibration of the distance between the two endstops
184
-    // without modifying the firmware (through the "M218 T1 X???" command).
185
-    // Remember: you should set the second extruder x-offset to 0 in your slicer.
186
-
187
-// Pins for second x-carriage stepper driver (defined here to avoid further complicating pins.h)
188
-#define X2_ENABLE_PIN 29
189
-#define X2_STEP_PIN 25
190
-#define X2_DIR_PIN 23
191
-
192
-// There are a few selectable movement modes for dual x-carriages using M605 S<mode>
193
-//    Mode 0: Full control. The slicer has full control over both x-carriages and can achieve optimal travel results
194
-//                           as long as it supports dual x-carriages. (M605 S0)
195
-//    Mode 1: Auto-park mode. The firmware will automatically park and unpark the x-carriages on tool changes so
196
-//                           that additional slicer support is not required. (M605 S1)
197
-//    Mode 2: Duplication mode. The firmware will transparently make the second x-carriage and extruder copy all
198
-//                           actions of the first x-carriage. This allows the printer to print 2 arbitrary items at
199
-//                           once. (2nd extruder x offset and temp offset are set using: M605 S2 [Xnnn] [Rmmm])
200
-
201
-// This is the default power-up mode which can be later using M605.
202
-#define DEFAULT_DUAL_X_CARRIAGE_MODE 0
203
-
204
-// Default settings in "Auto-park Mode"
205
-#define TOOLCHANGE_PARK_ZLIFT   0.2      // the distance to raise Z axis when parking an extruder
206
-#define TOOLCHANGE_UNPARK_ZLIFT 1        // the distance to raise Z axis when unparking an extruder
207
-
208
-// Default x offset in duplication mode (typically set to half print bed width)
209
-#define DEFAULT_DUPLICATION_X_OFFSET 100
115
+  // Configuration for second X-carriage
116
+  // Note: the first x-carriage is defined as the x-carriage which homes to the minimum endstop;
117
+  // the second x-carriage always homes to the maximum endstop.
118
+  #define X2_MIN_POS 80     // set minimum to ensure second x-carriage doesn't hit the parked first X-carriage
119
+  #define X2_MAX_POS 353    // set maximum to the distance between toolheads when both heads are homed
120
+  #define X2_HOME_DIR 1     // the second X-carriage always homes to the maximum endstop position
121
+  #define X2_HOME_POS X2_MAX_POS // default home position is the maximum carriage position
122
+      // However: In this mode the EXTRUDER_OFFSET_X value for the second extruder provides a software
123
+      // override for X2_HOME_POS. This also allow recalibration of the distance between the two endstops
124
+      // without modifying the firmware (through the "M218 T1 X???" command).
125
+      // Remember: you should set the second extruder x-offset to 0 in your slicer.
126
+
127
+  // Pins for second x-carriage stepper driver (defined here to avoid further complicating pins.h)
128
+  #define X2_ENABLE_PIN 29
129
+  #define X2_STEP_PIN 25
130
+  #define X2_DIR_PIN 23
131
+
132
+  // There are a few selectable movement modes for dual x-carriages using M605 S<mode>
133
+  //    Mode 0: Full control. The slicer has full control over both x-carriages and can achieve optimal travel results
134
+  //                           as long as it supports dual x-carriages. (M605 S0)
135
+  //    Mode 1: Auto-park mode. The firmware will automatically park and unpark the x-carriages on tool changes so
136
+  //                           that additional slicer support is not required. (M605 S1)
137
+  //    Mode 2: Duplication mode. The firmware will transparently make the second x-carriage and extruder copy all
138
+  //                           actions of the first x-carriage. This allows the printer to print 2 arbitrary items at
139
+  //                           once. (2nd extruder x offset and temp offset are set using: M605 S2 [Xnnn] [Rmmm])
140
+
141
+  // This is the default power-up mode which can be later using M605.
142
+  #define DEFAULT_DUAL_X_CARRIAGE_MODE 0
143
+
144
+  // Default settings in "Auto-park Mode"
145
+  #define TOOLCHANGE_PARK_ZLIFT   0.2      // the distance to raise Z axis when parking an extruder
146
+  #define TOOLCHANGE_UNPARK_ZLIFT 1        // the distance to raise Z axis when unparking an extruder
147
+
148
+  // Default x offset in duplication mode (typically set to half print bed width)
149
+  #define DEFAULT_DUPLICATION_X_OFFSET 100
210 150
 
211 151
 #endif //DUAL_X_CARRIAGE
212 152
 
@@ -218,31 +158,22 @@
218 158
 //#define QUICK_HOME  //if this is defined, if both x and y are to be homed, a diagonal move will be performed initially.
219 159
 
220 160
 #define AXIS_RELATIVE_MODES {false, false, false, false}
221
-#ifdef CONFIG_STEPPERS_TOSHIBA
222
-#define MAX_STEP_FREQUENCY 10000 // Max step frequency for Toshiba Stepper Controllers
223
-#else
224
-#define MAX_STEP_FREQUENCY 40000 // Max step frequency for Ultimaker (5000 pps / half step)
225
-#endif
161
+
226 162
 //By default pololu step drivers require an active high signal. However, some high power drivers require an active low signal as step.
227 163
 #define INVERT_X_STEP_PIN false
228 164
 #define INVERT_Y_STEP_PIN false
229 165
 #define INVERT_Z_STEP_PIN false
230 166
 #define INVERT_E_STEP_PIN false
231 167
 
232
-//default stepper release if idle. Set to 0 to deactivate.
168
+// Default stepper release if idle. Set to 0 to deactivate.
233 169
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
234 170
 
235 171
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
236 172
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
237 173
 
238
-// Feedrates for manual moves along X, Y, Z, E from panel
239
-#ifdef ULTIPANEL
240
-#define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60}  // set the speeds for manual moves (mm/min)
241
-#endif
242
-
243
-//Comment to disable setting feedrate multiplier via encoder
244 174
 #ifdef ULTIPANEL
245
-    #define ULTIPANEL_FEEDMULTIPLY
175
+  #define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60} // Feedrates for manual moves along X, Y, Z, E from panel
176
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
246 177
 #endif
247 178
 
248 179
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -261,13 +192,6 @@
261 192
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
262 193
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
263 194
 
264
-// MS1 MS2 Stepper Driver Microstepping mode table
265
-#define MICROSTEP1 LOW,LOW
266
-#define MICROSTEP2 HIGH,LOW
267
-#define MICROSTEP4 LOW,HIGH
268
-#define MICROSTEP8 HIGH,HIGH
269
-#define MICROSTEP16 HIGH,HIGH
270
-
271 195
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
272 196
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
273 197
 
@@ -313,12 +237,6 @@
313 237
   #define PROGRESS_MSG_EXPIRE   0
314 238
   // Enable this to show messages for MSG_TIME then hide them
315 239
   //#define PROGRESS_MSG_ONCE
316
-  #ifdef DOGLCD
317
-    #warning LCD_PROGRESS_BAR does not apply to graphical displays at this time.
318
-  #endif
319
-  #ifdef FILAMENT_LCD_DISPLAY
320
-    #error LCD_PROGRESS_BAR and FILAMENT_LCD_DISPLAY are not fully compatible. Comment out this line to use both.
321
-  #endif
322 240
 #endif
323 241
 
324 242
 // The hardware watchdog should reset the microcontroller disabling all outputs, in case the firmware gets stuck and doesn't do temperature regulation.
@@ -342,16 +260,6 @@
342 260
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
343 261
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
344 262
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
345
-
346
-  #ifdef COREXY
347
-    #error BABYSTEPPING not implemented for COREXY yet.
348
-  #endif
349
-
350
-  #ifdef DELTA
351
-    #ifdef BABYSTEP_XY
352
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
353
-    #endif
354
-  #endif
355 263
 #endif
356 264
 
357 265
 // extruder advance constant (s2/mm3)
@@ -365,12 +273,8 @@
365 273
 
366 274
 #ifdef ADVANCE
367 275
   #define EXTRUDER_ADVANCE_K .0
368
-
369 276
   #define D_FILAMENT 2.85
370 277
   #define STEPS_MM_E 836
371
-  #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
372
-  #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS]/ EXTRUSION_AREA)
373
-
374 278
 #endif // ADVANCE
375 279
 
376 280
 // Arc interpretation settings:
@@ -385,26 +289,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
385 289
 // be commented out otherwise
386 290
 #define SDCARDDETECTINVERTED
387 291
 
388
-#ifdef ULTIPANEL
389
- #undef SDCARDDETECTINVERTED
390
-#endif
391
-
392
-// Power Signal Control Definitions
393
-// By default use ATX definition
394
-#ifndef POWER_SUPPLY
395
-  #define POWER_SUPPLY 1
396
-#endif
397
-// 1 = ATX
398
-#if (POWER_SUPPLY == 1)
399
-  #define PS_ON_AWAKE  LOW
400
-  #define PS_ON_ASLEEP HIGH
401
-#endif
402
-// 2 = X-Box 360 203W
403
-#if (POWER_SUPPLY == 2)
404
-  #define PS_ON_AWAKE  HIGH
405
-  #define PS_ON_ASLEEP LOW
406
-#endif
407
-
408 292
 // Control heater 0 and heater 1 in parallel.
409 293
 //#define HEATERS_PARALLEL
410 294
 
@@ -414,7 +298,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
414 298
 
415 299
 // The number of linear motions that can be in the plan at any give time.
416 300
 // THE BLOCK_BUFFER_SIZE NEEDS TO BE A POWER OF 2, i.g. 8,16,32 because shifts and ors are used to do the ring-buffering.
417
-#if defined SDSUPPORT
301
+#ifdef SDSUPPORT
418 302
   #define BLOCK_BUFFER_SIZE 16   // SD,LCD,Buttons take more memory, block buffer needs to be smaller
419 303
 #else
420 304
   #define BLOCK_BUFFER_SIZE 16 // maximize block buffer
@@ -444,9 +328,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
444 328
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
445 329
 #endif
446 330
 
447
-//adds support for experimental filament exchange support M600; requires display
331
+// Add support for experimental filament exchange support M600; requires display
448 332
 #ifdef ULTIPANEL
449
-  #define FILAMENTCHANGEENABLE
333
+  //#define FILAMENTCHANGEENABLE
450 334
   #ifdef FILAMENTCHANGEENABLE
451 335
     #define FILAMENTCHANGE_XPOS 3
452 336
     #define FILAMENTCHANGE_YPOS 3
@@ -456,13 +340,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
456 340
   #endif
457 341
 #endif
458 342
 
459
-#ifdef FILAMENTCHANGEENABLE
460
-  #ifdef EXTRUDER_RUNOUT_PREVENT
461
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
462
-  #endif
463
-#endif
464
-
465
-
466 343
 /******************************************************************************\
467 344
  * enable this section if you have TMC26X motor drivers. 
468 345
  * you need to import the TMC26XStepper library into the arduino IDE for this
@@ -596,81 +473,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
596 473
 	
597 474
 #endif
598 475
 
476
+#include "Conditionals.h"
477
+#include "SanityCheck.h"
599 478
 
600
-//===========================================================================
601
-//=============================  Define Defines  ============================
602
-//===========================================================================
603
-
604
-#if defined (ENABLE_AUTO_BED_LEVELING) && defined (DELTA)
605
-  #error "Bed Auto Leveling is still not compatible with Delta Kinematics."
606
-#endif
607
-
608
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
609
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
610
-#endif
611
-
612
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
613
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
614
-#endif
615
-
616
-#if TEMP_SENSOR_0 > 0
617
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
618
-  #define HEATER_0_USES_THERMISTOR
619
-#endif
620
-#if TEMP_SENSOR_1 > 0
621
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
622
-  #define HEATER_1_USES_THERMISTOR
623
-#endif
624
-#if TEMP_SENSOR_2 > 0
625
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
626
-  #define HEATER_2_USES_THERMISTOR
627
-#endif
628
-#if TEMP_SENSOR_3 > 0
629
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
630
-  #define HEATER_3_USES_THERMISTOR
631
-#endif
632
-#if TEMP_SENSOR_BED > 0
633
-  #define THERMISTORBED TEMP_SENSOR_BED
634
-  #define BED_USES_THERMISTOR
635
-#endif
636
-#if TEMP_SENSOR_0 == -1
637
-  #define HEATER_0_USES_AD595
638
-#endif
639
-#if TEMP_SENSOR_1 == -1
640
-  #define HEATER_1_USES_AD595
641
-#endif
642
-#if TEMP_SENSOR_2 == -1
643
-  #define HEATER_2_USES_AD595
644
-#endif
645
-#if TEMP_SENSOR_3 == -1
646
-  #define HEATER_3_USES_AD595
647
-#endif
648
-#if TEMP_SENSOR_BED == -1
649
-  #define BED_USES_AD595
650
-#endif
651
-#if TEMP_SENSOR_0 == -2
652
-  #define HEATER_0_USES_MAX6675
653
-#endif
654
-#if TEMP_SENSOR_0 == 0
655
-  #undef HEATER_0_MINTEMP
656
-  #undef HEATER_0_MAXTEMP
657
-#endif
658
-#if TEMP_SENSOR_1 == 0
659
-  #undef HEATER_1_MINTEMP
660
-  #undef HEATER_1_MAXTEMP
661
-#endif
662
-#if TEMP_SENSOR_2 == 0
663
-  #undef HEATER_2_MINTEMP
664
-  #undef HEATER_2_MAXTEMP
665
-#endif
666
-#if TEMP_SENSOR_3 == 0
667
-  #undef HEATER_3_MINTEMP
668
-  #undef HEATER_3_MAXTEMP
669
-#endif
670
-#if TEMP_SENSOR_BED == 0
671
-  #undef BED_MINTEMP
672
-  #undef BED_MAXTEMP
673
-#endif
674
-
675
-
676
-#endif //__CONFIGURATION_ADV_H
479
+#endif //CONFIGURATION_ADV_H

+ 25
- 31
Marlin/Marlin.h ファイルの表示

@@ -20,11 +20,6 @@
20 20
 
21 21
 #include "fastio.h"
22 22
 #include "Configuration.h"
23
-#include "pins.h"
24
-
25
-#ifndef AT90USB
26
-  #define  HardwareSerial_h // trick to disable the standard HWserial
27
-#endif
28 23
 
29 24
 #if (ARDUINO >= 100)
30 25
   #include "Arduino.h"
@@ -191,17 +186,17 @@ void ClearToSend();
191 186
 
192 187
 void get_coordinates();
193 188
 #ifdef DELTA
194
-void calculate_delta(float cartesian[3]);
189
+  void calculate_delta(float cartesian[3]);
195 190
   #ifdef ENABLE_AUTO_BED_LEVELING
196
-  extern int delta_grid_spacing[2];
197
-  void adjust_delta(float cartesian[3]);
191
+    extern int delta_grid_spacing[2];
192
+    void adjust_delta(float cartesian[3]);
198 193
   #endif
199
-extern float delta[3];
200
-void prepare_move_raw();
194
+  extern float delta[3];
195
+  void prepare_move_raw();
201 196
 #endif
202 197
 #ifdef SCARA
203
-void calculate_delta(float cartesian[3]);
204
-void calculate_SCARA_forward_Transform(float f_scara[3]);
198
+  void calculate_delta(float cartesian[3]);
199
+  void calculate_SCARA_forward_Transform(float f_scara[3]);
205 200
 #endif
206 201
 void reset_bed_level();
207 202
 void prepare_move();
@@ -209,7 +204,7 @@ void kill();
209 204
 void Stop();
210 205
 
211 206
 #ifdef FILAMENT_RUNOUT_SENSOR
212
-void filrunout();
207
+  void filrunout();
213 208
 #endif
214 209
 
215 210
 bool IsStopped();
@@ -223,7 +218,7 @@ void clamp_to_software_endstops(float target[3]);
223 218
 void refresh_cmd_timeout(void);
224 219
 
225 220
 #ifdef FAST_PWM_FAN
226
-void setPwmFrequency(uint8_t pin, int val);
221
+  void setPwmFrequency(uint8_t pin, int val);
227 222
 #endif
228 223
 
229 224
 #ifndef CRITICAL_SECTION_START
@@ -242,14 +237,14 @@ extern float volumetric_multiplier[EXTRUDERS]; // reciprocal of cross-sectional
242 237
 extern float current_position[NUM_AXIS] ;
243 238
 extern float home_offset[3];
244 239
 #ifdef DELTA
245
-extern float endstop_adj[3];
246
-extern float delta_radius;
247
-extern float delta_diagonal_rod;
248
-extern float delta_segments_per_second;
249
-void recalc_delta_settings(float radius, float diagonal_rod);
240
+  extern float endstop_adj[3];
241
+  extern float delta_radius;
242
+  extern float delta_diagonal_rod;
243
+  extern float delta_segments_per_second;
244
+  void recalc_delta_settings(float radius, float diagonal_rod);
250 245
 #endif
251 246
 #ifdef SCARA
252
-extern float axis_scaling[3];  // Build size scaling
247
+  extern float axis_scaling[3];  // Build size scaling
253 248
 #endif
254 249
 extern float min_pos[3];
255 250
 extern float max_pos[3];
@@ -257,12 +252,12 @@ extern bool axis_known_position[3];
257 252
 extern float zprobe_zoffset;
258 253
 extern int fanSpeed;
259 254
 #ifdef BARICUDA
260
-extern int ValvePressure;
261
-extern int EtoPPressure;
255
+  extern int ValvePressure;
256
+  extern int EtoPPressure;
262 257
 #endif
263 258
 
264 259
 #ifdef FAN_SOFT_PWM
265
-extern unsigned char fanSpeedSoftPwm;
260
+  extern unsigned char fanSpeedSoftPwm;
266 261
 #endif
267 262
 
268 263
 #ifdef FILAMENT_SENSOR
@@ -276,10 +271,10 @@ extern unsigned char fanSpeedSoftPwm;
276 271
 #endif
277 272
 
278 273
 #ifdef FWRETRACT
279
-extern bool autoretract_enabled;
280
-extern bool retracted[EXTRUDERS];
281
-extern float retract_length, retract_length_swap, retract_feedrate, retract_zlift;
282
-extern float retract_recover_length, retract_recover_length_swap, retract_recover_feedrate;
274
+  extern bool autoretract_enabled;
275
+  extern bool retracted[EXTRUDERS];
276
+  extern float retract_length, retract_length_swap, retract_feedrate, retract_zlift;
277
+  extern float retract_recover_length, retract_recover_length_swap, retract_recover_feedrate;
283 278
 #endif
284 279
 
285 280
 extern unsigned long starttime;
@@ -289,11 +284,10 @@ extern unsigned long stoptime;
289 284
 extern uint8_t active_extruder;
290 285
 
291 286
 #ifdef DIGIPOT_I2C
292
-extern void digipot_i2c_set_current( int channel, float current );
293
-extern void digipot_i2c_init();
294
-#endif
295
-
287
+  extern void digipot_i2c_set_current( int channel, float current );
288
+  extern void digipot_i2c_init();
296 289
 #endif
297 290
 
298 291
 extern void calculate_volumetric_multipliers();
299 292
 
293
+#endif //MARLIN_H

+ 27
- 75
Marlin/Marlin_main.cpp ファイルの表示

@@ -30,9 +30,6 @@
30 30
 #include "Marlin.h"
31 31
 
32 32
 #ifdef ENABLE_AUTO_BED_LEVELING
33
-  #if Z_MIN_PIN == -1
34
-    #error "You must have a Z_MIN endstop to enable Auto Bed Leveling feature. Z_MIN_PIN must point to a valid hardware pin."
35
-  #endif
36 33
   #include "vector_3.h"
37 34
   #ifdef AUTO_BED_LEVELING_GRID
38 35
     #include "qr_solve.h"
@@ -967,43 +964,36 @@ XYZ_CONSTS_FROM_CONFIG(float, home_retract_mm, HOME_RETRACT_MM);
967 964
 XYZ_CONSTS_FROM_CONFIG(signed char, home_dir,  HOME_DIR);
968 965
 
969 966
 #ifdef DUAL_X_CARRIAGE
970
-  #if EXTRUDERS == 1 || defined(COREXY) \
971
-      || !defined(X2_ENABLE_PIN) || !defined(X2_STEP_PIN) || !defined(X2_DIR_PIN) \
972
-      || !defined(X2_HOME_POS) || !defined(X2_MIN_POS) || !defined(X2_MAX_POS) \
973
-      || !defined(X_MAX_PIN) || X_MAX_PIN < 0
974
-    #error "Missing or invalid definitions for DUAL_X_CARRIAGE mode."
975
-  #endif
976
-  #if X_HOME_DIR != -1 || X2_HOME_DIR != 1
977
-    #error "Please use canonical x-carriage assignment" // the x-carriages are defined by their homing directions
978
-  #endif
979 967
 
980
-#define DXC_FULL_CONTROL_MODE 0
981
-#define DXC_AUTO_PARK_MODE    1
982
-#define DXC_DUPLICATION_MODE  2
983
-static int dual_x_carriage_mode = DEFAULT_DUAL_X_CARRIAGE_MODE;
984
-
985
-static float x_home_pos(int extruder) {
986
-  if (extruder == 0)
987
-    return base_home_pos(X_AXIS) + home_offset[X_AXIS];
988
-  else
989
-    // In dual carriage mode the extruder offset provides an override of the
990
-    // second X-carriage offset when homed - otherwise X2_HOME_POS is used.
991
-    // This allow soft recalibration of the second extruder offset position without firmware reflash
992
-    // (through the M218 command).
993
-    return (extruder_offset[X_AXIS][1] > 0) ? extruder_offset[X_AXIS][1] : X2_HOME_POS;
994
-}
968
+  #define DXC_FULL_CONTROL_MODE 0
969
+  #define DXC_AUTO_PARK_MODE    1
970
+  #define DXC_DUPLICATION_MODE  2
995 971
 
996
-static int x_home_dir(int extruder) {
997
-  return (extruder == 0) ? X_HOME_DIR : X2_HOME_DIR;
998
-}
972
+  static int dual_x_carriage_mode = DEFAULT_DUAL_X_CARRIAGE_MODE;
973
+
974
+  static float x_home_pos(int extruder) {
975
+    if (extruder == 0)
976
+      return base_home_pos(X_AXIS) + add_homing[X_AXIS];
977
+    else
978
+      // In dual carriage mode the extruder offset provides an override of the
979
+      // second X-carriage offset when homed - otherwise X2_HOME_POS is used.
980
+      // This allow soft recalibration of the second extruder offset position without firmware reflash
981
+      // (through the M218 command).
982
+      return (extruder_offset[X_AXIS][1] > 0) ? extruder_offset[X_AXIS][1] : X2_HOME_POS;
983
+  }
984
+
985
+  static int x_home_dir(int extruder) {
986
+    return (extruder == 0) ? X_HOME_DIR : X2_HOME_DIR;
987
+  }
988
+
989
+  static float inactive_extruder_x_pos = X2_MAX_POS; // used in mode 0 & 1
990
+  static bool active_extruder_parked = false; // used in mode 1 & 2
991
+  static float raised_parked_position[NUM_AXIS]; // used in mode 1
992
+  static unsigned long delayed_move_time = 0; // used in mode 1
993
+  static float duplicate_extruder_x_offset = DEFAULT_DUPLICATION_X_OFFSET; // used in mode 2
994
+  static float duplicate_extruder_temp_offset = 0; // used in mode 2
995
+  bool extruder_duplication_enabled = false; // used in mode 2
999 996
 
1000
-static float inactive_extruder_x_pos = X2_MAX_POS; // used in mode 0 & 1
1001
-static bool active_extruder_parked = false; // used in mode 1 & 2
1002
-static float raised_parked_position[NUM_AXIS]; // used in mode 1
1003
-static unsigned long delayed_move_time = 0; // used in mode 1
1004
-static float duplicate_extruder_x_offset = DEFAULT_DUPLICATION_X_OFFSET; // used in mode 2
1005
-static float duplicate_extruder_temp_offset = 0; // used in mode 2
1006
-bool extruder_duplication_enabled = false; // used in mode 2
1007 997
 #endif //DUAL_X_CARRIAGE
1008 998
 
1009 999
 static void axis_is_at_home(int axis) {
@@ -2079,44 +2069,6 @@ inline void gcode_G28() {
2079 2069
 
2080 2070
 #ifdef ENABLE_AUTO_BED_LEVELING
2081 2071
 
2082
-  // Define the possible boundaries for probing based on set limits
2083
-  #define MIN_PROBE_X (max(X_MIN_POS, X_MIN_POS + X_PROBE_OFFSET_FROM_EXTRUDER))
2084
-  #define MAX_PROBE_X (min(X_MAX_POS, X_MAX_POS + X_PROBE_OFFSET_FROM_EXTRUDER))
2085
-  #define MIN_PROBE_Y (max(Y_MIN_POS, Y_MIN_POS + Y_PROBE_OFFSET_FROM_EXTRUDER))
2086
-  #define MAX_PROBE_Y (min(Y_MAX_POS, Y_MAX_POS + Y_PROBE_OFFSET_FROM_EXTRUDER))
2087
-
2088
-  #ifdef AUTO_BED_LEVELING_GRID
2089
-
2090
-    // Make sure probing points are reachable
2091
-
2092
-    #if LEFT_PROBE_BED_POSITION < MIN_PROBE_X
2093
-      #error "The given LEFT_PROBE_BED_POSITION can't be reached by the probe."
2094
-    #elif RIGHT_PROBE_BED_POSITION > MAX_PROBE_X
2095
-      #error "The given RIGHT_PROBE_BED_POSITION can't be reached by the probe."
2096
-    #elif FRONT_PROBE_BED_POSITION < MIN_PROBE_Y
2097
-      #error "The given FRONT_PROBE_BED_POSITION can't be reached by the probe."
2098
-    #elif BACK_PROBE_BED_POSITION > MAX_PROBE_Y
2099
-      #error "The given BACK_PROBE_BED_POSITION can't be reached by the probe."
2100
-    #endif
2101
-
2102
-  #else // !AUTO_BED_LEVELING_GRID
2103
-
2104
-    #if ABL_PROBE_PT_1_X < MIN_PROBE_X || ABL_PROBE_PT_1_X > MAX_PROBE_X
2105
-      #error "The given ABL_PROBE_PT_1_X can't be reached by the probe."
2106
-    #elif ABL_PROBE_PT_2_X < MIN_PROBE_X || ABL_PROBE_PT_2_X > MAX_PROBE_X
2107
-      #error "The given ABL_PROBE_PT_2_X can't be reached by the probe."
2108
-    #elif ABL_PROBE_PT_3_X < MIN_PROBE_X || ABL_PROBE_PT_3_X > MAX_PROBE_X
2109
-      #error "The given ABL_PROBE_PT_3_X can't be reached by the probe."
2110
-    #elif ABL_PROBE_PT_1_Y < MIN_PROBE_Y || ABL_PROBE_PT_1_Y > MAX_PROBE_Y
2111
-      #error "The given ABL_PROBE_PT_1_Y can't be reached by the probe."
2112
-    #elif ABL_PROBE_PT_2_Y < MIN_PROBE_Y || ABL_PROBE_PT_2_Y > MAX_PROBE_Y
2113
-      #error "The given ABL_PROBE_PT_2_Y can't be reached by the probe."
2114
-    #elif ABL_PROBE_PT_3_Y < MIN_PROBE_Y || ABL_PROBE_PT_3_Y > MAX_PROBE_Y
2115
-      #error "The given ABL_PROBE_PT_3_Y can't be reached by the probe."
2116
-    #endif
2117
-
2118
-  #endif // !AUTO_BED_LEVELING_GRID
2119
-
2120 2072
   /**
2121 2073
    * G29: Detailed Z-Probe, probes the bed at 3 or more points.
2122 2074
    *      Will fail if the printer has not been homed with G28.

+ 254
- 0
Marlin/SanityCheck.h ファイルの表示

@@ -0,0 +1,254 @@
1
+/**
2
+ * SanityCheck.h
3
+ *
4
+ * Test configuration values for errors at compile-time.
5
+ */
6
+#ifndef SANITYCHECK_H
7
+  #define SANITYCHECK_H
8
+
9
+  /**
10
+   * Dual Stepper Drivers
11
+   */
12
+  #if defined(Z_DUAL_STEPPER_DRIVERS) && defined(Y_DUAL_STEPPER_DRIVERS)
13
+    #error You cannot have dual stepper drivers for both Y and Z.
14
+  #endif
15
+
16
+  /**
17
+   * Progress Bar
18
+   */
19
+  #ifdef LCD_PROGRESS_BAR
20
+    #ifdef DOGLCD
21
+      #warning LCD_PROGRESS_BAR does not apply to graphical displays.
22
+    #endif
23
+    #ifdef FILAMENT_LCD_DISPLAY
24
+      #error LCD_PROGRESS_BAR and FILAMENT_LCD_DISPLAY are not fully compatible. Comment out this line to use both.
25
+    #endif
26
+  #endif
27
+
28
+  /**
29
+   * Babystepping
30
+   */
31
+  #ifdef BABYSTEPPING
32
+    #ifdef COREXY
33
+      #error BABYSTEPPING not implemented for COREXY yet.
34
+    #endif
35
+    #ifdef SCARA
36
+      #error BABYSTEPPING is not implemented for SCARA yet.
37
+    #endif
38
+    #if defined(DELTA) && defined(BABYSTEP_XY)
39
+      #error BABYSTEPPING only implemented for Z axis on deltabots.
40
+    #endif
41
+  #endif
42
+
43
+  /**
44
+   * Filament Change with Extruder Runout Prevention
45
+   */
46
+  #if defined(FILAMENTCHANGEENABLE) && defined(EXTRUDER_RUNOUT_PREVENT)
47
+    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE.
48
+  #endif
49
+
50
+  /**
51
+   * Options only for EXTRUDERS == 1
52
+   */
53
+  #if EXTRUDERS > 1
54
+
55
+    #if EXTRUDERS > 4
56
+      #error The maximum number of EXTRUDERS is 4.
57
+    #endif
58
+
59
+    #ifdef TEMP_SENSOR_1_AS_REDUNDANT
60
+      #error EXTRUDERS must be 1 with TEMP_SENSOR_1_AS_REDUNDANT.
61
+    #endif
62
+
63
+    #ifdef HEATERS_PARALLEL
64
+      #error EXTRUDERS must be 1 with HEATERS_PARALLEL.
65
+    #endif
66
+
67
+    #ifdef Y_DUAL_STEPPER_DRIVERS
68
+      #error EXTRUDERS must be 1 with Y_DUAL_STEPPER_DRIVERS.
69
+    #endif
70
+
71
+    #ifdef Z_DUAL_STEPPER_DRIVERS
72
+      #error EXTRUDERS must be 1 with Z_DUAL_STEPPER_DRIVERS.
73
+    #endif
74
+
75
+  #endif // EXTRUDERS > 1
76
+
77
+  /**
78
+   * Required LCD language
79
+   */
80
+  #if !defined(DOGLCD) && defined(ULTRA_LCD) && !defined(DISPLAY_CHARSET_HD44780_JAPAN) && !defined(DISPLAY_CHARSET_HD44780_WESTERN)
81
+    #error You must enable either DISPLAY_CHARSET_HD44780_JAPAN or DISPLAY_CHARSET_HD44780_WESTERN for your LCD controller.
82
+  #endif
83
+
84
+  /**
85
+   * Auto Bed Leveling
86
+   */
87
+  #ifdef ENABLE_AUTO_BED_LEVELING
88
+
89
+    /**
90
+     * Require a Z Min pin
91
+     */
92
+    #if Z_MIN_PIN == -1
93
+      #ifdef Z_PROBE_REPEATABILITY_TEST
94
+        #error You must have a Z_MIN endstop to enable Z_PROBE_REPEATABILITY_TEST.
95
+      #else
96
+        #error ENABLE_AUTO_BED_LEVELING requires a Z_MIN endstop. Z_MIN_PIN must point to a valid hardware pin.
97
+      #endif
98
+    #endif
99
+
100
+    /**
101
+     * Check if Probe_Offset * Grid Points is greater than Probing Range
102
+     */
103
+    #ifdef AUTO_BED_LEVELING_GRID
104
+
105
+      // Make sure probing points are reachable
106
+      #if LEFT_PROBE_BED_POSITION < MIN_PROBE_X
107
+        #error The given LEFT_PROBE_BED_POSITION can't be reached by the probe.
108
+      #elif RIGHT_PROBE_BED_POSITION > MAX_PROBE_X
109
+        #error The given RIGHT_PROBE_BED_POSITION can't be reached by the probe.
110
+      #elif FRONT_PROBE_BED_POSITION < MIN_PROBE_Y
111
+        #error The given FRONT_PROBE_BED_POSITION can't be reached by the probe.
112
+      #elif BACK_PROBE_BED_POSITION > MAX_PROBE_Y
113
+        #error The given BACK_PROBE_BED_POSITION can't be reached by the probe.
114
+      #endif
115
+
116
+      #define PROBE_SIZE_X (X_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1))
117
+      #define PROBE_SIZE_Y (Y_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1))
118
+      #define PROBE_AREA_WIDTH (RIGHT_PROBE_BED_POSITION - LEFT_PROBE_BED_POSITION)
119
+      #define PROBE_AREA_DEPTH (BACK_PROBE_BED_POSITION - FRONT_PROBE_BED_POSITION)
120
+      #if X_PROBE_OFFSET_FROM_EXTRUDER < 0
121
+        #if PROBE_SIZE_X <= -PROBE_AREA_WIDTH
122
+          #define X_PROBE_ERROR
123
+        #endif
124
+      #elif PROBE_SIZE_X >= PROBE_AREA_WIDTH
125
+        #define X_PROBE_ERROR
126
+      #endif
127
+      #ifdef X_PROBE_ERROR
128
+        #error The X axis probing range is too small to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS
129
+      #endif
130
+      #if Y_PROBE_OFFSET_FROM_EXTRUDER < 0
131
+        #if PROBE_SIZE_Y <= -PROBE_AREA_DEPTH
132
+          #define Y_PROBE_ERROR
133
+        #endif
134
+      #elif PROBE_SIZE_Y >= PROBE_AREA_DEPTH
135
+        #define Y_PROBE_ERROR
136
+      #endif
137
+      #ifdef Y_PROBE_ERROR
138
+        #error The Y axis probing range is to small to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS
139
+      #endif
140
+
141
+      #undef PROBE_SIZE_X
142
+      #undef PROBE_SIZE_Y
143
+      #undef PROBE_AREA_WIDTH
144
+      #undef PROBE_AREA_DEPTH
145
+
146
+    #else // !AUTO_BED_LEVELING_GRID
147
+
148
+      // Check the triangulation points
149
+      #if ABL_PROBE_PT_1_X < MIN_PROBE_X || ABL_PROBE_PT_1_X > MAX_PROBE_X
150
+        #error "The given ABL_PROBE_PT_1_X can't be reached by the probe."
151
+      #elif ABL_PROBE_PT_2_X < MIN_PROBE_X || ABL_PROBE_PT_2_X > MAX_PROBE_X
152
+        #error "The given ABL_PROBE_PT_2_X can't be reached by the probe."
153
+      #elif ABL_PROBE_PT_3_X < MIN_PROBE_X || ABL_PROBE_PT_3_X > MAX_PROBE_X
154
+        #error "The given ABL_PROBE_PT_3_X can't be reached by the probe."
155
+      #elif ABL_PROBE_PT_1_Y < MIN_PROBE_Y || ABL_PROBE_PT_1_Y > MAX_PROBE_Y
156
+        #error "The given ABL_PROBE_PT_1_Y can't be reached by the probe."
157
+      #elif ABL_PROBE_PT_2_Y < MIN_PROBE_Y || ABL_PROBE_PT_2_Y > MAX_PROBE_Y
158
+        #error "The given ABL_PROBE_PT_2_Y can't be reached by the probe."
159
+      #elif ABL_PROBE_PT_3_Y < MIN_PROBE_Y || ABL_PROBE_PT_3_Y > MAX_PROBE_Y
160
+        #error "The given ABL_PROBE_PT_3_Y can't be reached by the probe."
161
+      #endif
162
+
163
+    #endif // !AUTO_BED_LEVELING_GRID
164
+
165
+  #endif // ENABLE_AUTO_BED_LEVELING
166
+
167
+  /**
168
+   * ULTIPANEL encoder
169
+   */
170
+  #if defined(ULTIPANEL) && !defined(NEWPANEL) && !defined(SR_LCD_2W_NL) && !defined(SHIFT_CLK)
171
+    #error ULTIPANEL requires some kind of encoder.
172
+  #endif
173
+
174
+  /**
175
+   * Delta has limited bed leveling options
176
+   */
177
+  #ifdef DELTA
178
+
179
+    #ifdef ENABLE_AUTO_BED_LEVELING
180
+
181
+      #ifndef AUTO_BED_LEVELING_GRID
182
+        #error Only AUTO_BED_LEVELING_GRID is supported with DELTA.
183
+      #endif
184
+
185
+      #ifdef Z_PROBE_SLED
186
+        #error You cannot use Z_PROBE_SLED with DELTA.
187
+      #endif
188
+
189
+      #ifdef Z_PROBE_REPEATABILITY_TEST
190
+        #error Z_PROBE_REPEATABILITY_TEST is not supported with DELTA yet.
191
+      #endif
192
+
193
+    #endif
194
+
195
+  #endif
196
+
197
+  /**
198
+   * Allen Key Z Probe requires Auto Bed Leveling grid and Delta
199
+   */
200
+  #if defined(Z_PROBE_ALLEN_KEY) && !(defined(AUTO_BED_LEVELING_GRID) && defined(DELTA))
201
+    #error Invalid use of Z_PROBE_ALLEN_KEY.
202
+  #endif
203
+
204
+  /**
205
+   * Dual X Carriage requirements
206
+   */
207
+  #ifdef DUAL_X_CARRIAGE
208
+    #if EXTRUDERS == 1 || defined(COREXY) \
209
+        || !defined(X2_ENABLE_PIN) || !defined(X2_STEP_PIN) || !defined(X2_DIR_PIN) \
210
+        || !defined(X2_HOME_POS) || !defined(X2_MIN_POS) || !defined(X2_MAX_POS) \
211
+        || !defined(X_MAX_PIN) || X_MAX_PIN < 0
212
+      #error Missing or invalid definitions for DUAL_X_CARRIAGE mode.
213
+    #endif
214
+    #if X_HOME_DIR != -1 || X2_HOME_DIR != 1
215
+      #error Please use canonical x-carriage assignment.
216
+    #endif
217
+  #endif // DUAL_X_CARRIAGE
218
+
219
+  /**
220
+   * Make sure auto fan pins don't conflict with the fan pin
221
+   */
222
+  #if HAS_AUTO_FAN && HAS_FAN
223
+    #if EXTRUDER_0_AUTO_FAN_PIN == FAN_PIN
224
+      #error You cannot set EXTRUDER_0_AUTO_FAN_PIN equal to FAN_PIN
225
+    #elif EXTRUDER_1_AUTO_FAN_PIN == FAN_PIN
226
+      #error You cannot set EXTRUDER_1_AUTO_FAN_PIN equal to FAN_PIN
227
+    #elif EXTRUDER_2_AUTO_FAN_PIN == FAN_PIN
228
+      #error You cannot set EXTRUDER_2_AUTO_FAN_PIN equal to FAN_PIN
229
+    #elif EXTRUDER_3_AUTO_FAN_PIN == FAN_PIN
230
+      #error You cannot set EXTRUDER_3_AUTO_FAN_PIN equal to FAN_PIN
231
+    #endif
232
+  #endif
233
+
234
+  /**
235
+   * Test required HEATER defines
236
+   */
237
+  #if EXTRUDERS > 3
238
+    #if !HAS_HEATER_3
239
+      #error HEATER_3_PIN not defined for this board
240
+    #endif
241
+  #elif EXTRUDERS > 2
242
+    #if !HAS_HEATER_2
243
+      #error HEATER_2_PIN not defined for this board
244
+    #endif
245
+  #elif EXTRUDERS > 1 || defined(HEATERS_PARALLEL)
246
+    #if !HAS_HEATER_1
247
+      #error HEATER_1_PIN not defined for this board
248
+    #endif
249
+  #endif
250
+  #if !HAS_HEATER_0
251
+    #error HEATER_0_PIN not defined for this board
252
+  #endif
253
+
254
+#endif //SANITYCHECK_H

+ 2
- 3
Marlin/Sd2PinMap.h ファイルの表示

@@ -33,9 +33,7 @@ struct pin_map_t {
33 33
   uint8_t bit;
34 34
 };
35 35
 //------------------------------------------------------------------------------
36
-#if defined(__AVR_ATmega1280__)\
37
-|| defined(__AVR_ATmega2560__)
38
-// Mega
36
+#if defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__) // Mega
39 37
 
40 38
 // Two Wire (aka I2C) ports
41 39
 uint8_t const SDA_PIN = 20;  // D1
@@ -43,6 +41,7 @@ uint8_t const SCL_PIN = 21;  // D0
43 41
 
44 42
 #undef MOSI_PIN
45 43
 #undef MISO_PIN
44
+#undef SCK_PIN
46 45
 // SPI port
47 46
 uint8_t const SS_PIN = 53;    // B0
48 47
 uint8_t const MOSI_PIN = 51;  // B2

+ 18
- 159
Marlin/configurator/config/Configuration.h ファイルの表示

@@ -330,15 +330,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
330 330
   // #define ENDSTOPPULLUP_ZMIN
331 331
 #endif
332 332
 
333
-#ifdef ENDSTOPPULLUPS
334
-  #define ENDSTOPPULLUP_XMAX
335
-  #define ENDSTOPPULLUP_YMAX
336
-  #define ENDSTOPPULLUP_ZMAX
337
-  #define ENDSTOPPULLUP_XMIN
338
-  #define ENDSTOPPULLUP_YMIN
339
-  #define ENDSTOPPULLUP_ZMIN
340
-#endif
341
-
342 333
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
343 334
 const bool X_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
344 335
 const bool Y_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
@@ -405,12 +396,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
405 396
 #define Y_MAX_POS 205
406 397
 #define Z_MAX_POS 200
407 398
 
408
-// @section hidden
409
-
410
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
411
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
412
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
413
-
399
+//===========================================================================
400
+//============================= Filament Runout Sensor ======================
401
+//===========================================================================
402
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
403
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
404
+                                 // It is assumed that when logic high = filament available
405
+                                 //                    when logic  low = filament ran out
406
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
407
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
414 408
 
415 409
 //===========================================================================
416 410
 //============================= Bed Auto Leveling ===========================
@@ -650,114 +644,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
650 644
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
651 645
 //#define RA_CONTROL_PANEL
652 646
 
653
-// @section hidden
654
-
655
-//automatic expansion
656
-#if defined (MAKRPANEL)
657
- #define DOGLCD
658
- #define SDSUPPORT
659
- #define ULTIPANEL
660
- #define NEWPANEL
661
- #define DEFAULT_LCD_CONTRAST 17
662
-#endif
663
-
664
-#if defined(miniVIKI) || defined(VIKI2)
665
- #define ULTRA_LCD  //general LCD support, also 16x2
666
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
667
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
668
- 
669
-  #ifdef miniVIKI
670
-   #define DEFAULT_LCD_CONTRAST 95
671
-  #else
672
-   #define DEFAULT_LCD_CONTRAST 40
673
-  #endif
674
-  
675
- #define ENCODER_PULSES_PER_STEP 4
676
- #define ENCODER_STEPS_PER_MENU_ITEM 1
677
-#endif
678
-
679
-#if defined (PANEL_ONE)
680
- #define SDSUPPORT
681
- #define ULTIMAKERCONTROLLER
682
-#endif
683
-
684
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
685
- #define DOGLCD
686
- #define U8GLIB_ST7920
687
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
688
-#endif
689
-
690
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
691
- #define ULTIPANEL
692
- #define NEWPANEL
693
-#endif
694
-
695
-#if defined(REPRAPWORLD_KEYPAD)
696
-  #define NEWPANEL
697
-  #define ULTIPANEL
698
-#endif
699
-#if defined(RA_CONTROL_PANEL)
700
- #define ULTIPANEL
701
- #define NEWPANEL
702
- #define LCD_I2C_TYPE_PCA8574
703
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
704
-#endif
705
-
706
-//I2C PANELS
647
+/**
648
+ * I2C Panels
649
+ */
707 650
 
708 651
 //#define LCD_I2C_SAINSMART_YWROBOT
709
-#ifdef LCD_I2C_SAINSMART_YWROBOT
710
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
711
-  // Make sure it is placed in the Arduino libraries directory.
712
-  #define LCD_I2C_TYPE_PCF8575
713
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
714
-  #define NEWPANEL
715
-  #define ULTIPANEL
716
-#endif
717 652
 
718 653
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
719 654
 //#define LCD_I2C_PANELOLU2
720
-#ifdef LCD_I2C_PANELOLU2
721
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
722
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
723
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
724
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
725
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
726
-  #define LCD_I2C_TYPE_MCP23017
727
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
728
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
729
-  #define NEWPANEL
730
-  #define ULTIPANEL
731
-
732
-  #ifndef ENCODER_PULSES_PER_STEP
733
-	#define ENCODER_PULSES_PER_STEP 4
734
-  #endif
735
-
736
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
737
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
738
-  #endif
739
-
740
-
741
-  #ifdef LCD_USE_I2C_BUZZER
742
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
743
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
744
-  #endif
745
-
746
-#endif
747 655
 
748 656
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
749 657
 //#define LCD_I2C_VIKI
750
-#ifdef LCD_I2C_VIKI
751
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
752
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
753
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
754
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
755
-  #define LCD_I2C_TYPE_MCP23017
756
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
757
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
758
-  #define NEWPANEL
759
-  #define ULTIPANEL
760
-#endif
761 658
 
762 659
 // Shift register panels
763 660
 // ---------------------
@@ -765,55 +662,12 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
765 662
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
766 663
 
767 664
 //#define SAV_3DLCD
768
-#ifdef SAV_3DLCD
769
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
770
-   #define NEWPANEL
771
-   #define ULTIPANEL
772
-#endif
773
-
774
-
775
-#ifdef ULTIPANEL
776
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
777
-  #define SDSUPPORT
778
-  #define ULTRA_LCD
779
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
780
-    #define LCD_WIDTH 22
781
-    #define LCD_HEIGHT 5
782
-  #else
783
-    #define LCD_WIDTH 20
784
-    #define LCD_HEIGHT 4
785
-  #endif
786
-#else //no panel but just LCD
787
-  #ifdef ULTRA_LCD
788
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
789
-    #define LCD_WIDTH 22
790
-    #define LCD_HEIGHT 5
791
-  #else
792
-    #define LCD_WIDTH 16
793
-    #define LCD_HEIGHT 2
794
-  #endif
795
-  #endif
796
-#endif
797
-
798
-// @section lcd
799
-
800
-// default LCD contrast for dogm-like LCD displays
801
-#ifdef DOGLCD
802
-# ifndef DEFAULT_LCD_CONTRAST
803
-#  define DEFAULT_LCD_CONTRAST 32
804
-# endif
805
-#endif
806 665
 
807 666
 // @section extras
808 667
 
809 668
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
810 669
 //#define FAST_PWM_FAN
811 670
 
812
-// Temperature status LEDs that display the hotend and bet temperature.
813
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
814
-// Otherwise the RED led is on. There is 1C hysteresis.
815
-//#define TEMP_STAT_LEDS
816
-
817 671
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
818 672
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
819 673
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -825,6 +679,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
825 679
 // at zero value, there are 128 effective control positions.
826 680
 #define SOFT_PWM_SCALE 0
827 681
 
682
+// Temperature status LEDs that display the hotend and bet temperature.
683
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
684
+// Otherwise the RED led is on. There is 1C hysteresis.
685
+//#define TEMP_STAT_LEDS
686
+
828 687
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
829 688
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
830 689
 // #define PHOTOGRAPH_PIN     23
@@ -896,4 +755,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
896 755
 #include "Configuration_adv.h"
897 756
 #include "thermistortables.h"
898 757
 
899
-#endif //__CONFIGURATION_H
758
+#endif //CONFIGURATION_H

+ 10
- 211
Marlin/configurator/config/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 // @section temperature
5 7
 
6 8
 //===========================================================================
@@ -99,56 +101,6 @@
99 101
 
100 102
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
101 103
 
102
-
103
-// @section hidden
104
-
105
-
106
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
107
-//// Added by ZetaPhoenix 09-15-2012
108
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
109
-  #define X_HOME_POS MANUAL_X_HOME_POS
110
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
111
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
112
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
113
-  //X axis
114
-  #if X_HOME_DIR == -1
115
-    #ifdef BED_CENTER_AT_0_0
116
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
117
-    #else
118
-      #define X_HOME_POS X_MIN_POS
119
-    #endif //BED_CENTER_AT_0_0
120
-  #else
121
-    #ifdef BED_CENTER_AT_0_0
122
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
123
-    #else
124
-      #define X_HOME_POS X_MAX_POS
125
-    #endif //BED_CENTER_AT_0_0
126
-  #endif //X_HOME_DIR == -1
127
-
128
-  //Y axis
129
-  #if Y_HOME_DIR == -1
130
-    #ifdef BED_CENTER_AT_0_0
131
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
132
-    #else
133
-      #define Y_HOME_POS Y_MIN_POS
134
-    #endif //BED_CENTER_AT_0_0
135
-  #else
136
-    #ifdef BED_CENTER_AT_0_0
137
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
138
-    #else
139
-      #define Y_HOME_POS Y_MAX_POS
140
-    #endif //BED_CENTER_AT_0_0
141
-  #endif //Y_HOME_DIR == -1
142
-
143
-  // Z axis
144
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
145
-    #define Z_HOME_POS Z_MIN_POS
146
-  #else
147
-    #define Z_HOME_POS Z_MAX_POS
148
-  #endif //Z_HOME_DIR == -1
149
-#endif //End auto min/max positions
150
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
151
-
152 104
 // @section extras
153 105
 
154 106
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
@@ -160,26 +112,12 @@
160 112
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
161 113
 //#define Z_DUAL_STEPPER_DRIVERS
162 114
 
163
-#ifdef Z_DUAL_STEPPER_DRIVERS
164
-  #undef EXTRUDERS
165
-  #define EXTRUDERS 1
166
-#endif
167
-
168 115
 // Same again but for Y Axis.
169 116
 //#define Y_DUAL_STEPPER_DRIVERS
170 117
 
171 118
 // Define if the two Y drives need to rotate in opposite directions
172 119
 #define INVERT_Y2_VS_Y_DIR true
173 120
 
174
-#ifdef Y_DUAL_STEPPER_DRIVERS
175
-  #undef EXTRUDERS
176
-  #define EXTRUDERS 1
177
-#endif
178
-
179
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
180
-  #error "You cannot have dual drivers for both Y and Z"
181
-#endif
182
-
183 121
 // Enable this for dual x-carriage printers.
184 122
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
185 123
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -236,14 +174,6 @@
236 174
 
237 175
 #define AXIS_RELATIVE_MODES {false, false, false, false}
238 176
 
239
-// @section hidden
240
-
241
-#ifdef CONFIG_STEPPERS_TOSHIBA
242
-  #define MAX_STEP_FREQUENCY 10000 // Max step frequency for Toshiba Stepper Controllers
243
-#else
244
-  #define MAX_STEP_FREQUENCY 40000 // Max step frequency for Ultimaker (5000 pps / half step)
245
-#endif
246
-
247 177
 // @section machine
248 178
 
249 179
 //By default pololu step drivers require an active high signal. However, some high power drivers require an active low signal as step.
@@ -252,7 +182,7 @@
252 182
 #define INVERT_Z_STEP_PIN false
253 183
 #define INVERT_E_STEP_PIN false
254 184
 
255
-//default stepper release if idle. Set to 0 to deactivate.
185
+// Default stepper release if idle. Set to 0 to deactivate.
256 186
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
257 187
 
258 188
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
@@ -260,14 +190,9 @@
260 190
 
261 191
 // @section lcd
262 192
 
263
-// Feedrates for manual moves along X, Y, Z, E from panel
264 193
 #ifdef ULTIPANEL
265
-#define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60}  // set the speeds for manual moves (mm/min)
266
-#endif
267
-
268
-//Comment to disable setting feedrate multiplier via encoder
269
-#ifdef ULTIPANEL
270
-    #define ULTIPANEL_FEEDMULTIPLY
194
+  #define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60} // Feedrates for manual moves along X, Y, Z, E from panel
195
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
271 196
 #endif
272 197
 
273 198
 // @section extras
@@ -288,13 +213,6 @@
288 213
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
289 214
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
290 215
 
291
-// MS1 MS2 Stepper Driver Microstepping mode table
292
-#define MICROSTEP1 LOW,LOW
293
-#define MICROSTEP2 HIGH,LOW
294
-#define MICROSTEP4 LOW,HIGH
295
-#define MICROSTEP8 HIGH,HIGH
296
-#define MICROSTEP16 HIGH,HIGH
297
-
298 216
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
299 217
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
300 218
 
@@ -342,12 +260,6 @@
342 260
   #define PROGRESS_MSG_EXPIRE   0
343 261
   // Enable this to show messages for MSG_TIME then hide them
344 262
   //#define PROGRESS_MSG_ONCE
345
-  #ifdef DOGLCD
346
-    #warning LCD_PROGRESS_BAR does not apply to graphical displays at this time.
347
-  #endif
348
-  #ifdef FILAMENT_LCD_DISPLAY
349
-    #error LCD_PROGRESS_BAR and FILAMENT_LCD_DISPLAY are not fully compatible. Comment out this line to use both.
350
-  #endif
351 263
 #endif
352 264
 
353 265
 // @section more
@@ -373,16 +285,6 @@
373 285
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
374 286
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
375 287
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
376
-
377
-  #ifdef COREXY
378
-    #error BABYSTEPPING not implemented for COREXY yet.
379
-  #endif
380
-
381
-  #ifdef DELTA
382
-    #ifdef BABYSTEP_XY
383
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
384
-    #endif
385
-  #endif
386 288
 #endif
387 289
 
388 290
 // extruder advance constant (s2/mm3)
@@ -418,28 +320,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
418 320
 // be commented out otherwise
419 321
 #define SDCARDDETECTINVERTED
420 322
 
421
-// @section hidden
422
-
423
-#ifdef ULTIPANEL
424
- #undef SDCARDDETECTINVERTED
425
-#endif
426
-
427
-// Power Signal Control Definitions
428
-// By default use ATX definition
429
-#ifndef POWER_SUPPLY
430
-  #define POWER_SUPPLY 1
431
-#endif
432
-// 1 = ATX
433
-#if (POWER_SUPPLY == 1)
434
-  #define PS_ON_AWAKE  LOW
435
-  #define PS_ON_ASLEEP HIGH
436
-#endif
437
-// 2 = X-Box 360 203W
438
-#if (POWER_SUPPLY == 2)
439
-  #define PS_ON_AWAKE  HIGH
440
-  #define PS_ON_ASLEEP LOW
441
-#endif
442
-
443 323
 // @section temperature
444 324
 
445 325
 // Control heater 0 and heater 1 in parallel.
@@ -485,9 +365,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
485 365
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
486 366
 #endif
487 367
 
488
-//adds support for experimental filament exchange support M600; requires display
368
+// Add support for experimental filament exchange support M600; requires display
489 369
 #ifdef ULTIPANEL
490
-  #define FILAMENTCHANGEENABLE
370
+  //#define FILAMENTCHANGEENABLE
491 371
   #ifdef FILAMENTCHANGEENABLE
492 372
     #define FILAMENTCHANGE_XPOS 3
493 373
     #define FILAMENTCHANGE_YPOS 3
@@ -497,88 +377,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
497 377
   #endif
498 378
 #endif
499 379
 
500
-#ifdef FILAMENTCHANGEENABLE
501
-  #ifdef EXTRUDER_RUNOUT_PREVENT
502
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
503
-  #endif
504
-#endif
505
-
506
-//===========================================================================
507
-//=============================  Define Defines  ============================
508
-//===========================================================================
509
-
510
-// @section hidden
511
-
512
-#if defined (ENABLE_AUTO_BED_LEVELING) && defined (DELTA)
513
-  #error "Bed Auto Leveling is still not compatible with Delta Kinematics."
514
-#endif
515
-
516
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
517
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
518
-#endif
519
-
520
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
521
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
522
-#endif
523
-
524
-#if TEMP_SENSOR_0 > 0
525
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
526
-  #define HEATER_0_USES_THERMISTOR
527
-#endif
528
-#if TEMP_SENSOR_1 > 0
529
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
530
-  #define HEATER_1_USES_THERMISTOR
531
-#endif
532
-#if TEMP_SENSOR_2 > 0
533
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
534
-  #define HEATER_2_USES_THERMISTOR
535
-#endif
536
-#if TEMP_SENSOR_3 > 0
537
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
538
-  #define HEATER_3_USES_THERMISTOR
539
-#endif
540
-#if TEMP_SENSOR_BED > 0
541
-  #define THERMISTORBED TEMP_SENSOR_BED
542
-  #define BED_USES_THERMISTOR
543
-#endif
544
-#if TEMP_SENSOR_0 == -1
545
-  #define HEATER_0_USES_AD595
546
-#endif
547
-#if TEMP_SENSOR_1 == -1
548
-  #define HEATER_1_USES_AD595
549
-#endif
550
-#if TEMP_SENSOR_2 == -1
551
-  #define HEATER_2_USES_AD595
552
-#endif
553
-#if TEMP_SENSOR_3 == -1
554
-  #define HEATER_3_USES_AD595
555
-#endif
556
-#if TEMP_SENSOR_BED == -1
557
-  #define BED_USES_AD595
558
-#endif
559
-#if TEMP_SENSOR_0 == -2
560
-  #define HEATER_0_USES_MAX6675
561
-#endif
562
-#if TEMP_SENSOR_0 == 0
563
-  #undef HEATER_0_MINTEMP
564
-  #undef HEATER_0_MAXTEMP
565
-#endif
566
-#if TEMP_SENSOR_1 == 0
567
-  #undef HEATER_1_MINTEMP
568
-  #undef HEATER_1_MAXTEMP
569
-#endif
570
-#if TEMP_SENSOR_2 == 0
571
-  #undef HEATER_2_MINTEMP
572
-  #undef HEATER_2_MAXTEMP
573
-#endif
574
-#if TEMP_SENSOR_3 == 0
575
-  #undef HEATER_3_MINTEMP
576
-  #undef HEATER_3_MAXTEMP
577
-#endif
578
-#if TEMP_SENSOR_BED == 0
579
-  #undef BED_MINTEMP
580
-  #undef BED_MAXTEMP
581
-#endif
582
-
380
+#include "Conditionals.h"
381
+#include "SanityCheck.h"
583 382
 
584
-#endif //__CONFIGURATION_ADV_H
383
+#endif //CONFIGURATION_ADV_H

+ 17
- 171
Marlin/example_configurations/Felix/Configuration.h ファイルの表示

@@ -296,15 +296,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
296 296
   // #define ENDSTOPPULLUP_ZMIN
297 297
 #endif
298 298
 
299
-#ifdef ENDSTOPPULLUPS
300
-  #define ENDSTOPPULLUP_XMAX
301
-  #define ENDSTOPPULLUP_YMAX
302
-  #define ENDSTOPPULLUP_ZMAX
303
-  #define ENDSTOPPULLUP_XMIN
304
-  #define ENDSTOPPULLUP_YMIN
305
-  #define ENDSTOPPULLUP_ZMIN
306
-#endif
307
-
308 299
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
309 300
 const bool X_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
310 301
 const bool Y_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
@@ -353,10 +344,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
353 344
 #define Z_MAX_POS 235
354 345
 #define Z_MIN_POS 0
355 346
 
356
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
357
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
358
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
359
-
347
+//===========================================================================
348
+//============================= Filament Runout Sensor ======================
349
+//===========================================================================
350
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
351
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
352
+                                 // It is assumed that when logic high = filament available
353
+                                 //                    when logic  low = filament ran out
354
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
355
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
360 356
 
361 357
 //===========================================================================
362 358
 //============================= Bed Auto Leveling ===========================
@@ -451,29 +447,6 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
451 447
 
452 448
   #endif
453 449
 
454
-  #ifdef AUTO_BED_LEVELING_GRID	// Check if Probe_Offset * Grid Points is greater than Probing Range
455
-    #if X_PROBE_OFFSET_FROM_EXTRUDER < 0
456
-      #if (-(X_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1)) >= (RIGHT_PROBE_BED_POSITION - LEFT_PROBE_BED_POSITION))
457
-	     #error "The X axis probing range is not enough to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS"
458
-	  #endif
459
-	#else
460
-      #if ((X_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1)) >= (RIGHT_PROBE_BED_POSITION - LEFT_PROBE_BED_POSITION))
461
-	     #error "The X axis probing range is not enough to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS"
462
-	  #endif
463
-	#endif
464
-    #if Y_PROBE_OFFSET_FROM_EXTRUDER < 0
465
-      #if (-(Y_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1)) >= (BACK_PROBE_BED_POSITION - FRONT_PROBE_BED_POSITION))
466
-	     #error "The Y axis probing range is not enough to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS"
467
-	  #endif
468
-	#else
469
-      #if ((Y_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1)) >= (BACK_PROBE_BED_POSITION - FRONT_PROBE_BED_POSITION))
470
-	     #error "The Y axis probing range is not enough to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS"
471
-	  #endif
472
-	#endif
473
-
474
-
475
-  #endif
476
-
477 450
 #endif // ENABLE_AUTO_BED_LEVELING
478 451
 
479 452
 
@@ -609,112 +582,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
609 582
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
610 583
 //#define RA_CONTROL_PANEL
611 584
 
612
-//automatic expansion
613
-#if defined (MAKRPANEL)
614
- #define DOGLCD
615
- #define SDSUPPORT
616
- #define ULTIPANEL
617
- #define NEWPANEL
618
- #define DEFAULT_LCD_CONTRAST 17
619
-#endif
620
-
621
-#if defined(miniVIKI) || defined(VIKI2)
622
- #define ULTRA_LCD  //general LCD support, also 16x2
623
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
624
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
625
-
626
-  #ifdef miniVIKI
627
-   #define DEFAULT_LCD_CONTRAST 95
628
-  #else
629
-   #define DEFAULT_LCD_CONTRAST 40
630
-  #endif
631
-
632
- #define ENCODER_PULSES_PER_STEP 4
633
- #define ENCODER_STEPS_PER_MENU_ITEM 1
634
-#endif
635
-
636
-#if defined (PANEL_ONE)
637
- #define SDSUPPORT
638
- #define ULTIMAKERCONTROLLER
639
-#endif
640
-
641
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
642
- #define DOGLCD
643
- #define U8GLIB_ST7920
644
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
645
-#endif
646
-
647
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
648
- #define ULTIPANEL
649
- #define NEWPANEL
650
-#endif
651
-
652
-#if defined(REPRAPWORLD_KEYPAD)
653
-  #define NEWPANEL
654
-  #define ULTIPANEL
655
-#endif
656
-#if defined(RA_CONTROL_PANEL)
657
- #define ULTIPANEL
658
- #define NEWPANEL
659
- #define LCD_I2C_TYPE_PCA8574
660
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
661
-#endif
662
-
663
-//I2C PANELS
585
+/**
586
+ * I2C Panels
587
+ */
664 588
 
665 589
 //#define LCD_I2C_SAINSMART_YWROBOT
666
-#ifdef LCD_I2C_SAINSMART_YWROBOT
667
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
668
-  // Make sure it is placed in the Arduino libraries directory.
669
-  #define LCD_I2C_TYPE_PCF8575
670
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
671
-  #define NEWPANEL
672
-  #define ULTIPANEL
673
-#endif
674 590
 
675 591
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
676 592
 //#define LCD_I2C_PANELOLU2
677
-#ifdef LCD_I2C_PANELOLU2
678
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
679
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
680
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
681
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
682
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
683
-  #define LCD_I2C_TYPE_MCP23017
684
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
685
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
686
-  #define NEWPANEL
687
-  #define ULTIPANEL
688
-
689
-  #ifndef ENCODER_PULSES_PER_STEP
690
-	#define ENCODER_PULSES_PER_STEP 4
691
-  #endif
692
-
693
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
694
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
695
-  #endif
696
-
697
-
698
-  #ifdef LCD_USE_I2C_BUZZER
699
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
700
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
701
-  #endif
702
-
703
-#endif
704 593
 
705 594
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
706 595
 //#define LCD_I2C_VIKI
707
-#ifdef LCD_I2C_VIKI
708
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
709
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
710
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
711
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
712
-  #define LCD_I2C_TYPE_MCP23017
713
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
714
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
715
-  #define NEWPANEL
716
-  #define ULTIPANEL
717
-#endif
718 596
 
719 597
 // Shift register panels
720 598
 // ---------------------
@@ -722,42 +600,6 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
722 600
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection
723 601
 
724 602
 //#define SAV_3DLCD
725
-#ifdef SAV_3DLCD
726
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
727
-   #define NEWPANEL
728
-   #define ULTIPANEL
729
-#endif
730
-
731
-
732
-#ifdef ULTIPANEL
733
-  #define NEWPANEL  //enable this if you have a click-encoder panel
734
-  #define SDSUPPORT
735
-  #define ULTRA_LCD
736
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
737
-    #define LCD_WIDTH 22
738
-    #define LCD_HEIGHT 5
739
-  #else
740
-    #define LCD_WIDTH 20
741
-    #define LCD_HEIGHT 4
742
-  #endif
743
-#else //no panel but just LCD
744
-  #ifdef ULTRA_LCD
745
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
746
-    #define LCD_WIDTH 22
747
-    #define LCD_HEIGHT 5
748
-  #else
749
-    #define LCD_WIDTH 16
750
-    #define LCD_HEIGHT 2
751
-  #endif
752
-  #endif
753
-#endif
754
-
755
-// default LCD contrast for dogm-like LCD displays
756
-#ifdef DOGLCD
757
-# ifndef DEFAULT_LCD_CONTRAST
758
-#  define DEFAULT_LCD_CONTRAST 32
759
-# endif
760
-#endif
761 603
 
762 604
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
763 605
 #define FAST_PWM_FAN
@@ -842,7 +684,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
842 684
 //#define FILAMENT_LCD_DISPLAY
843 685
 
844 686
 
687
+
688
+
689
+
690
+
845 691
 #include "Configuration_adv.h"
846 692
 #include "thermistortables.h"
847 693
 
848
-#endif //__CONFIGURATION_H
694
+#endif //CONFIGURATION_H

+ 17
- 170
Marlin/example_configurations/Felix/Configuration_DUAL.h ファイルの表示

@@ -296,15 +296,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
296 296
   // #define ENDSTOPPULLUP_ZMIN
297 297
 #endif
298 298
 
299
-#ifdef ENDSTOPPULLUPS
300
-  #define ENDSTOPPULLUP_XMAX
301
-  #define ENDSTOPPULLUP_YMAX
302
-  #define ENDSTOPPULLUP_ZMAX
303
-  #define ENDSTOPPULLUP_XMIN
304
-  #define ENDSTOPPULLUP_YMIN
305
-  #define ENDSTOPPULLUP_ZMIN
306
-#endif
307
-
308 299
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
309 300
 const bool X_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
310 301
 const bool Y_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
@@ -353,10 +344,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
353 344
 #define Z_MAX_POS 235
354 345
 #define Z_MIN_POS 0
355 346
 
356
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
357
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
358
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
359
-
347
+//===========================================================================
348
+//============================= Filament Runout Sensor ======================
349
+//===========================================================================
350
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
351
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
352
+                                 // It is assumed that when logic high = filament available
353
+                                 //                    when logic  low = filament ran out
354
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
355
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
360 356
 
361 357
 //===========================================================================
362 358
 //============================= Bed Auto Leveling ===========================
@@ -451,29 +447,6 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
451 447
 
452 448
   #endif
453 449
 
454
-  #ifdef AUTO_BED_LEVELING_GRID	// Check if Probe_Offset * Grid Points is greater than Probing Range
455
-    #if X_PROBE_OFFSET_FROM_EXTRUDER < 0
456
-      #if (-(X_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1)) >= (RIGHT_PROBE_BED_POSITION - LEFT_PROBE_BED_POSITION))
457
-	     #error "The X axis probing range is not enough to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS"
458
-	  #endif
459
-	#else
460
-      #if ((X_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1)) >= (RIGHT_PROBE_BED_POSITION - LEFT_PROBE_BED_POSITION))
461
-	     #error "The X axis probing range is not enough to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS"
462
-	  #endif
463
-	#endif
464
-    #if Y_PROBE_OFFSET_FROM_EXTRUDER < 0
465
-      #if (-(Y_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1)) >= (BACK_PROBE_BED_POSITION - FRONT_PROBE_BED_POSITION))
466
-	     #error "The Y axis probing range is not enough to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS"
467
-	  #endif
468
-	#else
469
-      #if ((Y_PROBE_OFFSET_FROM_EXTRUDER * (AUTO_BED_LEVELING_GRID_POINTS-1)) >= (BACK_PROBE_BED_POSITION - FRONT_PROBE_BED_POSITION))
470
-	     #error "The Y axis probing range is not enough to fit all the points defined in AUTO_BED_LEVELING_GRID_POINTS"
471
-	  #endif
472
-	#endif
473
-
474
-
475
-  #endif
476
-
477 450
 #endif // ENABLE_AUTO_BED_LEVELING
478 451
 
479 452
 
@@ -609,112 +582,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
609 582
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
610 583
 //#define RA_CONTROL_PANEL
611 584
 
612
-//automatic expansion
613
-#if defined (MAKRPANEL)
614
- #define DOGLCD
615
- #define SDSUPPORT
616
- #define ULTIPANEL
617
- #define NEWPANEL
618
- #define DEFAULT_LCD_CONTRAST 17
619
-#endif
620
-
621
-#if defined(miniVIKI) || defined(VIKI2)
622
- #define ULTRA_LCD  //general LCD support, also 16x2
623
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
624
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
625
-
626
-  #ifdef miniVIKI
627
-   #define DEFAULT_LCD_CONTRAST 95
628
-  #else
629
-   #define DEFAULT_LCD_CONTRAST 40
630
-  #endif
631
-
632
- #define ENCODER_PULSES_PER_STEP 4
633
- #define ENCODER_STEPS_PER_MENU_ITEM 1
634
-#endif
635
-
636
-#if defined (PANEL_ONE)
637
- #define SDSUPPORT
638
- #define ULTIMAKERCONTROLLER
639
-#endif
640
-
641
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
642
- #define DOGLCD
643
- #define U8GLIB_ST7920
644
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
645
-#endif
646
-
647
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
648
- #define ULTIPANEL
649
- #define NEWPANEL
650
-#endif
651
-
652
-#if defined(REPRAPWORLD_KEYPAD)
653
-  #define NEWPANEL
654
-  #define ULTIPANEL
655
-#endif
656
-#if defined(RA_CONTROL_PANEL)
657
- #define ULTIPANEL
658
- #define NEWPANEL
659
- #define LCD_I2C_TYPE_PCA8574
660
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
661
-#endif
662
-
663
-//I2C PANELS
585
+/**
586
+ * I2C Panels
587
+ */
664 588
 
665 589
 //#define LCD_I2C_SAINSMART_YWROBOT
666
-#ifdef LCD_I2C_SAINSMART_YWROBOT
667
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
668
-  // Make sure it is placed in the Arduino libraries directory.
669
-  #define LCD_I2C_TYPE_PCF8575
670
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
671
-  #define NEWPANEL
672
-  #define ULTIPANEL
673
-#endif
674 590
 
675 591
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
676 592
 //#define LCD_I2C_PANELOLU2
677
-#ifdef LCD_I2C_PANELOLU2
678
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
679
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
680
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
681
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
682
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
683
-  #define LCD_I2C_TYPE_MCP23017
684
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
685
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
686
-  #define NEWPANEL
687
-  #define ULTIPANEL
688
-
689
-  #ifndef ENCODER_PULSES_PER_STEP
690
-	#define ENCODER_PULSES_PER_STEP 4
691
-  #endif
692
-
693
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
694
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
695
-  #endif
696
-
697
-
698
-  #ifdef LCD_USE_I2C_BUZZER
699
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
700
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
701
-  #endif
702
-
703
-#endif
704 593
 
705 594
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
706 595
 //#define LCD_I2C_VIKI
707
-#ifdef LCD_I2C_VIKI
708
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
709
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
710
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
711
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
712
-  #define LCD_I2C_TYPE_MCP23017
713
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
714
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
715
-  #define NEWPANEL
716
-  #define ULTIPANEL
717
-#endif
718 596
 
719 597
 // Shift register panels
720 598
 // ---------------------
@@ -722,43 +600,8 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
722 600
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection
723 601
 
724 602
 //#define SAV_3DLCD
725
-#ifdef SAV_3DLCD
726
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
727
-   #define NEWPANEL
728
-   #define ULTIPANEL
729
-#endif
730 603
 
731 604
 
732
-#ifdef ULTIPANEL
733
-  #define NEWPANEL  //enable this if you have a click-encoder panel
734
-  #define SDSUPPORT
735
-  #define ULTRA_LCD
736
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
737
-    #define LCD_WIDTH 22
738
-    #define LCD_HEIGHT 5
739
-  #else
740
-    #define LCD_WIDTH 20
741
-    #define LCD_HEIGHT 4
742
-  #endif
743
-#else //no panel but just LCD
744
-  #ifdef ULTRA_LCD
745
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
746
-    #define LCD_WIDTH 22
747
-    #define LCD_HEIGHT 5
748
-  #else
749
-    #define LCD_WIDTH 16
750
-    #define LCD_HEIGHT 2
751
-  #endif
752
-  #endif
753
-#endif
754
-
755
-// default LCD contrast for dogm-like LCD displays
756
-#ifdef DOGLCD
757
-# ifndef DEFAULT_LCD_CONTRAST
758
-#  define DEFAULT_LCD_CONTRAST 32
759
-# endif
760
-#endif
761
-
762 605
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
763 606
 #define FAST_PWM_FAN
764 607
 
@@ -842,7 +685,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
842 685
 //#define FILAMENT_LCD_DISPLAY
843 686
 
844 687
 
688
+
689
+
690
+
691
+
845 692
 #include "Configuration_adv.h"
846 693
 #include "thermistortables.h"
847 694
 
848
-#endif //__CONFIGURATION_H
695
+#endif //CONFIGURATION_H

+ 11
- 186
Marlin/example_configurations/Felix/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers.
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -218,31 +158,22 @@
218 158
 //#define QUICK_HOME  //if this is defined, if both x and y are to be homed, a diagonal move will be performed initially.
219 159
 
220 160
 #define AXIS_RELATIVE_MODES {false, false, false, false}
221
-#ifdef CONFIG_STEPPERS_TOSHIBA
222
-#define MAX_STEP_FREQUENCY 10000 // Max step frequency for Toshiba Stepper Controllers
223
-#else
224
-#define MAX_STEP_FREQUENCY 40000 // Max step frequency for Ultimaker (5000 pps / half step)
225
-#endif
161
+
226 162
 //By default pololu step drivers require an active high signal. However, some high power drivers require an active low signal as step.
227 163
 #define INVERT_X_STEP_PIN false
228 164
 #define INVERT_Y_STEP_PIN false
229 165
 #define INVERT_Z_STEP_PIN false
230 166
 #define INVERT_E_STEP_PIN false
231 167
 
232
-//default stepper release if idle. Set to 0 to deactivate.
168
+// Default stepper release if idle. Set to 0 to deactivate.
233 169
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
234 170
 
235 171
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
236 172
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
237 173
 
238
-// Feedrates for manual moves along X, Y, Z, E from panel
239 174
 #ifdef ULTIPANEL
240
-#define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60}  // set the speeds for manual moves (mm/min)
241
-#endif
242
-
243
-//Comment to disable setting feedrate multiplier via encoder
244
-#ifdef ULTIPANEL
245
-    #define ULTIPANEL_FEEDMULTIPLY
175
+  #define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60} // Feedrates for manual moves along X, Y, Z, E from panel
176
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
246 177
 #endif
247 178
 
248 179
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -261,13 +192,6 @@
261 192
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
262 193
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
263 194
 
264
-// MS1 MS2 Stepper Driver Microstepping mode table
265
-#define MICROSTEP1 LOW,LOW
266
-#define MICROSTEP2 HIGH,LOW
267
-#define MICROSTEP4 LOW,HIGH
268
-#define MICROSTEP8 HIGH,HIGH
269
-#define MICROSTEP16 HIGH,HIGH
270
-
271 195
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
272 196
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
273 197
 
@@ -313,12 +237,6 @@
313 237
   #define PROGRESS_MSG_EXPIRE   0
314 238
   // Enable this to show messages for MSG_TIME then hide them
315 239
   //#define PROGRESS_MSG_ONCE
316
-  #ifdef DOGLCD
317
-    #warning LCD_PROGRESS_BAR does not apply to graphical displays at this time.
318
-  #endif
319
-  #ifdef FILAMENT_LCD_DISPLAY
320
-    #error LCD_PROGRESS_BAR and FILAMENT_LCD_DISPLAY are not fully compatible. Comment out this line to use both.
321
-  #endif
322 240
 #endif
323 241
 
324 242
 // The hardware watchdog should reset the microcontroller disabling all outputs, in case the firmware gets stuck and doesn't do temperature regulation.
@@ -342,16 +260,6 @@
342 260
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
343 261
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
344 262
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
345
-
346
-  #ifdef COREXY
347
-    #error BABYSTEPPING not implemented for COREXY yet.
348
-  #endif
349
-
350
-  #ifdef DELTA
351
-    #ifdef BABYSTEP_XY
352
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
353
-    #endif
354
-  #endif
355 263
 #endif
356 264
 
357 265
 // extruder advance constant (s2/mm3)
@@ -365,12 +273,8 @@
365 273
 
366 274
 #ifdef ADVANCE
367 275
   #define EXTRUDER_ADVANCE_K .0
368
-
369 276
   #define D_FILAMENT 2.85
370 277
   #define STEPS_MM_E 836
371
-  #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
372
-  #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS]/ EXTRUSION_AREA)
373
-
374 278
 #endif // ADVANCE
375 279
 
376 280
 // Arc interpretation settings:
@@ -444,9 +348,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
444 348
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
445 349
 #endif
446 350
 
447
-//adds support for experimental filament exchange support M600; requires display
351
+// Add support for experimental filament exchange support M600; requires display
448 352
 #ifdef ULTIPANEL
449
-  #define FILAMENTCHANGEENABLE
353
+  //#define FILAMENTCHANGEENABLE
450 354
   #ifdef FILAMENTCHANGEENABLE
451 355
     #define FILAMENTCHANGE_XPOS 3
452 356
     #define FILAMENTCHANGE_YPOS 3
@@ -456,86 +360,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
456 360
   #endif
457 361
 #endif
458 362
 
459
-#ifdef FILAMENTCHANGEENABLE
460
-  #ifdef EXTRUDER_RUNOUT_PREVENT
461
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
462
-  #endif
463
-#endif
464
-
465
-//===========================================================================
466
-//=============================  Define Defines  ============================
467
-//===========================================================================
468
-
469
-#if defined (ENABLE_AUTO_BED_LEVELING) && defined (DELTA)
470
-  #error "Bed Auto Leveling is still not compatible with Delta Kinematics."
471
-#endif
472
-
473
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
474
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
475
-#endif
476
-
477
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
478
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
479
-#endif
480
-
481
-#if TEMP_SENSOR_0 > 0
482
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
483
-  #define HEATER_0_USES_THERMISTOR
484
-#endif
485
-#if TEMP_SENSOR_1 > 0
486
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
487
-  #define HEATER_1_USES_THERMISTOR
488
-#endif
489
-#if TEMP_SENSOR_2 > 0
490
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
491
-  #define HEATER_2_USES_THERMISTOR
492
-#endif
493
-#if TEMP_SENSOR_3 > 0
494
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
495
-  #define HEATER_3_USES_THERMISTOR
496
-#endif
497
-#if TEMP_SENSOR_BED > 0
498
-  #define THERMISTORBED TEMP_SENSOR_BED
499
-  #define BED_USES_THERMISTOR
500
-#endif
501
-#if TEMP_SENSOR_0 == -1
502
-  #define HEATER_0_USES_AD595
503
-#endif
504
-#if TEMP_SENSOR_1 == -1
505
-  #define HEATER_1_USES_AD595
506
-#endif
507
-#if TEMP_SENSOR_2 == -1
508
-  #define HEATER_2_USES_AD595
509
-#endif
510
-#if TEMP_SENSOR_3 == -1
511
-  #define HEATER_3_USES_AD595
512
-#endif
513
-#if TEMP_SENSOR_BED == -1
514
-  #define BED_USES_AD595
515
-#endif
516
-#if TEMP_SENSOR_0 == -2
517
-  #define HEATER_0_USES_MAX6675
518
-#endif
519
-#if TEMP_SENSOR_0 == 0
520
-  #undef HEATER_0_MINTEMP
521
-  #undef HEATER_0_MAXTEMP
522
-#endif
523
-#if TEMP_SENSOR_1 == 0
524
-  #undef HEATER_1_MINTEMP
525
-  #undef HEATER_1_MAXTEMP
526
-#endif
527
-#if TEMP_SENSOR_2 == 0
528
-  #undef HEATER_2_MINTEMP
529
-  #undef HEATER_2_MAXTEMP
530
-#endif
531
-#if TEMP_SENSOR_3 == 0
532
-  #undef HEATER_3_MINTEMP
533
-  #undef HEATER_3_MAXTEMP
534
-#endif
535
-#if TEMP_SENSOR_BED == 0
536
-  #undef BED_MINTEMP
537
-  #undef BED_MAXTEMP
538
-#endif
539
-
363
+#include "Conditionals.h"
364
+#include "SanityCheck.h"
540 365
 
541
-#endif //__CONFIGURATION_ADV_H
366
+#endif //CONFIGURATION_ADV_H

+ 18
- 153
Marlin/example_configurations/Hephestos/Configuration.h ファイルの表示

@@ -322,15 +322,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
322 322
   // #define ENDSTOPPULLUP_ZMIN
323 323
 #endif
324 324
 
325
-#ifdef ENDSTOPPULLUPS
326
-  #define ENDSTOPPULLUP_XMAX
327
-  #define ENDSTOPPULLUP_YMAX
328
-  #define ENDSTOPPULLUP_ZMAX
329
-  #define ENDSTOPPULLUP_XMIN
330
-  #define ENDSTOPPULLUP_YMIN
331
-  #define ENDSTOPPULLUP_ZMIN
332
-#endif
333
-
334 325
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
335 326
 const bool X_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
336 327
 const bool Y_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
@@ -379,10 +370,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
379 370
 #define Z_MAX_POS 180
380 371
 #define Z_MIN_POS 0
381 372
 
382
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
383
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
384
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
385
-
373
+//===========================================================================
374
+//============================= Filament Runout Sensor ======================
375
+//===========================================================================
376
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
377
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
378
+                                 // It is assumed that when logic high = filament available
379
+                                 //                    when logic  low = filament ran out
380
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
381
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
386 382
 
387 383
 //===========================================================================
388 384
 //============================= Bed Auto Leveling ===========================
@@ -614,112 +610,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
614 610
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
615 611
 //#define RA_CONTROL_PANEL
616 612
 
617
-//automatic expansion
618
-#if defined (MAKRPANEL)
619
- #define DOGLCD
620
- #define SDSUPPORT
621
- #define ULTIPANEL
622
- #define NEWPANEL
623
- #define DEFAULT_LCD_CONTRAST 17
624
-#endif
625
-
626
-#if defined(miniVIKI) || defined(VIKI2)
627
- #define ULTRA_LCD  //general LCD support, also 16x2
628
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
629
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
630
- 
631
-  #ifdef miniVIKI
632
-   #define DEFAULT_LCD_CONTRAST 95
633
-  #else
634
-   #define DEFAULT_LCD_CONTRAST 40
635
-  #endif
636
-  
637
- #define ENCODER_PULSES_PER_STEP 4
638
- #define ENCODER_STEPS_PER_MENU_ITEM 1
639
-#endif
640
-
641
-#if defined (PANEL_ONE)
642
- #define SDSUPPORT
643
- #define ULTIMAKERCONTROLLER
644
-#endif
645
-
646
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
647
- #define DOGLCD
648
- #define U8GLIB_ST7920
649
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
650
-#endif
651
-
652
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
653
- #define ULTIPANEL
654
- #define NEWPANEL
655
-#endif
656
-
657
-#if defined(REPRAPWORLD_KEYPAD)
658
-  #define NEWPANEL
659
-  #define ULTIPANEL
660
-#endif
661
-#if defined(RA_CONTROL_PANEL)
662
- #define ULTIPANEL
663
- #define NEWPANEL
664
- #define LCD_I2C_TYPE_PCA8574
665
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
666
-#endif
667
-
668
-//I2C PANELS
613
+/**
614
+ * I2C Panels
615
+ */
669 616
 
670 617
 //#define LCD_I2C_SAINSMART_YWROBOT
671
-#ifdef LCD_I2C_SAINSMART_YWROBOT
672
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
673
-  // Make sure it is placed in the Arduino libraries directory.
674
-  #define LCD_I2C_TYPE_PCF8575
675
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
676
-  #define NEWPANEL
677
-  #define ULTIPANEL
678
-#endif
679 618
 
680 619
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
681 620
 //#define LCD_I2C_PANELOLU2
682
-#ifdef LCD_I2C_PANELOLU2
683
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
684
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
685
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
686
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
687
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
688
-  #define LCD_I2C_TYPE_MCP23017
689
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
690
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
691
-  #define NEWPANEL
692
-  #define ULTIPANEL
693
-
694
-  #ifndef ENCODER_PULSES_PER_STEP
695
-	#define ENCODER_PULSES_PER_STEP 4
696
-  #endif
697
-
698
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
699
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
700
-  #endif
701
-
702
-
703
-  #ifdef LCD_USE_I2C_BUZZER
704
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
705
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
706
-  #endif
707
-
708
-#endif
709 621
 
710 622
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
711 623
 //#define LCD_I2C_VIKI
712
-#ifdef LCD_I2C_VIKI
713
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
714
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
715
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
716
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
717
-  #define LCD_I2C_TYPE_MCP23017
718
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
719
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
720
-  #define NEWPANEL
721
-  #define ULTIPANEL
722
-#endif
723 624
 
724 625
 // Shift register panels
725 626
 // ---------------------
@@ -727,51 +628,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
727 628
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
728 629
 
729 630
 //#define SAV_3DLCD
730
-#ifdef SAV_3DLCD
731
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
732
-   #define NEWPANEL
733
-   #define ULTIPANEL
734
-#endif
735
-
736
-
737
-#ifdef ULTIPANEL
738
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
739
-  #define SDSUPPORT
740
-  #define ULTRA_LCD
741
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
742
-    #define LCD_WIDTH 22
743
-    #define LCD_HEIGHT 5
744
-  #else
745
-    #define LCD_WIDTH 20
746
-    #define LCD_HEIGHT 4
747
-  #endif
748
-#else //no panel but just LCD
749
-  #ifdef ULTRA_LCD
750
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
751
-    #define LCD_WIDTH 22
752
-    #define LCD_HEIGHT 5
753
-  #else
754
-    #define LCD_WIDTH 16
755
-    #define LCD_HEIGHT 2
756
-  #endif
757
-  #endif
758
-#endif
759
-
760
-// default LCD contrast for dogm-like LCD displays
761
-#ifdef DOGLCD
762
-# ifndef DEFAULT_LCD_CONTRAST
763
-#  define DEFAULT_LCD_CONTRAST 32
764
-# endif
765
-#endif
766 631
 
767 632
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
768 633
 //#define FAST_PWM_FAN
769 634
 
770
-// Temperature status LEDs that display the hotend and bet temperature.
771
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
772
-// Otherwise the RED led is on. There is 1C hysteresis.
773
-//#define TEMP_STAT_LEDS
774
-
775 635
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
776 636
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
777 637
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -783,6 +643,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
783 643
 // at zero value, there are 128 effective control positions.
784 644
 #define SOFT_PWM_SCALE 0
785 645
 
646
+// Temperature status LEDs that display the hotend and bet temperature.
647
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
648
+// Otherwise the RED led is on. There is 1C hysteresis.
649
+//#define TEMP_STAT_LEDS
650
+
786 651
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
787 652
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
788 653
 // #define PHOTOGRAPH_PIN     23
@@ -854,4 +719,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
854 719
 #include "Configuration_adv.h"
855 720
 #include "thermistortables.h"
856 721
 
857
-#endif //__CONFIGURATION_H
722
+#endif //CONFIGURATION_H

+ 10
- 201
Marlin/example_configurations/Hephestos/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 //#define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers.
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -229,20 +169,15 @@
229 169
 #define INVERT_Z_STEP_PIN false
230 170
 #define INVERT_E_STEP_PIN false
231 171
 
232
-//default stepper release if idle. Set to 0 to deactivate.
172
+// Default stepper release if idle. Set to 0 to deactivate.
233 173
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
234 174
 
235 175
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
236 176
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
237 177
 
238
-// Feedrates for manual moves along X, Y, Z, E from panel
239 178
 #ifdef ULTIPANEL
240
-#define MANUAL_FEEDRATE {120*60, 120*60, 18*60, 60}  // set the speeds for manual moves (mm/min)
241
-#endif
242
-
243
-//Comment to disable setting feedrate multiplier via encoder
244
-#ifdef ULTIPANEL
245
-    #define ULTIPANEL_FEEDMULTIPLY
179
+  #define MANUAL_FEEDRATE {120*60, 120*60, 18*60, 60}  // Feedrates for manual moves along X, Y, Z, E from panel
180
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
246 181
 #endif
247 182
 
248 183
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -261,13 +196,6 @@
261 196
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
262 197
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
263 198
 
264
-// MS1 MS2 Stepper Driver Microstepping mode table
265
-#define MICROSTEP1 LOW,LOW
266
-#define MICROSTEP2 HIGH,LOW
267
-#define MICROSTEP4 LOW,HIGH
268
-#define MICROSTEP8 HIGH,HIGH
269
-#define MICROSTEP16 HIGH,HIGH
270
-
271 199
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
272 200
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
273 201
 
@@ -313,12 +241,6 @@
313 241
   #define PROGRESS_MSG_EXPIRE   0
314 242
   // Enable this to show messages for MSG_TIME then hide them
315 243
   //#define PROGRESS_MSG_ONCE
316
-  #ifdef DOGLCD
317
-    #warning LCD_PROGRESS_BAR does not apply to graphical displays at this time.
318
-  #endif
319
-  #ifdef FILAMENT_LCD_DISPLAY
320
-    #error LCD_PROGRESS_BAR and FILAMENT_LCD_DISPLAY are not fully compatible. Comment out this line to use both.
321
-  #endif
322 244
 #endif
323 245
 
324 246
 // The hardware watchdog should reset the microcontroller disabling all outputs, in case the firmware gets stuck and doesn't do temperature regulation.
@@ -342,16 +264,6 @@
342 264
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
343 265
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
344 266
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
345
-
346
-  #ifdef COREXY
347
-    #error BABYSTEPPING not implemented for COREXY yet.
348
-  #endif
349
-
350
-  #ifdef DELTA
351
-    #ifdef BABYSTEP_XY
352
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
353
-    #endif
354
-  #endif
355 267
 #endif
356 268
 
357 269
 // extruder advance constant (s2/mm3)
@@ -365,12 +277,8 @@
365 277
 
366 278
 #ifdef ADVANCE
367 279
   #define EXTRUDER_ADVANCE_K .0
368
-
369 280
   #define D_FILAMENT 1.75
370 281
   #define STEPS_MM_E 100.47095761381482
371
-  #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
372
-  #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS]/ EXTRUSION_AREA)
373
-
374 282
 #endif // ADVANCE
375 283
 
376 284
 // Arc interpretation settings:
@@ -385,26 +293,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
385 293
 // be commented out otherwise
386 294
 #define SDCARDDETECTINVERTED
387 295
 
388
-#ifdef ULTIPANEL
389
- #undef SDCARDDETECTINVERTED
390
-#endif
391
-
392
-// Power Signal Control Definitions
393
-// By default use ATX definition
394
-#ifndef POWER_SUPPLY
395
-  #define POWER_SUPPLY 1
396
-#endif
397
-// 1 = ATX
398
-#if (POWER_SUPPLY == 1)
399
-  #define PS_ON_AWAKE  LOW
400
-  #define PS_ON_ASLEEP HIGH
401
-#endif
402
-// 2 = X-Box 360 203W
403
-#if (POWER_SUPPLY == 2)
404
-  #define PS_ON_AWAKE  HIGH
405
-  #define PS_ON_ASLEEP LOW
406
-#endif
407
-
408 296
 // Control heater 0 and heater 1 in parallel.
409 297
 //#define HEATERS_PARALLEL
410 298
 
@@ -444,9 +332,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
444 332
   #define RETRACT_RECOVER_FEEDRATE 8*60     //default feedrate for recovering from retraction (mm/s)
445 333
 #endif
446 334
 
447
-//adds support for experimental filament exchange support M600; requires display
335
+// Add support for experimental filament exchange support M600; requires display
448 336
 #ifdef ULTIPANEL
449
-  #define FILAMENTCHANGEENABLE
337
+  //#define FILAMENTCHANGEENABLE
450 338
   #ifdef FILAMENTCHANGEENABLE
451 339
     #define FILAMENTCHANGE_XPOS 3
452 340
     #define FILAMENTCHANGE_YPOS 3
@@ -456,86 +344,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
456 344
   #endif
457 345
 #endif
458 346
 
459
-#ifdef FILAMENTCHANGEENABLE
460
-  #ifdef EXTRUDER_RUNOUT_PREVENT
461
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
462
-  #endif
463
-#endif
464
-
465
-//===========================================================================
466
-//=============================  Define Defines  ============================
467
-//===========================================================================
468
-
469
-#if defined (ENABLE_AUTO_BED_LEVELING) && defined (DELTA)
470
-  #error "Bed Auto Leveling is still not compatible with Delta Kinematics."
471
-#endif
472
-
473
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
474
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
475
-#endif
476
-
477
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
478
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
479
-#endif
480
-
481
-#if TEMP_SENSOR_0 > 0
482
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
483
-  #define HEATER_0_USES_THERMISTOR
484
-#endif
485
-#if TEMP_SENSOR_1 > 0
486
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
487
-  #define HEATER_1_USES_THERMISTOR
488
-#endif
489
-#if TEMP_SENSOR_2 > 0
490
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
491
-  #define HEATER_2_USES_THERMISTOR
492
-#endif
493
-#if TEMP_SENSOR_3 > 0
494
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
495
-  #define HEATER_3_USES_THERMISTOR
496
-#endif
497
-#if TEMP_SENSOR_BED > 0
498
-  #define THERMISTORBED TEMP_SENSOR_BED
499
-  #define BED_USES_THERMISTOR
500
-#endif
501
-#if TEMP_SENSOR_0 == -1
502
-  #define HEATER_0_USES_AD595
503
-#endif
504
-#if TEMP_SENSOR_1 == -1
505
-  #define HEATER_1_USES_AD595
506
-#endif
507
-#if TEMP_SENSOR_2 == -1
508
-  #define HEATER_2_USES_AD595
509
-#endif
510
-#if TEMP_SENSOR_3 == -1
511
-  #define HEATER_3_USES_AD595
512
-#endif
513
-#if TEMP_SENSOR_BED == -1
514
-  #define BED_USES_AD595
515
-#endif
516
-#if TEMP_SENSOR_0 == -2
517
-  #define HEATER_0_USES_MAX6675
518
-#endif
519
-#if TEMP_SENSOR_0 == 0
520
-  #undef HEATER_0_MINTEMP
521
-  #undef HEATER_0_MAXTEMP
522
-#endif
523
-#if TEMP_SENSOR_1 == 0
524
-  #undef HEATER_1_MINTEMP
525
-  #undef HEATER_1_MAXTEMP
526
-#endif
527
-#if TEMP_SENSOR_2 == 0
528
-  #undef HEATER_2_MINTEMP
529
-  #undef HEATER_2_MAXTEMP
530
-#endif
531
-#if TEMP_SENSOR_3 == 0
532
-  #undef HEATER_3_MINTEMP
533
-  #undef HEATER_3_MAXTEMP
534
-#endif
535
-#if TEMP_SENSOR_BED == 0
536
-  #undef BED_MINTEMP
537
-  #undef BED_MAXTEMP
538
-#endif
539
-
347
+#include "Conditionals.h"
348
+#include "SanityCheck.h"
540 349
 
541
-#endif //__CONFIGURATION_ADV_H
350
+#endif //CONFIGURATION_ADV_H

+ 18
- 153
Marlin/example_configurations/K8200/Configuration.h ファイルの表示

@@ -327,15 +327,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
327 327
   #define ENDSTOPPULLUP_ZMIN
328 328
 #endif
329 329
 
330
-#ifdef ENDSTOPPULLUPS
331
-  // #define ENDSTOPPULLUP_XMAX
332
-  // #define ENDSTOPPULLUP_YMAX
333
-  // #define ENDSTOPPULLUP_ZMAX
334
-  #define ENDSTOPPULLUP_XMIN
335
-  #define ENDSTOPPULLUP_YMIN
336
-  #define ENDSTOPPULLUP_ZMIN
337
-#endif
338
-
339 330
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
340 331
 const bool X_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
341 332
 const bool Y_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
@@ -384,10 +375,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
384 375
 #define Z_MAX_POS 200
385 376
 #define Z_MIN_POS 0
386 377
 
387
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
388
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
389
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
390
-
378
+//===========================================================================
379
+//============================= Filament Runout Sensor ======================
380
+//===========================================================================
381
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
382
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
383
+                                 // It is assumed that when logic high = filament available
384
+                                 //                    when logic  low = filament ran out
385
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
386
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
391 387
 
392 388
 //===========================================================================
393 389
 //============================= Bed Auto Leveling ===========================
@@ -618,112 +614,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
618 614
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
619 615
 //#define RA_CONTROL_PANEL
620 616
 
621
-//automatic expansion
622
-#if defined (MAKRPANEL)
623
- #define DOGLCD
624
- #define SDSUPPORT
625
- #define ULTIPANEL
626
- #define NEWPANEL
627
- #define DEFAULT_LCD_CONTRAST 17
628
-#endif
629
-
630
-#if defined(miniVIKI) || defined(VIKI2)
631
- #define ULTRA_LCD  //general LCD support, also 16x2
632
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
633
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
634
- 
635
-  #ifdef miniVIKI
636
-   #define DEFAULT_LCD_CONTRAST 95
637
-  #else
638
-   #define DEFAULT_LCD_CONTRAST 40
639
-  #endif
640
-  
641
- #define ENCODER_PULSES_PER_STEP 4
642
- #define ENCODER_STEPS_PER_MENU_ITEM 1
643
-#endif
644
-
645
-#if defined (PANEL_ONE)
646
- #define SDSUPPORT
647
- #define ULTIMAKERCONTROLLER
648
-#endif
649
-
650
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
651
- #define DOGLCD
652
- #define U8GLIB_ST7920
653
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
654
-#endif
655
-
656
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
657
- #define ULTIPANEL
658
- #define NEWPANEL
659
-#endif
660
-
661
-#if defined(REPRAPWORLD_KEYPAD)
662
-  #define NEWPANEL
663
-  #define ULTIPANEL
664
-#endif
665
-#if defined(RA_CONTROL_PANEL)
666
- #define ULTIPANEL
667
- #define NEWPANEL
668
- #define LCD_I2C_TYPE_PCA8574
669
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
670
-#endif
671
-
672
-//I2C PANELS
617
+/**
618
+ * I2C Panels
619
+ */
673 620
 
674 621
 //#define LCD_I2C_SAINSMART_YWROBOT
675
-#ifdef LCD_I2C_SAINSMART_YWROBOT
676
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
677
-  // Make sure it is placed in the Arduino libraries directory.
678
-  #define LCD_I2C_TYPE_PCF8575
679
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
680
-  #define NEWPANEL
681
-  #define ULTIPANEL
682
-#endif
683 622
 
684 623
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
685 624
 //#define LCD_I2C_PANELOLU2
686
-#ifdef LCD_I2C_PANELOLU2
687
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
688
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
689
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
690
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
691
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
692
-  #define LCD_I2C_TYPE_MCP23017
693
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
694
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
695
-  #define NEWPANEL
696
-  #define ULTIPANEL
697
-
698
-  #ifndef ENCODER_PULSES_PER_STEP
699
-	#define ENCODER_PULSES_PER_STEP 4
700
-  #endif
701
-
702
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
703
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
704
-  #endif
705
-
706
-
707
-  #ifdef LCD_USE_I2C_BUZZER
708
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
709
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
710
-  #endif
711
-
712
-#endif
713 625
 
714 626
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
715 627
 //#define LCD_I2C_VIKI
716
-#ifdef LCD_I2C_VIKI
717
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
718
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
719
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
720
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
721
-  #define LCD_I2C_TYPE_MCP23017
722
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
723
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
724
-  #define NEWPANEL
725
-  #define ULTIPANEL
726
-#endif
727 628
 
728 629
 // Shift register panels
729 630
 // ---------------------
@@ -731,51 +632,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
731 632
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
732 633
 
733 634
 //#define SAV_3DLCD
734
-#ifdef SAV_3DLCD
735
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
736
-   #define NEWPANEL
737
-   #define ULTIPANEL
738
-#endif
739
-
740
-
741
-#ifdef ULTIPANEL
742
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
743
-  #define SDSUPPORT
744
-  #define ULTRA_LCD
745
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
746
-    #define LCD_WIDTH 22
747
-    #define LCD_HEIGHT 5
748
-  #else
749
-    #define LCD_WIDTH 20
750
-    #define LCD_HEIGHT 4
751
-  #endif
752
-#else //no panel but just LCD
753
-  #ifdef ULTRA_LCD
754
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
755
-    #define LCD_WIDTH 22
756
-    #define LCD_HEIGHT 5
757
-  #else
758
-    #define LCD_WIDTH 16
759
-    #define LCD_HEIGHT 2
760
-  #endif
761
-  #endif
762
-#endif
763
-
764
-// default LCD contrast for dogm-like LCD displays
765
-#ifdef DOGLCD
766
-# ifndef DEFAULT_LCD_CONTRAST
767
-#  define DEFAULT_LCD_CONTRAST 32
768
-# endif
769
-#endif
770 635
 
771 636
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
772 637
 //#define FAST_PWM_FAN
773 638
 
774
-// Temperature status LEDs that display the hotend and bet temperature.
775
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
776
-// Otherwise the RED led is on. There is 1C hysteresis.
777
-//#define TEMP_STAT_LEDS
778
-
779 639
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
780 640
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
781 641
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -787,6 +647,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
787 647
 // at zero value, there are 128 effective control positions.
788 648
 #define SOFT_PWM_SCALE 0
789 649
 
650
+// Temperature status LEDs that display the hotend and bet temperature.
651
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
652
+// Otherwise the RED led is on. There is 1C hysteresis.
653
+//#define TEMP_STAT_LEDS
654
+
790 655
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
791 656
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
792 657
 // #define PHOTOGRAPH_PIN     23
@@ -858,4 +723,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
858 723
 #include "Configuration_adv.h"
859 724
 #include "thermistortables.h"
860 725
 
861
-#endif //__CONFIGURATION_H
726
+#endif //CONFIGURATION_H

+ 11
- 206
Marlin/example_configurations/K8200/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers.
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -218,31 +158,22 @@
218 158
 //#define QUICK_HOME  //if this is defined, if both x and y are to be homed, a diagonal move will be performed initially.
219 159
 
220 160
 #define AXIS_RELATIVE_MODES {false, false, false, false}
221
-#ifdef CONFIG_STEPPERS_TOSHIBA
222
-#define MAX_STEP_FREQUENCY 10000 // Max step frequency for Toshiba Stepper Controllers
223
-#else
224
-#define MAX_STEP_FREQUENCY 40000 // Max step frequency for Ultimaker (5000 pps / half step)
225
-#endif
161
+
226 162
 //By default pololu step drivers require an active high signal. However, some high power drivers require an active low signal as step.
227 163
 #define INVERT_X_STEP_PIN false
228 164
 #define INVERT_Y_STEP_PIN false
229 165
 #define INVERT_Z_STEP_PIN false
230 166
 #define INVERT_E_STEP_PIN false
231 167
 
232
-//default stepper release if idle. Set to 0 to deactivate.
168
+// Default stepper release if idle. Set to 0 to deactivate.
233 169
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
234 170
 
235 171
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
236 172
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
237 173
 
238
-// Feedrates for manual moves along X, Y, Z, E from panel
239
-#ifdef ULTIPANEL
240
-#define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60}  // set the speeds for manual moves (mm/min)
241
-#endif
242
-
243
-//Comment to disable setting feedrate multiplier via encoder
244 174
 #ifdef ULTIPANEL
245
-    #define ULTIPANEL_FEEDMULTIPLY
175
+  #define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60} // Feedrates for manual moves along X, Y, Z, E from panel
176
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
246 177
 #endif
247 178
 
248 179
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -261,13 +192,6 @@
261 192
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
262 193
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
263 194
 
264
-// MS1 MS2 Stepper Driver Microstepping mode table
265
-#define MICROSTEP1 LOW,LOW
266
-#define MICROSTEP2 HIGH,LOW
267
-#define MICROSTEP4 LOW,HIGH
268
-#define MICROSTEP8 HIGH,HIGH
269
-#define MICROSTEP16 HIGH,HIGH
270
-
271 195
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
272 196
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
273 197
 
@@ -313,12 +237,6 @@
313 237
   #define PROGRESS_MSG_EXPIRE   0
314 238
   // Enable this to show messages for MSG_TIME then hide them
315 239
   //#define PROGRESS_MSG_ONCE
316
-  #ifdef DOGLCD
317
-    #warning LCD_PROGRESS_BAR does not apply to graphical displays at this time.
318
-  #endif
319
-  #ifdef FILAMENT_LCD_DISPLAY
320
-    #error LCD_PROGRESS_BAR and FILAMENT_LCD_DISPLAY are not fully compatible. Comment out this line to use both.
321
-  #endif
322 240
 #endif
323 241
 
324 242
 // The hardware watchdog should reset the microcontroller disabling all outputs, in case the firmware gets stuck and doesn't do temperature regulation.
@@ -342,16 +260,6 @@
342 260
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
343 261
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
344 262
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
345
-
346
-  #ifdef COREXY
347
-    #error BABYSTEPPING not implemented for COREXY yet.
348
-  #endif
349
-
350
-  #ifdef DELTA
351
-    #ifdef BABYSTEP_XY
352
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
353
-    #endif
354
-  #endif
355 263
 #endif
356 264
 
357 265
 // extruder advance constant (s2/mm3)
@@ -365,12 +273,8 @@
365 273
 
366 274
 #ifdef ADVANCE
367 275
   #define EXTRUDER_ADVANCE_K .0
368
-
369 276
   #define D_FILAMENT 2.85
370 277
   #define STEPS_MM_E 836
371
-  #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
372
-  #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS]/ EXTRUSION_AREA)
373
-
374 278
 #endif // ADVANCE
375 279
 
376 280
 // Arc interpretation settings:
@@ -385,26 +289,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
385 289
 // be commented out otherwise
386 290
 #define SDCARDDETECTINVERTED
387 291
 
388
-#ifdef ULTIPANEL
389
- #undef SDCARDDETECTINVERTED
390
-#endif
391
-
392
-// Power Signal Control Definitions
393
-// By default use ATX definition
394
-#ifndef POWER_SUPPLY
395
-  #define POWER_SUPPLY 1
396
-#endif
397
-// 1 = ATX
398
-#if (POWER_SUPPLY == 1)
399
-  #define PS_ON_AWAKE  LOW
400
-  #define PS_ON_ASLEEP HIGH
401
-#endif
402
-// 2 = X-Box 360 203W
403
-#if (POWER_SUPPLY == 2)
404
-  #define PS_ON_AWAKE  HIGH
405
-  #define PS_ON_ASLEEP LOW
406
-#endif
407
-
408 292
 // Control heater 0 and heater 1 in parallel.
409 293
 //#define HEATERS_PARALLEL
410 294
 
@@ -444,9 +328,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
444 328
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
445 329
 #endif
446 330
 
447
-//adds support for experimental filament exchange support M600; requires display
331
+// Add support for experimental filament exchange support M600; requires display
448 332
 #ifdef ULTIPANEL
449
-  #define FILAMENTCHANGEENABLE
333
+  //#define FILAMENTCHANGEENABLE
450 334
   #ifdef FILAMENTCHANGEENABLE
451 335
     #define FILAMENTCHANGE_XPOS 3
452 336
     #define FILAMENTCHANGE_YPOS 3
@@ -456,86 +340,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
456 340
   #endif
457 341
 #endif
458 342
 
459
-#ifdef FILAMENTCHANGEENABLE
460
-  #ifdef EXTRUDER_RUNOUT_PREVENT
461
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
462
-  #endif
463
-#endif
464
-
465
-//===========================================================================
466
-//=============================  Define Defines  ============================
467
-//===========================================================================
468
-
469
-#if defined (ENABLE_AUTO_BED_LEVELING) && defined (DELTA)
470
-  #error "Bed Auto Leveling is still not compatible with Delta Kinematics."
471
-#endif
472
-
473
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
474
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
475
-#endif
476
-
477
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
478
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
479
-#endif
480
-
481
-#if TEMP_SENSOR_0 > 0
482
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
483
-  #define HEATER_0_USES_THERMISTOR
484
-#endif
485
-#if TEMP_SENSOR_1 > 0
486
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
487
-  #define HEATER_1_USES_THERMISTOR
488
-#endif
489
-#if TEMP_SENSOR_2 > 0
490
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
491
-  #define HEATER_2_USES_THERMISTOR
492
-#endif
493
-#if TEMP_SENSOR_3 > 0
494
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
495
-  #define HEATER_3_USES_THERMISTOR
496
-#endif
497
-#if TEMP_SENSOR_BED > 0
498
-  #define THERMISTORBED TEMP_SENSOR_BED
499
-  #define BED_USES_THERMISTOR
500
-#endif
501
-#if TEMP_SENSOR_0 == -1
502
-  #define HEATER_0_USES_AD595
503
-#endif
504
-#if TEMP_SENSOR_1 == -1
505
-  #define HEATER_1_USES_AD595
506
-#endif
507
-#if TEMP_SENSOR_2 == -1
508
-  #define HEATER_2_USES_AD595
509
-#endif
510
-#if TEMP_SENSOR_3 == -1
511
-  #define HEATER_3_USES_AD595
512
-#endif
513
-#if TEMP_SENSOR_BED == -1
514
-  #define BED_USES_AD595
515
-#endif
516
-#if TEMP_SENSOR_0 == -2
517
-  #define HEATER_0_USES_MAX6675
518
-#endif
519
-#if TEMP_SENSOR_0 == 0
520
-  #undef HEATER_0_MINTEMP
521
-  #undef HEATER_0_MAXTEMP
522
-#endif
523
-#if TEMP_SENSOR_1 == 0
524
-  #undef HEATER_1_MINTEMP
525
-  #undef HEATER_1_MAXTEMP
526
-#endif
527
-#if TEMP_SENSOR_2 == 0
528
-  #undef HEATER_2_MINTEMP
529
-  #undef HEATER_2_MAXTEMP
530
-#endif
531
-#if TEMP_SENSOR_3 == 0
532
-  #undef HEATER_3_MINTEMP
533
-  #undef HEATER_3_MAXTEMP
534
-#endif
535
-#if TEMP_SENSOR_BED == 0
536
-  #undef BED_MINTEMP
537
-  #undef BED_MAXTEMP
538
-#endif
539
-
343
+#include "Conditionals.h"
344
+#include "SanityCheck.h"
540 345
 
541
-#endif //__CONFIGURATION_ADV_H
346
+#endif //CONFIGURATION_ADV_H

+ 18
- 153
Marlin/example_configurations/SCARA/Configuration.h ファイルの表示

@@ -351,15 +351,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
351 351
   // #define ENDSTOPPULLUP_ZMIN
352 352
 #endif
353 353
 
354
-#ifdef ENDSTOPPULLUPS
355
-  #define ENDSTOPPULLUP_XMAX
356
-  #define ENDSTOPPULLUP_YMAX
357
-  #define ENDSTOPPULLUP_ZMAX
358
-  #define ENDSTOPPULLUP_XMIN
359
-  #define ENDSTOPPULLUP_YMIN
360
-  #define ENDSTOPPULLUP_ZMIN
361
-#endif
362
-
363 354
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
364 355
 const bool X_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
365 356
 const bool Y_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
@@ -408,10 +399,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
408 399
 #define Z_MAX_POS 225
409 400
 #define Z_MIN_POS MANUAL_Z_HOME_POS
410 401
 
411
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
412
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
413
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
414
-
402
+//===========================================================================
403
+//============================= Filament Runout Sensor ======================
404
+//===========================================================================
405
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
406
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
407
+                                 // It is assumed that when logic high = filament available
408
+                                 //                    when logic  low = filament ran out
409
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
410
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
415 411
 
416 412
 //===========================================================================
417 413
 //============================= Bed Auto Leveling ===========================
@@ -644,112 +640,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
644 640
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
645 641
 //#define RA_CONTROL_PANEL
646 642
 
647
-//automatic expansion
648
-#if defined (MAKRPANEL)
649
- #define DOGLCD
650
- #define SDSUPPORT
651
- #define ULTIPANEL
652
- #define NEWPANEL
653
- #define DEFAULT_LCD_CONTRAST 17
654
-#endif
655
-
656
-#if defined(miniVIKI) || defined(VIKI2)
657
- #define ULTRA_LCD  //general LCD support, also 16x2
658
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
659
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
660
- 
661
-  #ifdef miniVIKI
662
-   #define DEFAULT_LCD_CONTRAST 95
663
-  #else
664
-   #define DEFAULT_LCD_CONTRAST 40
665
-  #endif
666
-  
667
- #define ENCODER_PULSES_PER_STEP 4
668
- #define ENCODER_STEPS_PER_MENU_ITEM 1
669
-#endif
670
-
671
-#if defined (PANEL_ONE)
672
- #define SDSUPPORT
673
- #define ULTIMAKERCONTROLLER
674
-#endif
675
-
676
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
677
- #define DOGLCD
678
- #define U8GLIB_ST7920
679
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
680
-#endif
681
-
682
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
683
- #define ULTIPANEL
684
- #define NEWPANEL
685
-#endif
686
-
687
-#if defined(REPRAPWORLD_KEYPAD)
688
-  #define NEWPANEL
689
-  #define ULTIPANEL
690
-#endif
691
-#if defined(RA_CONTROL_PANEL)
692
- #define ULTIPANEL
693
- #define NEWPANEL
694
- #define LCD_I2C_TYPE_PCA8574
695
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
696
-#endif
697
-
698
-//I2C PANELS
643
+/**
644
+ * I2C Panels
645
+ */
699 646
 
700 647
 //#define LCD_I2C_SAINSMART_YWROBOT
701
-#ifdef LCD_I2C_SAINSMART_YWROBOT
702
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
703
-  // Make sure it is placed in the Arduino libraries directory.
704
-  #define LCD_I2C_TYPE_PCF8575
705
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
706
-  #define NEWPANEL
707
-  #define ULTIPANEL
708
-#endif
709 648
 
710 649
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
711 650
 //#define LCD_I2C_PANELOLU2
712
-#ifdef LCD_I2C_PANELOLU2
713
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
714
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
715
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
716
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
717
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
718
-  #define LCD_I2C_TYPE_MCP23017
719
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
720
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
721
-  #define NEWPANEL
722
-  #define ULTIPANEL
723
-
724
-  #ifndef ENCODER_PULSES_PER_STEP
725
-	#define ENCODER_PULSES_PER_STEP 4
726
-  #endif
727
-
728
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
729
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
730
-  #endif
731
-
732
-
733
-  #ifdef LCD_USE_I2C_BUZZER
734
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
735
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
736
-  #endif
737
-
738
-#endif
739 651
 
740 652
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
741 653
 //#define LCD_I2C_VIKI
742
-#ifdef LCD_I2C_VIKI
743
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
744
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
745
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
746
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
747
-  #define LCD_I2C_TYPE_MCP23017
748
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
749
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
750
-  #define NEWPANEL
751
-  #define ULTIPANEL
752
-#endif
753 654
 
754 655
 // Shift register panels
755 656
 // ---------------------
@@ -757,51 +658,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
757 658
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
758 659
 
759 660
 //#define SAV_3DLCD
760
-#ifdef SAV_3DLCD
761
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
762
-   #define NEWPANEL
763
-   #define ULTIPANEL
764
-#endif
765
-
766
-
767
-#ifdef ULTIPANEL
768
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
769
-  #define SDSUPPORT
770
-  #define ULTRA_LCD
771
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
772
-    #define LCD_WIDTH 22
773
-    #define LCD_HEIGHT 5
774
-  #else
775
-    #define LCD_WIDTH 20
776
-    #define LCD_HEIGHT 4
777
-  #endif
778
-#else //no panel but just LCD
779
-  #ifdef ULTRA_LCD
780
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
781
-    #define LCD_WIDTH 22
782
-    #define LCD_HEIGHT 5
783
-  #else
784
-    #define LCD_WIDTH 16
785
-    #define LCD_HEIGHT 2
786
-  #endif
787
-  #endif
788
-#endif
789
-
790
-// default LCD contrast for dogm-like LCD displays
791
-#ifdef DOGLCD
792
-# ifndef DEFAULT_LCD_CONTRAST
793
-#  define DEFAULT_LCD_CONTRAST 32
794
-# endif
795
-#endif
796 661
 
797 662
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
798 663
 //#define FAST_PWM_FAN
799 664
 
800
-// Temperature status LEDs that display the hotend and bet temperature.
801
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
802
-// Otherwise the RED led is on. There is 1C hysteresis.
803
-//#define TEMP_STAT_LEDS
804
-
805 665
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
806 666
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
807 667
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -813,6 +673,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
813 673
 // at zero value, there are 128 effective control positions.
814 674
 #define SOFT_PWM_SCALE 0
815 675
 
676
+// Temperature status LEDs that display the hotend and bet temperature.
677
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
678
+// Otherwise the RED led is on. There is 1C hysteresis.
679
+//#define TEMP_STAT_LEDS
680
+
816 681
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
817 682
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
818 683
 // #define PHOTOGRAPH_PIN     23
@@ -884,4 +749,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
884 749
 #include "Configuration_adv.h"
885 750
 #include "thermistortables.h"
886 751
 
887
-#endif //__CONFIGURATION_H
752
+#endif //CONFIGURATION_H

+ 11
- 197
Marlin/example_configurations/SCARA/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers.
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -216,9 +156,6 @@
216 156
 #define Z_HOME_RETRACT_MM 3
217 157
 #define HOMING_BUMP_DIVISOR {10, 10, 20}  // Re-Bump Speed Divisor (Divides the Homing Feedrate)
218 158
 //#define QUICK_HOME  //if this is defined, if both x and y are to be homed, a diagonal move will be performed initially.
219
-#ifdef SCARA
220
-	#define QUICK_HOME //SCARA needs Quickhome
221
-#endif
222 159
 
223 160
 #define AXIS_RELATIVE_MODES {false, false, false, false}
224 161
 
@@ -230,20 +167,15 @@
230 167
 #define INVERT_Z_STEP_PIN false
231 168
 #define INVERT_E_STEP_PIN false
232 169
 
233
-//default stepper release if idle. Set to 0 to deactivate.
170
+// Default stepper release if idle. Set to 0 to deactivate.
234 171
 #define DEFAULT_STEPPER_DEACTIVE_TIME 240
235 172
 
236 173
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
237 174
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
238 175
 
239
-// Feedrates for manual moves along X, Y, Z, E from panel
240
-#ifdef ULTIPANEL
241
-#define MANUAL_FEEDRATE {50*60, 50*60, 10*60, 60}  // set the speeds for manual moves (mm/min)
242
-#endif
243
-
244
-//Comment to disable setting feedrate multiplier via encoder
245 176
 #ifdef ULTIPANEL
246
-    #define ULTIPANEL_FEEDMULTIPLY
177
+  #define MANUAL_FEEDRATE {50*60, 50*60, 10*60, 60}  // Feedrates for manual moves along X, Y, Z, E from panel
178
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
247 179
 #endif
248 180
 
249 181
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -251,9 +183,7 @@
251 183
 
252 184
 // If defined the movements slow down when the look ahead buffer is only half full
253 185
 //#define SLOWDOWN
254
-#ifdef SCARA
255
- #undef SLOWDOWN
256
-#endif
186
+
257 187
 // Frequency limit
258 188
 // See nophead's blog for more info
259 189
 // Not working O
@@ -264,13 +194,6 @@
264 194
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
265 195
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
266 196
 
267
-// MS1 MS2 Stepper Driver Microstepping mode table
268
-#define MICROSTEP1 LOW,LOW
269
-#define MICROSTEP2 HIGH,LOW
270
-#define MICROSTEP4 LOW,HIGH
271
-#define MICROSTEP8 HIGH,HIGH
272
-#define MICROSTEP16 HIGH,HIGH
273
-
274 197
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
275 198
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
276 199
 
@@ -339,21 +262,6 @@
339 262
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
340 263
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
341 264
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
342
-
343
-  #ifdef COREXY
344
-    #error BABYSTEPPING not implemented for COREXY yet.
345
-  #endif
346
-
347
-  #ifdef DELTA
348
-    #ifdef BABYSTEP_XY
349
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
350
-    #endif
351
-  #endif
352
-  
353
-  #ifdef SCARA
354
-    #error BABYSTEPPING not implemented for SCARA yet.
355
-  #endif
356
-  
357 265
 #endif
358 266
 
359 267
 // extruder advance constant (s2/mm3)
@@ -387,26 +295,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
387 295
 // be commented out otherwise
388 296
 #define SDCARDDETECTINVERTED
389 297
 
390
-#ifdef ULTIPANEL
391
- #undef SDCARDDETECTINVERTED
392
-#endif
393
-
394
-// Power Signal Control Definitions
395
-// By default use ATX definition
396
-#ifndef POWER_SUPPLY
397
-  #define POWER_SUPPLY 1
398
-#endif
399
-// 1 = ATX
400
-#if (POWER_SUPPLY == 1)
401
-  #define PS_ON_AWAKE  LOW
402
-  #define PS_ON_ASLEEP HIGH
403
-#endif
404
-// 2 = X-Box 360 203W
405
-#if (POWER_SUPPLY == 2)
406
-  #define PS_ON_AWAKE  HIGH
407
-  #define PS_ON_ASLEEP LOW
408
-#endif
409
-
410 298
 // Control heater 0 and heater 1 in parallel.
411 299
 //#define HEATERS_PARALLEL
412 300
 
@@ -444,9 +332,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
444 332
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
445 333
 #endif
446 334
 
447
-//adds support for experimental filament exchange support M600; requires display
335
+// Add support for experimental filament exchange support M600; requires display
448 336
 #ifdef ULTIPANEL
449
-  #define FILAMENTCHANGEENABLE
337
+  //#define FILAMENTCHANGEENABLE
450 338
   #ifdef FILAMENTCHANGEENABLE
451 339
     #define FILAMENTCHANGE_XPOS 3
452 340
     #define FILAMENTCHANGE_YPOS 3
@@ -456,81 +344,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
456 344
   #endif
457 345
 #endif
458 346
 
459
-#ifdef FILAMENTCHANGEENABLE
460
-  #ifdef EXTRUDER_RUNOUT_PREVENT
461
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
462
-  #endif
463
-#endif
464
-
465
-//===========================================================================
466
-//=============================  Define Defines  ============================
467
-//===========================================================================
468
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
469
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
470
-#endif
471
-
472
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
473
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
474
-#endif
475
-
476
-#if TEMP_SENSOR_0 > 0
477
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
478
-  #define HEATER_0_USES_THERMISTOR
479
-#endif
480
-#if TEMP_SENSOR_1 > 0
481
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
482
-  #define HEATER_1_USES_THERMISTOR
483
-#endif
484
-#if TEMP_SENSOR_2 > 0
485
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
486
-  #define HEATER_2_USES_THERMISTOR
487
-#endif
488
-#if TEMP_SENSOR_3 > 0
489
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
490
-  #define HEATER_3_USES_THERMISTOR
491
-#endif
492
-#if TEMP_SENSOR_BED > 0
493
-  #define THERMISTORBED TEMP_SENSOR_BED
494
-  #define BED_USES_THERMISTOR
495
-#endif
496
-#if TEMP_SENSOR_0 == -1
497
-  #define HEATER_0_USES_AD595
498
-#endif
499
-#if TEMP_SENSOR_1 == -1
500
-  #define HEATER_1_USES_AD595
501
-#endif
502
-#if TEMP_SENSOR_2 == -1
503
-  #define HEATER_2_USES_AD595
504
-#endif
505
-#if TEMP_SENSOR_3 == -1
506
-  #define HEATER_3_USES_AD595
507
-#endif
508
-#if TEMP_SENSOR_BED == -1
509
-  #define BED_USES_AD595
510
-#endif
511
-#if TEMP_SENSOR_0 == -2
512
-  #define HEATER_0_USES_MAX6675
513
-#endif
514
-#if TEMP_SENSOR_0 == 0
515
-  #undef HEATER_0_MINTEMP
516
-  #undef HEATER_0_MAXTEMP
517
-#endif
518
-#if TEMP_SENSOR_1 == 0
519
-  #undef HEATER_1_MINTEMP
520
-  #undef HEATER_1_MAXTEMP
521
-#endif
522
-#if TEMP_SENSOR_2 == 0
523
-  #undef HEATER_2_MINTEMP
524
-  #undef HEATER_2_MAXTEMP
525
-#endif
526
-#if TEMP_SENSOR_3 == 0
527
-  #undef HEATER_3_MINTEMP
528
-  #undef HEATER_3_MAXTEMP
529
-#endif
530
-#if TEMP_SENSOR_BED == 0
531
-  #undef BED_MINTEMP
532
-  #undef BED_MAXTEMP
533
-#endif
534
-
347
+#include "Conditionals.h"
348
+#include "SanityCheck.h"
535 349
 
536
-#endif //__CONFIGURATION_ADV_H
350
+#endif //CONFIGURATION_ADV_H

+ 18
- 153
Marlin/example_configurations/WITBOX/Configuration.h ファイルの表示

@@ -321,15 +321,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
321 321
   // #define ENDSTOPPULLUP_ZMIN
322 322
 #endif
323 323
 
324
-#ifdef ENDSTOPPULLUPS
325
-  #define ENDSTOPPULLUP_XMAX
326
-  #define ENDSTOPPULLUP_YMAX
327
-  #define ENDSTOPPULLUP_ZMAX
328
-  #define ENDSTOPPULLUP_XMIN
329
-  #define ENDSTOPPULLUP_YMIN
330
-  #define ENDSTOPPULLUP_ZMIN
331
-#endif
332
-
333 324
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
334 325
 const bool X_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
335 326
 const bool Y_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
@@ -378,10 +369,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
378 369
 #define Z_MAX_POS 200
379 370
 #define Z_MIN_POS 0
380 371
 
381
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
382
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
383
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
384
-
372
+//===========================================================================
373
+//============================= Filament Runout Sensor ======================
374
+//===========================================================================
375
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
376
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
377
+                                 // It is assumed that when logic high = filament available
378
+                                 //                    when logic  low = filament ran out
379
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
380
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
385 381
 
386 382
 //===========================================================================
387 383
 //============================= Bed Auto Leveling ===========================
@@ -611,112 +607,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
611 607
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
612 608
 //#define RA_CONTROL_PANEL
613 609
 
614
-//automatic expansion
615
-#if defined (MAKRPANEL)
616
- #define DOGLCD
617
- #define SDSUPPORT
618
- #define ULTIPANEL
619
- #define NEWPANEL
620
- #define DEFAULT_LCD_CONTRAST 17
621
-#endif
622
-
623
-#if defined(miniVIKI) || defined(VIKI2)
624
- #define ULTRA_LCD  //general LCD support, also 16x2
625
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
626
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
627
- 
628
-  #ifdef miniVIKI
629
-   #define DEFAULT_LCD_CONTRAST 95
630
-  #else
631
-   #define DEFAULT_LCD_CONTRAST 40
632
-  #endif
633
-  
634
- #define ENCODER_PULSES_PER_STEP 4
635
- #define ENCODER_STEPS_PER_MENU_ITEM 1
636
-#endif
637
-
638
-#if defined (PANEL_ONE)
639
- #define SDSUPPORT
640
- #define ULTIMAKERCONTROLLER
641
-#endif
642
-
643
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
644
- #define DOGLCD
645
- #define U8GLIB_ST7920
646
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
647
-#endif
648
-
649
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
650
- #define ULTIPANEL
651
- #define NEWPANEL
652
-#endif
653
-
654
-#if defined(REPRAPWORLD_KEYPAD)
655
-  #define NEWPANEL
656
-  #define ULTIPANEL
657
-#endif
658
-#if defined(RA_CONTROL_PANEL)
659
- #define ULTIPANEL
660
- #define NEWPANEL
661
- #define LCD_I2C_TYPE_PCA8574
662
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
663
-#endif
664
-
665
-//I2C PANELS
610
+/**
611
+ * I2C Panels
612
+ */
666 613
 
667 614
 //#define LCD_I2C_SAINSMART_YWROBOT
668
-#ifdef LCD_I2C_SAINSMART_YWROBOT
669
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
670
-  // Make sure it is placed in the Arduino libraries directory.
671
-  #define LCD_I2C_TYPE_PCF8575
672
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
673
-  #define NEWPANEL
674
-  #define ULTIPANEL
675
-#endif
676 615
 
677 616
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
678 617
 //#define LCD_I2C_PANELOLU2
679
-#ifdef LCD_I2C_PANELOLU2
680
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
681
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
682
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
683
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
684
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
685
-  #define LCD_I2C_TYPE_MCP23017
686
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
687
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
688
-  #define NEWPANEL
689
-  #define ULTIPANEL
690
-
691
-  #ifndef ENCODER_PULSES_PER_STEP
692
-	#define ENCODER_PULSES_PER_STEP 4
693
-  #endif
694
-
695
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
696
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
697
-  #endif
698
-
699
-
700
-  #ifdef LCD_USE_I2C_BUZZER
701
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
702
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
703
-  #endif
704
-
705
-#endif
706 618
 
707 619
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
708 620
 //#define LCD_I2C_VIKI
709
-#ifdef LCD_I2C_VIKI
710
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
711
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
712
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
713
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
714
-  #define LCD_I2C_TYPE_MCP23017
715
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
716
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
717
-  #define NEWPANEL
718
-  #define ULTIPANEL
719
-#endif
720 621
 
721 622
 // Shift register panels
722 623
 // ---------------------
@@ -724,51 +625,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
724 625
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
725 626
 
726 627
 //#define SAV_3DLCD
727
-#ifdef SAV_3DLCD
728
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
729
-   #define NEWPANEL
730
-   #define ULTIPANEL
731
-#endif
732
-
733
-
734
-#ifdef ULTIPANEL
735
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
736
-  #define SDSUPPORT
737
-  #define ULTRA_LCD
738
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
739
-    #define LCD_WIDTH 22
740
-    #define LCD_HEIGHT 5
741
-  #else
742
-    #define LCD_WIDTH 20
743
-    #define LCD_HEIGHT 4
744
-  #endif
745
-#else //no panel but just LCD
746
-  #ifdef ULTRA_LCD
747
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
748
-    #define LCD_WIDTH 22
749
-    #define LCD_HEIGHT 5
750
-  #else
751
-    #define LCD_WIDTH 16
752
-    #define LCD_HEIGHT 2
753
-  #endif
754
-  #endif
755
-#endif
756
-
757
-// default LCD contrast for dogm-like LCD displays
758
-#ifdef DOGLCD
759
-# ifndef DEFAULT_LCD_CONTRAST
760
-#  define DEFAULT_LCD_CONTRAST 32
761
-# endif
762
-#endif
763 628
 
764 629
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
765 630
 //#define FAST_PWM_FAN
766 631
 
767
-// Temperature status LEDs that display the hotend and bet temperature.
768
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
769
-// Otherwise the RED led is on. There is 1C hysteresis.
770
-//#define TEMP_STAT_LEDS
771
-
772 632
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
773 633
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
774 634
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -780,6 +640,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
780 640
 // at zero value, there are 128 effective control positions.
781 641
 #define SOFT_PWM_SCALE 0
782 642
 
643
+// Temperature status LEDs that display the hotend and bet temperature.
644
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
645
+// Otherwise the RED led is on. There is 1C hysteresis.
646
+//#define TEMP_STAT_LEDS
647
+
783 648
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
784 649
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
785 650
 // #define PHOTOGRAPH_PIN     23
@@ -851,4 +716,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
851 716
 #include "Configuration_adv.h"
852 717
 #include "thermistortables.h"
853 718
 
854
-#endif //__CONFIGURATION_H
719
+#endif //CONFIGURATION_H

+ 10
- 201
Marlin/example_configurations/WITBOX/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 //#define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers.
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -229,20 +169,15 @@
229 169
 #define INVERT_Z_STEP_PIN false
230 170
 #define INVERT_E_STEP_PIN false
231 171
 
232
-//default stepper release if idle. Set to 0 to deactivate.
172
+// Default stepper release if idle. Set to 0 to deactivate.
233 173
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
234 174
 
235 175
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
236 176
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
237 177
 
238
-// Feedrates for manual moves along X, Y, Z, E from panel
239 178
 #ifdef ULTIPANEL
240
-#define MANUAL_FEEDRATE {120*60, 120*60, 18*60, 60}  // set the speeds for manual moves (mm/min)
241
-#endif
242
-
243
-//Comment to disable setting feedrate multiplier via encoder
244
-#ifdef ULTIPANEL
245
-    #define ULTIPANEL_FEEDMULTIPLY
179
+  #define MANUAL_FEEDRATE {120*60, 120*60, 18*60, 60}  // Feedrates for manual moves along X, Y, Z, E from panel
180
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
246 181
 #endif
247 182
 
248 183
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -261,13 +196,6 @@
261 196
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
262 197
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
263 198
 
264
-// MS1 MS2 Stepper Driver Microstepping mode table
265
-#define MICROSTEP1 LOW,LOW
266
-#define MICROSTEP2 HIGH,LOW
267
-#define MICROSTEP4 LOW,HIGH
268
-#define MICROSTEP8 HIGH,HIGH
269
-#define MICROSTEP16 HIGH,HIGH
270
-
271 199
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
272 200
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
273 201
 
@@ -313,12 +241,6 @@
313 241
   #define PROGRESS_MSG_EXPIRE   0
314 242
   // Enable this to show messages for MSG_TIME then hide them
315 243
   //#define PROGRESS_MSG_ONCE
316
-  #ifdef DOGLCD
317
-    #warning LCD_PROGRESS_BAR does not apply to graphical displays at this time.
318
-  #endif
319
-  #ifdef FILAMENT_LCD_DISPLAY
320
-    #error LCD_PROGRESS_BAR and FILAMENT_LCD_DISPLAY are not fully compatible. Comment out this line to use both.
321
-  #endif
322 244
 #endif
323 245
 
324 246
 // The hardware watchdog should reset the microcontroller disabling all outputs, in case the firmware gets stuck and doesn't do temperature regulation.
@@ -342,16 +264,6 @@
342 264
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
343 265
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
344 266
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
345
-
346
-  #ifdef COREXY
347
-    #error BABYSTEPPING not implemented for COREXY yet.
348
-  #endif
349
-
350
-  #ifdef DELTA
351
-    #ifdef BABYSTEP_XY
352
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
353
-    #endif
354
-  #endif
355 267
 #endif
356 268
 
357 269
 // extruder advance constant (s2/mm3)
@@ -365,12 +277,8 @@
365 277
 
366 278
 #ifdef ADVANCE
367 279
   #define EXTRUDER_ADVANCE_K .0
368
-
369 280
   #define D_FILAMENT 1.75
370 281
   #define STEPS_MM_E 100.47095761381482
371
-  #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
372
-  #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS]/ EXTRUSION_AREA)
373
-
374 282
 #endif // ADVANCE
375 283
 
376 284
 // Arc interpretation settings:
@@ -385,26 +293,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
385 293
 // be commented out otherwise
386 294
 #define SDCARDDETECTINVERTED
387 295
 
388
-#ifdef ULTIPANEL
389
- #undef SDCARDDETECTINVERTED
390
-#endif
391
-
392
-// Power Signal Control Definitions
393
-// By default use ATX definition
394
-#ifndef POWER_SUPPLY
395
-  #define POWER_SUPPLY 1
396
-#endif
397
-// 1 = ATX
398
-#if (POWER_SUPPLY == 1)
399
-  #define PS_ON_AWAKE  LOW
400
-  #define PS_ON_ASLEEP HIGH
401
-#endif
402
-// 2 = X-Box 360 203W
403
-#if (POWER_SUPPLY == 2)
404
-  #define PS_ON_AWAKE  HIGH
405
-  #define PS_ON_ASLEEP LOW
406
-#endif
407
-
408 296
 // Control heater 0 and heater 1 in parallel.
409 297
 //#define HEATERS_PARALLEL
410 298
 
@@ -444,9 +332,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
444 332
   #define RETRACT_RECOVER_FEEDRATE 8*60     //default feedrate for recovering from retraction (mm/s)
445 333
 #endif
446 334
 
447
-//adds support for experimental filament exchange support M600; requires display
335
+// Add support for experimental filament exchange support M600; requires display
448 336
 #ifdef ULTIPANEL
449
-  #define FILAMENTCHANGEENABLE
337
+  //#define FILAMENTCHANGEENABLE
450 338
   #ifdef FILAMENTCHANGEENABLE
451 339
     #define FILAMENTCHANGE_XPOS 3
452 340
     #define FILAMENTCHANGE_YPOS 3
@@ -456,86 +344,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
456 344
   #endif
457 345
 #endif
458 346
 
459
-#ifdef FILAMENTCHANGEENABLE
460
-  #ifdef EXTRUDER_RUNOUT_PREVENT
461
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
462
-  #endif
463
-#endif
464
-
465
-//===========================================================================
466
-//=============================  Define Defines  ============================
467
-//===========================================================================
468
-
469
-#if defined (ENABLE_AUTO_BED_LEVELING) && defined (DELTA)
470
-  #error "Bed Auto Leveling is still not compatible with Delta Kinematics."
471
-#endif
472
-
473
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
474
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
475
-#endif
476
-
477
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
478
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
479
-#endif
480
-
481
-#if TEMP_SENSOR_0 > 0
482
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
483
-  #define HEATER_0_USES_THERMISTOR
484
-#endif
485
-#if TEMP_SENSOR_1 > 0
486
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
487
-  #define HEATER_1_USES_THERMISTOR
488
-#endif
489
-#if TEMP_SENSOR_2 > 0
490
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
491
-  #define HEATER_2_USES_THERMISTOR
492
-#endif
493
-#if TEMP_SENSOR_3 > 0
494
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
495
-  #define HEATER_3_USES_THERMISTOR
496
-#endif
497
-#if TEMP_SENSOR_BED > 0
498
-  #define THERMISTORBED TEMP_SENSOR_BED
499
-  #define BED_USES_THERMISTOR
500
-#endif
501
-#if TEMP_SENSOR_0 == -1
502
-  #define HEATER_0_USES_AD595
503
-#endif
504
-#if TEMP_SENSOR_1 == -1
505
-  #define HEATER_1_USES_AD595
506
-#endif
507
-#if TEMP_SENSOR_2 == -1
508
-  #define HEATER_2_USES_AD595
509
-#endif
510
-#if TEMP_SENSOR_3 == -1
511
-  #define HEATER_3_USES_AD595
512
-#endif
513
-#if TEMP_SENSOR_BED == -1
514
-  #define BED_USES_AD595
515
-#endif
516
-#if TEMP_SENSOR_0 == -2
517
-  #define HEATER_0_USES_MAX6675
518
-#endif
519
-#if TEMP_SENSOR_0 == 0
520
-  #undef HEATER_0_MINTEMP
521
-  #undef HEATER_0_MAXTEMP
522
-#endif
523
-#if TEMP_SENSOR_1 == 0
524
-  #undef HEATER_1_MINTEMP
525
-  #undef HEATER_1_MAXTEMP
526
-#endif
527
-#if TEMP_SENSOR_2 == 0
528
-  #undef HEATER_2_MINTEMP
529
-  #undef HEATER_2_MAXTEMP
530
-#endif
531
-#if TEMP_SENSOR_3 == 0
532
-  #undef HEATER_3_MINTEMP
533
-  #undef HEATER_3_MAXTEMP
534
-#endif
535
-#if TEMP_SENSOR_BED == 0
536
-  #undef BED_MINTEMP
537
-  #undef BED_MAXTEMP
538
-#endif
539
-
347
+#include "Conditionals.h"
348
+#include "SanityCheck.h"
540 349
 
541
-#endif //__CONFIGURATION_ADV_H
350
+#endif //CONFIGURATION_ADV_H

+ 18
- 153
Marlin/example_configurations/delta/generic/Configuration.h ファイルの表示

@@ -349,15 +349,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
349 349
   // #define ENDSTOPPULLUP_ZMIN
350 350
 #endif
351 351
 
352
-#ifdef ENDSTOPPULLUPS
353
-  #define ENDSTOPPULLUP_XMAX
354
-  #define ENDSTOPPULLUP_YMAX
355
-  #define ENDSTOPPULLUP_ZMAX
356
-  #define ENDSTOPPULLUP_XMIN
357
-  #define ENDSTOPPULLUP_YMIN
358
-  #define ENDSTOPPULLUP_ZMIN
359
-#endif
360
-
361 352
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
362 353
 const bool X_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
363 354
 const bool Y_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
@@ -408,10 +399,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
408 399
 #define Z_MAX_POS MANUAL_Z_HOME_POS
409 400
 #define Z_MIN_POS 0
410 401
 
411
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
412
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
413
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
414
-
402
+//===========================================================================
403
+//============================= Filament Runout Sensor ======================
404
+//===========================================================================
405
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
406
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
407
+                                 // It is assumed that when logic high = filament available
408
+                                 //                    when logic  low = filament ran out
409
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
410
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
415 411
 
416 412
 //===========================================================================
417 413
 //============================= Bed Auto Leveling ===========================
@@ -634,112 +630,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
634 630
 // in ultralcd.cpp@lcd_delta_calibrate_menu()
635 631
 // #define DELTA_CALIBRATION_MENU
636 632
 
637
-//automatic expansion
638
-#if defined (MAKRPANEL)
639
- #define DOGLCD
640
- #define SDSUPPORT
641
- #define ULTIPANEL
642
- #define NEWPANEL
643
- #define DEFAULT_LCD_CONTRAST 17
644
-#endif
645
-
646
-#if defined(miniVIKI) || defined(VIKI2)
647
- #define ULTRA_LCD  //general LCD support, also 16x2
648
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
649
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
650
- 
651
-  #ifdef miniVIKI
652
-   #define DEFAULT_LCD_CONTRAST 95
653
-  #else
654
-   #define DEFAULT_LCD_CONTRAST 40
655
-  #endif
656
-  
657
- #define ENCODER_PULSES_PER_STEP 4
658
- #define ENCODER_STEPS_PER_MENU_ITEM 1
659
-#endif
660
-
661
-#if defined (PANEL_ONE)
662
- #define SDSUPPORT
663
- #define ULTIMAKERCONTROLLER
664
-#endif
665
-
666
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
667
- #define DOGLCD
668
- #define U8GLIB_ST7920
669
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
670
-#endif
671
-
672
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
673
- #define ULTIPANEL
674
- #define NEWPANEL
675
-#endif
676
-
677
-#if defined(REPRAPWORLD_KEYPAD)
678
-  #define NEWPANEL
679
-  #define ULTIPANEL
680
-#endif
681
-#if defined(RA_CONTROL_PANEL)
682
- #define ULTIPANEL
683
- #define NEWPANEL
684
- #define LCD_I2C_TYPE_PCA8574
685
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
686
-#endif
687
-
688
-//I2C PANELS
633
+/**
634
+ * I2C PANELS
635
+ */
689 636
 
690 637
 //#define LCD_I2C_SAINSMART_YWROBOT
691
-#ifdef LCD_I2C_SAINSMART_YWROBOT
692
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
693
-  // Make sure it is placed in the Arduino libraries directory.
694
-  #define LCD_I2C_TYPE_PCF8575
695
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
696
-  #define NEWPANEL
697
-  #define ULTIPANEL
698
-#endif
699 638
 
700 639
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
701 640
 //#define LCD_I2C_PANELOLU2
702
-#ifdef LCD_I2C_PANELOLU2
703
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
704
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
705
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
706
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
707
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
708
-  #define LCD_I2C_TYPE_MCP23017
709
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
710
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
711
-  #define NEWPANEL
712
-  #define ULTIPANEL
713
-
714
-  #ifndef ENCODER_PULSES_PER_STEP
715
-	#define ENCODER_PULSES_PER_STEP 4
716
-  #endif
717
-
718
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
719
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
720
-  #endif
721
-
722
-
723
-  #ifdef LCD_USE_I2C_BUZZER
724
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
725
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
726
-  #endif
727
-
728
-#endif
729 641
 
730 642
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
731 643
 //#define LCD_I2C_VIKI
732
-#ifdef LCD_I2C_VIKI
733
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
734
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
735
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
736
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
737
-  #define LCD_I2C_TYPE_MCP23017
738
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
739
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
740
-  #define NEWPANEL
741
-  #define ULTIPANEL
742
-#endif
743 644
 
744 645
 // Shift register panels
745 646
 // ---------------------
@@ -747,51 +648,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
747 648
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
748 649
 
749 650
 //#define SAV_3DLCD
750
-#ifdef SAV_3DLCD
751
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
752
-   #define NEWPANEL
753
-   #define ULTIPANEL
754
-#endif
755
-
756
-
757
-#ifdef ULTIPANEL
758
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
759
-  #define SDSUPPORT
760
-  #define ULTRA_LCD
761
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
762
-    #define LCD_WIDTH 22
763
-    #define LCD_HEIGHT 5
764
-  #else
765
-    #define LCD_WIDTH 20
766
-    #define LCD_HEIGHT 4
767
-  #endif
768
-#else //no panel but just LCD
769
-  #ifdef ULTRA_LCD
770
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
771
-    #define LCD_WIDTH 22
772
-    #define LCD_HEIGHT 5
773
-  #else
774
-    #define LCD_WIDTH 16
775
-    #define LCD_HEIGHT 2
776
-  #endif
777
-  #endif
778
-#endif
779
-
780
-// default LCD contrast for dogm-like LCD displays
781
-#ifdef DOGLCD
782
-# ifndef DEFAULT_LCD_CONTRAST
783
-#  define DEFAULT_LCD_CONTRAST 32
784
-# endif
785
-#endif
786 651
 
787 652
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
788 653
 //#define FAST_PWM_FAN
789 654
 
790
-// Temperature status LEDs that display the hotend and bet temperature.
791
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
792
-// Otherwise the RED led is on. There is 1C hysteresis.
793
-//#define TEMP_STAT_LEDS
794
-
795 655
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
796 656
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
797 657
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -803,6 +663,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
803 663
 // at zero value, there are 128 effective control positions.
804 664
 #define SOFT_PWM_SCALE 0
805 665
 
666
+// Temperature status LEDs that display the hotend and bet temperature.
667
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
668
+// Otherwise the RED led is on. There is 1C hysteresis.
669
+//#define TEMP_STAT_LEDS
670
+
806 671
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
807 672
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
808 673
 // #define PHOTOGRAPH_PIN     23
@@ -874,4 +739,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
874 739
 #include "Configuration_adv.h"
875 740
 #include "thermistortables.h"
876 741
 
877
-#endif //__CONFIGURATION_H
742
+#endif //CONFIGURATION_H

+ 9
- 207
Marlin/example_configurations/delta/generic/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else    
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-  
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else    
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-  
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else    
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers. 
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -228,7 +168,7 @@
228 168
 #define INVERT_Z_STEP_PIN false
229 169
 #define INVERT_E_STEP_PIN false
230 170
 
231
-//default stepper release if idle. Set to 0 to deactivate.
171
+// Default stepper release if idle. Set to 0 to deactivate.
232 172
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
233 173
 
234 174
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
@@ -236,7 +176,7 @@
236 176
 
237 177
 // Feedrates for manual moves along X, Y, Z, E from panel
238 178
 #ifdef ULTIPANEL
239
-#define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60}  // set the speeds for manual moves (mm/min)
179
+  #define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60} // Feedrates for manual moves along X, Y, Z, E from panel
240 180
 #endif
241 181
 
242 182
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -256,13 +196,6 @@
256 196
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
257 197
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
258 198
 
259
-// MS1 MS2 Stepper Driver Microstepping mode table
260
-#define MICROSTEP1 LOW,LOW
261
-#define MICROSTEP2 HIGH,LOW
262
-#define MICROSTEP4 LOW,HIGH
263
-#define MICROSTEP8 HIGH,HIGH
264
-#define MICROSTEP16 HIGH,HIGH
265
-
266 199
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
267 200
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
268 201
 
@@ -331,16 +264,6 @@
331 264
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
332 265
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
333 266
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
334
-  
335
-  #ifdef COREXY
336
-    #error BABYSTEPPING not implemented for COREXY yet.
337
-  #endif
338
-
339
-  #ifdef DELTA
340
-    #ifdef BABYSTEP_XY
341
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
342
-    #endif
343
-  #endif
344 267
 #endif
345 268
 
346 269
 // extruder advance constant (s2/mm3)
@@ -354,12 +277,8 @@
354 277
 
355 278
 #ifdef ADVANCE
356 279
   #define EXTRUDER_ADVANCE_K .0
357
-
358 280
   #define D_FILAMENT 2.85
359 281
   #define STEPS_MM_E 836
360
-  #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
361
-  #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS]/ EXTRUSION_AREA)
362
-
363 282
 #endif // ADVANCE
364 283
 
365 284
 // Arc interpretation settings:
@@ -374,26 +293,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
374 293
 // be commented out otherwise
375 294
 #define SDCARDDETECTINVERTED 
376 295
 
377
-#ifdef ULTIPANEL
378
- #undef SDCARDDETECTINVERTED
379
-#endif
380
-
381
-// Power Signal Control Definitions
382
-// By default use ATX definition
383
-#ifndef POWER_SUPPLY
384
-  #define POWER_SUPPLY 1
385
-#endif
386
-// 1 = ATX
387
-#if (POWER_SUPPLY == 1) 
388
-  #define PS_ON_AWAKE  LOW
389
-  #define PS_ON_ASLEEP HIGH
390
-#endif
391
-// 2 = X-Box 360 203W
392
-#if (POWER_SUPPLY == 2) 
393
-  #define PS_ON_AWAKE  HIGH
394
-  #define PS_ON_ASLEEP LOW
395
-#endif
396
-
397 296
 // Control heater 0 and heater 1 in parallel.
398 297
 //#define HEATERS_PARALLEL
399 298
 
@@ -433,9 +332,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
433 332
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
434 333
 #endif
435 334
 
436
-//adds support for experimental filament exchange support M600; requires display
335
+// Add support for experimental filament exchange support M600; requires display
437 336
 #ifdef ULTIPANEL
438
-  #define FILAMENTCHANGEENABLE
337
+  //#define FILAMENTCHANGEENABLE
439 338
   #ifdef FILAMENTCHANGEENABLE
440 339
     #define FILAMENTCHANGE_XPOS 3
441 340
     #define FILAMENTCHANGE_YPOS 3
@@ -445,104 +344,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
445 344
   #endif
446 345
 #endif
447 346
 
448
-#ifdef FILAMENTCHANGEENABLE
449
-  #ifdef EXTRUDER_RUNOUT_PREVENT
450
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
451
-  #endif 
452
-#endif
453
- 
454
-//===========================================================================
455
-//=============================  Define Defines  ============================
456
-//===========================================================================
457
-
458
-#if defined (ENABLE_AUTO_BED_LEVELING) && defined (DELTA)
459
-
460
-  #if not defined(AUTO_BED_LEVELING_GRID)
461
-    #error "Only Grid Bed Auto Leveling is supported on Deltas."
462
-  #endif
463
-  
464
-  #if defined(Z_PROBE_SLED)
465
-    #error "You cannot use Z_PROBE_SLED together with DELTA."
466
-  #endif
467
-
468
-  #if defined(Z_PROBE_REPEATABILITY_TEST)
469
-    #error "Z-probe repeatability test is not supported on Deltas yet."
470
-  #endif
471
-
472
-#endif  
473
-
474
-#if defined(Z_PROBE_ALLEN_KEY)
475
-  #if !defined(AUTO_BED_LEVELING_GRID) || !defined(DELTA)
476
-    #error "Invalid use of Z_PROBE_ALLEN_KEY."
477
-  #endif
478
-#endif
479
-
480
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
481
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
482
-#endif
483
-
484
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
485
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
486
-#endif
487
-
488
-#if TEMP_SENSOR_0 > 0
489
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
490
-  #define HEATER_0_USES_THERMISTOR
491
-#endif
492
-#if TEMP_SENSOR_1 > 0
493
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
494
-  #define HEATER_1_USES_THERMISTOR
495
-#endif
496
-#if TEMP_SENSOR_2 > 0
497
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
498
-  #define HEATER_2_USES_THERMISTOR
499
-#endif
500
-#if TEMP_SENSOR_3 > 0
501
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
502
-  #define HEATER_3_USES_THERMISTOR
503
-#endif
504
-#if TEMP_SENSOR_BED > 0
505
-  #define THERMISTORBED TEMP_SENSOR_BED
506
-  #define BED_USES_THERMISTOR
507
-#endif
508
-#if TEMP_SENSOR_0 == -1
509
-  #define HEATER_0_USES_AD595
510
-#endif
511
-#if TEMP_SENSOR_1 == -1
512
-  #define HEATER_1_USES_AD595
513
-#endif
514
-#if TEMP_SENSOR_2 == -1
515
-  #define HEATER_2_USES_AD595
516
-#endif
517
-#if TEMP_SENSOR_3 == -1
518
-  #define HEATER_3_USES_AD595
519
-#endif
520
-#if TEMP_SENSOR_BED == -1
521
-  #define BED_USES_AD595
522
-#endif
523
-#if TEMP_SENSOR_0 == -2
524
-  #define HEATER_0_USES_MAX6675
525
-#endif
526
-#if TEMP_SENSOR_0 == 0
527
-  #undef HEATER_0_MINTEMP
528
-  #undef HEATER_0_MAXTEMP
529
-#endif
530
-#if TEMP_SENSOR_1 == 0
531
-  #undef HEATER_1_MINTEMP
532
-  #undef HEATER_1_MAXTEMP
533
-#endif
534
-#if TEMP_SENSOR_2 == 0
535
-  #undef HEATER_2_MINTEMP
536
-  #undef HEATER_2_MAXTEMP
537
-#endif
538
-#if TEMP_SENSOR_3 == 0
539
-  #undef HEATER_3_MINTEMP
540
-  #undef HEATER_3_MAXTEMP
541
-#endif
542
-#if TEMP_SENSOR_BED == 0
543
-  #undef BED_MINTEMP
544
-  #undef BED_MAXTEMP
545
-#endif
546
-
347
+#include "Conditionals.h"
348
+#include "SanityCheck.h"
547 349
 
548
-#endif //__CONFIGURATION_ADV_H
350
+#endif //CONFIGURATION_ADV_H

+ 18
- 153
Marlin/example_configurations/delta/kossel_mini/Configuration.h ファイルの表示

@@ -350,15 +350,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
350 350
   // #define ENDSTOPPULLUP_ZMIN
351 351
 #endif
352 352
 
353
-#ifdef ENDSTOPPULLUPS
354
-  #define ENDSTOPPULLUP_XMAX
355
-  #define ENDSTOPPULLUP_YMAX
356
-  #define ENDSTOPPULLUP_ZMAX
357
-  #define ENDSTOPPULLUP_XMIN
358
-  #define ENDSTOPPULLUP_YMIN
359
-  #define ENDSTOPPULLUP_ZMIN
360
-#endif
361
-
362 353
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
363 354
 const bool X_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
364 355
 const bool Y_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
@@ -409,10 +400,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
409 400
 #define Z_MAX_POS MANUAL_Z_HOME_POS
410 401
 #define Z_MIN_POS 0
411 402
 
412
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
413
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
414
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
415
-
403
+//===========================================================================
404
+//============================= Filament Runout Sensor ======================
405
+//===========================================================================
406
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
407
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
408
+                                 // It is assumed that when logic high = filament available
409
+                                 //                    when logic  low = filament ran out
410
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
411
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
416 412
 
417 413
 //===========================================================================
418 414
 //============================= Bed Auto Leveling ===========================
@@ -636,112 +632,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
636 632
 // in ultralcd.cpp@lcd_delta_calibrate_menu()
637 633
 // #define DELTA_CALIBRATION_MENU
638 634
 
639
-//automatic expansion
640
-#if defined (MAKRPANEL)
641
- #define DOGLCD
642
- #define SDSUPPORT
643
- #define ULTIPANEL
644
- #define NEWPANEL
645
- #define DEFAULT_LCD_CONTRAST 17
646
-#endif
647
-
648
-#if defined(miniVIKI) || defined(VIKI2)
649
- #define ULTRA_LCD  //general LCD support, also 16x2
650
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
651
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
652
- 
653
-  #ifdef miniVIKI
654
-   #define DEFAULT_LCD_CONTRAST 95
655
-  #else
656
-   #define DEFAULT_LCD_CONTRAST 40
657
-  #endif
658
-  
659
- #define ENCODER_PULSES_PER_STEP 4
660
- #define ENCODER_STEPS_PER_MENU_ITEM 1
661
-#endif
662
-
663
-#if defined (PANEL_ONE)
664
- #define SDSUPPORT
665
- #define ULTIMAKERCONTROLLER
666
-#endif
667
-
668
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
669
- #define DOGLCD
670
- #define U8GLIB_ST7920
671
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
672
-#endif
673
-
674
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
675
- #define ULTIPANEL
676
- #define NEWPANEL
677
-#endif
678
-
679
-#if defined(REPRAPWORLD_KEYPAD)
680
-  #define NEWPANEL
681
-  #define ULTIPANEL
682
-#endif
683
-#if defined(RA_CONTROL_PANEL)
684
- #define ULTIPANEL
685
- #define NEWPANEL
686
- #define LCD_I2C_TYPE_PCA8574
687
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
688
-#endif
689
-
690
-//I2C PANELS
635
+/**
636
+ * I2C Panels
637
+ */
691 638
 
692 639
 //#define LCD_I2C_SAINSMART_YWROBOT
693
-#ifdef LCD_I2C_SAINSMART_YWROBOT
694
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
695
-  // Make sure it is placed in the Arduino libraries directory.
696
-  #define LCD_I2C_TYPE_PCF8575
697
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
698
-  #define NEWPANEL
699
-  #define ULTIPANEL
700
-#endif
701 640
 
702 641
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
703 642
 //#define LCD_I2C_PANELOLU2
704
-#ifdef LCD_I2C_PANELOLU2
705
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
706
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
707
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
708
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
709
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
710
-  #define LCD_I2C_TYPE_MCP23017
711
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
712
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
713
-  #define NEWPANEL
714
-  #define ULTIPANEL
715
-
716
-  #ifndef ENCODER_PULSES_PER_STEP
717
-	#define ENCODER_PULSES_PER_STEP 4
718
-  #endif
719
-
720
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
721
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
722
-  #endif
723
-
724
-
725
-  #ifdef LCD_USE_I2C_BUZZER
726
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
727
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
728
-  #endif
729
-
730
-#endif
731 643
 
732 644
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
733 645
 //#define LCD_I2C_VIKI
734
-#ifdef LCD_I2C_VIKI
735
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
736
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
737
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
738
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
739
-  #define LCD_I2C_TYPE_MCP23017
740
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
741
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
742
-  #define NEWPANEL
743
-  #define ULTIPANEL
744
-#endif
745 646
 
746 647
 // Shift register panels
747 648
 // ---------------------
@@ -749,51 +650,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
749 650
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
750 651
 
751 652
 //#define SAV_3DLCD
752
-#ifdef SAV_3DLCD
753
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
754
-   #define NEWPANEL
755
-   #define ULTIPANEL
756
-#endif
757
-
758
-
759
-#ifdef ULTIPANEL
760
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
761
-  #define SDSUPPORT
762
-  #define ULTRA_LCD
763
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
764
-    #define LCD_WIDTH 22
765
-    #define LCD_HEIGHT 5
766
-  #else
767
-    #define LCD_WIDTH 20
768
-    #define LCD_HEIGHT 4
769
-  #endif
770
-#else //no panel but just LCD
771
-  #ifdef ULTRA_LCD
772
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
773
-    #define LCD_WIDTH 22
774
-    #define LCD_HEIGHT 5
775
-  #else
776
-    #define LCD_WIDTH 16
777
-    #define LCD_HEIGHT 2
778
-  #endif
779
-  #endif
780
-#endif
781
-
782
-// default LCD contrast for dogm-like LCD displays
783
-#ifdef DOGLCD
784
-# ifndef DEFAULT_LCD_CONTRAST
785
-#  define DEFAULT_LCD_CONTRAST 32
786
-# endif
787
-#endif
788 653
 
789 654
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
790 655
 //#define FAST_PWM_FAN
791 656
 
792
-// Temperature status LEDs that display the hotend and bet temperature.
793
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
794
-// Otherwise the RED led is on. There is 1C hysteresis.
795
-//#define TEMP_STAT_LEDS
796
-
797 657
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
798 658
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
799 659
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -805,6 +665,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
805 665
 // at zero value, there are 128 effective control positions.
806 666
 #define SOFT_PWM_SCALE 0
807 667
 
668
+// Temperature status LEDs that display the hotend and bet temperature.
669
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
670
+// Otherwise the RED led is on. There is 1C hysteresis.
671
+//#define TEMP_STAT_LEDS
672
+
808 673
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
809 674
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
810 675
 // #define PHOTOGRAPH_PIN     23
@@ -876,4 +741,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = false; // set to true to invert the logic o
876 741
 #include "Configuration_adv.h"
877 742
 #include "thermistortables.h"
878 743
 
879
-#endif //__CONFIGURATION_H
744
+#endif //CONFIGURATION_H

+ 9
- 207
Marlin/example_configurations/delta/kossel_mini/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else    
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-  
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else    
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-  
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else    
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers. 
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -228,7 +168,7 @@
228 168
 #define INVERT_Z_STEP_PIN false
229 169
 #define INVERT_E_STEP_PIN false
230 170
 
231
-//default stepper release if idle. Set to 0 to deactivate.
171
+// Default stepper release if idle. Set to 0 to deactivate.
232 172
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
233 173
 
234 174
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
@@ -236,7 +176,7 @@
236 176
 
237 177
 // Feedrates for manual moves along X, Y, Z, E from panel
238 178
 #ifdef ULTIPANEL
239
-#define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60}  // set the speeds for manual moves (mm/min)
179
+  #define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60} // Feedrates for manual moves along X, Y, Z, E from panel
240 180
 #endif
241 181
 
242 182
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -255,13 +195,6 @@
255 195
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
256 196
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
257 197
 
258
-// MS1 MS2 Stepper Driver Microstepping mode table
259
-#define MICROSTEP1 LOW,LOW
260
-#define MICROSTEP2 HIGH,LOW
261
-#define MICROSTEP4 LOW,HIGH
262
-#define MICROSTEP8 HIGH,HIGH
263
-#define MICROSTEP16 HIGH,HIGH
264
-
265 198
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
266 199
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
267 200
 
@@ -330,16 +263,6 @@
330 263
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
331 264
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
332 265
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
333
-  
334
-  #ifdef COREXY
335
-    #error BABYSTEPPING not implemented for COREXY yet.
336
-  #endif
337
-
338
-  #ifdef DELTA
339
-    #ifdef BABYSTEP_XY
340
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
341
-    #endif
342
-  #endif
343 266
 #endif
344 267
 
345 268
 // extruder advance constant (s2/mm3)
@@ -353,12 +276,8 @@
353 276
 
354 277
 #ifdef ADVANCE
355 278
   #define EXTRUDER_ADVANCE_K .0
356
-
357 279
   #define D_FILAMENT 2.85
358 280
   #define STEPS_MM_E 836
359
-  #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
360
-  #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS]/ EXTRUSION_AREA)
361
-
362 281
 #endif // ADVANCE
363 282
 
364 283
 // Arc interpretation settings:
@@ -373,26 +292,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
373 292
 // be commented out otherwise
374 293
 #define SDCARDDETECTINVERTED 
375 294
 
376
-#ifdef ULTIPANEL
377
- #undef SDCARDDETECTINVERTED
378
-#endif
379
-
380
-// Power Signal Control Definitions
381
-// By default use ATX definition
382
-#ifndef POWER_SUPPLY
383
-  #define POWER_SUPPLY 1
384
-#endif
385
-// 1 = ATX
386
-#if (POWER_SUPPLY == 1) 
387
-  #define PS_ON_AWAKE  LOW
388
-  #define PS_ON_ASLEEP HIGH
389
-#endif
390
-// 2 = X-Box 360 203W
391
-#if (POWER_SUPPLY == 2) 
392
-  #define PS_ON_AWAKE  HIGH
393
-  #define PS_ON_ASLEEP LOW
394
-#endif
395
-
396 295
 // Control heater 0 and heater 1 in parallel.
397 296
 //#define HEATERS_PARALLEL
398 297
 
@@ -432,9 +331,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
432 331
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
433 332
 #endif
434 333
 
435
-//adds support for experimental filament exchange support M600; requires display
334
+// Add support for experimental filament exchange support M600; requires display
436 335
 #ifdef ULTIPANEL
437
-  #define FILAMENTCHANGEENABLE
336
+  //#define FILAMENTCHANGEENABLE
438 337
   #ifdef FILAMENTCHANGEENABLE
439 338
     #define FILAMENTCHANGE_XPOS 3
440 339
     #define FILAMENTCHANGE_YPOS 3
@@ -444,104 +343,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
444 343
   #endif
445 344
 #endif
446 345
 
447
-#ifdef FILAMENTCHANGEENABLE
448
-  #ifdef EXTRUDER_RUNOUT_PREVENT
449
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
450
-  #endif 
451
-#endif
452
- 
453
-//===========================================================================
454
-//=============================  Define Defines  ============================
455
-//===========================================================================
456
-
457
-#if defined (ENABLE_AUTO_BED_LEVELING) && defined (DELTA)
458
-
459
-  #if not defined(AUTO_BED_LEVELING_GRID)
460
-    #error "Only Grid Bed Auto Leveling is supported on Deltas."
461
-  #endif
462
-  
463
-  #if defined(Z_PROBE_SLED)
464
-    #error "You cannot use Z_PROBE_SLED together with DELTA."
465
-  #endif
466
-
467
-  #if defined(Z_PROBE_REPEATABILITY_TEST)
468
-    #error "Z-probe repeatability test is not supported on Deltas yet."
469
-  #endif
470
-
471
-#endif  
472
-
473
-#if defined(Z_PROBE_ALLEN_KEY)
474
-  #if !defined(AUTO_BED_LEVELING_GRID) || !defined(DELTA)
475
-    #error "Invalid use of Z_PROBE_ALLEN_KEY."
476
-  #endif
477
-#endif
478
-
479
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
480
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
481
-#endif
482
-
483
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
484
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
485
-#endif
486
-
487
-#if TEMP_SENSOR_0 > 0
488
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
489
-  #define HEATER_0_USES_THERMISTOR
490
-#endif
491
-#if TEMP_SENSOR_1 > 0
492
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
493
-  #define HEATER_1_USES_THERMISTOR
494
-#endif
495
-#if TEMP_SENSOR_2 > 0
496
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
497
-  #define HEATER_2_USES_THERMISTOR
498
-#endif
499
-#if TEMP_SENSOR_3 > 0
500
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
501
-  #define HEATER_3_USES_THERMISTOR
502
-#endif
503
-#if TEMP_SENSOR_BED > 0
504
-  #define THERMISTORBED TEMP_SENSOR_BED
505
-  #define BED_USES_THERMISTOR
506
-#endif
507
-#if TEMP_SENSOR_0 == -1
508
-  #define HEATER_0_USES_AD595
509
-#endif
510
-#if TEMP_SENSOR_1 == -1
511
-  #define HEATER_1_USES_AD595
512
-#endif
513
-#if TEMP_SENSOR_2 == -1
514
-  #define HEATER_2_USES_AD595
515
-#endif
516
-#if TEMP_SENSOR_3 == -1
517
-  #define HEATER_3_USES_AD595
518
-#endif
519
-#if TEMP_SENSOR_BED == -1
520
-  #define BED_USES_AD595
521
-#endif
522
-#if TEMP_SENSOR_0 == -2
523
-  #define HEATER_0_USES_MAX6675
524
-#endif
525
-#if TEMP_SENSOR_0 == 0
526
-  #undef HEATER_0_MINTEMP
527
-  #undef HEATER_0_MAXTEMP
528
-#endif
529
-#if TEMP_SENSOR_1 == 0
530
-  #undef HEATER_1_MINTEMP
531
-  #undef HEATER_1_MAXTEMP
532
-#endif
533
-#if TEMP_SENSOR_2 == 0
534
-  #undef HEATER_2_MINTEMP
535
-  #undef HEATER_2_MAXTEMP
536
-#endif
537
-#if TEMP_SENSOR_3 == 0
538
-  #undef HEATER_3_MINTEMP
539
-  #undef HEATER_3_MAXTEMP
540
-#endif
541
-#if TEMP_SENSOR_BED == 0
542
-  #undef BED_MINTEMP
543
-  #undef BED_MAXTEMP
544
-#endif
545
-
346
+#include "Conditionals.h"
347
+#include "SanityCheck.h"
546 348
 
547
-#endif //__CONFIGURATION_ADV_H
349
+#endif //CONFIGURATION_ADV_H

+ 18
- 153
Marlin/example_configurations/makibox/Configuration.h ファイルの表示

@@ -319,15 +319,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
319 319
   // #define ENDSTOPPULLUP_ZMIN
320 320
 #endif
321 321
 
322
-#ifdef ENDSTOPPULLUPS
323
-  #define ENDSTOPPULLUP_XMAX
324
-  #define ENDSTOPPULLUP_YMAX
325
-  #define ENDSTOPPULLUP_ZMAX
326
-  #define ENDSTOPPULLUP_XMIN
327
-  #define ENDSTOPPULLUP_YMIN
328
-  #define ENDSTOPPULLUP_ZMIN
329
-#endif
330
-
331 322
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
332 323
 const bool X_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
333 324
 const bool Y_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
@@ -376,10 +367,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
376 367
 #define Z_MAX_POS 86
377 368
 #define Z_MIN_POS 0
378 369
 
379
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
380
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
381
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
382
-
370
+//===========================================================================
371
+//============================= Filament Runout Sensor ======================
372
+//===========================================================================
373
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
374
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
375
+                                 // It is assumed that when logic high = filament available
376
+                                 //                    when logic  low = filament ran out
377
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
378
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
383 379
 
384 380
 //===========================================================================
385 381
 //============================= Bed Auto Leveling ===========================
@@ -609,112 +605,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
609 605
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
610 606
 //#define RA_CONTROL_PANEL
611 607
 
612
-//automatic expansion
613
-#if defined (MAKRPANEL)
614
- #define DOGLCD
615
- #define SDSUPPORT
616
- #define ULTIPANEL
617
- #define NEWPANEL
618
- #define DEFAULT_LCD_CONTRAST 17
619
-#endif
620
-
621
-#if defined(miniVIKI) || defined(VIKI2)
622
- #define ULTRA_LCD  //general LCD support, also 16x2
623
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
624
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
625
- 
626
-  #ifdef miniVIKI
627
-   #define DEFAULT_LCD_CONTRAST 95
628
-  #else
629
-   #define DEFAULT_LCD_CONTRAST 40
630
-  #endif
631
-  
632
- #define ENCODER_PULSES_PER_STEP 4
633
- #define ENCODER_STEPS_PER_MENU_ITEM 1
634
-#endif
635
-
636
-#if defined (PANEL_ONE)
637
- #define SDSUPPORT
638
- #define ULTIMAKERCONTROLLER
639
-#endif
640
-
641
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
642
- #define DOGLCD
643
- #define U8GLIB_ST7920
644
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
645
-#endif
646
-
647
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
648
- #define ULTIPANEL
649
- #define NEWPANEL
650
-#endif
651
-
652
-#if defined(REPRAPWORLD_KEYPAD)
653
-  #define NEWPANEL
654
-  #define ULTIPANEL
655
-#endif
656
-#if defined(RA_CONTROL_PANEL)
657
- #define ULTIPANEL
658
- #define NEWPANEL
659
- #define LCD_I2C_TYPE_PCA8574
660
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
661
-#endif
662
-
663
-//I2C PANELS
608
+/**
609
+ * I2C Panels
610
+ */
664 611
 
665 612
 //#define LCD_I2C_SAINSMART_YWROBOT
666
-#ifdef LCD_I2C_SAINSMART_YWROBOT
667
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
668
-  // Make sure it is placed in the Arduino libraries directory.
669
-  #define LCD_I2C_TYPE_PCF8575
670
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
671
-  #define NEWPANEL
672
-  #define ULTIPANEL
673
-#endif
674 613
 
675 614
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
676 615
 //#define LCD_I2C_PANELOLU2
677
-#ifdef LCD_I2C_PANELOLU2
678
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
679
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
680
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
681
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
682
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
683
-  #define LCD_I2C_TYPE_MCP23017
684
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
685
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
686
-  #define NEWPANEL
687
-  #define ULTIPANEL
688
-
689
-  #ifndef ENCODER_PULSES_PER_STEP
690
-	#define ENCODER_PULSES_PER_STEP 4
691
-  #endif
692
-
693
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
694
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
695
-  #endif
696
-
697
-
698
-  #ifdef LCD_USE_I2C_BUZZER
699
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
700
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
701
-  #endif
702
-
703
-#endif
704 616
 
705 617
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
706 618
 //#define LCD_I2C_VIKI
707
-#ifdef LCD_I2C_VIKI
708
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
709
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
710
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
711
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
712
-  #define LCD_I2C_TYPE_MCP23017
713
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
714
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
715
-  #define NEWPANEL
716
-  #define ULTIPANEL
717
-#endif
718 619
 
719 620
 // Shift register panels
720 621
 // ---------------------
@@ -722,51 +623,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
722 623
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
723 624
 
724 625
 //#define SAV_3DLCD
725
-#ifdef SAV_3DLCD
726
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
727
-   #define NEWPANEL
728
-   #define ULTIPANEL
729
-#endif
730
-
731
-
732
-#ifdef ULTIPANEL
733
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
734
-  #define SDSUPPORT
735
-  #define ULTRA_LCD
736
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
737
-    #define LCD_WIDTH 22
738
-    #define LCD_HEIGHT 5
739
-  #else
740
-    #define LCD_WIDTH 20
741
-    #define LCD_HEIGHT 4
742
-  #endif
743
-#else //no panel but just LCD
744
-  #ifdef ULTRA_LCD
745
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
746
-    #define LCD_WIDTH 22
747
-    #define LCD_HEIGHT 5
748
-  #else
749
-    #define LCD_WIDTH 16
750
-    #define LCD_HEIGHT 2
751
-  #endif
752
-  #endif
753
-#endif
754
-
755
-// default LCD contrast for dogm-like LCD displays
756
-#ifdef DOGLCD
757
-# ifndef DEFAULT_LCD_CONTRAST
758
-#  define DEFAULT_LCD_CONTRAST 32
759
-# endif
760
-#endif
761 626
 
762 627
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
763 628
 //#define FAST_PWM_FAN
764 629
 
765
-// Temperature status LEDs that display the hotend and bet temperature.
766
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
767
-// Otherwise the RED led is on. There is 1C hysteresis.
768
-//#define TEMP_STAT_LEDS
769
-
770 630
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
771 631
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
772 632
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -778,6 +638,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
778 638
 // at zero value, there are 128 effective control positions.
779 639
 #define SOFT_PWM_SCALE 0
780 640
 
641
+// Temperature status LEDs that display the hotend and bet temperature.
642
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
643
+// Otherwise the RED led is on. There is 1C hysteresis.
644
+//#define TEMP_STAT_LEDS
645
+
781 646
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
782 647
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
783 648
 // #define PHOTOGRAPH_PIN     23
@@ -849,4 +714,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
849 714
 #include "Configuration_adv.h"
850 715
 #include "thermistortables.h"
851 716
 
852
-#endif //__CONFIGURATION_H
717
+#endif //CONFIGURATION_H

+ 10
- 190
Marlin/example_configurations/makibox/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers.
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -227,20 +167,15 @@
227 167
 #define INVERT_Z_STEP_PIN false
228 168
 #define INVERT_E_STEP_PIN false
229 169
 
230
-//default stepper release if idle. Set to 0 to deactivate.
170
+// Default stepper release if idle. Set to 0 to deactivate.
231 171
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
232 172
 
233 173
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
234 174
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
235 175
 
236
-// Feedrates for manual moves along X, Y, Z, E from panel
237 176
 #ifdef ULTIPANEL
238
-#define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60}  // set the speeds for manual moves (mm/min)
239
-#endif
240
-
241
-//Comment to disable setting feedrate multiplier via encoder
242
-#ifdef ULTIPANEL
243
-    #define ULTIPANEL_FEEDMULTIPLY
177
+  #define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60} // Feedrates for manual moves along X, Y, Z, E from panel
178
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
244 179
 #endif
245 180
 
246 181
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -259,13 +194,6 @@
259 194
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
260 195
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
261 196
 
262
-// MS1 MS2 Stepper Driver Microstepping mode table
263
-#define MICROSTEP1 LOW,LOW
264
-#define MICROSTEP2 HIGH,LOW
265
-#define MICROSTEP4 LOW,HIGH
266
-#define MICROSTEP8 HIGH,HIGH
267
-#define MICROSTEP16 HIGH,HIGH
268
-
269 197
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
270 198
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
271 199
 
@@ -335,16 +263,6 @@
335 263
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
336 264
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
337 265
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
338
-
339
-  #ifdef COREXY
340
-    #error BABYSTEPPING not implemented for COREXY yet.
341
-  #endif
342
-
343
-  #ifdef DELTA
344
-    #ifdef BABYSTEP_XY
345
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
346
-    #endif
347
-  #endif
348 266
 #endif
349 267
 
350 268
 // extruder advance constant (s2/mm3)
@@ -358,12 +276,8 @@
358 276
 
359 277
 #ifdef ADVANCE
360 278
   #define EXTRUDER_ADVANCE_K .0
361
-
362 279
   #define D_FILAMENT 2.85
363 280
   #define STEPS_MM_E 836
364
-  #define EXTRUSION_AREA (0.25 * D_FILAMENT * D_FILAMENT * 3.14159)
365
-  #define STEPS_PER_CUBIC_MM_E (axis_steps_per_unit[E_AXIS]/ EXTRUSION_AREA)
366
-
367 281
 #endif // ADVANCE
368 282
 
369 283
 // Arc interpretation settings:
@@ -378,26 +292,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
378 292
 // be commented out otherwise
379 293
 //#define SDCARDDETECTINVERTED
380 294
 
381
-#ifdef ULTIPANEL
382
- #undef SDCARDDETECTINVERTED
383
-#endif
384
-
385
-// Power Signal Control Definitions
386
-// By default use ATX definition
387
-#ifndef POWER_SUPPLY
388
-  #define POWER_SUPPLY 1
389
-#endif
390
-// 1 = ATX
391
-#if (POWER_SUPPLY == 1)
392
-  #define PS_ON_AWAKE  LOW
393
-  #define PS_ON_ASLEEP HIGH
394
-#endif
395
-// 2 = X-Box 360 203W
396
-#if (POWER_SUPPLY == 2)
397
-  #define PS_ON_AWAKE  HIGH
398
-  #define PS_ON_ASLEEP LOW
399
-#endif
400
-
401 295
 // Control heater 0 and heater 1 in parallel.
402 296
 //#define HEATERS_PARALLEL
403 297
 
@@ -435,9 +329,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
435 329
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
436 330
 #endif
437 331
 
438
-//adds support for experimental filament exchange support M600; requires display
332
+// Add support for experimental filament exchange support M600; requires display
439 333
 #ifdef ULTIPANEL
440
-  #define FILAMENTCHANGEENABLE
334
+  //#define FILAMENTCHANGEENABLE
441 335
   #ifdef FILAMENTCHANGEENABLE
442 336
     #define FILAMENTCHANGE_XPOS 3
443 337
     #define FILAMENTCHANGE_YPOS 3
@@ -447,81 +341,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
447 341
   #endif
448 342
 #endif
449 343
 
450
-#ifdef FILAMENTCHANGEENABLE
451
-  #ifdef EXTRUDER_RUNOUT_PREVENT
452
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
453
-  #endif
454
-#endif
455
-
456
-//===========================================================================
457
-//=============================  Define Defines  ============================
458
-//===========================================================================
459
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
460
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
461
-#endif
462
-
463
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
464
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
465
-#endif
466
-
467
-#if TEMP_SENSOR_0 > 0
468
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
469
-  #define HEATER_0_USES_THERMISTOR
470
-#endif
471
-#if TEMP_SENSOR_1 > 0
472
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
473
-  #define HEATER_1_USES_THERMISTOR
474
-#endif
475
-#if TEMP_SENSOR_2 > 0
476
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
477
-  #define HEATER_2_USES_THERMISTOR
478
-#endif
479
-#if TEMP_SENSOR_3 > 0
480
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
481
-  #define HEATER_3_USES_THERMISTOR
482
-#endif
483
-#if TEMP_SENSOR_BED > 0
484
-  #define THERMISTORBED TEMP_SENSOR_BED
485
-  #define BED_USES_THERMISTOR
486
-#endif
487
-#if TEMP_SENSOR_0 == -1
488
-  #define HEATER_0_USES_AD595
489
-#endif
490
-#if TEMP_SENSOR_1 == -1
491
-  #define HEATER_1_USES_AD595
492
-#endif
493
-#if TEMP_SENSOR_2 == -1
494
-  #define HEATER_2_USES_AD595
495
-#endif
496
-#if TEMP_SENSOR_3 == -1
497
-  #define HEATER_3_USES_AD595
498
-#endif
499
-#if TEMP_SENSOR_BED == -1
500
-  #define BED_USES_AD595
501
-#endif
502
-#if TEMP_SENSOR_0 == -2
503
-  #define HEATER_0_USES_MAX6675
504
-#endif
505
-#if TEMP_SENSOR_0 == 0
506
-  #undef HEATER_0_MINTEMP
507
-  #undef HEATER_0_MAXTEMP
508
-#endif
509
-#if TEMP_SENSOR_1 == 0
510
-  #undef HEATER_1_MINTEMP
511
-  #undef HEATER_1_MAXTEMP
512
-#endif
513
-#if TEMP_SENSOR_2 == 0
514
-  #undef HEATER_2_MINTEMP
515
-  #undef HEATER_2_MAXTEMP
516
-#endif
517
-#if TEMP_SENSOR_3 == 0
518
-  #undef HEATER_3_MINTEMP
519
-  #undef HEATER_3_MAXTEMP
520
-#endif
521
-#if TEMP_SENSOR_BED == 0
522
-  #undef BED_MINTEMP
523
-  #undef BED_MAXTEMP
524
-#endif
525
-
344
+#include "Conditionals.h"
345
+#include "SanityCheck.h"
526 346
 
527
-#endif //__CONFIGURATION_ADV_H
347
+#endif //CONFIGURATION_ADV_H

+ 18
- 153
Marlin/example_configurations/tvrrug/Round2/Configuration.h ファイルの表示

@@ -321,15 +321,6 @@ your extruder heater takes 2 minutes to hit the target on heating.
321 321
   // #define ENDSTOPPULLUP_ZMIN
322 322
 #endif
323 323
 
324
-#ifdef ENDSTOPPULLUPS
325
-  #define ENDSTOPPULLUP_XMAX
326
-  #define ENDSTOPPULLUP_YMAX
327
-  #define ENDSTOPPULLUP_ZMAX
328
-  #define ENDSTOPPULLUP_XMIN
329
-  #define ENDSTOPPULLUP_YMIN
330
-  #define ENDSTOPPULLUP_ZMIN
331
-#endif
332
-
333 324
 // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
334 325
 const bool X_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
335 326
 const bool Y_MIN_ENDSTOP_INVERTING = true; // set to true to invert the logic of the endstop.
@@ -378,10 +369,15 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
378 369
 #define Z_MAX_POS 120
379 370
 #define Z_MIN_POS 0
380 371
 
381
-#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
382
-#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
383
-#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)
384
-
372
+//===========================================================================
373
+//============================= Filament Runout Sensor ======================
374
+//===========================================================================
375
+//#define FILAMENT_RUNOUT_SENSOR // Uncomment for defining a filament runout sensor such as a mechanical or opto endstop to check the existence of filament
376
+                                 // In RAMPS uses servo pin 2. Can be changed in pins file. For other boards pin definition should be made.
377
+                                 // It is assumed that when logic high = filament available
378
+                                 //                    when logic  low = filament ran out
379
+//const bool FIL_RUNOUT_INVERTING = true;  // Should be uncommented and true or false should assigned
380
+//#define ENDSTOPPULLUP_FIL_RUNOUT // Uncomment to use internal pullup for filament runout pins if the sensor is defined.
385 381
 
386 382
 //===========================================================================
387 383
 //============================= Bed Auto Leveling ===========================
@@ -616,112 +612,17 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
616 612
 // REMEMBER TO INSTALL LiquidCrystal_I2C.h in your ARDUINO library folder: https://github.com/kiyoshigawa/LiquidCrystal_I2C
617 613
 //#define RA_CONTROL_PANEL
618 614
 
619
-//automatic expansion
620
-#if defined (MAKRPANEL)
621
- #define DOGLCD
622
- #define SDSUPPORT
623
- #define ULTIPANEL
624
- #define NEWPANEL
625
- #define DEFAULT_LCD_CONTRAST 17
626
-#endif
627
-
628
-#if defined(miniVIKI) || defined(VIKI2)
629
- #define ULTRA_LCD  //general LCD support, also 16x2
630
- #define DOGLCD  // Support for SPI LCD 128x64 (Controller ST7565R graphic Display Family)
631
- #define ULTIMAKERCONTROLLER //as available from the Ultimaker online store.
632
- 
633
-  #ifdef miniVIKI
634
-   #define DEFAULT_LCD_CONTRAST 95
635
-  #else
636
-   #define DEFAULT_LCD_CONTRAST 40
637
-  #endif
638
-  
639
- #define ENCODER_PULSES_PER_STEP 4
640
- #define ENCODER_STEPS_PER_MENU_ITEM 1
641
-#endif
642
-
643
-#if defined (PANEL_ONE)
644
- #define SDSUPPORT
645
- #define ULTIMAKERCONTROLLER
646
-#endif
647
-
648
-#if defined (REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
649
- #define DOGLCD
650
- #define U8GLIB_ST7920
651
- #define REPRAP_DISCOUNT_SMART_CONTROLLER
652
-#endif
653
-
654
-#if defined(ULTIMAKERCONTROLLER) || defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
655
- #define ULTIPANEL
656
- #define NEWPANEL
657
-#endif
658
-
659
-#if defined(REPRAPWORLD_KEYPAD)
660
-  #define NEWPANEL
661
-  #define ULTIPANEL
662
-#endif
663
-#if defined(RA_CONTROL_PANEL)
664
- #define ULTIPANEL
665
- #define NEWPANEL
666
- #define LCD_I2C_TYPE_PCA8574
667
- #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
668
-#endif
669
-
670
-//I2C PANELS
615
+/**
616
+ * I2C Panels
617
+ */
671 618
 
672 619
 //#define LCD_I2C_SAINSMART_YWROBOT
673
-#ifdef LCD_I2C_SAINSMART_YWROBOT
674
-  // This uses the LiquidCrystal_I2C library ( https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/Home )
675
-  // Make sure it is placed in the Arduino libraries directory.
676
-  #define LCD_I2C_TYPE_PCF8575
677
-  #define LCD_I2C_ADDRESS 0x27   // I2C Address of the port expander
678
-  #define NEWPANEL
679
-  #define ULTIPANEL
680
-#endif
681 620
 
682 621
 // PANELOLU2 LCD with status LEDs, separate encoder and click inputs
683 622
 //#define LCD_I2C_PANELOLU2
684
-#ifdef LCD_I2C_PANELOLU2
685
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
686
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
687
-  // (v1.2.3 no longer requires you to define PANELOLU in the LiquidTWI2.h library header file)
688
-  // Note: The PANELOLU2 encoder click input can either be directly connected to a pin
689
-  //       (if BTN_ENC defined to != -1) or read through I2C (when BTN_ENC == -1).
690
-  #define LCD_I2C_TYPE_MCP23017
691
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
692
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD
693
-  #define NEWPANEL
694
-  #define ULTIPANEL
695
-
696
-  #ifndef ENCODER_PULSES_PER_STEP
697
-	#define ENCODER_PULSES_PER_STEP 4
698
-  #endif
699
-
700
-  #ifndef ENCODER_STEPS_PER_MENU_ITEM
701
-	#define ENCODER_STEPS_PER_MENU_ITEM 1
702
-  #endif
703
-
704
-
705
-  #ifdef LCD_USE_I2C_BUZZER
706
-	#define LCD_FEEDBACK_FREQUENCY_HZ 1000
707
-	#define LCD_FEEDBACK_FREQUENCY_DURATION_MS 100
708
-  #endif
709
-
710
-#endif
711 623
 
712 624
 // Panucatt VIKI LCD with status LEDs, integrated click & L/R/U/P buttons, separate encoder inputs
713 625
 //#define LCD_I2C_VIKI
714
-#ifdef LCD_I2C_VIKI
715
-  // This uses the LiquidTWI2 library v1.2.3 or later ( https://github.com/lincomatic/LiquidTWI2 )
716
-  // Make sure the LiquidTWI2 directory is placed in the Arduino or Sketchbook libraries subdirectory.
717
-  // Note: The pause/stop/resume LCD button pin should be connected to the Arduino
718
-  //       BTN_ENC pin (or set BTN_ENC to -1 if not used)
719
-  #define LCD_I2C_TYPE_MCP23017
720
-  #define LCD_I2C_ADDRESS 0x20 // I2C Address of the port expander
721
-  #define LCD_USE_I2C_BUZZER //comment out to disable buzzer on LCD (requires LiquidTWI2 v1.2.3 or later)
722
-  #define NEWPANEL
723
-  #define ULTIPANEL
724
-#endif
725 626
 
726 627
 // Shift register panels
727 628
 // ---------------------
@@ -729,51 +630,10 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
729 630
 // https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics#!shiftregister-connection 
730 631
 
731 632
 //#define SAV_3DLCD
732
-#ifdef SAV_3DLCD
733
-   #define SR_LCD_2W_NL    // Non latching 2 wire shiftregister
734
-   #define NEWPANEL
735
-   #define ULTIPANEL
736
-#endif
737
-
738
-
739
-#ifdef ULTIPANEL
740
-//  #define NEWPANEL  //enable this if you have a click-encoder panel
741
-  #define SDSUPPORT
742
-  #define ULTRA_LCD
743
-  #ifdef DOGLCD // Change number of lines to match the DOG graphic display
744
-    #define LCD_WIDTH 22
745
-    #define LCD_HEIGHT 5
746
-  #else
747
-    #define LCD_WIDTH 20
748
-    #define LCD_HEIGHT 4
749
-  #endif
750
-#else //no panel but just LCD
751
-  #ifdef ULTRA_LCD
752
-  #ifdef DOGLCD // Change number of lines to match the 128x64 graphics display
753
-    #define LCD_WIDTH 22
754
-    #define LCD_HEIGHT 5
755
-  #else
756
-    #define LCD_WIDTH 16
757
-    #define LCD_HEIGHT 2
758
-  #endif
759
-  #endif
760
-#endif
761
-
762
-// default LCD contrast for dogm-like LCD displays
763
-#ifdef DOGLCD
764
-# ifndef DEFAULT_LCD_CONTRAST
765
-#  define DEFAULT_LCD_CONTRAST 32
766
-# endif
767
-#endif
768 633
 
769 634
 // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
770 635
 //#define FAST_PWM_FAN
771 636
 
772
-// Temperature status LEDs that display the hotend and bet temperature.
773
-// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
774
-// Otherwise the RED led is on. There is 1C hysteresis.
775
-//#define TEMP_STAT_LEDS
776
-
777 637
 // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
778 638
 // which is not ass annoying as with the hardware PWM. On the other hand, if this frequency
779 639
 // is too low, you should also increment SOFT_PWM_SCALE.
@@ -785,6 +645,11 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
785 645
 // at zero value, there are 128 effective control positions.
786 646
 #define SOFT_PWM_SCALE 0
787 647
 
648
+// Temperature status LEDs that display the hotend and bet temperature.
649
+// If all hotends and bed temperature and temperature setpoint are < 54C then the BLUE led is on.
650
+// Otherwise the RED led is on. There is 1C hysteresis.
651
+//#define TEMP_STAT_LEDS
652
+
788 653
 // M240  Triggers a camera by emulating a Canon RC-1 Remote
789 654
 // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
790 655
 // #define PHOTOGRAPH_PIN     23
@@ -856,4 +721,4 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of
856 721
 #include "Configuration_adv.h"
857 722
 #include "thermistortables.h"
858 723
 
859
-#endif //__CONFIGURATION_H
724
+#endif //CONFIGURATION_H

+ 10
- 186
Marlin/example_configurations/tvrrug/Round2/Configuration_adv.h ファイルの表示

@@ -1,6 +1,8 @@
1 1
 #ifndef CONFIGURATION_ADV_H
2 2
 #define CONFIGURATION_ADV_H
3 3
 
4
+#include "Conditionals.h"
5
+
4 6
 //===========================================================================
5 7
 //=============================Thermal Settings  ============================
6 8
 //===========================================================================
@@ -89,54 +91,6 @@
89 91
 
90 92
 #define ENDSTOPS_ONLY_FOR_HOMING // If defined the endstops will only be used for homing
91 93
 
92
-
93
-//// AUTOSET LOCATIONS OF LIMIT SWITCHES
94
-//// Added by ZetaPhoenix 09-15-2012
95
-#ifdef MANUAL_HOME_POSITIONS  // Use manual limit switch locations
96
-  #define X_HOME_POS MANUAL_X_HOME_POS
97
-  #define Y_HOME_POS MANUAL_Y_HOME_POS
98
-  #define Z_HOME_POS MANUAL_Z_HOME_POS
99
-#else //Set min/max homing switch positions based upon homing direction and min/max travel limits
100
-  //X axis
101
-  #if X_HOME_DIR == -1
102
-    #ifdef BED_CENTER_AT_0_0
103
-      #define X_HOME_POS X_MAX_LENGTH * -0.5
104
-    #else
105
-      #define X_HOME_POS X_MIN_POS
106
-    #endif //BED_CENTER_AT_0_0
107
-  #else
108
-    #ifdef BED_CENTER_AT_0_0
109
-      #define X_HOME_POS X_MAX_LENGTH * 0.5
110
-    #else
111
-      #define X_HOME_POS X_MAX_POS
112
-    #endif //BED_CENTER_AT_0_0
113
-  #endif //X_HOME_DIR == -1
114
-
115
-  //Y axis
116
-  #if Y_HOME_DIR == -1
117
-    #ifdef BED_CENTER_AT_0_0
118
-      #define Y_HOME_POS Y_MAX_LENGTH * -0.5
119
-    #else
120
-      #define Y_HOME_POS Y_MIN_POS
121
-    #endif //BED_CENTER_AT_0_0
122
-  #else
123
-    #ifdef BED_CENTER_AT_0_0
124
-      #define Y_HOME_POS Y_MAX_LENGTH * 0.5
125
-    #else
126
-      #define Y_HOME_POS Y_MAX_POS
127
-    #endif //BED_CENTER_AT_0_0
128
-  #endif //Y_HOME_DIR == -1
129
-
130
-  // Z axis
131
-  #if Z_HOME_DIR == -1 //BED_CENTER_AT_0_0 not used
132
-    #define Z_HOME_POS Z_MIN_POS
133
-  #else
134
-    #define Z_HOME_POS Z_MAX_POS
135
-  #endif //Z_HOME_DIR == -1
136
-#endif //End auto min/max positions
137
-//END AUTOSET LOCATIONS OF LIMIT SWITCHES -ZP
138
-
139
-
140 94
 //#define Z_LATE_ENABLE // Enable Z the last moment. Needed if your Z driver overheats.
141 95
 
142 96
 // A single Z stepper driver is usually used to drive 2 stepper motors.
@@ -146,26 +100,12 @@
146 100
 // On a RAMPS (or other 5 driver) motherboard, using this feature will limit you to using 1 extruder.
147 101
 //#define Z_DUAL_STEPPER_DRIVERS
148 102
 
149
-#ifdef Z_DUAL_STEPPER_DRIVERS
150
-  #undef EXTRUDERS
151
-  #define EXTRUDERS 1
152
-#endif
153
-
154 103
 // Same again but for Y Axis.
155 104
 //#define Y_DUAL_STEPPER_DRIVERS
156 105
 
157 106
 // Define if the two Y drives need to rotate in opposite directions
158 107
 #define INVERT_Y2_VS_Y_DIR true
159 108
 
160
-#ifdef Y_DUAL_STEPPER_DRIVERS
161
-  #undef EXTRUDERS
162
-  #define EXTRUDERS 1
163
-#endif
164
-
165
-#if defined (Z_DUAL_STEPPER_DRIVERS) && defined (Y_DUAL_STEPPER_DRIVERS)
166
-  #error "You cannot have dual drivers for both Y and Z"
167
-#endif
168
-
169 109
 // Enable this for dual x-carriage printers.
170 110
 // A dual x-carriage design has the advantage that the inactive extruder can be parked which
171 111
 // prevents hot-end ooze contaminating the print. It also reduces the weight of each x-carriage
@@ -229,20 +169,15 @@
229 169
 #define INVERT_Z_STEP_PIN false
230 170
 #define INVERT_E_STEP_PIN false
231 171
 
232
-//default stepper release if idle. Set to 0 to deactivate.
172
+// Default stepper release if idle. Set to 0 to deactivate.
233 173
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
234 174
 
235 175
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
236 176
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
237 177
 
238
-// Feedrates for manual moves along X, Y, Z, E from panel
239
-#ifdef ULTIPANEL
240
-#define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60}  // set the speeds for manual moves (mm/min)
241
-#endif
242
-
243
-//Comment to disable setting feedrate multiplier via encoder
244 178
 #ifdef ULTIPANEL
245
-    #define ULTIPANEL_FEEDMULTIPLY
179
+  #define MANUAL_FEEDRATE {50*60, 50*60, 4*60, 60} // Feedrates for manual moves along X, Y, Z, E from panel
180
+  #define ULTIPANEL_FEEDMULTIPLY  // Comment to disable setting feedrate multiplier via encoder
246 181
 #endif
247 182
 
248 183
 // minimum time in microseconds that a movement needs to take if the buffer is emptied.
@@ -261,13 +196,6 @@
261 196
 // if unwanted behavior is observed on a user's machine when running at very slow speeds.
262 197
 #define MINIMUM_PLANNER_SPEED 0.05// (mm/sec)
263 198
 
264
-// MS1 MS2 Stepper Driver Microstepping mode table
265
-#define MICROSTEP1 LOW,LOW
266
-#define MICROSTEP2 HIGH,LOW
267
-#define MICROSTEP4 LOW,HIGH
268
-#define MICROSTEP8 HIGH,HIGH
269
-#define MICROSTEP16 HIGH,HIGH
270
-
271 199
 // Microstep setting (Only functional when stepper driver microstep pins are connected to MCU.
272 200
 #define MICROSTEP_MODES {16,16,16,16,16} // [1,2,4,8,16]
273 201
 
@@ -336,16 +264,6 @@
336 264
   #define BABYSTEP_XY  //not only z, but also XY in the menu. more clutter, more functions
337 265
   #define BABYSTEP_INVERT_Z false  //true for inverse movements in Z
338 266
   #define BABYSTEP_Z_MULTIPLICATOR 2 //faster z movements
339
-
340
-  #ifdef COREXY
341
-    #error BABYSTEPPING not implemented for COREXY yet.
342
-  #endif
343
-
344
-  #ifdef DELTA
345
-    #ifdef BABYSTEP_XY
346
-      #error BABYSTEPPING only implemented for Z axis on deltabots.
347
-    #endif
348
-  #endif
349 267
 #endif
350 268
 
351 269
 // extruder advance constant (s2/mm3)
@@ -379,26 +297,6 @@ const unsigned int dropsegments=5; //everything with less than this number of st
379 297
 // be commented out otherwise
380 298
 #define SDCARDDETECTINVERTED
381 299
 
382
-#ifdef ULTIPANEL
383
- #undef SDCARDDETECTINVERTED
384
-#endif
385
-
386
-// Power Signal Control Definitions
387
-// By default use ATX definition
388
-#ifndef POWER_SUPPLY
389
-  #define POWER_SUPPLY 1
390
-#endif
391
-// 1 = ATX
392
-#if (POWER_SUPPLY == 1)
393
-  #define PS_ON_AWAKE  LOW
394
-  #define PS_ON_ASLEEP HIGH
395
-#endif
396
-// 2 = X-Box 360 203W
397
-#if (POWER_SUPPLY == 2)
398
-  #define PS_ON_AWAKE  HIGH
399
-  #define PS_ON_ASLEEP LOW
400
-#endif
401
-
402 300
 // Control heater 0 and heater 1 in parallel.
403 301
 //#define HEATERS_PARALLEL
404 302
 
@@ -438,9 +336,9 @@ const unsigned int dropsegments=5; //everything with less than this number of st
438 336
   #define RETRACT_RECOVER_FEEDRATE 8     //default feedrate for recovering from retraction (mm/s)
439 337
 #endif
440 338
 
441
-//adds support for experimental filament exchange support M600; requires display
339
+// Add support for experimental filament exchange support M600; requires display
442 340
 #ifdef ULTIPANEL
443
-  #define FILAMENTCHANGEENABLE
341
+  //#define FILAMENTCHANGEENABLE
444 342
   #ifdef FILAMENTCHANGEENABLE
445 343
     #define FILAMENTCHANGE_XPOS 3
446 344
     #define FILAMENTCHANGE_YPOS 3
@@ -450,81 +348,7 @@ const unsigned int dropsegments=5; //everything with less than this number of st
450 348
   #endif
451 349
 #endif
452 350
 
453
-#ifdef FILAMENTCHANGEENABLE
454
-  #ifdef EXTRUDER_RUNOUT_PREVENT
455
-    #error EXTRUDER_RUNOUT_PREVENT currently incompatible with FILAMENTCHANGE
456
-  #endif
457
-#endif
458
-
459
-//===========================================================================
460
-//=============================  Define Defines  ============================
461
-//===========================================================================
462
-#if EXTRUDERS > 1 && defined TEMP_SENSOR_1_AS_REDUNDANT
463
-  #error "You cannot use TEMP_SENSOR_1_AS_REDUNDANT if EXTRUDERS > 1"
464
-#endif
465
-
466
-#if EXTRUDERS > 1 && defined HEATERS_PARALLEL
467
-  #error "You cannot use HEATERS_PARALLEL if EXTRUDERS > 1"
468
-#endif
469
-
470
-#if TEMP_SENSOR_0 > 0
471
-  #define THERMISTORHEATER_0 TEMP_SENSOR_0
472
-  #define HEATER_0_USES_THERMISTOR
473
-#endif
474
-#if TEMP_SENSOR_1 > 0
475
-  #define THERMISTORHEATER_1 TEMP_SENSOR_1
476
-  #define HEATER_1_USES_THERMISTOR
477
-#endif
478
-#if TEMP_SENSOR_2 > 0
479
-  #define THERMISTORHEATER_2 TEMP_SENSOR_2
480
-  #define HEATER_2_USES_THERMISTOR
481
-#endif
482
-#if TEMP_SENSOR_3 > 0
483
-  #define THERMISTORHEATER_3 TEMP_SENSOR_3
484
-  #define HEATER_3_USES_THERMISTOR
485
-#endif
486
-#if TEMP_SENSOR_BED > 0
487
-  #define THERMISTORBED TEMP_SENSOR_BED
488
-  #define BED_USES_THERMISTOR
489
-#endif
490
-#if TEMP_SENSOR_0 == -1
491
-  #define HEATER_0_USES_AD595
492
-#endif
493
-#if TEMP_SENSOR_1 == -1
494
-  #define HEATER_1_USES_AD595
495
-#endif
496
-#if TEMP_SENSOR_2 == -1
497
-  #define HEATER_2_USES_AD595
498
-#endif
499
-#if TEMP_SENSOR_3 == -1
500
-  #define HEATER_3_USES_AD595
501
-#endif
502
-#if TEMP_SENSOR_BED == -1
503
-  #define BED_USES_AD595
504
-#endif
505
-#if TEMP_SENSOR_0 == -2
506
-  #define HEATER_0_USES_MAX6675
507
-#endif
508
-#if TEMP_SENSOR_0 == 0
509
-  #undef HEATER_0_MINTEMP
510
-  #undef HEATER_0_MAXTEMP
511
-#endif
512
-#if TEMP_SENSOR_1 == 0
513
-  #undef HEATER_1_MINTEMP
514
-  #undef HEATER_1_MAXTEMP
515
-#endif
516
-#if TEMP_SENSOR_2 == 0
517
-  #undef HEATER_2_MINTEMP
518
-  #undef HEATER_2_MAXTEMP
519
-#endif
520
-#if TEMP_SENSOR_3 == 0
521
-  #undef HEATER_3_MINTEMP
522
-  #undef HEATER_3_MAXTEMP
523
-#endif
524
-#if TEMP_SENSOR_BED == 0
525
-  #undef BED_MINTEMP
526
-  #undef BED_MAXTEMP
527
-#endif
528
-
351
+#include "Conditionals.h"
352
+#include "SanityCheck.h"
529 353
 
530
-#endif //__CONFIGURATION_ADV_H
354
+#endif //CONFIGURATION_ADV_H

+ 0
- 2
Marlin/language.h ファイルの表示

@@ -238,8 +238,6 @@
238 238
     #define STR_h3 "\263"
239 239
     #define STR_Deg "\337"
240 240
     #define STR_THERMOMETER "\002"
241
-  #elif defined(ULTRA_LCD)
242
-    #error You must enable either DISPLAY_CHARSET_HD44780_JAPAN or DISPLAY_CHARSET_HD44780_WESTERN for your LCD controller.
243 241
   #endif
244 242
 #endif
245 243
 /*

+ 0
- 2
Marlin/pins.h ファイルの表示

@@ -5,8 +5,6 @@
5 5
 #ifndef PINS_H
6 6
 #define PINS_H
7 7
 
8
-#include "boards.h"
9
-
10 8
 // Preset optional pins
11 9
 #define X_MS1_PIN -1
12 10
 #define X_MS2_PIN -1

+ 3
- 88
Marlin/temperature.cpp ファイルの表示

@@ -41,50 +41,14 @@
41 41
 //================================== macros =================================
42 42
 //===========================================================================
43 43
 
44
-#if EXTRUDERS > 4
45
-  #error Unsupported number of extruders
46
-#elif EXTRUDERS > 3
47
-  #define ARRAY_BY_EXTRUDERS(v1, v2, v3, v4) { v1, v2, v3, v4 }
48
-#elif EXTRUDERS > 2
49
-  #define ARRAY_BY_EXTRUDERS(v1, v2, v3, v4) { v1, v2, v3 }
50
-#elif EXTRUDERS > 1
51
-  #define ARRAY_BY_EXTRUDERS(v1, v2, v3, v4) { v1, v2 }
52
-#else
53
-  #define ARRAY_BY_EXTRUDERS(v1, v2, v3, v4) { v1 }
44
+#ifdef K1 // Defined in Configuration.h in the PID settings
45
+  #define K2 (1.0-K1)
54 46
 #endif
55 47
 
56
-#define HAS_TEMP_0 (defined(TEMP_0_PIN) && TEMP_0_PIN >= 0)
57
-#define HAS_TEMP_1 (defined(TEMP_1_PIN) && TEMP_1_PIN >= 0)
58
-#define HAS_TEMP_2 (defined(TEMP_2_PIN) && TEMP_2_PIN >= 0)
59
-#define HAS_TEMP_3 (defined(TEMP_3_PIN) && TEMP_3_PIN >= 0)
60
-#define HAS_TEMP_BED (defined(TEMP_BED_PIN) && TEMP_BED_PIN >= 0)
61
-#define HAS_FILAMENT_SENSOR (defined(FILAMENT_SENSOR) && defined(FILWIDTH_PIN) && FILWIDTH_PIN >= 0)
62
-#define HAS_HEATER_0 (defined(HEATER_0_PIN) && HEATER_0_PIN >= 0)
63
-#define HAS_HEATER_1 (defined(HEATER_1_PIN) && HEATER_1_PIN >= 0)
64
-#define HAS_HEATER_2 (defined(HEATER_2_PIN) && HEATER_2_PIN >= 0)
65
-#define HAS_HEATER_3 (defined(HEATER_3_PIN) && HEATER_3_PIN >= 0)
66
-#define HAS_HEATER_BED (defined(HEATER_BED_PIN) && HEATER_BED_PIN >= 0)
67
-#define HAS_AUTO_FAN_0 (defined(EXTRUDER_0_AUTO_FAN_PIN) && EXTRUDER_0_AUTO_FAN_PIN >= 0)
68
-#define HAS_AUTO_FAN_1 (defined(EXTRUDER_1_AUTO_FAN_PIN) && EXTRUDER_1_AUTO_FAN_PIN >= 0)
69
-#define HAS_AUTO_FAN_2 (defined(EXTRUDER_2_AUTO_FAN_PIN) && EXTRUDER_2_AUTO_FAN_PIN >= 0)
70
-#define HAS_AUTO_FAN_3 (defined(EXTRUDER_3_AUTO_FAN_PIN) && EXTRUDER_3_AUTO_FAN_PIN >= 0)
71
-#define HAS_AUTO_FAN HAS_AUTO_FAN_0 || HAS_AUTO_FAN_1 || HAS_AUTO_FAN_2 || HAS_AUTO_FAN_3
72
-#define HAS_FAN (defined(FAN_PIN) && FAN_PIN >= 0)
73
-
74 48
 //===========================================================================
75 49
 //============================= public variables ============================
76 50
 //===========================================================================
77 51
 
78
-#ifdef K1 // Defined in Configuration.h in the PID settings
79
-  #define K2 (1.0-K1)
80
-#endif
81
-
82
-// Sampling period of the temperature routine
83
-#ifdef PID_dT
84
-  #undef PID_dT
85
-#endif
86
-#define PID_dT ((OVERSAMPLENR * 12.0)/(F_CPU / 64.0 / 256.0))
87
-
88 52
 int target_temperature[EXTRUDERS] = { 0 };
89 53
 int target_temperature_bed = 0;
90 54
 int current_temperature_raw[EXTRUDERS] = { 0 };
@@ -391,21 +355,6 @@ int getHeaterPower(int heater) {
391 355
 
392 356
 #if HAS_AUTO_FAN
393 357
 
394
-  #if HAS_FAN
395
-    #if EXTRUDER_0_AUTO_FAN_PIN == FAN_PIN
396
-       #error "You cannot set EXTRUDER_0_AUTO_FAN_PIN equal to FAN_PIN"
397
-    #endif
398
-    #if EXTRUDER_1_AUTO_FAN_PIN == FAN_PIN
399
-       #error "You cannot set EXTRUDER_1_AUTO_FAN_PIN equal to FAN_PIN"
400
-    #endif
401
-    #if EXTRUDER_2_AUTO_FAN_PIN == FAN_PIN
402
-       #error "You cannot set EXTRUDER_2_AUTO_FAN_PIN equal to FAN_PIN"
403
-    #endif
404
-    #if EXTRUDER_3_AUTO_FAN_PIN == FAN_PIN
405
-       #error "You cannot set EXTRUDER_3_AUTO_FAN_PIN equal to FAN_PIN"
406
-    #endif
407
-  #endif 
408
-
409 358
 void setExtruderAutoFanState(int pin, bool state)
410 359
 {
411 360
   unsigned char newFanSpeed = (state != 0) ? EXTRUDER_AUTO_FAN_SPEED : 0;
@@ -482,42 +431,8 @@ void checkExtruderAutoFans()
482 431
 #endif // any extruder auto fan pins set
483 432
 
484 433
 //
485
-// Error checking and Write Routines
434
+// Temperature Error Handlers
486 435
 //
487
-#if !HAS_HEATER_0
488
-  #error HEATER_0_PIN not defined for this board
489
-#endif
490
-#define WRITE_HEATER_0P(v) WRITE(HEATER_0_PIN, v)
491
-#if EXTRUDERS > 1 || defined(HEATERS_PARALLEL)
492
-  #if !HAS_HEATER_1
493
-    #error HEATER_1_PIN not defined for this board
494
-  #endif
495
-  #define WRITE_HEATER_1(v) WRITE(HEATER_1_PIN, v)
496
-  #if EXTRUDERS > 2
497
-    #if !HAS_HEATER_2
498
-      #error HEATER_2_PIN not defined for this board
499
-    #endif
500
-    #define WRITE_HEATER_2(v) WRITE(HEATER_2_PIN, v)
501
-    #if EXTRUDERS > 3
502
-      #if !HAS_HEATER_3
503
-        #error HEATER_3_PIN not defined for this board
504
-      #endif
505
-      #define WRITE_HEATER_3(v) WRITE(HEATER_3_PIN, v)
506
-    #endif
507
-  #endif
508
-#endif
509
-#ifdef HEATERS_PARALLEL
510
-  #define WRITE_HEATER_0(v) { WRITE_HEATER_0P(v); WRITE_HEATER_1(v); }
511
-#else
512
-  #define WRITE_HEATER_0(v) WRITE_HEATER_0P(v)
513
-#endif
514
-#if HAS_HEATER_BED
515
-  #define WRITE_HEATER_BED(v) WRITE(HEATER_BED_PIN, v)
516
-#endif
517
-#if HAS_FAN
518
-  #define WRITE_FAN(v) WRITE(FAN_PIN, v)
519
-#endif
520
-
521 436
 inline void _temp_error(int e, const char *msg1, const char *msg2) {
522 437
   if (!IsStopped()) {
523 438
     SERIAL_ERROR_START;

+ 0
- 5
Marlin/ultralcd.cpp ファイルの表示

@@ -1,4 +1,3 @@
1
-#include "temperature.h"
2 1
 #include "ultralcd.h"
3 2
 #ifdef ULTRA_LCD
4 3
 #include "Marlin.h"
@@ -1200,10 +1199,6 @@ void lcd_init() {
1200 1199
      WRITE(SHIFT_OUT,HIGH);
1201 1200
      WRITE(SHIFT_LD,HIGH);
1202 1201
      WRITE(SHIFT_EN,LOW);
1203
-  #else
1204
-     #ifdef ULTIPANEL
1205
-     #error ULTIPANEL requires an encoder
1206
-     #endif
1207 1202
   #endif // SR_LCD_2W_NL
1208 1203
 #endif//!NEWPANEL
1209 1204
 

+ 12
- 13
Marlin/ultralcd.h ファイルの表示

@@ -14,10 +14,10 @@
14 14
   void lcd_reset_alert_level();
15 15
   bool lcd_detected(void);
16 16
 
17
-#ifdef DOGLCD
18
-  extern int lcd_contrast;
19
-  void lcd_setcontrast(uint8_t value);
20
-#endif
17
+  #ifdef DOGLCD
18
+    extern int lcd_contrast;
19
+    void lcd_setcontrast(uint8_t value);
20
+  #endif
21 21
 
22 22
   static unsigned char blink = 0;	// Variable for visualization of fan rotation in GLCD
23 23
 
@@ -28,27 +28,26 @@
28 28
   #define LCD_TIMEOUT_TO_STATUS 15000
29 29
 
30 30
   #ifdef ULTIPANEL
31
-  void lcd_buttons_update();
32
-  extern volatile uint8_t buttons;  //the last checked buttons in a bit array.
33
-  #ifdef REPRAPWORLD_KEYPAD
34
-    extern volatile uint8_t buttons_reprapworld_keypad; // to store the keypad shift register values
35
-  #endif
31
+    void lcd_buttons_update();
32
+    extern volatile uint8_t buttons;  //the last checked buttons in a bit array.
33
+    #ifdef REPRAPWORLD_KEYPAD
34
+      extern volatile uint8_t buttons_reprapworld_keypad; // to store the keypad shift register values
35
+    #endif
36 36
   #else
37
-  FORCE_INLINE void lcd_buttons_update() {}
37
+    FORCE_INLINE void lcd_buttons_update() {}
38 38
   #endif
39 39
 
40 40
   extern int plaPreheatHotendTemp;
41 41
   extern int plaPreheatHPBTemp;
42 42
   extern int plaPreheatFanSpeed;
43
-
44 43
   extern int absPreheatHotendTemp;
45 44
   extern int absPreheatHPBTemp;
46 45
   extern int absPreheatFanSpeed;
47
-  
46
+
48 47
   extern bool cancel_heatup;
49 48
   
50 49
   #ifdef FILAMENT_LCD_DISPLAY
51
-        extern unsigned long message_millis;
50
+    extern unsigned long message_millis;
52 51
   #endif
53 52
 
54 53
   void lcd_buzz(long duration,uint16_t freq);

読み込み中…
キャンセル
保存