浏览代码

Add *_DRIVER_TYPE to example configs

Co-Authored-By: teemuatlut <teemu.mantykallio@live.fi>
Scott Lahteine 6 年前
父节点
当前提交
e5c0b490c8
共有 90 个文件被更改,包括 2802 次插入4359 次删除
  1. 37
    88
      Marlin/src/config/examples/AlephObjects/TAZ4/Configuration_adv.h
  2. 23
    0
      Marlin/src/config/examples/AliExpress/CL-260/Configuration.h
  3. 23
    0
      Marlin/src/config/examples/Anet/A6/Configuration.h
  4. 37
    88
      Marlin/src/config/examples/Anet/A6/Configuration_adv.h
  5. 37
    88
      Marlin/src/config/examples/Anet/A8/Configuration_adv.h
  6. 23
    0
      Marlin/src/config/examples/Azteeg/X5GT/Configuration.h
  7. 37
    88
      Marlin/src/config/examples/Azteeg/X5GT/Configuration_adv.h
  8. 37
    88
      Marlin/src/config/examples/BIBO/TouchX/cyclops/Configuration_adv.h
  9. 37
    88
      Marlin/src/config/examples/BIBO/TouchX/default/Configuration_adv.h
  10. 37
    88
      Marlin/src/config/examples/BQ/Hephestos/Configuration_adv.h
  11. 23
    0
      Marlin/src/config/examples/BQ/Hephestos_2/Configuration.h
  12. 37
    88
      Marlin/src/config/examples/BQ/Hephestos_2/Configuration_adv.h
  13. 37
    88
      Marlin/src/config/examples/BQ/WITBOX/Configuration_adv.h
  14. 37
    88
      Marlin/src/config/examples/Cartesio/Configuration_adv.h
  15. 23
    0
      Marlin/src/config/examples/Creality/CR-10/Configuration.h
  16. 37
    88
      Marlin/src/config/examples/Creality/CR-10/Configuration_adv.h
  17. 23
    0
      Marlin/src/config/examples/Creality/CR-10S/Configuration.h
  18. 37
    88
      Marlin/src/config/examples/Creality/CR-10S/Configuration_adv.h
  19. 23
    0
      Marlin/src/config/examples/Creality/CR-10mini/Configuration.h
  20. 37
    88
      Marlin/src/config/examples/Creality/CR-10mini/Configuration_adv.h
  21. 23
    0
      Marlin/src/config/examples/Creality/CR-8/Configuration.h
  22. 37
    88
      Marlin/src/config/examples/Creality/CR-8/Configuration_adv.h
  23. 23
    0
      Marlin/src/config/examples/Creality/Ender-2/Configuration.h
  24. 37
    88
      Marlin/src/config/examples/Creality/Ender-2/Configuration_adv.h
  25. 23
    0
      Marlin/src/config/examples/Creality/Ender-3/Configuration.h
  26. 37
    88
      Marlin/src/config/examples/Creality/Ender-3/Configuration_adv.h
  27. 23
    0
      Marlin/src/config/examples/Creality/Ender-4/Configuration.h
  28. 37
    88
      Marlin/src/config/examples/Creality/Ender-4/Configuration_adv.h
  29. 23
    0
      Marlin/src/config/examples/Felix/Configuration.h
  30. 37
    88
      Marlin/src/config/examples/Felix/Configuration_adv.h
  31. 23
    0
      Marlin/src/config/examples/Felix/DUAL/Configuration.h
  32. 37
    88
      Marlin/src/config/examples/FolgerTech/i3-2020/Configuration_adv.h
  33. 23
    0
      Marlin/src/config/examples/Geeetech/GT2560/Configuration.h
  34. 23
    0
      Marlin/src/config/examples/Geeetech/I3_Pro_X-GT2560/Configuration.h
  35. 23
    0
      Marlin/src/config/examples/Geeetech/Prusa i3 Pro B/bltouch/Configuration.h
  36. 23
    0
      Marlin/src/config/examples/Geeetech/Prusa i3 Pro B/noprobe/Configuration.h
  37. 23
    0
      Marlin/src/config/examples/Geeetech/Prusa i3 Pro C/Configuration.h
  38. 37
    88
      Marlin/src/config/examples/Geeetech/Prusa i3 Pro C/Configuration_adv.h
  39. 23
    0
      Marlin/src/config/examples/Geeetech/Prusa i3 Pro W/Configuration.h
  40. 37
    88
      Marlin/src/config/examples/Geeetech/Prusa i3 Pro W/Configuration_adv.h
  41. 37
    88
      Marlin/src/config/examples/Infitary/i3-M508/Configuration_adv.h
  42. 23
    0
      Marlin/src/config/examples/JGAurora/A5/Configuration.h
  43. 37
    88
      Marlin/src/config/examples/JGAurora/A5/Configuration_adv.h
  44. 37
    88
      Marlin/src/config/examples/MakerParts/Configuration_adv.h
  45. 37
    88
      Marlin/src/config/examples/Malyan/M150/Configuration_adv.h
  46. 23
    0
      Marlin/src/config/examples/Malyan/M200/Configuration.h
  47. 37
    88
      Marlin/src/config/examples/Malyan/M200/Configuration_adv.h
  48. 23
    0
      Marlin/src/config/examples/Micromake/C1/basic/Configuration.h
  49. 37
    88
      Marlin/src/config/examples/Micromake/C1/enhanced/Configuration_adv.h
  50. 37
    88
      Marlin/src/config/examples/Mks/Sbase/Configuration_adv.h
  51. 23
    0
      Marlin/src/config/examples/RepRapPro/Huxley/Configuration.h
  52. 37
    88
      Marlin/src/config/examples/RigidBot/Configuration_adv.h
  53. 37
    88
      Marlin/src/config/examples/SCARA/Configuration_adv.h
  54. 23
    0
      Marlin/src/config/examples/STM32F10/Configuration.h
  55. 23
    0
      Marlin/src/config/examples/STM32F4/Configuration.h
  56. 23
    0
      Marlin/src/config/examples/Sanguinololu/Configuration.h
  57. 37
    88
      Marlin/src/config/examples/Sanguinololu/Configuration_adv.h
  58. 81
    133
      Marlin/src/config/examples/TheBorg/Configuration_adv.h
  59. 24
    1
      Marlin/src/config/examples/TinyBoy2/Configuration.h
  60. 37
    88
      Marlin/src/config/examples/TinyBoy2/Configuration_adv.h
  61. 23
    0
      Marlin/src/config/examples/Tronxy/X1/Configuration.h
  62. 37
    88
      Marlin/src/config/examples/Tronxy/X3A/Configuration_adv.h
  63. 23
    0
      Marlin/src/config/examples/Tronxy/XY100/Configuration.h
  64. 23
    0
      Marlin/src/config/examples/UltiMachine/Archim2/Configuration.h
  65. 37
    88
      Marlin/src/config/examples/UltiMachine/Archim2/Configuration_adv.h
  66. 23
    0
      Marlin/src/config/examples/Velleman/K8200/Configuration.h
  67. 37
    88
      Marlin/src/config/examples/Velleman/K8200/Configuration_adv.h
  68. 37
    88
      Marlin/src/config/examples/Velleman/K8400/Configuration_adv.h
  69. 23
    0
      Marlin/src/config/examples/Wanhao/Duplicator 6/Configuration.h
  70. 37
    88
      Marlin/src/config/examples/Wanhao/Duplicator 6/Configuration_adv.h
  71. 23
    0
      Marlin/src/config/examples/adafruit/ST7565/Configuration.h
  72. 37
    88
      Marlin/src/config/examples/delta/FLSUN/auto_calibrate/Configuration_adv.h
  73. 37
    88
      Marlin/src/config/examples/delta/FLSUN/kossel/Configuration_adv.h
  74. 23
    0
      Marlin/src/config/examples/delta/FLSUN/kossel_mini/Configuration.h
  75. 37
    88
      Marlin/src/config/examples/delta/FLSUN/kossel_mini/Configuration_adv.h
  76. 37
    88
      Marlin/src/config/examples/delta/generic/Configuration_adv.h
  77. 23
    0
      Marlin/src/config/examples/delta/kossel_mini/Configuration.h
  78. 37
    88
      Marlin/src/config/examples/delta/kossel_mini/Configuration_adv.h
  79. 23
    0
      Marlin/src/config/examples/delta/kossel_pro/Configuration.h
  80. 37
    88
      Marlin/src/config/examples/delta/kossel_pro/Configuration_adv.h
  81. 23
    0
      Marlin/src/config/examples/delta/kossel_xl/Configuration.h
  82. 37
    88
      Marlin/src/config/examples/delta/kossel_xl/Configuration_adv.h
  83. 24
    1
      Marlin/src/config/examples/gCreate/gMax1.5+/Configuration.h
  84. 37
    88
      Marlin/src/config/examples/gCreate/gMax1.5+/Configuration_adv.h
  85. 23
    0
      Marlin/src/config/examples/makibox/Configuration.h
  86. 37
    88
      Marlin/src/config/examples/makibox/Configuration_adv.h
  87. 23
    0
      Marlin/src/config/examples/stm32f103ret6/Configuration.h
  88. 37
    88
      Marlin/src/config/examples/tvrrug/Round2/Configuration_adv.h
  89. 23
    0
      Marlin/src/config/examples/wt150/Configuration.h
  90. 37
    88
      Marlin/src/config/examples/wt150/Configuration_adv.h

+ 37
- 88
Marlin/src/config/examples/AlephObjects/TAZ4/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/AliExpress/CL-260/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 23
- 0
Marlin/src/config/examples/Anet/A6/Configuration.h 查看文件

571
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
571
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
572
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
572
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
573
 
573
 
574
+/**
575
+ * Specify Stepper Driver types
576
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
577
+ * Stepper timing options can be overridden in Configuration_adv.h
578
+ *
579
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
580
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
581
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
582
+ *          TMC5130, TMC5130_STANDALONE
583
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
584
+ */
585
+#define X_DRIVER_TYPE  A4988
586
+#define Y_DRIVER_TYPE  A4988
587
+#define Z_DRIVER_TYPE  A4988
588
+#define X2_DRIVER_TYPE A4988
589
+#define Y2_DRIVER_TYPE A4988
590
+#define Z2_DRIVER_TYPE A4988
591
+#define E0_DRIVER_TYPE A4988
592
+#define E1_DRIVER_TYPE A4988
593
+#define E2_DRIVER_TYPE A4988
594
+#define E3_DRIVER_TYPE A4988
595
+#define E4_DRIVER_TYPE A4988
596
+
574
 // Enable this feature if all enabled endstop pins are interrupt-capable.
597
 // Enable this feature if all enabled endstop pins are interrupt-capable.
575
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
598
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
576
 #define ENDSTOP_INTERRUPTS_FEATURE
599
 #define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Anet/A6/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/Anet/A8/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Azteeg/X5GT/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Azteeg/X5GT/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/BIBO/TouchX/cyclops/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/BIBO/TouchX/default/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/BQ/Hephestos/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/BQ/Hephestos_2/Configuration.h 查看文件

552
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
552
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
553
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
554
 
554
 
555
+/**
556
+ * Specify Stepper Driver types
557
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
558
+ * Stepper timing options can be overridden in Configuration_adv.h
559
+ *
560
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
561
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
562
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
563
+ *          TMC5130, TMC5130_STANDALONE
564
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
565
+ */
566
+#define X_DRIVER_TYPE  A4988
567
+#define Y_DRIVER_TYPE  A4988
568
+#define Z_DRIVER_TYPE  A4988
569
+#define X2_DRIVER_TYPE A4988
570
+#define Y2_DRIVER_TYPE A4988
571
+#define Z2_DRIVER_TYPE A4988
572
+#define E0_DRIVER_TYPE A4988
573
+#define E1_DRIVER_TYPE A4988
574
+#define E2_DRIVER_TYPE A4988
575
+#define E3_DRIVER_TYPE A4988
576
+#define E4_DRIVER_TYPE A4988
577
+
555
 // Enable this feature if all enabled endstop pins are interrupt-capable.
578
 // Enable this feature if all enabled endstop pins are interrupt-capable.
556
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
579
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
557
 #define ENDSTOP_INTERRUPTS_FEATURE
580
 #define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/BQ/Hephestos_2/Configuration_adv.h 查看文件

845
 
845
 
846
 /**
846
 /**
847
  * Minimum delay after setting the stepper DIR (in ns)
847
  * Minimum delay after setting the stepper DIR (in ns)
848
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
849
- *   20 : Minimum for TMC2xxx drivers
850
- *  200 : Minimum for A4988 drivers
851
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
852
- *  650 : Minimum for DRV8825 drivers
853
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
854
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
848
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
849
+ *    20 : Minimum for TMC2xxx drivers
850
+ *   200 : Minimum for A4988 drivers
851
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
852
+ *   650 : Minimum for DRV8825 drivers
853
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
854
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
855
+ *
856
+ * Override the default value based on the driver type set in Configuration.h.
855
  */
857
  */
856
-#define MINIMUM_STEPPER_DIR_DELAY 0
858
+//#define MINIMUM_STEPPER_DIR_DELAY 650
857
 
859
 
858
 /**
860
 /**
859
  * Minimum stepper driver pulse width (in µs)
861
  * Minimum stepper driver pulse width (in µs)
863
  *   2 : Minimum for DRV8825 stepper drivers
865
  *   2 : Minimum for DRV8825 stepper drivers
864
  *   3 : Minimum for TB6600 stepper drivers
866
  *   3 : Minimum for TB6600 stepper drivers
865
  *  30 : Minimum for TB6560 stepper drivers
867
  *  30 : Minimum for TB6560 stepper drivers
868
+ *
869
+ * Override the default value based on the driver type set in Configuration.h.
866
  */
870
  */
867
-#define MINIMUM_STEPPER_PULSE 2
871
+//#define MINIMUM_STEPPER_PULSE 2
868
 
872
 
869
 /**
873
 /**
870
  * Maximum stepping rate (in Hz) the stepper driver allows
874
  * Maximum stepping rate (in Hz) the stepper driver allows
875
  *  150000 : Maximum for TB6600 stepper driver
879
  *  150000 : Maximum for TB6600 stepper driver
876
  *  130000 : Maximum for LV8729 stepper driver
880
  *  130000 : Maximum for LV8729 stepper driver
877
  *   15000 : Maximum for TB6560 stepper driver
881
  *   15000 : Maximum for TB6560 stepper driver
882
+ *
883
+ * Override the default value based on the driver type set in Configuration.h.
878
  */
884
  */
879
-#define MAXIMUM_STEPPER_RATE 250000
885
+//#define MAXIMUM_STEPPER_RATE 250000
880
 
886
 
881
 // @section temperature
887
 // @section temperature
882
 
888
 
1044
 // @section tmc
1050
 // @section tmc
1045
 
1051
 
1046
 /**
1052
 /**
1047
- * Enable this section if you have TMC26X motor drivers.
1048
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1049
- * (https://github.com/trinamic/TMC26XStepper.git)
1053
+ * TMC26X Stepper Driver options
1054
+ *
1055
+ * The TMC26XStepper library is required for this stepper driver.
1056
+ * https://github.com/trinamic/TMC26XStepper
1050
  */
1057
  */
1051
-//#define HAVE_TMC26X
1052
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1053
-  //#define X_IS_TMC26X
1054
-  //#define X2_IS_TMC26X
1055
-  //#define Y_IS_TMC26X
1056
-  //#define Y2_IS_TMC26X
1057
-  //#define Z_IS_TMC26X
1058
-  //#define Z2_IS_TMC26X
1059
-  //#define E0_IS_TMC26X
1060
-  //#define E1_IS_TMC26X
1061
-  //#define E2_IS_TMC26X
1062
-  //#define E3_IS_TMC26X
1063
-  //#define E4_IS_TMC26X
1058
+#if HAS_DRIVER(TMC26X)
1064
 
1059
 
1065
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_MAX_CURRENT     1000 // in mA
1066
   #define X_SENSE_RESISTOR    91 // in mOhms
1061
   #define X_SENSE_RESISTOR    91 // in mOhms
1106
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_SENSE_RESISTOR   91
1107
   #define E4_MICROSTEPS       16
1102
   #define E4_MICROSTEPS       16
1108
 
1103
 
1109
-#endif
1104
+#endif // TMC26X
1110
 
1105
 
1111
 // @section tmc_smart
1106
 // @section tmc_smart
1112
 
1107
 
1113
 /**
1108
 /**
1114
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1115
- *
1116
- * You'll also need the TMC2130Stepper Arduino library
1117
- * (https://github.com/teemuatlut/TMC2130Stepper).
1118
- *
1119
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1109
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1120
  * the hardware SPI interface on your board and define the required CS pins
1110
  * the hardware SPI interface on your board and define the required CS pins
1121
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1111
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1122
  * You may also use software SPI if you wish to use general purpose IO pins.
1112
  * You may also use software SPI if you wish to use general purpose IO pins.
1123
- */
1124
-//#define HAVE_TMC2130
1125
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1126
-  //#define X_IS_TMC2130
1127
-  //#define X2_IS_TMC2130
1128
-  //#define Y_IS_TMC2130
1129
-  //#define Y2_IS_TMC2130
1130
-  //#define Z_IS_TMC2130
1131
-  //#define Z2_IS_TMC2130
1132
-  //#define E0_IS_TMC2130
1133
-  //#define E1_IS_TMC2130
1134
-  //#define E2_IS_TMC2130
1135
-  //#define E3_IS_TMC2130
1136
-  //#define E4_IS_TMC2130
1137
-#endif
1138
-
1139
-/**
1140
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1141
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1113
+ *
1114
+ * The TMC2130Stepper library is required for this stepper driver.
1115
+ * https://github.com/teemuatlut/TMC2130Stepper
1116
+ *
1117
+ * To use TMC2208 stepper UART-configurable stepper drivers
1118
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1142
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1119
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1143
  * to PDN_UART without a resistor.
1120
  * to PDN_UART without a resistor.
1144
  * The drivers can also be used with hardware serial.
1121
  * The drivers can also be used with hardware serial.
1145
  *
1122
  *
1146
- * You'll also need the TMC2208Stepper Arduino library
1147
- * (https://github.com/teemuatlut/TMC2208Stepper).
1123
+ * The TMC2208Stepper library is required for this stepper driver.
1124
+ * https://github.com/teemuatlut/TMC2208Stepper
1148
  */
1125
  */
1149
-//#define HAVE_TMC2208
1150
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1151
-  //#define X_IS_TMC2208
1152
-  //#define X2_IS_TMC2208
1153
-  //#define Y_IS_TMC2208
1154
-  //#define Y2_IS_TMC2208
1155
-  //#define Z_IS_TMC2208
1156
-  //#define Z2_IS_TMC2208
1157
-  //#define E0_IS_TMC2208
1158
-  //#define E1_IS_TMC2208
1159
-  //#define E2_IS_TMC2208
1160
-  //#define E3_IS_TMC2208
1161
-  //#define E4_IS_TMC2208
1162
-#endif
1163
-
1164
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1126
+#if HAS_TRINAMIC
1165
 
1127
 
1166
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1128
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1167
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1129
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1316
 // @section L6470
1278
 // @section L6470
1317
 
1279
 
1318
 /**
1280
 /**
1319
- * Enable this section if you have L6470 motor drivers.
1320
- * You need to import the L6470 library into the Arduino IDE for this.
1321
- * (https://github.com/ameyer/Arduino-L6470)
1281
+ * L6470 Stepper Driver options
1282
+ *
1283
+ * The Arduino-L6470 library is required for this stepper driver.
1284
+ * https://github.com/ameyer/Arduino-L6470
1322
  */
1285
  */
1323
-
1324
-//#define HAVE_L6470DRIVER
1325
-#if ENABLED(HAVE_L6470DRIVER)
1326
-
1327
-  //#define X_IS_L6470
1328
-  //#define X2_IS_L6470
1329
-  //#define Y_IS_L6470
1330
-  //#define Y2_IS_L6470
1331
-  //#define Z_IS_L6470
1332
-  //#define Z2_IS_L6470
1333
-  //#define E0_IS_L6470
1334
-  //#define E1_IS_L6470
1335
-  //#define E2_IS_L6470
1336
-  //#define E3_IS_L6470
1337
-  //#define E4_IS_L6470
1286
+#if HAS_DRIVER(L6470)
1338
 
1287
 
1339
   #define X_MICROSTEPS      16 // number of microsteps
1288
   #define X_MICROSTEPS      16 // number of microsteps
1340
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1289
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1380
   #define E4_OVERCURRENT  2000
1329
   #define E4_OVERCURRENT  2000
1381
   #define E4_STALLCURRENT 1500
1330
   #define E4_STALLCURRENT 1500
1382
 
1331
 
1383
-#endif
1332
+#endif // L6470
1384
 
1333
 
1385
 /**
1334
 /**
1386
  * TWI/I2C BUS
1335
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/BQ/WITBOX/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/Cartesio/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Creality/CR-10/Configuration.h 查看文件

561
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
561
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
562
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
562
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
563
 
563
 
564
+/**
565
+ * Specify Stepper Driver types
566
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
567
+ * Stepper timing options can be overridden in Configuration_adv.h
568
+ *
569
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
570
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
571
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
572
+ *          TMC5130, TMC5130_STANDALONE
573
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
574
+ */
575
+#define X_DRIVER_TYPE  A4988
576
+#define Y_DRIVER_TYPE  A4988
577
+#define Z_DRIVER_TYPE  A4988
578
+#define X2_DRIVER_TYPE A4988
579
+#define Y2_DRIVER_TYPE A4988
580
+#define Z2_DRIVER_TYPE A4988
581
+#define E0_DRIVER_TYPE A4988
582
+#define E1_DRIVER_TYPE A4988
583
+#define E2_DRIVER_TYPE A4988
584
+#define E3_DRIVER_TYPE A4988
585
+#define E4_DRIVER_TYPE A4988
586
+
564
 // Enable this feature if all enabled endstop pins are interrupt-capable.
587
 // Enable this feature if all enabled endstop pins are interrupt-capable.
565
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
588
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
566
 //#define ENDSTOP_INTERRUPTS_FEATURE
589
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Creality/CR-10/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Creality/CR-10S/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Creality/CR-10S/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Creality/CR-10mini/Configuration.h 查看文件

570
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
570
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
571
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
571
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
572
 
572
 
573
+/**
574
+ * Specify Stepper Driver types
575
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
576
+ * Stepper timing options can be overridden in Configuration_adv.h
577
+ *
578
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
579
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
580
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
581
+ *          TMC5130, TMC5130_STANDALONE
582
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
583
+ */
584
+#define X_DRIVER_TYPE  A4988
585
+#define Y_DRIVER_TYPE  A4988
586
+#define Z_DRIVER_TYPE  A4988
587
+#define X2_DRIVER_TYPE A4988
588
+#define Y2_DRIVER_TYPE A4988
589
+#define Z2_DRIVER_TYPE A4988
590
+#define E0_DRIVER_TYPE A4988
591
+#define E1_DRIVER_TYPE A4988
592
+#define E2_DRIVER_TYPE A4988
593
+#define E3_DRIVER_TYPE A4988
594
+#define E4_DRIVER_TYPE A4988
595
+
573
 // Enable this feature if all enabled endstop pins are interrupt-capable.
596
 // Enable this feature if all enabled endstop pins are interrupt-capable.
574
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
597
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
575
 //#define ENDSTOP_INTERRUPTS_FEATURE
598
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Creality/CR-10mini/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Creality/CR-8/Configuration.h 查看文件

561
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
561
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
562
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
562
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
563
 
563
 
564
+/**
565
+ * Specify Stepper Driver types
566
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
567
+ * Stepper timing options can be overridden in Configuration_adv.h
568
+ *
569
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
570
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
571
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
572
+ *          TMC5130, TMC5130_STANDALONE
573
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
574
+ */
575
+#define X_DRIVER_TYPE  A4988
576
+#define Y_DRIVER_TYPE  A4988
577
+#define Z_DRIVER_TYPE  A4988
578
+#define X2_DRIVER_TYPE A4988
579
+#define Y2_DRIVER_TYPE A4988
580
+#define Z2_DRIVER_TYPE A4988
581
+#define E0_DRIVER_TYPE A4988
582
+#define E1_DRIVER_TYPE A4988
583
+#define E2_DRIVER_TYPE A4988
584
+#define E3_DRIVER_TYPE A4988
585
+#define E4_DRIVER_TYPE A4988
586
+
564
 // Enable this feature if all enabled endstop pins are interrupt-capable.
587
 // Enable this feature if all enabled endstop pins are interrupt-capable.
565
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
588
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
566
 //#define ENDSTOP_INTERRUPTS_FEATURE
589
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Creality/CR-8/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Creality/Ender-2/Configuration.h 查看文件

555
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
555
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
556
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
556
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
557
 
557
 
558
+/**
559
+ * Specify Stepper Driver types
560
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
561
+ * Stepper timing options can be overridden in Configuration_adv.h
562
+ *
563
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
564
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
565
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
566
+ *          TMC5130, TMC5130_STANDALONE
567
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
568
+ */
569
+#define X_DRIVER_TYPE  A4988
570
+#define Y_DRIVER_TYPE  A4988
571
+#define Z_DRIVER_TYPE  A4988
572
+#define X2_DRIVER_TYPE A4988
573
+#define Y2_DRIVER_TYPE A4988
574
+#define Z2_DRIVER_TYPE A4988
575
+#define E0_DRIVER_TYPE A4988
576
+#define E1_DRIVER_TYPE A4988
577
+#define E2_DRIVER_TYPE A4988
578
+#define E3_DRIVER_TYPE A4988
579
+#define E4_DRIVER_TYPE A4988
580
+
558
 // Enable this feature if all enabled endstop pins are interrupt-capable.
581
 // Enable this feature if all enabled endstop pins are interrupt-capable.
559
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
582
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
560
 //#define ENDSTOP_INTERRUPTS_FEATURE
583
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Creality/Ender-2/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Creality/Ender-3/Configuration.h 查看文件

555
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
555
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
556
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
556
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
557
 
557
 
558
+/**
559
+ * Specify Stepper Driver types
560
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
561
+ * Stepper timing options can be overridden in Configuration_adv.h
562
+ *
563
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
564
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
565
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
566
+ *          TMC5130, TMC5130_STANDALONE
567
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
568
+ */
569
+#define X_DRIVER_TYPE  A4988
570
+#define Y_DRIVER_TYPE  A4988
571
+#define Z_DRIVER_TYPE  A4988
572
+#define X2_DRIVER_TYPE A4988
573
+#define Y2_DRIVER_TYPE A4988
574
+#define Z2_DRIVER_TYPE A4988
575
+#define E0_DRIVER_TYPE A4988
576
+#define E1_DRIVER_TYPE A4988
577
+#define E2_DRIVER_TYPE A4988
578
+#define E3_DRIVER_TYPE A4988
579
+#define E4_DRIVER_TYPE A4988
580
+
558
 // Enable this feature if all enabled endstop pins are interrupt-capable.
581
 // Enable this feature if all enabled endstop pins are interrupt-capable.
559
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
582
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
560
 //#define ENDSTOP_INTERRUPTS_FEATURE
583
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Creality/Ender-3/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Creality/Ender-4/Configuration.h 查看文件

561
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
561
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
562
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
562
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
563
 
563
 
564
+/**
565
+ * Specify Stepper Driver types
566
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
567
+ * Stepper timing options can be overridden in Configuration_adv.h
568
+ *
569
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
570
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
571
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
572
+ *          TMC5130, TMC5130_STANDALONE
573
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
574
+ */
575
+#define X_DRIVER_TYPE  A4988
576
+#define Y_DRIVER_TYPE  A4988
577
+#define Z_DRIVER_TYPE  A4988
578
+#define X2_DRIVER_TYPE A4988
579
+#define Y2_DRIVER_TYPE A4988
580
+#define Z2_DRIVER_TYPE A4988
581
+#define E0_DRIVER_TYPE A4988
582
+#define E1_DRIVER_TYPE A4988
583
+#define E2_DRIVER_TYPE A4988
584
+#define E3_DRIVER_TYPE A4988
585
+#define E4_DRIVER_TYPE A4988
586
+
564
 // Enable this feature if all enabled endstop pins are interrupt-capable.
587
 // Enable this feature if all enabled endstop pins are interrupt-capable.
565
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
588
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
566
 //#define ENDSTOP_INTERRUPTS_FEATURE
589
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Creality/Ender-4/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Felix/Configuration.h 查看文件

532
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
532
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
533
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
533
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
534
 
534
 
535
+/**
536
+ * Specify Stepper Driver types
537
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
538
+ * Stepper timing options can be overridden in Configuration_adv.h
539
+ *
540
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
541
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
542
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
543
+ *          TMC5130, TMC5130_STANDALONE
544
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
545
+ */
546
+#define X_DRIVER_TYPE  A4988
547
+#define Y_DRIVER_TYPE  A4988
548
+#define Z_DRIVER_TYPE  A4988
549
+#define X2_DRIVER_TYPE A4988
550
+#define Y2_DRIVER_TYPE A4988
551
+#define Z2_DRIVER_TYPE A4988
552
+#define E0_DRIVER_TYPE A4988
553
+#define E1_DRIVER_TYPE A4988
554
+#define E2_DRIVER_TYPE A4988
555
+#define E3_DRIVER_TYPE A4988
556
+#define E4_DRIVER_TYPE A4988
557
+
535
 // Enable this feature if all enabled endstop pins are interrupt-capable.
558
 // Enable this feature if all enabled endstop pins are interrupt-capable.
536
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
559
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
537
 //#define ENDSTOP_INTERRUPTS_FEATURE
560
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Felix/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Felix/DUAL/Configuration.h 查看文件

532
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
532
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
533
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
533
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
534
 
534
 
535
+/**
536
+ * Specify Stepper Driver types
537
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
538
+ * Stepper timing options can be overridden in Configuration_adv.h
539
+ *
540
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
541
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
542
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
543
+ *          TMC5130, TMC5130_STANDALONE
544
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
545
+ */
546
+#define X_DRIVER_TYPE  A4988
547
+#define Y_DRIVER_TYPE  A4988
548
+#define Z_DRIVER_TYPE  A4988
549
+#define X2_DRIVER_TYPE A4988
550
+#define Y2_DRIVER_TYPE A4988
551
+#define Z2_DRIVER_TYPE A4988
552
+#define E0_DRIVER_TYPE A4988
553
+#define E1_DRIVER_TYPE A4988
554
+#define E2_DRIVER_TYPE A4988
555
+#define E3_DRIVER_TYPE A4988
556
+#define E4_DRIVER_TYPE A4988
557
+
535
 // Enable this feature if all enabled endstop pins are interrupt-capable.
558
 // Enable this feature if all enabled endstop pins are interrupt-capable.
536
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
559
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
537
 //#define ENDSTOP_INTERRUPTS_FEATURE
560
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/FolgerTech/i3-2020/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Geeetech/GT2560/Configuration.h 查看文件

566
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
566
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
567
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
567
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
568
 
568
 
569
+/**
570
+ * Specify Stepper Driver types
571
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
572
+ * Stepper timing options can be overridden in Configuration_adv.h
573
+ *
574
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
575
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
576
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
577
+ *          TMC5130, TMC5130_STANDALONE
578
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
579
+ */
580
+#define X_DRIVER_TYPE  A4988
581
+#define Y_DRIVER_TYPE  A4988
582
+#define Z_DRIVER_TYPE  A4988
583
+#define X2_DRIVER_TYPE A4988
584
+#define Y2_DRIVER_TYPE A4988
585
+#define Z2_DRIVER_TYPE A4988
586
+#define E0_DRIVER_TYPE A4988
587
+#define E1_DRIVER_TYPE A4988
588
+#define E2_DRIVER_TYPE A4988
589
+#define E3_DRIVER_TYPE A4988
590
+#define E4_DRIVER_TYPE A4988
591
+
569
 // Enable this feature if all enabled endstop pins are interrupt-capable.
592
 // Enable this feature if all enabled endstop pins are interrupt-capable.
570
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
593
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
571
 //#define ENDSTOP_INTERRUPTS_FEATURE
594
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 23
- 0
Marlin/src/config/examples/Geeetech/I3_Pro_X-GT2560/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 23
- 0
Marlin/src/config/examples/Geeetech/Prusa i3 Pro B/bltouch/Configuration.h 查看文件

566
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
566
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
567
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
567
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
568
 
568
 
569
+/**
570
+ * Specify Stepper Driver types
571
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
572
+ * Stepper timing options can be overridden in Configuration_adv.h
573
+ *
574
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
575
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
576
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
577
+ *          TMC5130, TMC5130_STANDALONE
578
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
579
+ */
580
+#define X_DRIVER_TYPE  A4988
581
+#define Y_DRIVER_TYPE  A4988
582
+#define Z_DRIVER_TYPE  A4988
583
+#define X2_DRIVER_TYPE A4988
584
+#define Y2_DRIVER_TYPE A4988
585
+#define Z2_DRIVER_TYPE A4988
586
+#define E0_DRIVER_TYPE A4988
587
+#define E1_DRIVER_TYPE A4988
588
+#define E2_DRIVER_TYPE A4988
589
+#define E3_DRIVER_TYPE A4988
590
+#define E4_DRIVER_TYPE A4988
591
+
569
 // Enable this feature if all enabled endstop pins are interrupt-capable.
592
 // Enable this feature if all enabled endstop pins are interrupt-capable.
570
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
593
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
571
 //#define ENDSTOP_INTERRUPTS_FEATURE
594
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 23
- 0
Marlin/src/config/examples/Geeetech/Prusa i3 Pro B/noprobe/Configuration.h 查看文件

566
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
566
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
567
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
567
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
568
 
568
 
569
+/**
570
+ * Specify Stepper Driver types
571
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
572
+ * Stepper timing options can be overridden in Configuration_adv.h
573
+ *
574
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
575
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
576
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
577
+ *          TMC5130, TMC5130_STANDALONE
578
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
579
+ */
580
+#define X_DRIVER_TYPE  A4988
581
+#define Y_DRIVER_TYPE  A4988
582
+#define Z_DRIVER_TYPE  A4988
583
+#define X2_DRIVER_TYPE A4988
584
+#define Y2_DRIVER_TYPE A4988
585
+#define Z2_DRIVER_TYPE A4988
586
+#define E0_DRIVER_TYPE A4988
587
+#define E1_DRIVER_TYPE A4988
588
+#define E2_DRIVER_TYPE A4988
589
+#define E3_DRIVER_TYPE A4988
590
+#define E4_DRIVER_TYPE A4988
591
+
569
 // Enable this feature if all enabled endstop pins are interrupt-capable.
592
 // Enable this feature if all enabled endstop pins are interrupt-capable.
570
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
593
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
571
 //#define ENDSTOP_INTERRUPTS_FEATURE
594
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 23
- 0
Marlin/src/config/examples/Geeetech/Prusa i3 Pro C/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Geeetech/Prusa i3 Pro C/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Geeetech/Prusa i3 Pro W/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Geeetech/Prusa i3 Pro W/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/Infitary/i3-M508/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/JGAurora/A5/Configuration.h 查看文件

563
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
563
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
564
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
564
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
565
 
565
 
566
+/**
567
+ * Specify Stepper Driver types
568
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
569
+ * Stepper timing options can be overridden in Configuration_adv.h
570
+ *
571
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
572
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
573
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
574
+ *          TMC5130, TMC5130_STANDALONE
575
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
576
+ */
577
+#define X_DRIVER_TYPE  A4988
578
+#define Y_DRIVER_TYPE  A4988
579
+#define Z_DRIVER_TYPE  A4988
580
+#define X2_DRIVER_TYPE A4988
581
+#define Y2_DRIVER_TYPE A4988
582
+#define Z2_DRIVER_TYPE A4988
583
+#define E0_DRIVER_TYPE A4988
584
+#define E1_DRIVER_TYPE A4988
585
+#define E2_DRIVER_TYPE A4988
586
+#define E3_DRIVER_TYPE A4988
587
+#define E4_DRIVER_TYPE A4988
588
+
566
 // Enable this feature if all enabled endstop pins are interrupt-capable.
589
 // Enable this feature if all enabled endstop pins are interrupt-capable.
567
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
590
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
568
 //#define ENDSTOP_INTERRUPTS_FEATURE
591
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/JGAurora/A5/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/MakerParts/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/Malyan/M150/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Malyan/M200/Configuration.h 查看文件

550
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
550
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
551
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 
552
 
553
+/**
554
+ * Specify Stepper Driver types
555
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
556
+ * Stepper timing options can be overridden in Configuration_adv.h
557
+ *
558
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
559
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
560
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
561
+ *          TMC5130, TMC5130_STANDALONE
562
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
563
+ */
564
+#define X_DRIVER_TYPE  A4988
565
+#define Y_DRIVER_TYPE  A4988
566
+#define Z_DRIVER_TYPE  A4988
567
+#define X2_DRIVER_TYPE A4988
568
+#define Y2_DRIVER_TYPE A4988
569
+#define Z2_DRIVER_TYPE A4988
570
+#define E0_DRIVER_TYPE A4988
571
+#define E1_DRIVER_TYPE A4988
572
+#define E2_DRIVER_TYPE A4988
573
+#define E3_DRIVER_TYPE A4988
574
+#define E4_DRIVER_TYPE A4988
575
+
553
 // Enable this feature if all enabled endstop pins are interrupt-capable.
576
 // Enable this feature if all enabled endstop pins are interrupt-capable.
554
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
577
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
555
 //#define ENDSTOP_INTERRUPTS_FEATURE
578
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Malyan/M200/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Micromake/C1/basic/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Micromake/C1/enhanced/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/Mks/Sbase/Configuration_adv.h 查看文件

845
 
845
 
846
 /**
846
 /**
847
  * Minimum delay after setting the stepper DIR (in ns)
847
  * Minimum delay after setting the stepper DIR (in ns)
848
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
849
- *   20 : Minimum for TMC2xxx drivers
850
- *  200 : Minimum for A4988 drivers
851
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
852
- *  650 : Minimum for DRV8825 drivers
853
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
854
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
848
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
849
+ *    20 : Minimum for TMC2xxx drivers
850
+ *   200 : Minimum for A4988 drivers
851
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
852
+ *   650 : Minimum for DRV8825 drivers
853
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
854
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
855
+ *
856
+ * Override the default value based on the driver type set in Configuration.h.
855
  */
857
  */
856
-#define MINIMUM_STEPPER_DIR_DELAY 0
858
+//#define MINIMUM_STEPPER_DIR_DELAY 650
857
 
859
 
858
 /**
860
 /**
859
  * Minimum stepper driver pulse width (in µs)
861
  * Minimum stepper driver pulse width (in µs)
863
  *   2 : Minimum for DRV8825 stepper drivers
865
  *   2 : Minimum for DRV8825 stepper drivers
864
  *   3 : Minimum for TB6600 stepper drivers
866
  *   3 : Minimum for TB6600 stepper drivers
865
  *  30 : Minimum for TB6560 stepper drivers
867
  *  30 : Minimum for TB6560 stepper drivers
868
+ *
869
+ * Override the default value based on the driver type set in Configuration.h.
866
  */
870
  */
867
-#define MINIMUM_STEPPER_PULSE 4
871
+//#define MINIMUM_STEPPER_PULSE 2
868
 
872
 
869
 /**
873
 /**
870
  * Maximum stepping rate (in Hz) the stepper driver allows
874
  * Maximum stepping rate (in Hz) the stepper driver allows
875
  *  150000 : Maximum for TB6600 stepper driver
879
  *  150000 : Maximum for TB6600 stepper driver
876
  *  130000 : Maximum for LV8729 stepper driver
880
  *  130000 : Maximum for LV8729 stepper driver
877
  *   15000 : Maximum for TB6560 stepper driver
881
  *   15000 : Maximum for TB6560 stepper driver
882
+ *
883
+ * Override the default value based on the driver type set in Configuration.h.
878
  */
884
  */
879
-#define MAXIMUM_STEPPER_RATE 250000
885
+//#define MAXIMUM_STEPPER_RATE 250000
880
 
886
 
881
 // @section temperature
887
 // @section temperature
882
 
888
 
1044
 // @section tmc
1050
 // @section tmc
1045
 
1051
 
1046
 /**
1052
 /**
1047
- * Enable this section if you have TMC26X motor drivers.
1048
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1049
- * (https://github.com/trinamic/TMC26XStepper.git)
1053
+ * TMC26X Stepper Driver options
1054
+ *
1055
+ * The TMC26XStepper library is required for this stepper driver.
1056
+ * https://github.com/trinamic/TMC26XStepper
1050
  */
1057
  */
1051
-//#define HAVE_TMC26X
1052
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1053
-  //#define X_IS_TMC26X
1054
-  //#define X2_IS_TMC26X
1055
-  //#define Y_IS_TMC26X
1056
-  //#define Y2_IS_TMC26X
1057
-  //#define Z_IS_TMC26X
1058
-  //#define Z2_IS_TMC26X
1059
-  //#define E0_IS_TMC26X
1060
-  //#define E1_IS_TMC26X
1061
-  //#define E2_IS_TMC26X
1062
-  //#define E3_IS_TMC26X
1063
-  //#define E4_IS_TMC26X
1058
+#if HAS_DRIVER(TMC26X)
1064
 
1059
 
1065
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_MAX_CURRENT     1000 // in mA
1066
   #define X_SENSE_RESISTOR    91 // in mOhms
1061
   #define X_SENSE_RESISTOR    91 // in mOhms
1106
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_SENSE_RESISTOR   91
1107
   #define E4_MICROSTEPS       16
1102
   #define E4_MICROSTEPS       16
1108
 
1103
 
1109
-#endif
1104
+#endif // TMC26X
1110
 
1105
 
1111
 // @section tmc_smart
1106
 // @section tmc_smart
1112
 
1107
 
1113
 /**
1108
 /**
1114
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1115
- *
1116
- * You'll also need the TMC2130Stepper Arduino library
1117
- * (https://github.com/teemuatlut/TMC2130Stepper).
1118
- *
1119
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1109
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1120
  * the hardware SPI interface on your board and define the required CS pins
1110
  * the hardware SPI interface on your board and define the required CS pins
1121
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1111
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1122
  * You may also use software SPI if you wish to use general purpose IO pins.
1112
  * You may also use software SPI if you wish to use general purpose IO pins.
1123
- */
1124
-//#define HAVE_TMC2130
1125
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1126
-  //#define X_IS_TMC2130
1127
-  //#define X2_IS_TMC2130
1128
-  //#define Y_IS_TMC2130
1129
-  //#define Y2_IS_TMC2130
1130
-  //#define Z_IS_TMC2130
1131
-  //#define Z2_IS_TMC2130
1132
-  //#define E0_IS_TMC2130
1133
-  //#define E1_IS_TMC2130
1134
-  //#define E2_IS_TMC2130
1135
-  //#define E3_IS_TMC2130
1136
-  //#define E4_IS_TMC2130
1137
-#endif
1138
-
1139
-/**
1140
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1141
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1113
+ *
1114
+ * The TMC2130Stepper library is required for this stepper driver.
1115
+ * https://github.com/teemuatlut/TMC2130Stepper
1116
+ *
1117
+ * To use TMC2208 stepper UART-configurable stepper drivers
1118
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1142
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1119
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1143
  * to PDN_UART without a resistor.
1120
  * to PDN_UART without a resistor.
1144
  * The drivers can also be used with hardware serial.
1121
  * The drivers can also be used with hardware serial.
1145
  *
1122
  *
1146
- * You'll also need the TMC2208Stepper Arduino library
1147
- * (https://github.com/teemuatlut/TMC2208Stepper).
1123
+ * The TMC2208Stepper library is required for this stepper driver.
1124
+ * https://github.com/teemuatlut/TMC2208Stepper
1148
  */
1125
  */
1149
-//#define HAVE_TMC2208
1150
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1151
-  //#define X_IS_TMC2208
1152
-  //#define X2_IS_TMC2208
1153
-  //#define Y_IS_TMC2208
1154
-  //#define Y2_IS_TMC2208
1155
-  //#define Z_IS_TMC2208
1156
-  //#define Z2_IS_TMC2208
1157
-  //#define E0_IS_TMC2208
1158
-  //#define E1_IS_TMC2208
1159
-  //#define E2_IS_TMC2208
1160
-  //#define E3_IS_TMC2208
1161
-  //#define E4_IS_TMC2208
1162
-#endif
1163
-
1164
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1126
+#if HAS_TRINAMIC
1165
 
1127
 
1166
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1128
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1167
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1129
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1316
 // @section L6470
1278
 // @section L6470
1317
 
1279
 
1318
 /**
1280
 /**
1319
- * Enable this section if you have L6470 motor drivers.
1320
- * You need to import the L6470 library into the Arduino IDE for this.
1321
- * (https://github.com/ameyer/Arduino-L6470)
1281
+ * L6470 Stepper Driver options
1282
+ *
1283
+ * The Arduino-L6470 library is required for this stepper driver.
1284
+ * https://github.com/ameyer/Arduino-L6470
1322
  */
1285
  */
1323
-
1324
-//#define HAVE_L6470DRIVER
1325
-#if ENABLED(HAVE_L6470DRIVER)
1326
-
1327
-  //#define X_IS_L6470
1328
-  //#define X2_IS_L6470
1329
-  //#define Y_IS_L6470
1330
-  //#define Y2_IS_L6470
1331
-  //#define Z_IS_L6470
1332
-  //#define Z2_IS_L6470
1333
-  //#define E0_IS_L6470
1334
-  //#define E1_IS_L6470
1335
-  //#define E2_IS_L6470
1336
-  //#define E3_IS_L6470
1337
-  //#define E4_IS_L6470
1286
+#if HAS_DRIVER(L6470)
1338
 
1287
 
1339
   #define X_MICROSTEPS      16 // number of microsteps
1288
   #define X_MICROSTEPS      16 // number of microsteps
1340
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1289
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1380
   #define E4_OVERCURRENT  2000
1329
   #define E4_OVERCURRENT  2000
1381
   #define E4_STALLCURRENT 1500
1330
   #define E4_STALLCURRENT 1500
1382
 
1331
 
1383
-#endif
1332
+#endif // L6470
1384
 
1333
 
1385
 /**
1334
 /**
1386
  * TWI/I2C BUS
1335
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/RepRapPro/Huxley/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/RigidBot/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/SCARA/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/STM32F10/Configuration.h 查看文件

553
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
553
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
554
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
554
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
555
 
555
 
556
+/**
557
+ * Specify Stepper Driver types
558
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
559
+ * Stepper timing options can be overridden in Configuration_adv.h
560
+ *
561
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
562
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
563
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
564
+ *          TMC5130, TMC5130_STANDALONE
565
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
566
+ */
567
+#define X_DRIVER_TYPE  A4988
568
+#define Y_DRIVER_TYPE  A4988
569
+#define Z_DRIVER_TYPE  A4988
570
+#define X2_DRIVER_TYPE A4988
571
+#define Y2_DRIVER_TYPE A4988
572
+#define Z2_DRIVER_TYPE A4988
573
+#define E0_DRIVER_TYPE A4988
574
+#define E1_DRIVER_TYPE A4988
575
+#define E2_DRIVER_TYPE A4988
576
+#define E3_DRIVER_TYPE A4988
577
+#define E4_DRIVER_TYPE A4988
578
+
556
 // Enable this feature if all enabled endstop pins are interrupt-capable.
579
 // Enable this feature if all enabled endstop pins are interrupt-capable.
557
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
580
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
558
 //#define ENDSTOP_INTERRUPTS_FEATURE
581
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 23
- 0
Marlin/src/config/examples/STM32F4/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 23
- 0
Marlin/src/config/examples/Sanguinololu/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Sanguinololu/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 81
- 133
Marlin/src/config/examples/TheBorg/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-#define HAVE_TMC26X
1044
-
1045
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1046
-  #define X_IS_TMC26X
1047
-  //#define X2_IS_TMC26X
1048
-  #define Y_IS_TMC26X
1049
-  //#define Y2_IS_TMC26X
1050
-  #define Z_IS_TMC26X
1051
-  #define Z2_IS_TMC26X
1052
-  #define E0_IS_TMC26X
1053
-  //#define E1_IS_TMC26X
1054
-  //#define E2_IS_TMC26X
1055
-  //#define E3_IS_TMC26X
1056
-  //#define E4_IS_TMC26X
1057
-
1058
-  #define X_MAX_CURRENT     1200 // in mA
1059
-  #define X_SENSE_RESISTOR    50 // in mOhms
1060
-  #define X_MICROSTEPS        32 // number of microsteps
1061
-
1062
-  #define X2_MAX_CURRENT    1200
1063
-  #define X2_SENSE_RESISTOR   50
1064
-  #define X2_MICROSTEPS       32
1065
-
1066
-  #define Y_MAX_CURRENT     1200
1067
-  #define Y_SENSE_RESISTOR    50
1068
-  #define Y_MICROSTEPS        32
1069
-
1070
-  #define Y2_MAX_CURRENT    1200
1071
-  #define Y2_SENSE_RESISTOR   50
1072
-  #define Y2_MICROSTEPS       32
1073
-
1074
-  #define Z_MAX_CURRENT     1200
1075
-  #define Z_SENSE_RESISTOR    50
1076
-  #define Z_MICROSTEPS        32
1077
-
1078
-  #define Z2_MAX_CURRENT    1200
1079
-  #define Z2_SENSE_RESISTOR   50
1080
-  #define Z2_MICROSTEPS       32
1081
-
1082
-  #define E0_MAX_CURRENT    1200
1083
-  #define E0_SENSE_RESISTOR   50
1084
-  #define E0_MICROSTEPS       32
1085
-
1086
-  #define E1_MAX_CURRENT    1200
1087
-  #define E1_SENSE_RESISTOR   50
1088
-  #define E1_MICROSTEPS       32
1089
-
1090
-  #define E2_MAX_CURRENT    1200
1091
-  #define E2_SENSE_RESISTOR   50
1092
-  #define E2_MICROSTEPS       32
1093
-
1094
-  #define E3_MAX_CURRENT    1200
1095
-  #define E3_SENSE_RESISTOR   50
1096
-  #define E3_MICROSTEPS       32
1097
-
1098
-  #define E4_MAX_CURRENT    1200
1099
-  #define E4_SENSE_RESISTOR   50
1100
-  #define E4_MICROSTEPS       32
1050
+#if HAS_DRIVER(TMC26X)
1101
 
1051
 
1102
-#endif
1052
+  #define X_MAX_CURRENT     1000 // in mA
1053
+  #define X_SENSE_RESISTOR    91 // in mOhms
1054
+  #define X_MICROSTEPS        16 // number of microsteps
1055
+
1056
+  #define X2_MAX_CURRENT    1000
1057
+  #define X2_SENSE_RESISTOR   91
1058
+  #define X2_MICROSTEPS       16
1059
+
1060
+  #define Y_MAX_CURRENT     1000
1061
+  #define Y_SENSE_RESISTOR    91
1062
+  #define Y_MICROSTEPS        16
1063
+
1064
+  #define Y2_MAX_CURRENT    1000
1065
+  #define Y2_SENSE_RESISTOR   91
1066
+  #define Y2_MICROSTEPS       16
1067
+
1068
+  #define Z_MAX_CURRENT     1000
1069
+  #define Z_SENSE_RESISTOR    91
1070
+  #define Z_MICROSTEPS        16
1071
+
1072
+  #define Z2_MAX_CURRENT    1000
1073
+  #define Z2_SENSE_RESISTOR   91
1074
+  #define Z2_MICROSTEPS       16
1075
+
1076
+  #define E0_MAX_CURRENT    1000
1077
+  #define E0_SENSE_RESISTOR   91
1078
+  #define E0_MICROSTEPS       16
1079
+
1080
+  #define E1_MAX_CURRENT    1000
1081
+  #define E1_SENSE_RESISTOR   91
1082
+  #define E1_MICROSTEPS       16
1083
+
1084
+  #define E2_MAX_CURRENT    1000
1085
+  #define E2_SENSE_RESISTOR   91
1086
+  #define E2_MICROSTEPS       16
1087
+
1088
+  #define E3_MAX_CURRENT    1000
1089
+  #define E3_SENSE_RESISTOR   91
1090
+  #define E3_MICROSTEPS       16
1091
+
1092
+  #define E4_MAX_CURRENT    1000
1093
+  #define E4_SENSE_RESISTOR   91
1094
+  #define E4_MICROSTEPS       16
1095
+
1096
+#endif // TMC26X
1103
 
1097
 
1104
 // @section tmc_smart
1098
 // @section tmc_smart
1105
 
1099
 
1106
 /**
1100
 /**
1107
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1108
- *
1109
- * You'll also need the TMC2130Stepper Arduino library
1110
- * (https://github.com/teemuatlut/TMC2130Stepper).
1111
- *
1112
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1113
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1114
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1115
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1116
- */
1117
-//#define HAVE_TMC2130
1118
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1119
-  //#define X_IS_TMC2130
1120
-  //#define X2_IS_TMC2130
1121
-  //#define Y_IS_TMC2130
1122
-  //#define Y2_IS_TMC2130
1123
-  //#define Z_IS_TMC2130
1124
-  //#define Z2_IS_TMC2130
1125
-  //#define E0_IS_TMC2130
1126
-  //#define E1_IS_TMC2130
1127
-  //#define E2_IS_TMC2130
1128
-  //#define E3_IS_TMC2130
1129
-  //#define E4_IS_TMC2130
1130
-#endif
1131
-
1132
-/**
1133
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1134
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1135
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1136
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1137
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1138
  *
1114
  *
1139
- * You'll also need the TMC2208Stepper Arduino library
1140
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1141
  */
1117
  */
1142
-//#define HAVE_TMC2208
1143
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1144
-  //#define X_IS_TMC2208
1145
-  //#define X2_IS_TMC2208
1146
-  //#define Y_IS_TMC2208
1147
-  //#define Y2_IS_TMC2208
1148
-  //#define Z_IS_TMC2208
1149
-  //#define Z2_IS_TMC2208
1150
-  //#define E0_IS_TMC2208
1151
-  //#define E1_IS_TMC2208
1152
-  //#define E2_IS_TMC2208
1153
-  //#define E3_IS_TMC2208
1154
-  //#define E4_IS_TMC2208
1155
-#endif
1156
-
1157
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1158
 
1119
 
1159
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1160
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1309
 // @section L6470
1270
 // @section L6470
1310
 
1271
 
1311
 /**
1272
 /**
1312
- * Enable this section if you have L6470 motor drivers.
1313
- * You need to import the L6470 library into the Arduino IDE for this.
1314
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1315
  */
1277
  */
1316
-
1317
-//#define HAVE_L6470DRIVER
1318
-#if ENABLED(HAVE_L6470DRIVER)
1319
-
1320
-  //#define X_IS_L6470
1321
-  //#define X2_IS_L6470
1322
-  //#define Y_IS_L6470
1323
-  //#define Y2_IS_L6470
1324
-  //#define Z_IS_L6470
1325
-  //#define Z2_IS_L6470
1326
-  //#define E0_IS_L6470
1327
-  //#define E1_IS_L6470
1328
-  //#define E2_IS_L6470
1329
-  //#define E3_IS_L6470
1330
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1331
 
1279
 
1332
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1333
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1373
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1374
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1375
 
1323
 
1376
-#endif
1324
+#endif // L6470
1377
 
1325
 
1378
 /**
1326
 /**
1379
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 24
- 1
Marlin/src/config/examples/TinyBoy2/Configuration.h 查看文件

602
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
602
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
603
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
603
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
604
 
604
 
605
+/**
606
+ * Specify Stepper Driver types
607
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
608
+ * Stepper timing options can be overridden in Configuration_adv.h
609
+ *
610
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
611
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
612
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
613
+ *          TMC5130, TMC5130_STANDALONE
614
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
615
+ */
616
+#define X_DRIVER_TYPE  A4988
617
+#define Y_DRIVER_TYPE  A4988
618
+#define Z_DRIVER_TYPE  A4988
619
+#define X2_DRIVER_TYPE A4988
620
+#define Y2_DRIVER_TYPE A4988
621
+#define Z2_DRIVER_TYPE A4988
622
+#define E0_DRIVER_TYPE A4988
623
+#define E1_DRIVER_TYPE A4988
624
+#define E2_DRIVER_TYPE A4988
625
+#define E3_DRIVER_TYPE A4988
626
+#define E4_DRIVER_TYPE A4988
627
+
605
 // Enable this feature if all enabled endstop pins are interrupt-capable.
628
 // Enable this feature if all enabled endstop pins are interrupt-capable.
606
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
629
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
607
-#define ENDSTOP_INTERRUPTS_FEATURE
630
+//#define ENDSTOP_INTERRUPTS_FEATURE
608
 
631
 
609
 /**
632
 /**
610
  * Endstop Noise Filter
633
  * Endstop Noise Filter

+ 37
- 88
Marlin/src/config/examples/TinyBoy2/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Tronxy/X1/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Tronxy/X3A/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Tronxy/XY100/Configuration.h 查看文件

562
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
562
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
563
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
563
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
564
 
564
 
565
+/**
566
+ * Specify Stepper Driver types
567
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
568
+ * Stepper timing options can be overridden in Configuration_adv.h
569
+ *
570
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
571
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
572
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
573
+ *          TMC5130, TMC5130_STANDALONE
574
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
575
+ */
576
+#define X_DRIVER_TYPE  A4988
577
+#define Y_DRIVER_TYPE  A4988
578
+#define Z_DRIVER_TYPE  A4988
579
+#define X2_DRIVER_TYPE A4988
580
+#define Y2_DRIVER_TYPE A4988
581
+#define Z2_DRIVER_TYPE A4988
582
+#define E0_DRIVER_TYPE A4988
583
+#define E1_DRIVER_TYPE A4988
584
+#define E2_DRIVER_TYPE A4988
585
+#define E3_DRIVER_TYPE A4988
586
+#define E4_DRIVER_TYPE A4988
587
+
565
 // Enable this feature if all enabled endstop pins are interrupt-capable.
588
 // Enable this feature if all enabled endstop pins are interrupt-capable.
566
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
589
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
567
 //#define ENDSTOP_INTERRUPTS_FEATURE
590
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 23
- 0
Marlin/src/config/examples/UltiMachine/Archim2/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  TMC2130
566
+#define Y_DRIVER_TYPE  TMC2130
567
+#define Z_DRIVER_TYPE  TMC2130
568
+//#define X2_DRIVER_TYPE A4988
569
+//#define Y2_DRIVER_TYPE A4988
570
+//#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE TMC2130
572
+//#define E1_DRIVER_TYPE A4988
573
+//#define E2_DRIVER_TYPE A4988
574
+//#define E3_DRIVER_TYPE A4988
575
+//#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/UltiMachine/Archim2/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Velleman/K8200/Configuration.h 查看文件

581
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
581
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
582
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
582
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
583
 
583
 
584
+/**
585
+ * Specify Stepper Driver types
586
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
587
+ * Stepper timing options can be overridden in Configuration_adv.h
588
+ *
589
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
590
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
591
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
592
+ *          TMC5130, TMC5130_STANDALONE
593
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
594
+ */
595
+#define X_DRIVER_TYPE  A4988
596
+#define Y_DRIVER_TYPE  A4988
597
+#define Z_DRIVER_TYPE  A4988
598
+#define X2_DRIVER_TYPE A4988
599
+#define Y2_DRIVER_TYPE A4988
600
+#define Z2_DRIVER_TYPE A4988
601
+#define E0_DRIVER_TYPE A4988
602
+#define E1_DRIVER_TYPE A4988
603
+#define E2_DRIVER_TYPE A4988
604
+#define E3_DRIVER_TYPE A4988
605
+#define E4_DRIVER_TYPE A4988
606
+
584
 // Enable this feature if all enabled endstop pins are interrupt-capable.
607
 // Enable this feature if all enabled endstop pins are interrupt-capable.
585
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
608
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
586
 //#define ENDSTOP_INTERRUPTS_FEATURE
609
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Velleman/K8200/Configuration_adv.h 查看文件

840
 
840
 
841
 /**
841
 /**
842
  * Minimum delay after setting the stepper DIR (in ns)
842
  * Minimum delay after setting the stepper DIR (in ns)
843
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
844
- *   20 : Minimum for TMC2xxx drivers
845
- *  200 : Minimum for A4988 drivers
846
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
847
- *  650 : Minimum for DRV8825 drivers
848
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
849
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
843
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
844
+ *    20 : Minimum for TMC2xxx drivers
845
+ *   200 : Minimum for A4988 drivers
846
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
847
+ *   650 : Minimum for DRV8825 drivers
848
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
849
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
850
+ *
851
+ * Override the default value based on the driver type set in Configuration.h.
850
  */
852
  */
851
-#define MINIMUM_STEPPER_DIR_DELAY 0
853
+//#define MINIMUM_STEPPER_DIR_DELAY 650
852
 
854
 
853
 /**
855
 /**
854
  * Minimum stepper driver pulse width (in µs)
856
  * Minimum stepper driver pulse width (in µs)
858
  *   2 : Minimum for DRV8825 stepper drivers
860
  *   2 : Minimum for DRV8825 stepper drivers
859
  *   3 : Minimum for TB6600 stepper drivers
861
  *   3 : Minimum for TB6600 stepper drivers
860
  *  30 : Minimum for TB6560 stepper drivers
862
  *  30 : Minimum for TB6560 stepper drivers
863
+ *
864
+ * Override the default value based on the driver type set in Configuration.h.
861
  */
865
  */
862
-#define MINIMUM_STEPPER_PULSE 2
866
+//#define MINIMUM_STEPPER_PULSE 2
863
 
867
 
864
 /**
868
 /**
865
  * Maximum stepping rate (in Hz) the stepper driver allows
869
  * Maximum stepping rate (in Hz) the stepper driver allows
870
  *  150000 : Maximum for TB6600 stepper driver
874
  *  150000 : Maximum for TB6600 stepper driver
871
  *  130000 : Maximum for LV8729 stepper driver
875
  *  130000 : Maximum for LV8729 stepper driver
872
  *   15000 : Maximum for TB6560 stepper driver
876
  *   15000 : Maximum for TB6560 stepper driver
877
+ *
878
+ * Override the default value based on the driver type set in Configuration.h.
873
  */
879
  */
874
-#define MAXIMUM_STEPPER_RATE 250000
880
+//#define MAXIMUM_STEPPER_RATE 250000
875
 
881
 
876
 // @section temperature
882
 // @section temperature
877
 
883
 
1039
 // @section tmc
1045
 // @section tmc
1040
 
1046
 
1041
 /**
1047
 /**
1042
- * Enable this section if you have TMC26X motor drivers.
1043
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1044
- * (https://github.com/trinamic/TMC26XStepper.git)
1048
+ * TMC26X Stepper Driver options
1049
+ *
1050
+ * The TMC26XStepper library is required for this stepper driver.
1051
+ * https://github.com/trinamic/TMC26XStepper
1045
  */
1052
  */
1046
-//#define HAVE_TMC26X
1047
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1048
-  //#define X_IS_TMC26X
1049
-  //#define X2_IS_TMC26X
1050
-  //#define Y_IS_TMC26X
1051
-  //#define Y2_IS_TMC26X
1052
-  //#define Z_IS_TMC26X
1053
-  //#define Z2_IS_TMC26X
1054
-  //#define E0_IS_TMC26X
1055
-  //#define E1_IS_TMC26X
1056
-  //#define E2_IS_TMC26X
1057
-  //#define E3_IS_TMC26X
1058
-  //#define E4_IS_TMC26X
1053
+#if HAS_DRIVER(TMC26X)
1059
 
1054
 
1060
   #define X_MAX_CURRENT     1000 // in mA
1055
   #define X_MAX_CURRENT     1000 // in mA
1061
   #define X_SENSE_RESISTOR    91 // in mOhms
1056
   #define X_SENSE_RESISTOR    91 // in mOhms
1101
   #define E4_SENSE_RESISTOR   91
1096
   #define E4_SENSE_RESISTOR   91
1102
   #define E4_MICROSTEPS       16
1097
   #define E4_MICROSTEPS       16
1103
 
1098
 
1104
-#endif
1099
+#endif // TMC26X
1105
 
1100
 
1106
 // @section tmc_smart
1101
 // @section tmc_smart
1107
 
1102
 
1108
 /**
1103
 /**
1109
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1110
- *
1111
- * You'll also need the TMC2130Stepper Arduino library
1112
- * (https://github.com/teemuatlut/TMC2130Stepper).
1113
- *
1114
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1104
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1115
  * the hardware SPI interface on your board and define the required CS pins
1105
  * the hardware SPI interface on your board and define the required CS pins
1116
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1106
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1117
  * You may also use software SPI if you wish to use general purpose IO pins.
1107
  * You may also use software SPI if you wish to use general purpose IO pins.
1118
- */
1119
-//#define HAVE_TMC2130
1120
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1121
-  //#define X_IS_TMC2130
1122
-  //#define X2_IS_TMC2130
1123
-  //#define Y_IS_TMC2130
1124
-  //#define Y2_IS_TMC2130
1125
-  //#define Z_IS_TMC2130
1126
-  //#define Z2_IS_TMC2130
1127
-  //#define E0_IS_TMC2130
1128
-  //#define E1_IS_TMC2130
1129
-  //#define E2_IS_TMC2130
1130
-  //#define E3_IS_TMC2130
1131
-  //#define E4_IS_TMC2130
1132
-#endif
1133
-
1134
-/**
1135
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1136
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1108
+ *
1109
+ * The TMC2130Stepper library is required for this stepper driver.
1110
+ * https://github.com/teemuatlut/TMC2130Stepper
1111
+ *
1112
+ * To use TMC2208 stepper UART-configurable stepper drivers
1113
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1137
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1114
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1138
  * to PDN_UART without a resistor.
1115
  * to PDN_UART without a resistor.
1139
  * The drivers can also be used with hardware serial.
1116
  * The drivers can also be used with hardware serial.
1140
  *
1117
  *
1141
- * You'll also need the TMC2208Stepper Arduino library
1142
- * (https://github.com/teemuatlut/TMC2208Stepper).
1118
+ * The TMC2208Stepper library is required for this stepper driver.
1119
+ * https://github.com/teemuatlut/TMC2208Stepper
1143
  */
1120
  */
1144
-//#define HAVE_TMC2208
1145
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1146
-  //#define X_IS_TMC2208
1147
-  //#define X2_IS_TMC2208
1148
-  //#define Y_IS_TMC2208
1149
-  //#define Y2_IS_TMC2208
1150
-  //#define Z_IS_TMC2208
1151
-  //#define Z2_IS_TMC2208
1152
-  //#define E0_IS_TMC2208
1153
-  //#define E1_IS_TMC2208
1154
-  //#define E2_IS_TMC2208
1155
-  //#define E3_IS_TMC2208
1156
-  //#define E4_IS_TMC2208
1157
-#endif
1158
-
1159
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1121
+#if HAS_TRINAMIC
1160
 
1122
 
1161
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1123
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1162
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1124
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1311
 // @section L6470
1273
 // @section L6470
1312
 
1274
 
1313
 /**
1275
 /**
1314
- * Enable this section if you have L6470 motor drivers.
1315
- * You need to import the L6470 library into the Arduino IDE for this.
1316
- * (https://github.com/ameyer/Arduino-L6470)
1276
+ * L6470 Stepper Driver options
1277
+ *
1278
+ * The Arduino-L6470 library is required for this stepper driver.
1279
+ * https://github.com/ameyer/Arduino-L6470
1317
  */
1280
  */
1318
-
1319
-//#define HAVE_L6470DRIVER
1320
-#if ENABLED(HAVE_L6470DRIVER)
1321
-
1322
-  //#define X_IS_L6470
1323
-  //#define X2_IS_L6470
1324
-  //#define Y_IS_L6470
1325
-  //#define Y2_IS_L6470
1326
-  //#define Z_IS_L6470
1327
-  //#define Z2_IS_L6470
1328
-  //#define E0_IS_L6470
1329
-  //#define E1_IS_L6470
1330
-  //#define E2_IS_L6470
1331
-  //#define E3_IS_L6470
1332
-  //#define E4_IS_L6470
1281
+#if HAS_DRIVER(L6470)
1333
 
1282
 
1334
   #define X_MICROSTEPS      16 // number of microsteps
1283
   #define X_MICROSTEPS      16 // number of microsteps
1335
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1284
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1375
   #define E4_OVERCURRENT  2000
1324
   #define E4_OVERCURRENT  2000
1376
   #define E4_STALLCURRENT 1500
1325
   #define E4_STALLCURRENT 1500
1377
 
1326
 
1378
-#endif
1327
+#endif // L6470
1379
 
1328
 
1380
 /**
1329
 /**
1381
  * TWI/I2C BUS
1330
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/Velleman/K8400/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/Wanhao/Duplicator 6/Configuration.h 查看文件

561
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
561
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
562
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
562
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
563
 
563
 
564
+/**
565
+ * Specify Stepper Driver types
566
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
567
+ * Stepper timing options can be overridden in Configuration_adv.h
568
+ *
569
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
570
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
571
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
572
+ *          TMC5130, TMC5130_STANDALONE
573
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
574
+ */
575
+#define X_DRIVER_TYPE  A4988
576
+#define Y_DRIVER_TYPE  A4988
577
+#define Z_DRIVER_TYPE  A4988
578
+#define X2_DRIVER_TYPE A4988
579
+#define Y2_DRIVER_TYPE A4988
580
+#define Z2_DRIVER_TYPE A4988
581
+#define E0_DRIVER_TYPE A4988
582
+#define E1_DRIVER_TYPE A4988
583
+#define E2_DRIVER_TYPE A4988
584
+#define E3_DRIVER_TYPE A4988
585
+#define E4_DRIVER_TYPE A4988
586
+
564
 // Enable this feature if all enabled endstop pins are interrupt-capable.
587
 // Enable this feature if all enabled endstop pins are interrupt-capable.
565
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
588
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
566
 //#define ENDSTOP_INTERRUPTS_FEATURE
589
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/Wanhao/Duplicator 6/Configuration_adv.h 查看文件

839
 
839
 
840
 /**
840
 /**
841
  * Minimum delay after setting the stepper DIR (in ns)
841
  * Minimum delay after setting the stepper DIR (in ns)
842
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
- *   20 : Minimum for TMC2xxx drivers
844
- *  200 : Minimum for A4988 drivers
845
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
- *  650 : Minimum for DRV8825 drivers
847
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
842
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
+ *    20 : Minimum for TMC2xxx drivers
844
+ *   200 : Minimum for A4988 drivers
845
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
+ *   650 : Minimum for DRV8825 drivers
847
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
849
+ *
850
+ * Override the default value based on the driver type set in Configuration.h.
849
  */
851
  */
850
-#define MINIMUM_STEPPER_DIR_DELAY 0
852
+//#define MINIMUM_STEPPER_DIR_DELAY 650
851
 
853
 
852
 /**
854
 /**
853
  * Minimum stepper driver pulse width (in µs)
855
  * Minimum stepper driver pulse width (in µs)
857
  *   2 : Minimum for DRV8825 stepper drivers
859
  *   2 : Minimum for DRV8825 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
860
  *   3 : Minimum for TB6600 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
861
  *  30 : Minimum for TB6560 stepper drivers
862
+ *
863
+ * Override the default value based on the driver type set in Configuration.h.
860
  */
864
  */
861
-#define MINIMUM_STEPPER_PULSE 2
865
+//#define MINIMUM_STEPPER_PULSE 2
862
 
866
 
863
 /**
867
 /**
864
  * Maximum stepping rate (in Hz) the stepper driver allows
868
  * Maximum stepping rate (in Hz) the stepper driver allows
869
  *  150000 : Maximum for TB6600 stepper driver
873
  *  150000 : Maximum for TB6600 stepper driver
870
  *  130000 : Maximum for LV8729 stepper driver
874
  *  130000 : Maximum for LV8729 stepper driver
871
  *   15000 : Maximum for TB6560 stepper driver
875
  *   15000 : Maximum for TB6560 stepper driver
876
+ *
877
+ * Override the default value based on the driver type set in Configuration.h.
872
  */
878
  */
873
-#define MAXIMUM_STEPPER_RATE 250000
879
+//#define MAXIMUM_STEPPER_RATE 250000
874
 
880
 
875
 // @section temperature
881
 // @section temperature
876
 
882
 
1038
 // @section tmc
1044
 // @section tmc
1039
 
1045
 
1040
 /**
1046
 /**
1041
- * Enable this section if you have TMC26X motor drivers.
1042
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1043
- * (https://github.com/trinamic/TMC26XStepper.git)
1047
+ * TMC26X Stepper Driver options
1048
+ *
1049
+ * The TMC26XStepper library is required for this stepper driver.
1050
+ * https://github.com/trinamic/TMC26XStepper
1044
  */
1051
  */
1045
-//#define HAVE_TMC26X
1046
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1047
-  //#define X_IS_TMC26X
1048
-  //#define X2_IS_TMC26X
1049
-  //#define Y_IS_TMC26X
1050
-  //#define Y2_IS_TMC26X
1051
-  //#define Z_IS_TMC26X
1052
-  //#define Z2_IS_TMC26X
1053
-  //#define E0_IS_TMC26X
1054
-  //#define E1_IS_TMC26X
1055
-  //#define E2_IS_TMC26X
1056
-  //#define E3_IS_TMC26X
1057
-  //#define E4_IS_TMC26X
1052
+#if HAS_DRIVER(TMC26X)
1058
 
1053
 
1059
   #define X_MAX_CURRENT     1000 // in mA
1054
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_SENSE_RESISTOR    91 // in mOhms
1055
   #define X_SENSE_RESISTOR    91 // in mOhms
1100
   #define E4_SENSE_RESISTOR   91
1095
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_MICROSTEPS       16
1096
   #define E4_MICROSTEPS       16
1102
 
1097
 
1103
-#endif
1098
+#endif // TMC26X
1104
 
1099
 
1105
 // @section tmc_smart
1100
 // @section tmc_smart
1106
 
1101
 
1107
 /**
1102
 /**
1108
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1109
- *
1110
- * You'll also need the TMC2130Stepper Arduino library
1111
- * (https://github.com/teemuatlut/TMC2130Stepper).
1112
- *
1113
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1103
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1114
  * the hardware SPI interface on your board and define the required CS pins
1104
  * the hardware SPI interface on your board and define the required CS pins
1115
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1105
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1116
  * You may also use software SPI if you wish to use general purpose IO pins.
1106
  * You may also use software SPI if you wish to use general purpose IO pins.
1117
- */
1118
-//#define HAVE_TMC2130
1119
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1120
-  //#define X_IS_TMC2130
1121
-  //#define X2_IS_TMC2130
1122
-  //#define Y_IS_TMC2130
1123
-  //#define Y2_IS_TMC2130
1124
-  //#define Z_IS_TMC2130
1125
-  //#define Z2_IS_TMC2130
1126
-  //#define E0_IS_TMC2130
1127
-  //#define E1_IS_TMC2130
1128
-  //#define E2_IS_TMC2130
1129
-  //#define E3_IS_TMC2130
1130
-  //#define E4_IS_TMC2130
1131
-#endif
1132
-
1133
-/**
1134
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1135
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1107
+ *
1108
+ * The TMC2130Stepper library is required for this stepper driver.
1109
+ * https://github.com/teemuatlut/TMC2130Stepper
1110
+ *
1111
+ * To use TMC2208 stepper UART-configurable stepper drivers
1112
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1136
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1113
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1137
  * to PDN_UART without a resistor.
1114
  * to PDN_UART without a resistor.
1138
  * The drivers can also be used with hardware serial.
1115
  * The drivers can also be used with hardware serial.
1139
  *
1116
  *
1140
- * You'll also need the TMC2208Stepper Arduino library
1141
- * (https://github.com/teemuatlut/TMC2208Stepper).
1117
+ * The TMC2208Stepper library is required for this stepper driver.
1118
+ * https://github.com/teemuatlut/TMC2208Stepper
1142
  */
1119
  */
1143
-//#define HAVE_TMC2208
1144
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1145
-  //#define X_IS_TMC2208
1146
-  //#define X2_IS_TMC2208
1147
-  //#define Y_IS_TMC2208
1148
-  //#define Y2_IS_TMC2208
1149
-  //#define Z_IS_TMC2208
1150
-  //#define Z2_IS_TMC2208
1151
-  //#define E0_IS_TMC2208
1152
-  //#define E1_IS_TMC2208
1153
-  //#define E2_IS_TMC2208
1154
-  //#define E3_IS_TMC2208
1155
-  //#define E4_IS_TMC2208
1156
-#endif
1157
-
1158
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1120
+#if HAS_TRINAMIC
1159
 
1121
 
1160
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1122
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1161
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1123
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1310
 // @section L6470
1272
 // @section L6470
1311
 
1273
 
1312
 /**
1274
 /**
1313
- * Enable this section if you have L6470 motor drivers.
1314
- * You need to import the L6470 library into the Arduino IDE for this.
1315
- * (https://github.com/ameyer/Arduino-L6470)
1275
+ * L6470 Stepper Driver options
1276
+ *
1277
+ * The Arduino-L6470 library is required for this stepper driver.
1278
+ * https://github.com/ameyer/Arduino-L6470
1316
  */
1279
  */
1317
-
1318
-//#define HAVE_L6470DRIVER
1319
-#if ENABLED(HAVE_L6470DRIVER)
1320
-
1321
-  //#define X_IS_L6470
1322
-  //#define X2_IS_L6470
1323
-  //#define Y_IS_L6470
1324
-  //#define Y2_IS_L6470
1325
-  //#define Z_IS_L6470
1326
-  //#define Z2_IS_L6470
1327
-  //#define E0_IS_L6470
1328
-  //#define E1_IS_L6470
1329
-  //#define E2_IS_L6470
1330
-  //#define E3_IS_L6470
1331
-  //#define E4_IS_L6470
1280
+#if HAS_DRIVER(L6470)
1332
 
1281
 
1333
   #define X_MICROSTEPS      16 // number of microsteps
1282
   #define X_MICROSTEPS      16 // number of microsteps
1334
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1283
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1374
   #define E4_OVERCURRENT  2000
1323
   #define E4_OVERCURRENT  2000
1375
   #define E4_STALLCURRENT 1500
1324
   #define E4_STALLCURRENT 1500
1376
 
1325
 
1377
-#endif
1326
+#endif // L6470
1378
 
1327
 
1379
 /**
1328
 /**
1380
  * TWI/I2C BUS
1329
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/adafruit/ST7565/Configuration.h 查看文件

551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
551
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
552
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
553
 
553
 
554
+/**
555
+ * Specify Stepper Driver types
556
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
557
+ * Stepper timing options can be overridden in Configuration_adv.h
558
+ *
559
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
560
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
561
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
562
+ *          TMC5130, TMC5130_STANDALONE
563
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
564
+ */
565
+#define X_DRIVER_TYPE  A4988
566
+#define Y_DRIVER_TYPE  A4988
567
+#define Z_DRIVER_TYPE  A4988
568
+#define X2_DRIVER_TYPE A4988
569
+#define Y2_DRIVER_TYPE A4988
570
+#define Z2_DRIVER_TYPE A4988
571
+#define E0_DRIVER_TYPE A4988
572
+#define E1_DRIVER_TYPE A4988
573
+#define E2_DRIVER_TYPE A4988
574
+#define E3_DRIVER_TYPE A4988
575
+#define E4_DRIVER_TYPE A4988
576
+
554
 // Enable this feature if all enabled endstop pins are interrupt-capable.
577
 // Enable this feature if all enabled endstop pins are interrupt-capable.
555
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
578
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
556
 //#define ENDSTOP_INTERRUPTS_FEATURE
579
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/delta/FLSUN/auto_calibrate/Configuration_adv.h 查看文件

839
 
839
 
840
 /**
840
 /**
841
  * Minimum delay after setting the stepper DIR (in ns)
841
  * Minimum delay after setting the stepper DIR (in ns)
842
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
- *   20 : Minimum for TMC2xxx drivers
844
- *  200 : Minimum for A4988 drivers
845
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
- *  650 : Minimum for DRV8825 drivers
847
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
842
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
+ *    20 : Minimum for TMC2xxx drivers
844
+ *   200 : Minimum for A4988 drivers
845
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
+ *   650 : Minimum for DRV8825 drivers
847
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
849
+ *
850
+ * Override the default value based on the driver type set in Configuration.h.
849
  */
851
  */
850
-#define MINIMUM_STEPPER_DIR_DELAY 0
852
+//#define MINIMUM_STEPPER_DIR_DELAY 650
851
 
853
 
852
 /**
854
 /**
853
  * Minimum stepper driver pulse width (in µs)
855
  * Minimum stepper driver pulse width (in µs)
857
  *   2 : Minimum for DRV8825 stepper drivers
859
  *   2 : Minimum for DRV8825 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
860
  *   3 : Minimum for TB6600 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
861
  *  30 : Minimum for TB6560 stepper drivers
862
+ *
863
+ * Override the default value based on the driver type set in Configuration.h.
860
  */
864
  */
861
-#define MINIMUM_STEPPER_PULSE 2
865
+//#define MINIMUM_STEPPER_PULSE 2
862
 
866
 
863
 /**
867
 /**
864
  * Maximum stepping rate (in Hz) the stepper driver allows
868
  * Maximum stepping rate (in Hz) the stepper driver allows
869
  *  150000 : Maximum for TB6600 stepper driver
873
  *  150000 : Maximum for TB6600 stepper driver
870
  *  130000 : Maximum for LV8729 stepper driver
874
  *  130000 : Maximum for LV8729 stepper driver
871
  *   15000 : Maximum for TB6560 stepper driver
875
  *   15000 : Maximum for TB6560 stepper driver
876
+ *
877
+ * Override the default value based on the driver type set in Configuration.h.
872
  */
878
  */
873
-#define MAXIMUM_STEPPER_RATE 250000
879
+//#define MAXIMUM_STEPPER_RATE 250000
874
 
880
 
875
 // @section temperature
881
 // @section temperature
876
 
882
 
1038
 // @section tmc
1044
 // @section tmc
1039
 
1045
 
1040
 /**
1046
 /**
1041
- * Enable this section if you have TMC26X motor drivers.
1042
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1043
- * (https://github.com/trinamic/TMC26XStepper.git)
1047
+ * TMC26X Stepper Driver options
1048
+ *
1049
+ * The TMC26XStepper library is required for this stepper driver.
1050
+ * https://github.com/trinamic/TMC26XStepper
1044
  */
1051
  */
1045
-//#define HAVE_TMC26X
1046
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1047
-  //#define X_IS_TMC26X
1048
-  //#define X2_IS_TMC26X
1049
-  //#define Y_IS_TMC26X
1050
-  //#define Y2_IS_TMC26X
1051
-  //#define Z_IS_TMC26X
1052
-  //#define Z2_IS_TMC26X
1053
-  //#define E0_IS_TMC26X
1054
-  //#define E1_IS_TMC26X
1055
-  //#define E2_IS_TMC26X
1056
-  //#define E3_IS_TMC26X
1057
-  //#define E4_IS_TMC26X
1052
+#if HAS_DRIVER(TMC26X)
1058
 
1053
 
1059
   #define X_MAX_CURRENT     1000 // in mA
1054
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_SENSE_RESISTOR    91 // in mOhms
1055
   #define X_SENSE_RESISTOR    91 // in mOhms
1100
   #define E4_SENSE_RESISTOR   91
1095
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_MICROSTEPS       16
1096
   #define E4_MICROSTEPS       16
1102
 
1097
 
1103
-#endif
1098
+#endif // TMC26X
1104
 
1099
 
1105
 // @section tmc_smart
1100
 // @section tmc_smart
1106
 
1101
 
1107
 /**
1102
 /**
1108
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1109
- *
1110
- * You'll also need the TMC2130Stepper Arduino library
1111
- * (https://github.com/teemuatlut/TMC2130Stepper).
1112
- *
1113
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1103
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1114
  * the hardware SPI interface on your board and define the required CS pins
1104
  * the hardware SPI interface on your board and define the required CS pins
1115
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1105
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1116
  * You may also use software SPI if you wish to use general purpose IO pins.
1106
  * You may also use software SPI if you wish to use general purpose IO pins.
1117
- */
1118
-//#define HAVE_TMC2130
1119
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1120
-  //#define X_IS_TMC2130
1121
-  //#define X2_IS_TMC2130
1122
-  //#define Y_IS_TMC2130
1123
-  //#define Y2_IS_TMC2130
1124
-  //#define Z_IS_TMC2130
1125
-  //#define Z2_IS_TMC2130
1126
-  //#define E0_IS_TMC2130
1127
-  //#define E1_IS_TMC2130
1128
-  //#define E2_IS_TMC2130
1129
-  //#define E3_IS_TMC2130
1130
-  //#define E4_IS_TMC2130
1131
-#endif
1132
-
1133
-/**
1134
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1135
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1107
+ *
1108
+ * The TMC2130Stepper library is required for this stepper driver.
1109
+ * https://github.com/teemuatlut/TMC2130Stepper
1110
+ *
1111
+ * To use TMC2208 stepper UART-configurable stepper drivers
1112
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1136
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1113
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1137
  * to PDN_UART without a resistor.
1114
  * to PDN_UART without a resistor.
1138
  * The drivers can also be used with hardware serial.
1115
  * The drivers can also be used with hardware serial.
1139
  *
1116
  *
1140
- * You'll also need the TMC2208Stepper Arduino library
1141
- * (https://github.com/teemuatlut/TMC2208Stepper).
1117
+ * The TMC2208Stepper library is required for this stepper driver.
1118
+ * https://github.com/teemuatlut/TMC2208Stepper
1142
  */
1119
  */
1143
-//#define HAVE_TMC2208
1144
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1145
-  //#define X_IS_TMC2208
1146
-  //#define X2_IS_TMC2208
1147
-  //#define Y_IS_TMC2208
1148
-  //#define Y2_IS_TMC2208
1149
-  //#define Z_IS_TMC2208
1150
-  //#define Z2_IS_TMC2208
1151
-  //#define E0_IS_TMC2208
1152
-  //#define E1_IS_TMC2208
1153
-  //#define E2_IS_TMC2208
1154
-  //#define E3_IS_TMC2208
1155
-  //#define E4_IS_TMC2208
1156
-#endif
1157
-
1158
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1120
+#if HAS_TRINAMIC
1159
 
1121
 
1160
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1122
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1161
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1123
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1310
 // @section L6470
1272
 // @section L6470
1311
 
1273
 
1312
 /**
1274
 /**
1313
- * Enable this section if you have L6470 motor drivers.
1314
- * You need to import the L6470 library into the Arduino IDE for this.
1315
- * (https://github.com/ameyer/Arduino-L6470)
1275
+ * L6470 Stepper Driver options
1276
+ *
1277
+ * The Arduino-L6470 library is required for this stepper driver.
1278
+ * https://github.com/ameyer/Arduino-L6470
1316
  */
1279
  */
1317
-
1318
-//#define HAVE_L6470DRIVER
1319
-#if ENABLED(HAVE_L6470DRIVER)
1320
-
1321
-  //#define X_IS_L6470
1322
-  //#define X2_IS_L6470
1323
-  //#define Y_IS_L6470
1324
-  //#define Y2_IS_L6470
1325
-  //#define Z_IS_L6470
1326
-  //#define Z2_IS_L6470
1327
-  //#define E0_IS_L6470
1328
-  //#define E1_IS_L6470
1329
-  //#define E2_IS_L6470
1330
-  //#define E3_IS_L6470
1331
-  //#define E4_IS_L6470
1280
+#if HAS_DRIVER(L6470)
1332
 
1281
 
1333
   #define X_MICROSTEPS      16 // number of microsteps
1282
   #define X_MICROSTEPS      16 // number of microsteps
1334
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1283
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1374
   #define E4_OVERCURRENT  2000
1323
   #define E4_OVERCURRENT  2000
1375
   #define E4_STALLCURRENT 1500
1324
   #define E4_STALLCURRENT 1500
1376
 
1325
 
1377
-#endif
1326
+#endif // L6470
1378
 
1327
 
1379
 /**
1328
 /**
1380
  * TWI/I2C BUS
1329
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/delta/FLSUN/kossel/Configuration_adv.h 查看文件

839
 
839
 
840
 /**
840
 /**
841
  * Minimum delay after setting the stepper DIR (in ns)
841
  * Minimum delay after setting the stepper DIR (in ns)
842
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
- *   20 : Minimum for TMC2xxx drivers
844
- *  200 : Minimum for A4988 drivers
845
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
- *  650 : Minimum for DRV8825 drivers
847
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
842
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
+ *    20 : Minimum for TMC2xxx drivers
844
+ *   200 : Minimum for A4988 drivers
845
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
+ *   650 : Minimum for DRV8825 drivers
847
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
849
+ *
850
+ * Override the default value based on the driver type set in Configuration.h.
849
  */
851
  */
850
-#define MINIMUM_STEPPER_DIR_DELAY 0
852
+//#define MINIMUM_STEPPER_DIR_DELAY 650
851
 
853
 
852
 /**
854
 /**
853
  * Minimum stepper driver pulse width (in µs)
855
  * Minimum stepper driver pulse width (in µs)
857
  *   2 : Minimum for DRV8825 stepper drivers
859
  *   2 : Minimum for DRV8825 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
860
  *   3 : Minimum for TB6600 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
861
  *  30 : Minimum for TB6560 stepper drivers
862
+ *
863
+ * Override the default value based on the driver type set in Configuration.h.
860
  */
864
  */
861
-#define MINIMUM_STEPPER_PULSE 2
865
+//#define MINIMUM_STEPPER_PULSE 2
862
 
866
 
863
 /**
867
 /**
864
  * Maximum stepping rate (in Hz) the stepper driver allows
868
  * Maximum stepping rate (in Hz) the stepper driver allows
869
  *  150000 : Maximum for TB6600 stepper driver
873
  *  150000 : Maximum for TB6600 stepper driver
870
  *  130000 : Maximum for LV8729 stepper driver
874
  *  130000 : Maximum for LV8729 stepper driver
871
  *   15000 : Maximum for TB6560 stepper driver
875
  *   15000 : Maximum for TB6560 stepper driver
876
+ *
877
+ * Override the default value based on the driver type set in Configuration.h.
872
  */
878
  */
873
-#define MAXIMUM_STEPPER_RATE 250000
879
+//#define MAXIMUM_STEPPER_RATE 250000
874
 
880
 
875
 // @section temperature
881
 // @section temperature
876
 
882
 
1038
 // @section tmc
1044
 // @section tmc
1039
 
1045
 
1040
 /**
1046
 /**
1041
- * Enable this section if you have TMC26X motor drivers.
1042
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1043
- * (https://github.com/trinamic/TMC26XStepper.git)
1047
+ * TMC26X Stepper Driver options
1048
+ *
1049
+ * The TMC26XStepper library is required for this stepper driver.
1050
+ * https://github.com/trinamic/TMC26XStepper
1044
  */
1051
  */
1045
-//#define HAVE_TMC26X
1046
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1047
-  //#define X_IS_TMC26X
1048
-  //#define X2_IS_TMC26X
1049
-  //#define Y_IS_TMC26X
1050
-  //#define Y2_IS_TMC26X
1051
-  //#define Z_IS_TMC26X
1052
-  //#define Z2_IS_TMC26X
1053
-  //#define E0_IS_TMC26X
1054
-  //#define E1_IS_TMC26X
1055
-  //#define E2_IS_TMC26X
1056
-  //#define E3_IS_TMC26X
1057
-  //#define E4_IS_TMC26X
1052
+#if HAS_DRIVER(TMC26X)
1058
 
1053
 
1059
   #define X_MAX_CURRENT     1000 // in mA
1054
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_SENSE_RESISTOR    91 // in mOhms
1055
   #define X_SENSE_RESISTOR    91 // in mOhms
1100
   #define E4_SENSE_RESISTOR   91
1095
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_MICROSTEPS       16
1096
   #define E4_MICROSTEPS       16
1102
 
1097
 
1103
-#endif
1098
+#endif // TMC26X
1104
 
1099
 
1105
 // @section tmc_smart
1100
 // @section tmc_smart
1106
 
1101
 
1107
 /**
1102
 /**
1108
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1109
- *
1110
- * You'll also need the TMC2130Stepper Arduino library
1111
- * (https://github.com/teemuatlut/TMC2130Stepper).
1112
- *
1113
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1103
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1114
  * the hardware SPI interface on your board and define the required CS pins
1104
  * the hardware SPI interface on your board and define the required CS pins
1115
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1105
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1116
  * You may also use software SPI if you wish to use general purpose IO pins.
1106
  * You may also use software SPI if you wish to use general purpose IO pins.
1117
- */
1118
-//#define HAVE_TMC2130
1119
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1120
-  //#define X_IS_TMC2130
1121
-  //#define X2_IS_TMC2130
1122
-  //#define Y_IS_TMC2130
1123
-  //#define Y2_IS_TMC2130
1124
-  //#define Z_IS_TMC2130
1125
-  //#define Z2_IS_TMC2130
1126
-  //#define E0_IS_TMC2130
1127
-  //#define E1_IS_TMC2130
1128
-  //#define E2_IS_TMC2130
1129
-  //#define E3_IS_TMC2130
1130
-  //#define E4_IS_TMC2130
1131
-#endif
1132
-
1133
-/**
1134
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1135
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1107
+ *
1108
+ * The TMC2130Stepper library is required for this stepper driver.
1109
+ * https://github.com/teemuatlut/TMC2130Stepper
1110
+ *
1111
+ * To use TMC2208 stepper UART-configurable stepper drivers
1112
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1136
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1113
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1137
  * to PDN_UART without a resistor.
1114
  * to PDN_UART without a resistor.
1138
  * The drivers can also be used with hardware serial.
1115
  * The drivers can also be used with hardware serial.
1139
  *
1116
  *
1140
- * You'll also need the TMC2208Stepper Arduino library
1141
- * (https://github.com/teemuatlut/TMC2208Stepper).
1117
+ * The TMC2208Stepper library is required for this stepper driver.
1118
+ * https://github.com/teemuatlut/TMC2208Stepper
1142
  */
1119
  */
1143
-//#define HAVE_TMC2208
1144
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1145
-  //#define X_IS_TMC2208
1146
-  //#define X2_IS_TMC2208
1147
-  //#define Y_IS_TMC2208
1148
-  //#define Y2_IS_TMC2208
1149
-  //#define Z_IS_TMC2208
1150
-  //#define Z2_IS_TMC2208
1151
-  //#define E0_IS_TMC2208
1152
-  //#define E1_IS_TMC2208
1153
-  //#define E2_IS_TMC2208
1154
-  //#define E3_IS_TMC2208
1155
-  //#define E4_IS_TMC2208
1156
-#endif
1157
-
1158
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1120
+#if HAS_TRINAMIC
1159
 
1121
 
1160
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1122
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1161
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1123
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1310
 // @section L6470
1272
 // @section L6470
1311
 
1273
 
1312
 /**
1274
 /**
1313
- * Enable this section if you have L6470 motor drivers.
1314
- * You need to import the L6470 library into the Arduino IDE for this.
1315
- * (https://github.com/ameyer/Arduino-L6470)
1275
+ * L6470 Stepper Driver options
1276
+ *
1277
+ * The Arduino-L6470 library is required for this stepper driver.
1278
+ * https://github.com/ameyer/Arduino-L6470
1316
  */
1279
  */
1317
-
1318
-//#define HAVE_L6470DRIVER
1319
-#if ENABLED(HAVE_L6470DRIVER)
1320
-
1321
-  //#define X_IS_L6470
1322
-  //#define X2_IS_L6470
1323
-  //#define Y_IS_L6470
1324
-  //#define Y2_IS_L6470
1325
-  //#define Z_IS_L6470
1326
-  //#define Z2_IS_L6470
1327
-  //#define E0_IS_L6470
1328
-  //#define E1_IS_L6470
1329
-  //#define E2_IS_L6470
1330
-  //#define E3_IS_L6470
1331
-  //#define E4_IS_L6470
1280
+#if HAS_DRIVER(L6470)
1332
 
1281
 
1333
   #define X_MICROSTEPS      16 // number of microsteps
1282
   #define X_MICROSTEPS      16 // number of microsteps
1334
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1283
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1374
   #define E4_OVERCURRENT  2000
1323
   #define E4_OVERCURRENT  2000
1375
   #define E4_STALLCURRENT 1500
1324
   #define E4_STALLCURRENT 1500
1376
 
1325
 
1377
-#endif
1326
+#endif // L6470
1378
 
1327
 
1379
 /**
1328
 /**
1380
  * TWI/I2C BUS
1329
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/delta/FLSUN/kossel_mini/Configuration.h 查看文件

627
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
627
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
628
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
628
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
629
 
629
 
630
+/**
631
+ * Specify Stepper Driver types
632
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
633
+ * Stepper timing options can be overridden in Configuration_adv.h
634
+ *
635
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
636
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
637
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
638
+ *          TMC5130, TMC5130_STANDALONE
639
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
640
+ */
641
+#define X_DRIVER_TYPE  A4988
642
+#define Y_DRIVER_TYPE  A4988
643
+#define Z_DRIVER_TYPE  A4988
644
+#define X2_DRIVER_TYPE A4988
645
+#define Y2_DRIVER_TYPE A4988
646
+#define Z2_DRIVER_TYPE A4988
647
+#define E0_DRIVER_TYPE A4988
648
+#define E1_DRIVER_TYPE A4988
649
+#define E2_DRIVER_TYPE A4988
650
+#define E3_DRIVER_TYPE A4988
651
+#define E4_DRIVER_TYPE A4988
652
+
630
 // Enable this feature if all enabled endstop pins are interrupt-capable.
653
 // Enable this feature if all enabled endstop pins are interrupt-capable.
631
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
654
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
632
 //#define ENDSTOP_INTERRUPTS_FEATURE
655
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/delta/FLSUN/kossel_mini/Configuration_adv.h 查看文件

839
 
839
 
840
 /**
840
 /**
841
  * Minimum delay after setting the stepper DIR (in ns)
841
  * Minimum delay after setting the stepper DIR (in ns)
842
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
- *   20 : Minimum for TMC2xxx drivers
844
- *  200 : Minimum for A4988 drivers
845
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
- *  650 : Minimum for DRV8825 drivers
847
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
842
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
+ *    20 : Minimum for TMC2xxx drivers
844
+ *   200 : Minimum for A4988 drivers
845
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
+ *   650 : Minimum for DRV8825 drivers
847
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
849
+ *
850
+ * Override the default value based on the driver type set in Configuration.h.
849
  */
851
  */
850
-#define MINIMUM_STEPPER_DIR_DELAY 0
852
+//#define MINIMUM_STEPPER_DIR_DELAY 650
851
 
853
 
852
 /**
854
 /**
853
  * Minimum stepper driver pulse width (in µs)
855
  * Minimum stepper driver pulse width (in µs)
857
  *   2 : Minimum for DRV8825 stepper drivers
859
  *   2 : Minimum for DRV8825 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
860
  *   3 : Minimum for TB6600 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
861
  *  30 : Minimum for TB6560 stepper drivers
862
+ *
863
+ * Override the default value based on the driver type set in Configuration.h.
860
  */
864
  */
861
-#define MINIMUM_STEPPER_PULSE 2
865
+//#define MINIMUM_STEPPER_PULSE 2
862
 
866
 
863
 /**
867
 /**
864
  * Maximum stepping rate (in Hz) the stepper driver allows
868
  * Maximum stepping rate (in Hz) the stepper driver allows
869
  *  150000 : Maximum for TB6600 stepper driver
873
  *  150000 : Maximum for TB6600 stepper driver
870
  *  130000 : Maximum for LV8729 stepper driver
874
  *  130000 : Maximum for LV8729 stepper driver
871
  *   15000 : Maximum for TB6560 stepper driver
875
  *   15000 : Maximum for TB6560 stepper driver
876
+ *
877
+ * Override the default value based on the driver type set in Configuration.h.
872
  */
878
  */
873
-#define MAXIMUM_STEPPER_RATE 250000
879
+//#define MAXIMUM_STEPPER_RATE 250000
874
 
880
 
875
 // @section temperature
881
 // @section temperature
876
 
882
 
1038
 // @section tmc
1044
 // @section tmc
1039
 
1045
 
1040
 /**
1046
 /**
1041
- * Enable this section if you have TMC26X motor drivers.
1042
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1043
- * (https://github.com/trinamic/TMC26XStepper.git)
1047
+ * TMC26X Stepper Driver options
1048
+ *
1049
+ * The TMC26XStepper library is required for this stepper driver.
1050
+ * https://github.com/trinamic/TMC26XStepper
1044
  */
1051
  */
1045
-//#define HAVE_TMC26X
1046
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1047
-  //#define X_IS_TMC26X
1048
-  //#define X2_IS_TMC26X
1049
-  //#define Y_IS_TMC26X
1050
-  //#define Y2_IS_TMC26X
1051
-  //#define Z_IS_TMC26X
1052
-  //#define Z2_IS_TMC26X
1053
-  //#define E0_IS_TMC26X
1054
-  //#define E1_IS_TMC26X
1055
-  //#define E2_IS_TMC26X
1056
-  //#define E3_IS_TMC26X
1057
-  //#define E4_IS_TMC26X
1052
+#if HAS_DRIVER(TMC26X)
1058
 
1053
 
1059
   #define X_MAX_CURRENT     1000 // in mA
1054
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_SENSE_RESISTOR    91 // in mOhms
1055
   #define X_SENSE_RESISTOR    91 // in mOhms
1100
   #define E4_SENSE_RESISTOR   91
1095
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_MICROSTEPS       16
1096
   #define E4_MICROSTEPS       16
1102
 
1097
 
1103
-#endif
1098
+#endif // TMC26X
1104
 
1099
 
1105
 // @section tmc_smart
1100
 // @section tmc_smart
1106
 
1101
 
1107
 /**
1102
 /**
1108
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1109
- *
1110
- * You'll also need the TMC2130Stepper Arduino library
1111
- * (https://github.com/teemuatlut/TMC2130Stepper).
1112
- *
1113
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1103
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1114
  * the hardware SPI interface on your board and define the required CS pins
1104
  * the hardware SPI interface on your board and define the required CS pins
1115
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1105
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1116
  * You may also use software SPI if you wish to use general purpose IO pins.
1106
  * You may also use software SPI if you wish to use general purpose IO pins.
1117
- */
1118
-//#define HAVE_TMC2130
1119
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1120
-  //#define X_IS_TMC2130
1121
-  //#define X2_IS_TMC2130
1122
-  //#define Y_IS_TMC2130
1123
-  //#define Y2_IS_TMC2130
1124
-  //#define Z_IS_TMC2130
1125
-  //#define Z2_IS_TMC2130
1126
-  //#define E0_IS_TMC2130
1127
-  //#define E1_IS_TMC2130
1128
-  //#define E2_IS_TMC2130
1129
-  //#define E3_IS_TMC2130
1130
-  //#define E4_IS_TMC2130
1131
-#endif
1132
-
1133
-/**
1134
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1135
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1107
+ *
1108
+ * The TMC2130Stepper library is required for this stepper driver.
1109
+ * https://github.com/teemuatlut/TMC2130Stepper
1110
+ *
1111
+ * To use TMC2208 stepper UART-configurable stepper drivers
1112
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1136
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1113
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1137
  * to PDN_UART without a resistor.
1114
  * to PDN_UART without a resistor.
1138
  * The drivers can also be used with hardware serial.
1115
  * The drivers can also be used with hardware serial.
1139
  *
1116
  *
1140
- * You'll also need the TMC2208Stepper Arduino library
1141
- * (https://github.com/teemuatlut/TMC2208Stepper).
1117
+ * The TMC2208Stepper library is required for this stepper driver.
1118
+ * https://github.com/teemuatlut/TMC2208Stepper
1142
  */
1119
  */
1143
-//#define HAVE_TMC2208
1144
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1145
-  //#define X_IS_TMC2208
1146
-  //#define X2_IS_TMC2208
1147
-  //#define Y_IS_TMC2208
1148
-  //#define Y2_IS_TMC2208
1149
-  //#define Z_IS_TMC2208
1150
-  //#define Z2_IS_TMC2208
1151
-  //#define E0_IS_TMC2208
1152
-  //#define E1_IS_TMC2208
1153
-  //#define E2_IS_TMC2208
1154
-  //#define E3_IS_TMC2208
1155
-  //#define E4_IS_TMC2208
1156
-#endif
1157
-
1158
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1120
+#if HAS_TRINAMIC
1159
 
1121
 
1160
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1122
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1161
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1123
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1310
 // @section L6470
1272
 // @section L6470
1311
 
1273
 
1312
 /**
1274
 /**
1313
- * Enable this section if you have L6470 motor drivers.
1314
- * You need to import the L6470 library into the Arduino IDE for this.
1315
- * (https://github.com/ameyer/Arduino-L6470)
1275
+ * L6470 Stepper Driver options
1276
+ *
1277
+ * The Arduino-L6470 library is required for this stepper driver.
1278
+ * https://github.com/ameyer/Arduino-L6470
1316
  */
1279
  */
1317
-
1318
-//#define HAVE_L6470DRIVER
1319
-#if ENABLED(HAVE_L6470DRIVER)
1320
-
1321
-  //#define X_IS_L6470
1322
-  //#define X2_IS_L6470
1323
-  //#define Y_IS_L6470
1324
-  //#define Y2_IS_L6470
1325
-  //#define Z_IS_L6470
1326
-  //#define Z2_IS_L6470
1327
-  //#define E0_IS_L6470
1328
-  //#define E1_IS_L6470
1329
-  //#define E2_IS_L6470
1330
-  //#define E3_IS_L6470
1331
-  //#define E4_IS_L6470
1280
+#if HAS_DRIVER(L6470)
1332
 
1281
 
1333
   #define X_MICROSTEPS      16 // number of microsteps
1282
   #define X_MICROSTEPS      16 // number of microsteps
1334
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1283
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1374
   #define E4_OVERCURRENT  2000
1323
   #define E4_OVERCURRENT  2000
1375
   #define E4_STALLCURRENT 1500
1324
   #define E4_STALLCURRENT 1500
1376
 
1325
 
1377
-#endif
1326
+#endif // L6470
1378
 
1327
 
1379
 /**
1328
 /**
1380
  * TWI/I2C BUS
1329
  * TWI/I2C BUS

+ 37
- 88
Marlin/src/config/examples/delta/generic/Configuration_adv.h 查看文件

839
 
839
 
840
 /**
840
 /**
841
  * Minimum delay after setting the stepper DIR (in ns)
841
  * Minimum delay after setting the stepper DIR (in ns)
842
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
- *   20 : Minimum for TMC2xxx drivers
844
- *  200 : Minimum for A4988 drivers
845
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
- *  650 : Minimum for DRV8825 drivers
847
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
842
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
+ *    20 : Minimum for TMC2xxx drivers
844
+ *   200 : Minimum for A4988 drivers
845
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
+ *   650 : Minimum for DRV8825 drivers
847
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
849
+ *
850
+ * Override the default value based on the driver type set in Configuration.h.
849
  */
851
  */
850
-#define MINIMUM_STEPPER_DIR_DELAY 0
852
+//#define MINIMUM_STEPPER_DIR_DELAY 650
851
 
853
 
852
 /**
854
 /**
853
  * Minimum stepper driver pulse width (in µs)
855
  * Minimum stepper driver pulse width (in µs)
857
  *   2 : Minimum for DRV8825 stepper drivers
859
  *   2 : Minimum for DRV8825 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
860
  *   3 : Minimum for TB6600 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
861
  *  30 : Minimum for TB6560 stepper drivers
862
+ *
863
+ * Override the default value based on the driver type set in Configuration.h.
860
  */
864
  */
861
-#define MINIMUM_STEPPER_PULSE 2
865
+//#define MINIMUM_STEPPER_PULSE 2
862
 
866
 
863
 /**
867
 /**
864
  * Maximum stepping rate (in Hz) the stepper driver allows
868
  * Maximum stepping rate (in Hz) the stepper driver allows
869
  *  150000 : Maximum for TB6600 stepper driver
873
  *  150000 : Maximum for TB6600 stepper driver
870
  *  130000 : Maximum for LV8729 stepper driver
874
  *  130000 : Maximum for LV8729 stepper driver
871
  *   15000 : Maximum for TB6560 stepper driver
875
  *   15000 : Maximum for TB6560 stepper driver
876
+ *
877
+ * Override the default value based on the driver type set in Configuration.h.
872
  */
878
  */
873
-#define MAXIMUM_STEPPER_RATE 250000
879
+//#define MAXIMUM_STEPPER_RATE 250000
874
 
880
 
875
 // @section temperature
881
 // @section temperature
876
 
882
 
1038
 // @section tmc
1044
 // @section tmc
1039
 
1045
 
1040
 /**
1046
 /**
1041
- * Enable this section if you have TMC26X motor drivers.
1042
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1043
- * (https://github.com/trinamic/TMC26XStepper.git)
1047
+ * TMC26X Stepper Driver options
1048
+ *
1049
+ * The TMC26XStepper library is required for this stepper driver.
1050
+ * https://github.com/trinamic/TMC26XStepper
1044
  */
1051
  */
1045
-//#define HAVE_TMC26X
1046
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1047
-  //#define X_IS_TMC26X
1048
-  //#define X2_IS_TMC26X
1049
-  //#define Y_IS_TMC26X
1050
-  //#define Y2_IS_TMC26X
1051
-  //#define Z_IS_TMC26X
1052
-  //#define Z2_IS_TMC26X
1053
-  //#define E0_IS_TMC26X
1054
-  //#define E1_IS_TMC26X
1055
-  //#define E2_IS_TMC26X
1056
-  //#define E3_IS_TMC26X
1057
-  //#define E4_IS_TMC26X
1052
+#if HAS_DRIVER(TMC26X)
1058
 
1053
 
1059
   #define X_MAX_CURRENT     1000 // in mA
1054
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_SENSE_RESISTOR    91 // in mOhms
1055
   #define X_SENSE_RESISTOR    91 // in mOhms
1100
   #define E4_SENSE_RESISTOR   91
1095
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_MICROSTEPS       16
1096
   #define E4_MICROSTEPS       16
1102
 
1097
 
1103
-#endif
1098
+#endif // TMC26X
1104
 
1099
 
1105
 // @section tmc_smart
1100
 // @section tmc_smart
1106
 
1101
 
1107
 /**
1102
 /**
1108
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1109
- *
1110
- * You'll also need the TMC2130Stepper Arduino library
1111
- * (https://github.com/teemuatlut/TMC2130Stepper).
1112
- *
1113
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1103
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1114
  * the hardware SPI interface on your board and define the required CS pins
1104
  * the hardware SPI interface on your board and define the required CS pins
1115
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1105
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1116
  * You may also use software SPI if you wish to use general purpose IO pins.
1106
  * You may also use software SPI if you wish to use general purpose IO pins.
1117
- */
1118
-//#define HAVE_TMC2130
1119
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1120
-  //#define X_IS_TMC2130
1121
-  //#define X2_IS_TMC2130
1122
-  //#define Y_IS_TMC2130
1123
-  //#define Y2_IS_TMC2130
1124
-  //#define Z_IS_TMC2130
1125
-  //#define Z2_IS_TMC2130
1126
-  //#define E0_IS_TMC2130
1127
-  //#define E1_IS_TMC2130
1128
-  //#define E2_IS_TMC2130
1129
-  //#define E3_IS_TMC2130
1130
-  //#define E4_IS_TMC2130
1131
-#endif
1132
-
1133
-/**
1134
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1135
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1107
+ *
1108
+ * The TMC2130Stepper library is required for this stepper driver.
1109
+ * https://github.com/teemuatlut/TMC2130Stepper
1110
+ *
1111
+ * To use TMC2208 stepper UART-configurable stepper drivers
1112
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1136
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1113
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1137
  * to PDN_UART without a resistor.
1114
  * to PDN_UART without a resistor.
1138
  * The drivers can also be used with hardware serial.
1115
  * The drivers can also be used with hardware serial.
1139
  *
1116
  *
1140
- * You'll also need the TMC2208Stepper Arduino library
1141
- * (https://github.com/teemuatlut/TMC2208Stepper).
1117
+ * The TMC2208Stepper library is required for this stepper driver.
1118
+ * https://github.com/teemuatlut/TMC2208Stepper
1142
  */
1119
  */
1143
-//#define HAVE_TMC2208
1144
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1145
-  //#define X_IS_TMC2208
1146
-  //#define X2_IS_TMC2208
1147
-  //#define Y_IS_TMC2208
1148
-  //#define Y2_IS_TMC2208
1149
-  //#define Z_IS_TMC2208
1150
-  //#define Z2_IS_TMC2208
1151
-  //#define E0_IS_TMC2208
1152
-  //#define E1_IS_TMC2208
1153
-  //#define E2_IS_TMC2208
1154
-  //#define E3_IS_TMC2208
1155
-  //#define E4_IS_TMC2208
1156
-#endif
1157
-
1158
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1120
+#if HAS_TRINAMIC
1159
 
1121
 
1160
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1122
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1161
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1123
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1310
 // @section L6470
1272
 // @section L6470
1311
 
1273
 
1312
 /**
1274
 /**
1313
- * Enable this section if you have L6470 motor drivers.
1314
- * You need to import the L6470 library into the Arduino IDE for this.
1315
- * (https://github.com/ameyer/Arduino-L6470)
1275
+ * L6470 Stepper Driver options
1276
+ *
1277
+ * The Arduino-L6470 library is required for this stepper driver.
1278
+ * https://github.com/ameyer/Arduino-L6470
1316
  */
1279
  */
1317
-
1318
-//#define HAVE_L6470DRIVER
1319
-#if ENABLED(HAVE_L6470DRIVER)
1320
-
1321
-  //#define X_IS_L6470
1322
-  //#define X2_IS_L6470
1323
-  //#define Y_IS_L6470
1324
-  //#define Y2_IS_L6470
1325
-  //#define Z_IS_L6470
1326
-  //#define Z2_IS_L6470
1327
-  //#define E0_IS_L6470
1328
-  //#define E1_IS_L6470
1329
-  //#define E2_IS_L6470
1330
-  //#define E3_IS_L6470
1331
-  //#define E4_IS_L6470
1280
+#if HAS_DRIVER(L6470)
1332
 
1281
 
1333
   #define X_MICROSTEPS      16 // number of microsteps
1282
   #define X_MICROSTEPS      16 // number of microsteps
1334
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1283
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1374
   #define E4_OVERCURRENT  2000
1323
   #define E4_OVERCURRENT  2000
1375
   #define E4_STALLCURRENT 1500
1324
   #define E4_STALLCURRENT 1500
1376
 
1325
 
1377
-#endif
1326
+#endif // L6470
1378
 
1327
 
1379
 /**
1328
 /**
1380
  * TWI/I2C BUS
1329
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/delta/kossel_mini/Configuration.h 查看文件

617
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
617
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
618
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
618
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
619
 
619
 
620
+/**
621
+ * Specify Stepper Driver types
622
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
623
+ * Stepper timing options can be overridden in Configuration_adv.h
624
+ *
625
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
626
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
627
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
628
+ *          TMC5130, TMC5130_STANDALONE
629
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
630
+ */
631
+#define X_DRIVER_TYPE  A4988
632
+#define Y_DRIVER_TYPE  A4988
633
+#define Z_DRIVER_TYPE  A4988
634
+#define X2_DRIVER_TYPE A4988
635
+#define Y2_DRIVER_TYPE A4988
636
+#define Z2_DRIVER_TYPE A4988
637
+#define E0_DRIVER_TYPE A4988
638
+#define E1_DRIVER_TYPE A4988
639
+#define E2_DRIVER_TYPE A4988
640
+#define E3_DRIVER_TYPE A4988
641
+#define E4_DRIVER_TYPE A4988
642
+
620
 // Enable this feature if all enabled endstop pins are interrupt-capable.
643
 // Enable this feature if all enabled endstop pins are interrupt-capable.
621
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
644
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
622
 //#define ENDSTOP_INTERRUPTS_FEATURE
645
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/delta/kossel_mini/Configuration_adv.h 查看文件

839
 
839
 
840
 /**
840
 /**
841
  * Minimum delay after setting the stepper DIR (in ns)
841
  * Minimum delay after setting the stepper DIR (in ns)
842
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
- *   20 : Minimum for TMC2xxx drivers
844
- *  200 : Minimum for A4988 drivers
845
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
- *  650 : Minimum for DRV8825 drivers
847
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
842
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
+ *    20 : Minimum for TMC2xxx drivers
844
+ *   200 : Minimum for A4988 drivers
845
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
+ *   650 : Minimum for DRV8825 drivers
847
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
849
+ *
850
+ * Override the default value based on the driver type set in Configuration.h.
849
  */
851
  */
850
-#define MINIMUM_STEPPER_DIR_DELAY 0
852
+//#define MINIMUM_STEPPER_DIR_DELAY 650
851
 
853
 
852
 /**
854
 /**
853
  * Minimum stepper driver pulse width (in µs)
855
  * Minimum stepper driver pulse width (in µs)
857
  *   2 : Minimum for DRV8825 stepper drivers
859
  *   2 : Minimum for DRV8825 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
860
  *   3 : Minimum for TB6600 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
861
  *  30 : Minimum for TB6560 stepper drivers
862
+ *
863
+ * Override the default value based on the driver type set in Configuration.h.
860
  */
864
  */
861
-#define MINIMUM_STEPPER_PULSE 2
865
+//#define MINIMUM_STEPPER_PULSE 2
862
 
866
 
863
 /**
867
 /**
864
  * Maximum stepping rate (in Hz) the stepper driver allows
868
  * Maximum stepping rate (in Hz) the stepper driver allows
869
  *  150000 : Maximum for TB6600 stepper driver
873
  *  150000 : Maximum for TB6600 stepper driver
870
  *  130000 : Maximum for LV8729 stepper driver
874
  *  130000 : Maximum for LV8729 stepper driver
871
  *   15000 : Maximum for TB6560 stepper driver
875
  *   15000 : Maximum for TB6560 stepper driver
876
+ *
877
+ * Override the default value based on the driver type set in Configuration.h.
872
  */
878
  */
873
-#define MAXIMUM_STEPPER_RATE 250000
879
+//#define MAXIMUM_STEPPER_RATE 250000
874
 
880
 
875
 // @section temperature
881
 // @section temperature
876
 
882
 
1038
 // @section tmc
1044
 // @section tmc
1039
 
1045
 
1040
 /**
1046
 /**
1041
- * Enable this section if you have TMC26X motor drivers.
1042
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1043
- * (https://github.com/trinamic/TMC26XStepper.git)
1047
+ * TMC26X Stepper Driver options
1048
+ *
1049
+ * The TMC26XStepper library is required for this stepper driver.
1050
+ * https://github.com/trinamic/TMC26XStepper
1044
  */
1051
  */
1045
-//#define HAVE_TMC26X
1046
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1047
-  //#define X_IS_TMC26X
1048
-  //#define X2_IS_TMC26X
1049
-  //#define Y_IS_TMC26X
1050
-  //#define Y2_IS_TMC26X
1051
-  //#define Z_IS_TMC26X
1052
-  //#define Z2_IS_TMC26X
1053
-  //#define E0_IS_TMC26X
1054
-  //#define E1_IS_TMC26X
1055
-  //#define E2_IS_TMC26X
1056
-  //#define E3_IS_TMC26X
1057
-  //#define E4_IS_TMC26X
1052
+#if HAS_DRIVER(TMC26X)
1058
 
1053
 
1059
   #define X_MAX_CURRENT     1000 // in mA
1054
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_SENSE_RESISTOR    91 // in mOhms
1055
   #define X_SENSE_RESISTOR    91 // in mOhms
1100
   #define E4_SENSE_RESISTOR   91
1095
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_MICROSTEPS       16
1096
   #define E4_MICROSTEPS       16
1102
 
1097
 
1103
-#endif
1098
+#endif // TMC26X
1104
 
1099
 
1105
 // @section tmc_smart
1100
 // @section tmc_smart
1106
 
1101
 
1107
 /**
1102
 /**
1108
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1109
- *
1110
- * You'll also need the TMC2130Stepper Arduino library
1111
- * (https://github.com/teemuatlut/TMC2130Stepper).
1112
- *
1113
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1103
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1114
  * the hardware SPI interface on your board and define the required CS pins
1104
  * the hardware SPI interface on your board and define the required CS pins
1115
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1105
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1116
  * You may also use software SPI if you wish to use general purpose IO pins.
1106
  * You may also use software SPI if you wish to use general purpose IO pins.
1117
- */
1118
-//#define HAVE_TMC2130
1119
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1120
-  //#define X_IS_TMC2130
1121
-  //#define X2_IS_TMC2130
1122
-  //#define Y_IS_TMC2130
1123
-  //#define Y2_IS_TMC2130
1124
-  //#define Z_IS_TMC2130
1125
-  //#define Z2_IS_TMC2130
1126
-  //#define E0_IS_TMC2130
1127
-  //#define E1_IS_TMC2130
1128
-  //#define E2_IS_TMC2130
1129
-  //#define E3_IS_TMC2130
1130
-  //#define E4_IS_TMC2130
1131
-#endif
1132
-
1133
-/**
1134
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1135
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1107
+ *
1108
+ * The TMC2130Stepper library is required for this stepper driver.
1109
+ * https://github.com/teemuatlut/TMC2130Stepper
1110
+ *
1111
+ * To use TMC2208 stepper UART-configurable stepper drivers
1112
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1136
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1113
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1137
  * to PDN_UART without a resistor.
1114
  * to PDN_UART without a resistor.
1138
  * The drivers can also be used with hardware serial.
1115
  * The drivers can also be used with hardware serial.
1139
  *
1116
  *
1140
- * You'll also need the TMC2208Stepper Arduino library
1141
- * (https://github.com/teemuatlut/TMC2208Stepper).
1117
+ * The TMC2208Stepper library is required for this stepper driver.
1118
+ * https://github.com/teemuatlut/TMC2208Stepper
1142
  */
1119
  */
1143
-//#define HAVE_TMC2208
1144
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1145
-  //#define X_IS_TMC2208
1146
-  //#define X2_IS_TMC2208
1147
-  //#define Y_IS_TMC2208
1148
-  //#define Y2_IS_TMC2208
1149
-  //#define Z_IS_TMC2208
1150
-  //#define Z2_IS_TMC2208
1151
-  //#define E0_IS_TMC2208
1152
-  //#define E1_IS_TMC2208
1153
-  //#define E2_IS_TMC2208
1154
-  //#define E3_IS_TMC2208
1155
-  //#define E4_IS_TMC2208
1156
-#endif
1157
-
1158
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1120
+#if HAS_TRINAMIC
1159
 
1121
 
1160
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1122
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1161
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1123
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1310
 // @section L6470
1272
 // @section L6470
1311
 
1273
 
1312
 /**
1274
 /**
1313
- * Enable this section if you have L6470 motor drivers.
1314
- * You need to import the L6470 library into the Arduino IDE for this.
1315
- * (https://github.com/ameyer/Arduino-L6470)
1275
+ * L6470 Stepper Driver options
1276
+ *
1277
+ * The Arduino-L6470 library is required for this stepper driver.
1278
+ * https://github.com/ameyer/Arduino-L6470
1316
  */
1279
  */
1317
-
1318
-//#define HAVE_L6470DRIVER
1319
-#if ENABLED(HAVE_L6470DRIVER)
1320
-
1321
-  //#define X_IS_L6470
1322
-  //#define X2_IS_L6470
1323
-  //#define Y_IS_L6470
1324
-  //#define Y2_IS_L6470
1325
-  //#define Z_IS_L6470
1326
-  //#define Z2_IS_L6470
1327
-  //#define E0_IS_L6470
1328
-  //#define E1_IS_L6470
1329
-  //#define E2_IS_L6470
1330
-  //#define E3_IS_L6470
1331
-  //#define E4_IS_L6470
1280
+#if HAS_DRIVER(L6470)
1332
 
1281
 
1333
   #define X_MICROSTEPS      16 // number of microsteps
1282
   #define X_MICROSTEPS      16 // number of microsteps
1334
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1283
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1374
   #define E4_OVERCURRENT  2000
1323
   #define E4_OVERCURRENT  2000
1375
   #define E4_STALLCURRENT 1500
1324
   #define E4_STALLCURRENT 1500
1376
 
1325
 
1377
-#endif
1326
+#endif // L6470
1378
 
1327
 
1379
 /**
1328
 /**
1380
  * TWI/I2C BUS
1329
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/delta/kossel_pro/Configuration.h 查看文件

603
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
603
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
604
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
604
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
605
 
605
 
606
+/**
607
+ * Specify Stepper Driver types
608
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
609
+ * Stepper timing options can be overridden in Configuration_adv.h
610
+ *
611
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
612
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
613
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
614
+ *          TMC5130, TMC5130_STANDALONE
615
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
616
+ */
617
+#define X_DRIVER_TYPE  A4988
618
+#define Y_DRIVER_TYPE  A4988
619
+#define Z_DRIVER_TYPE  A4988
620
+#define X2_DRIVER_TYPE A4988
621
+#define Y2_DRIVER_TYPE A4988
622
+#define Z2_DRIVER_TYPE A4988
623
+#define E0_DRIVER_TYPE A4988
624
+#define E1_DRIVER_TYPE A4988
625
+#define E2_DRIVER_TYPE A4988
626
+#define E3_DRIVER_TYPE A4988
627
+#define E4_DRIVER_TYPE A4988
628
+
606
 // Enable this feature if all enabled endstop pins are interrupt-capable.
629
 // Enable this feature if all enabled endstop pins are interrupt-capable.
607
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
630
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
608
 //#define ENDSTOP_INTERRUPTS_FEATURE
631
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/delta/kossel_pro/Configuration_adv.h 查看文件

844
 
844
 
845
 /**
845
 /**
846
  * Minimum delay after setting the stepper DIR (in ns)
846
  * Minimum delay after setting the stepper DIR (in ns)
847
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
848
- *   20 : Minimum for TMC2xxx drivers
849
- *  200 : Minimum for A4988 drivers
850
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
851
- *  650 : Minimum for DRV8825 drivers
852
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
853
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
848
+ *    20 : Minimum for TMC2xxx drivers
849
+ *   200 : Minimum for A4988 drivers
850
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
851
+ *   650 : Minimum for DRV8825 drivers
852
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
853
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
854
+ *
855
+ * Override the default value based on the driver type set in Configuration.h.
854
  */
856
  */
855
-#define MINIMUM_STEPPER_DIR_DELAY 0
857
+//#define MINIMUM_STEPPER_DIR_DELAY 650
856
 
858
 
857
 /**
859
 /**
858
  * Minimum stepper driver pulse width (in µs)
860
  * Minimum stepper driver pulse width (in µs)
862
  *   2 : Minimum for DRV8825 stepper drivers
864
  *   2 : Minimum for DRV8825 stepper drivers
863
  *   3 : Minimum for TB6600 stepper drivers
865
  *   3 : Minimum for TB6600 stepper drivers
864
  *  30 : Minimum for TB6560 stepper drivers
866
  *  30 : Minimum for TB6560 stepper drivers
867
+ *
868
+ * Override the default value based on the driver type set in Configuration.h.
865
  */
869
  */
866
-#define MINIMUM_STEPPER_PULSE 2
870
+//#define MINIMUM_STEPPER_PULSE 2
867
 
871
 
868
 /**
872
 /**
869
  * Maximum stepping rate (in Hz) the stepper driver allows
873
  * Maximum stepping rate (in Hz) the stepper driver allows
874
  *  150000 : Maximum for TB6600 stepper driver
878
  *  150000 : Maximum for TB6600 stepper driver
875
  *  130000 : Maximum for LV8729 stepper driver
879
  *  130000 : Maximum for LV8729 stepper driver
876
  *   15000 : Maximum for TB6560 stepper driver
880
  *   15000 : Maximum for TB6560 stepper driver
881
+ *
882
+ * Override the default value based on the driver type set in Configuration.h.
877
  */
883
  */
878
-#define MAXIMUM_STEPPER_RATE 250000
884
+//#define MAXIMUM_STEPPER_RATE 250000
879
 
885
 
880
 // @section temperature
886
 // @section temperature
881
 
887
 
1043
 // @section tmc
1049
 // @section tmc
1044
 
1050
 
1045
 /**
1051
 /**
1046
- * Enable this section if you have TMC26X motor drivers.
1047
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1048
- * (https://github.com/trinamic/TMC26XStepper.git)
1052
+ * TMC26X Stepper Driver options
1053
+ *
1054
+ * The TMC26XStepper library is required for this stepper driver.
1055
+ * https://github.com/trinamic/TMC26XStepper
1049
  */
1056
  */
1050
-//#define HAVE_TMC26X
1051
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1052
-  //#define X_IS_TMC26X
1053
-  //#define X2_IS_TMC26X
1054
-  //#define Y_IS_TMC26X
1055
-  //#define Y2_IS_TMC26X
1056
-  //#define Z_IS_TMC26X
1057
-  //#define Z2_IS_TMC26X
1058
-  //#define E0_IS_TMC26X
1059
-  //#define E1_IS_TMC26X
1060
-  //#define E2_IS_TMC26X
1061
-  //#define E3_IS_TMC26X
1062
-  //#define E4_IS_TMC26X
1057
+#if HAS_DRIVER(TMC26X)
1063
 
1058
 
1064
   #define X_MAX_CURRENT     1000 // in mA
1059
   #define X_MAX_CURRENT     1000 // in mA
1065
   #define X_SENSE_RESISTOR    91 // in mOhms
1060
   #define X_SENSE_RESISTOR    91 // in mOhms
1105
   #define E4_SENSE_RESISTOR   91
1100
   #define E4_SENSE_RESISTOR   91
1106
   #define E4_MICROSTEPS       16
1101
   #define E4_MICROSTEPS       16
1107
 
1102
 
1108
-#endif
1103
+#endif // TMC26X
1109
 
1104
 
1110
 // @section tmc_smart
1105
 // @section tmc_smart
1111
 
1106
 
1112
 /**
1107
 /**
1113
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1114
- *
1115
- * You'll also need the TMC2130Stepper Arduino library
1116
- * (https://github.com/teemuatlut/TMC2130Stepper).
1117
- *
1118
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1108
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1119
  * the hardware SPI interface on your board and define the required CS pins
1109
  * the hardware SPI interface on your board and define the required CS pins
1120
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1110
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1121
  * You may also use software SPI if you wish to use general purpose IO pins.
1111
  * You may also use software SPI if you wish to use general purpose IO pins.
1122
- */
1123
-//#define HAVE_TMC2130
1124
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1125
-  //#define X_IS_TMC2130
1126
-  //#define X2_IS_TMC2130
1127
-  //#define Y_IS_TMC2130
1128
-  //#define Y2_IS_TMC2130
1129
-  //#define Z_IS_TMC2130
1130
-  //#define Z2_IS_TMC2130
1131
-  //#define E0_IS_TMC2130
1132
-  //#define E1_IS_TMC2130
1133
-  //#define E2_IS_TMC2130
1134
-  //#define E3_IS_TMC2130
1135
-  //#define E4_IS_TMC2130
1136
-#endif
1137
-
1138
-/**
1139
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1140
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1112
+ *
1113
+ * The TMC2130Stepper library is required for this stepper driver.
1114
+ * https://github.com/teemuatlut/TMC2130Stepper
1115
+ *
1116
+ * To use TMC2208 stepper UART-configurable stepper drivers
1117
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1141
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1118
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1142
  * to PDN_UART without a resistor.
1119
  * to PDN_UART without a resistor.
1143
  * The drivers can also be used with hardware serial.
1120
  * The drivers can also be used with hardware serial.
1144
  *
1121
  *
1145
- * You'll also need the TMC2208Stepper Arduino library
1146
- * (https://github.com/teemuatlut/TMC2208Stepper).
1122
+ * The TMC2208Stepper library is required for this stepper driver.
1123
+ * https://github.com/teemuatlut/TMC2208Stepper
1147
  */
1124
  */
1148
-//#define HAVE_TMC2208
1149
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1150
-  //#define X_IS_TMC2208
1151
-  //#define X2_IS_TMC2208
1152
-  //#define Y_IS_TMC2208
1153
-  //#define Y2_IS_TMC2208
1154
-  //#define Z_IS_TMC2208
1155
-  //#define Z2_IS_TMC2208
1156
-  //#define E0_IS_TMC2208
1157
-  //#define E1_IS_TMC2208
1158
-  //#define E2_IS_TMC2208
1159
-  //#define E3_IS_TMC2208
1160
-  //#define E4_IS_TMC2208
1161
-#endif
1162
-
1163
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1125
+#if HAS_TRINAMIC
1164
 
1126
 
1165
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1127
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1166
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1128
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1315
 // @section L6470
1277
 // @section L6470
1316
 
1278
 
1317
 /**
1279
 /**
1318
- * Enable this section if you have L6470 motor drivers.
1319
- * You need to import the L6470 library into the Arduino IDE for this.
1320
- * (https://github.com/ameyer/Arduino-L6470)
1280
+ * L6470 Stepper Driver options
1281
+ *
1282
+ * The Arduino-L6470 library is required for this stepper driver.
1283
+ * https://github.com/ameyer/Arduino-L6470
1321
  */
1284
  */
1322
-
1323
-//#define HAVE_L6470DRIVER
1324
-#if ENABLED(HAVE_L6470DRIVER)
1325
-
1326
-  //#define X_IS_L6470
1327
-  //#define X2_IS_L6470
1328
-  //#define Y_IS_L6470
1329
-  //#define Y2_IS_L6470
1330
-  //#define Z_IS_L6470
1331
-  //#define Z2_IS_L6470
1332
-  //#define E0_IS_L6470
1333
-  //#define E1_IS_L6470
1334
-  //#define E2_IS_L6470
1335
-  //#define E3_IS_L6470
1336
-  //#define E4_IS_L6470
1285
+#if HAS_DRIVER(L6470)
1337
 
1286
 
1338
   #define X_MICROSTEPS      16 // number of microsteps
1287
   #define X_MICROSTEPS      16 // number of microsteps
1339
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1288
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1379
   #define E4_OVERCURRENT  2000
1328
   #define E4_OVERCURRENT  2000
1380
   #define E4_STALLCURRENT 1500
1329
   #define E4_STALLCURRENT 1500
1381
 
1330
 
1382
-#endif
1331
+#endif // L6470
1383
 
1332
 
1384
 /**
1333
 /**
1385
  * TWI/I2C BUS
1334
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/delta/kossel_xl/Configuration.h 查看文件

621
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
621
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
622
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
622
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
623
 
623
 
624
+/**
625
+ * Specify Stepper Driver types
626
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
627
+ * Stepper timing options can be overridden in Configuration_adv.h
628
+ *
629
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
630
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
631
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
632
+ *          TMC5130, TMC5130_STANDALONE
633
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
634
+ */
635
+#define X_DRIVER_TYPE  A4988
636
+#define Y_DRIVER_TYPE  A4988
637
+#define Z_DRIVER_TYPE  A4988
638
+#define X2_DRIVER_TYPE A4988
639
+#define Y2_DRIVER_TYPE A4988
640
+#define Z2_DRIVER_TYPE A4988
641
+#define E0_DRIVER_TYPE A4988
642
+#define E1_DRIVER_TYPE A4988
643
+#define E2_DRIVER_TYPE A4988
644
+#define E3_DRIVER_TYPE A4988
645
+#define E4_DRIVER_TYPE A4988
646
+
624
 // Enable this feature if all enabled endstop pins are interrupt-capable.
647
 // Enable this feature if all enabled endstop pins are interrupt-capable.
625
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
648
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
626
 //#define ENDSTOP_INTERRUPTS_FEATURE
649
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/delta/kossel_xl/Configuration_adv.h 查看文件

839
 
839
 
840
 /**
840
 /**
841
  * Minimum delay after setting the stepper DIR (in ns)
841
  * Minimum delay after setting the stepper DIR (in ns)
842
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
- *   20 : Minimum for TMC2xxx drivers
844
- *  200 : Minimum for A4988 drivers
845
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
- *  650 : Minimum for DRV8825 drivers
847
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
842
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
843
+ *    20 : Minimum for TMC2xxx drivers
844
+ *   200 : Minimum for A4988 drivers
845
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
846
+ *   650 : Minimum for DRV8825 drivers
847
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
848
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
849
+ *
850
+ * Override the default value based on the driver type set in Configuration.h.
849
  */
851
  */
850
-#define MINIMUM_STEPPER_DIR_DELAY 0
852
+//#define MINIMUM_STEPPER_DIR_DELAY 650
851
 
853
 
852
 /**
854
 /**
853
  * Minimum stepper driver pulse width (in µs)
855
  * Minimum stepper driver pulse width (in µs)
857
  *   2 : Minimum for DRV8825 stepper drivers
859
  *   2 : Minimum for DRV8825 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
860
  *   3 : Minimum for TB6600 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
861
  *  30 : Minimum for TB6560 stepper drivers
862
+ *
863
+ * Override the default value based on the driver type set in Configuration.h.
860
  */
864
  */
861
-#define MINIMUM_STEPPER_PULSE 2
865
+//#define MINIMUM_STEPPER_PULSE 2
862
 
866
 
863
 /**
867
 /**
864
  * Maximum stepping rate (in Hz) the stepper driver allows
868
  * Maximum stepping rate (in Hz) the stepper driver allows
869
  *  150000 : Maximum for TB6600 stepper driver
873
  *  150000 : Maximum for TB6600 stepper driver
870
  *  130000 : Maximum for LV8729 stepper driver
874
  *  130000 : Maximum for LV8729 stepper driver
871
  *   15000 : Maximum for TB6560 stepper driver
875
  *   15000 : Maximum for TB6560 stepper driver
876
+ *
877
+ * Override the default value based on the driver type set in Configuration.h.
872
  */
878
  */
873
-#define MAXIMUM_STEPPER_RATE 250000
879
+//#define MAXIMUM_STEPPER_RATE 250000
874
 
880
 
875
 // @section temperature
881
 // @section temperature
876
 
882
 
1038
 // @section tmc
1044
 // @section tmc
1039
 
1045
 
1040
 /**
1046
 /**
1041
- * Enable this section if you have TMC26X motor drivers.
1042
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1043
- * (https://github.com/trinamic/TMC26XStepper.git)
1047
+ * TMC26X Stepper Driver options
1048
+ *
1049
+ * The TMC26XStepper library is required for this stepper driver.
1050
+ * https://github.com/trinamic/TMC26XStepper
1044
  */
1051
  */
1045
-//#define HAVE_TMC26X
1046
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1047
-  //#define X_IS_TMC26X
1048
-  //#define X2_IS_TMC26X
1049
-  //#define Y_IS_TMC26X
1050
-  //#define Y2_IS_TMC26X
1051
-  //#define Z_IS_TMC26X
1052
-  //#define Z2_IS_TMC26X
1053
-  //#define E0_IS_TMC26X
1054
-  //#define E1_IS_TMC26X
1055
-  //#define E2_IS_TMC26X
1056
-  //#define E3_IS_TMC26X
1057
-  //#define E4_IS_TMC26X
1052
+#if HAS_DRIVER(TMC26X)
1058
 
1053
 
1059
   #define X_MAX_CURRENT     1000 // in mA
1054
   #define X_MAX_CURRENT     1000 // in mA
1060
   #define X_SENSE_RESISTOR    91 // in mOhms
1055
   #define X_SENSE_RESISTOR    91 // in mOhms
1100
   #define E4_SENSE_RESISTOR   91
1095
   #define E4_SENSE_RESISTOR   91
1101
   #define E4_MICROSTEPS       16
1096
   #define E4_MICROSTEPS       16
1102
 
1097
 
1103
-#endif
1098
+#endif // TMC26X
1104
 
1099
 
1105
 // @section tmc_smart
1100
 // @section tmc_smart
1106
 
1101
 
1107
 /**
1102
 /**
1108
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1109
- *
1110
- * You'll also need the TMC2130Stepper Arduino library
1111
- * (https://github.com/teemuatlut/TMC2130Stepper).
1112
- *
1113
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1103
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1114
  * the hardware SPI interface on your board and define the required CS pins
1104
  * the hardware SPI interface on your board and define the required CS pins
1115
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1105
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1116
  * You may also use software SPI if you wish to use general purpose IO pins.
1106
  * You may also use software SPI if you wish to use general purpose IO pins.
1117
- */
1118
-//#define HAVE_TMC2130
1119
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1120
-  //#define X_IS_TMC2130
1121
-  //#define X2_IS_TMC2130
1122
-  //#define Y_IS_TMC2130
1123
-  //#define Y2_IS_TMC2130
1124
-  //#define Z_IS_TMC2130
1125
-  //#define Z2_IS_TMC2130
1126
-  //#define E0_IS_TMC2130
1127
-  //#define E1_IS_TMC2130
1128
-  //#define E2_IS_TMC2130
1129
-  //#define E3_IS_TMC2130
1130
-  //#define E4_IS_TMC2130
1131
-#endif
1132
-
1133
-/**
1134
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1135
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1107
+ *
1108
+ * The TMC2130Stepper library is required for this stepper driver.
1109
+ * https://github.com/teemuatlut/TMC2130Stepper
1110
+ *
1111
+ * To use TMC2208 stepper UART-configurable stepper drivers
1112
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1136
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1113
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1137
  * to PDN_UART without a resistor.
1114
  * to PDN_UART without a resistor.
1138
  * The drivers can also be used with hardware serial.
1115
  * The drivers can also be used with hardware serial.
1139
  *
1116
  *
1140
- * You'll also need the TMC2208Stepper Arduino library
1141
- * (https://github.com/teemuatlut/TMC2208Stepper).
1117
+ * The TMC2208Stepper library is required for this stepper driver.
1118
+ * https://github.com/teemuatlut/TMC2208Stepper
1142
  */
1119
  */
1143
-//#define HAVE_TMC2208
1144
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1145
-  //#define X_IS_TMC2208
1146
-  //#define X2_IS_TMC2208
1147
-  //#define Y_IS_TMC2208
1148
-  //#define Y2_IS_TMC2208
1149
-  //#define Z_IS_TMC2208
1150
-  //#define Z2_IS_TMC2208
1151
-  //#define E0_IS_TMC2208
1152
-  //#define E1_IS_TMC2208
1153
-  //#define E2_IS_TMC2208
1154
-  //#define E3_IS_TMC2208
1155
-  //#define E4_IS_TMC2208
1156
-#endif
1157
-
1158
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1120
+#if HAS_TRINAMIC
1159
 
1121
 
1160
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1122
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1161
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1123
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1310
 // @section L6470
1272
 // @section L6470
1311
 
1273
 
1312
 /**
1274
 /**
1313
- * Enable this section if you have L6470 motor drivers.
1314
- * You need to import the L6470 library into the Arduino IDE for this.
1315
- * (https://github.com/ameyer/Arduino-L6470)
1275
+ * L6470 Stepper Driver options
1276
+ *
1277
+ * The Arduino-L6470 library is required for this stepper driver.
1278
+ * https://github.com/ameyer/Arduino-L6470
1316
  */
1279
  */
1317
-
1318
-//#define HAVE_L6470DRIVER
1319
-#if ENABLED(HAVE_L6470DRIVER)
1320
-
1321
-  //#define X_IS_L6470
1322
-  //#define X2_IS_L6470
1323
-  //#define Y_IS_L6470
1324
-  //#define Y2_IS_L6470
1325
-  //#define Z_IS_L6470
1326
-  //#define Z2_IS_L6470
1327
-  //#define E0_IS_L6470
1328
-  //#define E1_IS_L6470
1329
-  //#define E2_IS_L6470
1330
-  //#define E3_IS_L6470
1331
-  //#define E4_IS_L6470
1280
+#if HAS_DRIVER(L6470)
1332
 
1281
 
1333
   #define X_MICROSTEPS      16 // number of microsteps
1282
   #define X_MICROSTEPS      16 // number of microsteps
1334
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1283
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1374
   #define E4_OVERCURRENT  2000
1323
   #define E4_OVERCURRENT  2000
1375
   #define E4_STALLCURRENT 1500
1324
   #define E4_STALLCURRENT 1500
1376
 
1325
 
1377
-#endif
1326
+#endif // L6470
1378
 
1327
 
1379
 /**
1328
 /**
1380
  * TWI/I2C BUS
1329
  * TWI/I2C BUS

+ 24
- 1
Marlin/src/config/examples/gCreate/gMax1.5+/Configuration.h 查看文件

564
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
564
 #define Z_MAX_ENDSTOP_INVERTING false // set to true to invert the logic of the endstop.
565
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
565
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
566
 
566
 
567
+/**
568
+ * Specify Stepper Driver types
569
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
570
+ * Stepper timing options can be overridden in Configuration_adv.h
571
+ *
572
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
573
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
574
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
575
+ *          TMC5130, TMC5130_STANDALONE
576
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
577
+ */
578
+#define X_DRIVER_TYPE  A4988
579
+#define Y_DRIVER_TYPE  A4988
580
+#define Z_DRIVER_TYPE  A4988
581
+#define X2_DRIVER_TYPE A4988
582
+#define Y2_DRIVER_TYPE A4988
583
+#define Z2_DRIVER_TYPE A4988
584
+#define E0_DRIVER_TYPE A4988
585
+#define E1_DRIVER_TYPE A4988
586
+#define E2_DRIVER_TYPE A4988
587
+#define E3_DRIVER_TYPE A4988
588
+#define E4_DRIVER_TYPE A4988
589
+
567
 // Enable this feature if all enabled endstop pins are interrupt-capable.
590
 // Enable this feature if all enabled endstop pins are interrupt-capable.
568
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
591
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
569
-#define ENDSTOP_INTERRUPTS_FEATURE
592
+//#define ENDSTOP_INTERRUPTS_FEATURE
570
 
593
 
571
 /**
594
 /**
572
  * Endstop Noise Filter
595
  * Endstop Noise Filter

+ 37
- 88
Marlin/src/config/examples/gCreate/gMax1.5+/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/makibox/Configuration.h 查看文件

554
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
554
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
555
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
555
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
556
 
556
 
557
+/**
558
+ * Specify Stepper Driver types
559
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
560
+ * Stepper timing options can be overridden in Configuration_adv.h
561
+ *
562
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
563
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
564
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
565
+ *          TMC5130, TMC5130_STANDALONE
566
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
567
+ */
568
+#define X_DRIVER_TYPE  A4988
569
+#define Y_DRIVER_TYPE  A4988
570
+#define Z_DRIVER_TYPE  A4988
571
+#define X2_DRIVER_TYPE A4988
572
+#define Y2_DRIVER_TYPE A4988
573
+#define Z2_DRIVER_TYPE A4988
574
+#define E0_DRIVER_TYPE A4988
575
+#define E1_DRIVER_TYPE A4988
576
+#define E2_DRIVER_TYPE A4988
577
+#define E3_DRIVER_TYPE A4988
578
+#define E4_DRIVER_TYPE A4988
579
+
557
 // Enable this feature if all enabled endstop pins are interrupt-capable.
580
 // Enable this feature if all enabled endstop pins are interrupt-capable.
558
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
581
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
559
 //#define ENDSTOP_INTERRUPTS_FEATURE
582
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/makibox/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 2
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 250000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/stm32f103ret6/Configuration.h 查看文件

553
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
553
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
554
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
554
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
555
 
555
 
556
+/**
557
+ * Specify Stepper Driver types
558
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
559
+ * Stepper timing options can be overridden in Configuration_adv.h
560
+ *
561
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
562
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
563
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
564
+ *          TMC5130, TMC5130_STANDALONE
565
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
566
+ */
567
+#define X_DRIVER_TYPE  A4988
568
+#define Y_DRIVER_TYPE  A4988
569
+#define Z_DRIVER_TYPE  A4988
570
+#define X2_DRIVER_TYPE A4988
571
+#define Y2_DRIVER_TYPE A4988
572
+#define Z2_DRIVER_TYPE A4988
573
+#define E0_DRIVER_TYPE A4988
574
+#define E1_DRIVER_TYPE A4988
575
+#define E2_DRIVER_TYPE A4988
576
+#define E3_DRIVER_TYPE A4988
577
+#define E4_DRIVER_TYPE A4988
578
+
556
 // Enable this feature if all enabled endstop pins are interrupt-capable.
579
 // Enable this feature if all enabled endstop pins are interrupt-capable.
557
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
580
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
558
 //#define ENDSTOP_INTERRUPTS_FEATURE
581
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/tvrrug/Round2/Configuration_adv.h 查看文件

837
 
837
 
838
 /**
838
 /**
839
  * Minimum delay after setting the stepper DIR (in ns)
839
  * Minimum delay after setting the stepper DIR (in ns)
840
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
- *   20 : Minimum for TMC2xxx drivers
842
- *  200 : Minimum for A4988 drivers
843
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
- *  650 : Minimum for DRV8825 drivers
845
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
840
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
841
+ *    20 : Minimum for TMC2xxx drivers
842
+ *   200 : Minimum for A4988 drivers
843
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
844
+ *   650 : Minimum for DRV8825 drivers
845
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
846
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
847
+ *
848
+ * Override the default value based on the driver type set in Configuration.h.
847
  */
849
  */
848
-#define MINIMUM_STEPPER_DIR_DELAY 0
850
+//#define MINIMUM_STEPPER_DIR_DELAY 650
849
 
851
 
850
 /**
852
 /**
851
  * Minimum stepper driver pulse width (in µs)
853
  * Minimum stepper driver pulse width (in µs)
855
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   2 : Minimum for DRV8825 stepper drivers
856
  *   3 : Minimum for TB6600 stepper drivers
858
  *   3 : Minimum for TB6600 stepper drivers
857
  *  30 : Minimum for TB6560 stepper drivers
859
  *  30 : Minimum for TB6560 stepper drivers
860
+ *
861
+ * Override the default value based on the driver type set in Configuration.h.
858
  */
862
  */
859
-#define MINIMUM_STEPPER_PULSE 30
863
+//#define MINIMUM_STEPPER_PULSE 2
860
 
864
 
861
 /**
865
 /**
862
  * Maximum stepping rate (in Hz) the stepper driver allows
866
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  *  150000 : Maximum for TB6600 stepper driver
871
  *  150000 : Maximum for TB6600 stepper driver
868
  *  130000 : Maximum for LV8729 stepper driver
872
  *  130000 : Maximum for LV8729 stepper driver
869
  *   15000 : Maximum for TB6560 stepper driver
873
  *   15000 : Maximum for TB6560 stepper driver
874
+ *
875
+ * Override the default value based on the driver type set in Configuration.h.
870
  */
876
  */
871
-#define MAXIMUM_STEPPER_RATE 15000
877
+//#define MAXIMUM_STEPPER_RATE 250000
872
 
878
 
873
 // @section temperature
879
 // @section temperature
874
 
880
 
1036
 // @section tmc
1042
 // @section tmc
1037
 
1043
 
1038
 /**
1044
 /**
1039
- * Enable this section if you have TMC26X motor drivers.
1040
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1041
- * (https://github.com/trinamic/TMC26XStepper.git)
1045
+ * TMC26X Stepper Driver options
1046
+ *
1047
+ * The TMC26XStepper library is required for this stepper driver.
1048
+ * https://github.com/trinamic/TMC26XStepper
1042
  */
1049
  */
1043
-//#define HAVE_TMC26X
1044
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1045
-  //#define X_IS_TMC26X
1046
-  //#define X2_IS_TMC26X
1047
-  //#define Y_IS_TMC26X
1048
-  //#define Y2_IS_TMC26X
1049
-  //#define Z_IS_TMC26X
1050
-  //#define Z2_IS_TMC26X
1051
-  //#define E0_IS_TMC26X
1052
-  //#define E1_IS_TMC26X
1053
-  //#define E2_IS_TMC26X
1054
-  //#define E3_IS_TMC26X
1055
-  //#define E4_IS_TMC26X
1050
+#if HAS_DRIVER(TMC26X)
1056
 
1051
 
1057
   #define X_MAX_CURRENT     1000 // in mA
1052
   #define X_MAX_CURRENT     1000 // in mA
1058
   #define X_SENSE_RESISTOR    91 // in mOhms
1053
   #define X_SENSE_RESISTOR    91 // in mOhms
1098
   #define E4_SENSE_RESISTOR   91
1093
   #define E4_SENSE_RESISTOR   91
1099
   #define E4_MICROSTEPS       16
1094
   #define E4_MICROSTEPS       16
1100
 
1095
 
1101
-#endif
1096
+#endif // TMC26X
1102
 
1097
 
1103
 // @section tmc_smart
1098
 // @section tmc_smart
1104
 
1099
 
1105
 /**
1100
 /**
1106
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1107
- *
1108
- * You'll also need the TMC2130Stepper Arduino library
1109
- * (https://github.com/teemuatlut/TMC2130Stepper).
1110
- *
1111
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1101
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1112
  * the hardware SPI interface on your board and define the required CS pins
1102
  * the hardware SPI interface on your board and define the required CS pins
1113
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1103
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1114
  * You may also use software SPI if you wish to use general purpose IO pins.
1104
  * You may also use software SPI if you wish to use general purpose IO pins.
1115
- */
1116
-//#define HAVE_TMC2130
1117
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1118
-  //#define X_IS_TMC2130
1119
-  //#define X2_IS_TMC2130
1120
-  //#define Y_IS_TMC2130
1121
-  //#define Y2_IS_TMC2130
1122
-  //#define Z_IS_TMC2130
1123
-  //#define Z2_IS_TMC2130
1124
-  //#define E0_IS_TMC2130
1125
-  //#define E1_IS_TMC2130
1126
-  //#define E2_IS_TMC2130
1127
-  //#define E3_IS_TMC2130
1128
-  //#define E4_IS_TMC2130
1129
-#endif
1130
-
1131
-/**
1132
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1133
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1105
+ *
1106
+ * The TMC2130Stepper library is required for this stepper driver.
1107
+ * https://github.com/teemuatlut/TMC2130Stepper
1108
+ *
1109
+ * To use TMC2208 stepper UART-configurable stepper drivers
1110
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1134
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1111
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1135
  * to PDN_UART without a resistor.
1112
  * to PDN_UART without a resistor.
1136
  * The drivers can also be used with hardware serial.
1113
  * The drivers can also be used with hardware serial.
1137
  *
1114
  *
1138
- * You'll also need the TMC2208Stepper Arduino library
1139
- * (https://github.com/teemuatlut/TMC2208Stepper).
1115
+ * The TMC2208Stepper library is required for this stepper driver.
1116
+ * https://github.com/teemuatlut/TMC2208Stepper
1140
  */
1117
  */
1141
-//#define HAVE_TMC2208
1142
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1143
-  //#define X_IS_TMC2208
1144
-  //#define X2_IS_TMC2208
1145
-  //#define Y_IS_TMC2208
1146
-  //#define Y2_IS_TMC2208
1147
-  //#define Z_IS_TMC2208
1148
-  //#define Z2_IS_TMC2208
1149
-  //#define E0_IS_TMC2208
1150
-  //#define E1_IS_TMC2208
1151
-  //#define E2_IS_TMC2208
1152
-  //#define E3_IS_TMC2208
1153
-  //#define E4_IS_TMC2208
1154
-#endif
1155
-
1156
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1118
+#if HAS_TRINAMIC
1157
 
1119
 
1158
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1120
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1159
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1121
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1308
 // @section L6470
1270
 // @section L6470
1309
 
1271
 
1310
 /**
1272
 /**
1311
- * Enable this section if you have L6470 motor drivers.
1312
- * You need to import the L6470 library into the Arduino IDE for this.
1313
- * (https://github.com/ameyer/Arduino-L6470)
1273
+ * L6470 Stepper Driver options
1274
+ *
1275
+ * The Arduino-L6470 library is required for this stepper driver.
1276
+ * https://github.com/ameyer/Arduino-L6470
1314
  */
1277
  */
1315
-
1316
-//#define HAVE_L6470DRIVER
1317
-#if ENABLED(HAVE_L6470DRIVER)
1318
-
1319
-  //#define X_IS_L6470
1320
-  //#define X2_IS_L6470
1321
-  //#define Y_IS_L6470
1322
-  //#define Y2_IS_L6470
1323
-  //#define Z_IS_L6470
1324
-  //#define Z2_IS_L6470
1325
-  //#define E0_IS_L6470
1326
-  //#define E1_IS_L6470
1327
-  //#define E2_IS_L6470
1328
-  //#define E3_IS_L6470
1329
-  //#define E4_IS_L6470
1278
+#if HAS_DRIVER(L6470)
1330
 
1279
 
1331
   #define X_MICROSTEPS      16 // number of microsteps
1280
   #define X_MICROSTEPS      16 // number of microsteps
1332
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1281
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1372
   #define E4_OVERCURRENT  2000
1321
   #define E4_OVERCURRENT  2000
1373
   #define E4_STALLCURRENT 1500
1322
   #define E4_STALLCURRENT 1500
1374
 
1323
 
1375
-#endif
1324
+#endif // L6470
1376
 
1325
 
1377
 /**
1326
 /**
1378
  * TWI/I2C BUS
1327
  * TWI/I2C BUS

+ 23
- 0
Marlin/src/config/examples/wt150/Configuration.h 查看文件

556
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
556
 #define Z_MAX_ENDSTOP_INVERTING true  // set to true to invert the logic of the endstop.
557
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
557
 #define Z_MIN_PROBE_ENDSTOP_INVERTING false // set to true to invert the logic of the probe.
558
 
558
 
559
+/**
560
+ * Specify Stepper Driver types
561
+ * The options are used to determine driver pulse timings as well as more advanced functionality.
562
+ * Stepper timing options can be overridden in Configuration_adv.h
563
+ *
564
+ * Options: A4988, DRV8825, LV8729, L6470, TB6560, TB6600, TMC2100,
565
+ *          TMC2130, TMC2130_STANDALONE, TMC2208, TMC2208_STANDALONE,
566
+ *          TMC26X,  TMC26X_STANDALONE,  TMC2660, TMC2660_STANDALONE,
567
+ *          TMC5130, TMC5130_STANDALONE
568
+ * :['A4988', 'DRV8825', 'LV8729', 'L6470', 'TB6560', 'TB6600', 'TMC2100', 'TMC2130', 'TMC2130_STANDALONE', 'TMC2208', 'TMC2208_STANDALONE', 'TMC26X', 'TMC26X_STANDALONE', 'TMC2660', 'TMC2660_STANDALONE', 'TMC5130', 'TMC5130_STANDALONE']
569
+ */
570
+#define X_DRIVER_TYPE  A4988
571
+#define Y_DRIVER_TYPE  A4988
572
+#define Z_DRIVER_TYPE  A4988
573
+#define X2_DRIVER_TYPE A4988
574
+#define Y2_DRIVER_TYPE A4988
575
+#define Z2_DRIVER_TYPE A4988
576
+#define E0_DRIVER_TYPE A4988
577
+#define E1_DRIVER_TYPE A4988
578
+#define E2_DRIVER_TYPE A4988
579
+#define E3_DRIVER_TYPE A4988
580
+#define E4_DRIVER_TYPE A4988
581
+
559
 // Enable this feature if all enabled endstop pins are interrupt-capable.
582
 // Enable this feature if all enabled endstop pins are interrupt-capable.
560
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
583
 // This will remove the need to poll the interrupt pins, saving many CPU cycles.
561
 //#define ENDSTOP_INTERRUPTS_FEATURE
584
 //#define ENDSTOP_INTERRUPTS_FEATURE

+ 37
- 88
Marlin/src/config/examples/wt150/Configuration_adv.h 查看文件

838
 
838
 
839
 /**
839
 /**
840
  * Minimum delay after setting the stepper DIR (in ns)
840
  * Minimum delay after setting the stepper DIR (in ns)
841
- *    0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
842
- *   20 : Minimum for TMC2xxx drivers
843
- *  200 : Minimum for A4988 drivers
844
- *  500 : Minimum for LV8729 drivers (guess, no info in datasheet)
845
- *  650 : Minimum for DRV8825 drivers
846
- * 1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
847
- *15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
841
+ *     0 : No delay (Expect at least 10µS since one Stepper ISR must transpire)
842
+ *    20 : Minimum for TMC2xxx drivers
843
+ *   200 : Minimum for A4988 drivers
844
+ *   500 : Minimum for LV8729 drivers (guess, no info in datasheet)
845
+ *   650 : Minimum for DRV8825 drivers
846
+ *  1500 : Minimum for TB6600 drivers (guess, no info in datasheet)
847
+ * 15000 : Minimum for TB6560 drivers (guess, no info in datasheet)
848
+ *
849
+ * Override the default value based on the driver type set in Configuration.h.
848
  */
850
  */
849
-#define MINIMUM_STEPPER_DIR_DELAY 0
851
+//#define MINIMUM_STEPPER_DIR_DELAY 650
850
 
852
 
851
 /**
853
 /**
852
  * Minimum stepper driver pulse width (in µs)
854
  * Minimum stepper driver pulse width (in µs)
856
  *   2 : Minimum for DRV8825 stepper drivers
858
  *   2 : Minimum for DRV8825 stepper drivers
857
  *   3 : Minimum for TB6600 stepper drivers
859
  *   3 : Minimum for TB6600 stepper drivers
858
  *  30 : Minimum for TB6560 stepper drivers
860
  *  30 : Minimum for TB6560 stepper drivers
861
+ *
862
+ * Override the default value based on the driver type set in Configuration.h.
859
  */
863
  */
860
-#define MINIMUM_STEPPER_PULSE 2
864
+//#define MINIMUM_STEPPER_PULSE 2
861
 
865
 
862
 /**
866
 /**
863
  * Maximum stepping rate (in Hz) the stepper driver allows
867
  * Maximum stepping rate (in Hz) the stepper driver allows
868
  *  150000 : Maximum for TB6600 stepper driver
872
  *  150000 : Maximum for TB6600 stepper driver
869
  *  130000 : Maximum for LV8729 stepper driver
873
  *  130000 : Maximum for LV8729 stepper driver
870
  *   15000 : Maximum for TB6560 stepper driver
874
  *   15000 : Maximum for TB6560 stepper driver
875
+ *
876
+ * Override the default value based on the driver type set in Configuration.h.
871
  */
877
  */
872
-#define MAXIMUM_STEPPER_RATE 250000
878
+//#define MAXIMUM_STEPPER_RATE 250000
873
 
879
 
874
 // @section temperature
880
 // @section temperature
875
 
881
 
1037
 // @section tmc
1043
 // @section tmc
1038
 
1044
 
1039
 /**
1045
 /**
1040
- * Enable this section if you have TMC26X motor drivers.
1041
- * You will need to import the TMC26XStepper library into the Arduino IDE for this
1042
- * (https://github.com/trinamic/TMC26XStepper.git)
1046
+ * TMC26X Stepper Driver options
1047
+ *
1048
+ * The TMC26XStepper library is required for this stepper driver.
1049
+ * https://github.com/trinamic/TMC26XStepper
1043
  */
1050
  */
1044
-//#define HAVE_TMC26X
1045
-#if ENABLED(HAVE_TMC26X)  // Choose your axes here. This is mandatory!
1046
-  //#define X_IS_TMC26X
1047
-  //#define X2_IS_TMC26X
1048
-  //#define Y_IS_TMC26X
1049
-  //#define Y2_IS_TMC26X
1050
-  //#define Z_IS_TMC26X
1051
-  //#define Z2_IS_TMC26X
1052
-  //#define E0_IS_TMC26X
1053
-  //#define E1_IS_TMC26X
1054
-  //#define E2_IS_TMC26X
1055
-  //#define E3_IS_TMC26X
1056
-  //#define E4_IS_TMC26X
1051
+#if HAS_DRIVER(TMC26X)
1057
 
1052
 
1058
   #define X_MAX_CURRENT     1000 // in mA
1053
   #define X_MAX_CURRENT     1000 // in mA
1059
   #define X_SENSE_RESISTOR    91 // in mOhms
1054
   #define X_SENSE_RESISTOR    91 // in mOhms
1099
   #define E4_SENSE_RESISTOR   91
1094
   #define E4_SENSE_RESISTOR   91
1100
   #define E4_MICROSTEPS       16
1095
   #define E4_MICROSTEPS       16
1101
 
1096
 
1102
-#endif
1097
+#endif // TMC26X
1103
 
1098
 
1104
 // @section tmc_smart
1099
 // @section tmc_smart
1105
 
1100
 
1106
 /**
1101
 /**
1107
- * Enable this for SilentStepStick Trinamic TMC2130 SPI-configurable stepper drivers.
1108
- *
1109
- * You'll also need the TMC2130Stepper Arduino library
1110
- * (https://github.com/teemuatlut/TMC2130Stepper).
1111
- *
1112
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1102
  * To use TMC2130 stepper drivers in SPI mode connect your SPI pins to
1113
  * the hardware SPI interface on your board and define the required CS pins
1103
  * the hardware SPI interface on your board and define the required CS pins
1114
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1104
  * in your `pins_MYBOARD.h` file. (e.g., RAMPS 1.4 uses AUX3 pins `X_CS_PIN 53`, `Y_CS_PIN 49`, etc.).
1115
  * You may also use software SPI if you wish to use general purpose IO pins.
1105
  * You may also use software SPI if you wish to use general purpose IO pins.
1116
- */
1117
-//#define HAVE_TMC2130
1118
-#if ENABLED(HAVE_TMC2130)  // Choose your axes here. This is mandatory!
1119
-  //#define X_IS_TMC2130
1120
-  //#define X2_IS_TMC2130
1121
-  //#define Y_IS_TMC2130
1122
-  //#define Y2_IS_TMC2130
1123
-  //#define Z_IS_TMC2130
1124
-  //#define Z2_IS_TMC2130
1125
-  //#define E0_IS_TMC2130
1126
-  //#define E1_IS_TMC2130
1127
-  //#define E2_IS_TMC2130
1128
-  //#define E3_IS_TMC2130
1129
-  //#define E4_IS_TMC2130
1130
-#endif
1131
-
1132
-/**
1133
- * Enable this for SilentStepStick Trinamic TMC2208 UART-configurable stepper drivers.
1134
- * Connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1106
+ *
1107
+ * The TMC2130Stepper library is required for this stepper driver.
1108
+ * https://github.com/teemuatlut/TMC2130Stepper
1109
+ *
1110
+ * To use TMC2208 stepper UART-configurable stepper drivers
1111
+ * connect #_SERIAL_TX_PIN to the driver side PDN_UART pin with a 1K resistor.
1135
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1112
  * To use the reading capabilities, also connect #_SERIAL_RX_PIN
1136
  * to PDN_UART without a resistor.
1113
  * to PDN_UART without a resistor.
1137
  * The drivers can also be used with hardware serial.
1114
  * The drivers can also be used with hardware serial.
1138
  *
1115
  *
1139
- * You'll also need the TMC2208Stepper Arduino library
1140
- * (https://github.com/teemuatlut/TMC2208Stepper).
1116
+ * The TMC2208Stepper library is required for this stepper driver.
1117
+ * https://github.com/teemuatlut/TMC2208Stepper
1141
  */
1118
  */
1142
-//#define HAVE_TMC2208
1143
-#if ENABLED(HAVE_TMC2208)  // Choose your axes here. This is mandatory!
1144
-  //#define X_IS_TMC2208
1145
-  //#define X2_IS_TMC2208
1146
-  //#define Y_IS_TMC2208
1147
-  //#define Y2_IS_TMC2208
1148
-  //#define Z_IS_TMC2208
1149
-  //#define Z2_IS_TMC2208
1150
-  //#define E0_IS_TMC2208
1151
-  //#define E1_IS_TMC2208
1152
-  //#define E2_IS_TMC2208
1153
-  //#define E3_IS_TMC2208
1154
-  //#define E4_IS_TMC2208
1155
-#endif
1156
-
1157
-#if ENABLED(HAVE_TMC2130) || ENABLED(HAVE_TMC2208)
1119
+#if HAS_TRINAMIC
1158
 
1120
 
1159
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1121
   #define R_SENSE           0.11  // R_sense resistor for SilentStepStick2130
1160
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1122
   #define HOLD_MULTIPLIER    0.5  // Scales down the holding current from run current
1309
 // @section L6470
1271
 // @section L6470
1310
 
1272
 
1311
 /**
1273
 /**
1312
- * Enable this section if you have L6470 motor drivers.
1313
- * You need to import the L6470 library into the Arduino IDE for this.
1314
- * (https://github.com/ameyer/Arduino-L6470)
1274
+ * L6470 Stepper Driver options
1275
+ *
1276
+ * The Arduino-L6470 library is required for this stepper driver.
1277
+ * https://github.com/ameyer/Arduino-L6470
1315
  */
1278
  */
1316
-
1317
-//#define HAVE_L6470DRIVER
1318
-#if ENABLED(HAVE_L6470DRIVER)
1319
-
1320
-  //#define X_IS_L6470
1321
-  //#define X2_IS_L6470
1322
-  //#define Y_IS_L6470
1323
-  //#define Y2_IS_L6470
1324
-  //#define Z_IS_L6470
1325
-  //#define Z2_IS_L6470
1326
-  //#define E0_IS_L6470
1327
-  //#define E1_IS_L6470
1328
-  //#define E2_IS_L6470
1329
-  //#define E3_IS_L6470
1330
-  //#define E4_IS_L6470
1279
+#if HAS_DRIVER(L6470)
1331
 
1280
 
1332
   #define X_MICROSTEPS      16 // number of microsteps
1281
   #define X_MICROSTEPS      16 // number of microsteps
1333
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1282
   #define X_OVERCURRENT   2000 // maxc current in mA. If the current goes over this value, the driver will switch off
1373
   #define E4_OVERCURRENT  2000
1322
   #define E4_OVERCURRENT  2000
1374
   #define E4_STALLCURRENT 1500
1323
   #define E4_STALLCURRENT 1500
1375
 
1324
 
1376
-#endif
1325
+#endif // L6470
1377
 
1326
 
1378
 /**
1327
 /**
1379
  * TWI/I2C BUS
1328
  * TWI/I2C BUS

正在加载...
取消
保存