My Marlin configs for Fabrikator Mini and CTC i3 Pro B
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

pins.h 6.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263
  1. /**
  2. * pins.h
  3. */
  4. #ifndef PINS_H
  5. #define PINS_H
  6. // Preset optional pins
  7. #define X_MS1_PIN -1
  8. #define X_MS2_PIN -1
  9. #define Y_MS1_PIN -1
  10. #define Y_MS2_PIN -1
  11. #define Z_MS1_PIN -1
  12. #define Z_MS2_PIN -1
  13. #define E0_MS1_PIN -1
  14. #define E0_MS2_PIN -1
  15. #define E1_MS1_PIN -1
  16. #define E1_MS2_PIN -1
  17. #define DIGIPOTSS_PIN -1
  18. #define HEATER_3_PIN -1
  19. #define TEMP_3_PIN -1
  20. #if MB(GEN7_CUSTOM)
  21. #include "pins_GEN7_CUSTOM.h"
  22. #elif MB(GEN7_12)
  23. #include "pins_GEN7_12.h"
  24. #elif MB(GEN7_13)
  25. #include "pins_GEN7_13.h"
  26. #elif MB(GEN7_14)
  27. #include "pins_GEN7_14.h"
  28. #elif MB(CHEAPTRONIC)
  29. #include "pins_CHEAPTRONIC.h"
  30. #elif MB(SETHI)
  31. #include "pins_SETHI.h"
  32. #elif MB(RAMPS_OLD)
  33. #include "pins_RAMPS_OLD.h"
  34. #elif MB(RAMPS_13_EFB)
  35. #include "pins_RAMPS_13_EFB.h"
  36. #elif MB(RAMPS_13_EEB) || MB(RAMPS_13_EFF) || MB(RAMPS_13_EEF) || MB(RAMPS_13_SF)
  37. #include "pins_RAMPS_13.h"
  38. #elif MB(RAMPS_14_EFB)
  39. #define IS_RAMPS_14
  40. #include "pins_RAMPS_13_EFB.h"
  41. #elif MB(RAMPS_14_EEB) || MB(RAMPS_14_EFF) || MB(RAMPS_14_EEF) || MB(RAMPS_14_SF)
  42. #define IS_RAMPS_14
  43. #include "pins_RAMPS_13.h"
  44. #elif MB(GEN6)
  45. #include "pins_GEN6.h"
  46. #elif MB(GEN6_DELUXE)
  47. #include "pins_GEN6_DELUXE.h"
  48. #elif MB(SANGUINOLOLU_11)
  49. #include "pins_SANGUINOLOLU_11.h"
  50. #elif MB(SANGUINOLOLU_12)
  51. #include "pins_SANGUINOLOLU_12.h"
  52. #elif MB(MELZI)
  53. #include "pins_MELZI.h"
  54. #elif MB(STB_11)
  55. #include "pins_STB_11.h"
  56. #elif MB(AZTEEG_X1)
  57. #include "pins_AZTEEG_X1.h"
  58. #elif MB(MELZI_MAKR3D)
  59. #include "pins_MELZI_MAKR3D.h"
  60. #elif MB(AZTEEG_X3)
  61. #include "pins_AZTEEG_X3.h"
  62. #elif MB(AZTEEG_X3_PRO)
  63. #include "pins_AZTEEG_X3_PRO.h"
  64. #elif MB(ULTIMAKER)
  65. #include "pins_ULTIMAKER.h"
  66. #elif MB(ULTIMAKER_OLD)
  67. #include "pins_ULTIMAKER_OLD.h"
  68. #elif MB(ULTIMAIN_2)
  69. #include "pins_ULTIMAIN_2.h"
  70. #elif MB(3DRAG)
  71. #include "pins_3DRAG.h"
  72. #elif MB(K8200)
  73. #include "pins_K8200.h"
  74. #elif MB(TEENSYLU)
  75. #include "pins_TEENSYLU.h"
  76. #elif MB(RUMBA)
  77. #include "pins_RUMBA.h"
  78. #elif MB(PRINTRBOARD)
  79. #include "pins_PRINTRBOARD.h"
  80. #elif MB(BRAINWAVE)
  81. #include "pins_BRAINWAVE.h"
  82. #elif MB(BRAINWAVE_PRO)
  83. #include "pins_BRAINWAVE_PRO.h"
  84. #elif MB(SAV_MKI)
  85. #include "pins_SAV_MKI.h"
  86. #elif MB(TEENSY2)
  87. #include "pins_TEENSY2.h"
  88. #elif MB(GEN3_PLUS)
  89. #include "pins_GEN3_PLUS.h"
  90. #elif MB(GEN3_MONOLITHIC)
  91. #include "pins_GEN3_MONOLITHIC.h"
  92. #elif MB(MEGATRONICS)
  93. #include "pins_MEGATRONICS.h"
  94. #elif MB(MINITRONICS)
  95. #include "pins_MINITRONICS.h"
  96. #elif MB(MEGATRONICS_2)
  97. #include "pins_MEGATRONICS_2.h"
  98. #elif MB(MEGATRONICS_3)
  99. #include "pins_MEGATRONICS_3.h"
  100. #elif MB(OMCA_A)
  101. #include "pins_OMCA_A.h"
  102. #elif MB(OMCA)
  103. #include "pins_OMCA.h"
  104. #elif MB(RAMBO)
  105. #include "pins_RAMBO.h"
  106. #elif MB(MINIRAMBO)
  107. #include "pins_MINIRAMBO.h"
  108. #elif MB(ELEFU_3)
  109. #include "pins_ELEFU_3.h"
  110. #elif MB(5DPRINT)
  111. #include "pins_5DPRINT.h"
  112. #elif MB(LEAPFROG)
  113. #include "pins_LEAPFROG.h"
  114. #elif MB(BAM_DICE)
  115. #include "pins_RAMPS_13.h"
  116. #elif MB(BAM_DICE_DUE)
  117. #include "pins_BAM_DICE_DUE.h"
  118. #elif MB(FELIX2)
  119. #include "pins_FELIX2.h"
  120. #elif MB(MKS_BASE)
  121. #include "pins_MKS_BASE.h"
  122. #elif MB(RIGIDBOARD)
  123. #include "pins_RIGIDBOARD.h"
  124. #elif MB(MEGACONTROLLER)
  125. #include "pins_MEGACONTROLLER.h"
  126. #elif MB(99)
  127. #include "pins_99.h"
  128. #else
  129. #error Unknown MOTHERBOARD value set in Configuration.h
  130. #endif
  131. // List of pins which to ignore when asked to change by gcode, 0 and 1 are RX and TX, do not mess with those!
  132. #define _E0_PINS E0_STEP_PIN, E0_DIR_PIN, E0_ENABLE_PIN, HEATER_0_PIN, analogInputToDigitalPin(TEMP_0_PIN),
  133. #define _E1_PINS
  134. #define _E2_PINS
  135. #define _E3_PINS
  136. #if EXTRUDERS > 1
  137. #undef _E1_PINS
  138. #define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN, HEATER_1_PIN, analogInputToDigitalPin(TEMP_1_PIN),
  139. #if EXTRUDERS > 2
  140. #undef _E2_PINS
  141. #define _E2_PINS E2_STEP_PIN, E2_DIR_PIN, E2_ENABLE_PIN, HEATER_2_PIN, analogInputToDigitalPin(TEMP_2_PIN),
  142. #if EXTRUDERS > 3
  143. #undef _E3_PINS
  144. #define _E3_PINS E3_STEP_PIN, E3_DIR_PIN, E3_ENABLE_PIN, HEATER_3_PIN, analogInputToDigitalPin(TEMP_3_PIN),
  145. #endif
  146. #endif
  147. #elif ENABLED(Y_DUAL_STEPPER_DRIVERS) || ENABLED(Z_DUAL_STEPPER_DRIVERS)
  148. #undef _E1_PINS
  149. #define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN,
  150. #endif
  151. #ifdef X_STOP_PIN
  152. #if X_HOME_DIR < 0
  153. #define X_MIN_PIN X_STOP_PIN
  154. #define X_MAX_PIN -1
  155. #else
  156. #define X_MIN_PIN -1
  157. #define X_MAX_PIN X_STOP_PIN
  158. #endif
  159. #endif
  160. #ifdef Y_STOP_PIN
  161. #if Y_HOME_DIR < 0
  162. #define Y_MIN_PIN Y_STOP_PIN
  163. #define Y_MAX_PIN -1
  164. #else
  165. #define Y_MIN_PIN -1
  166. #define Y_MAX_PIN Y_STOP_PIN
  167. #endif
  168. #endif
  169. #ifdef Z_STOP_PIN
  170. #if Z_HOME_DIR < 0
  171. #define Z_MIN_PIN Z_STOP_PIN
  172. #define Z_MAX_PIN -1
  173. #else
  174. #define Z_MIN_PIN -1
  175. #define Z_MAX_PIN Z_STOP_PIN
  176. #endif
  177. #endif
  178. #if ENABLED(DISABLE_MAX_ENDSTOPS)
  179. #undef X_MAX_PIN
  180. #undef Y_MAX_PIN
  181. #undef Z_MAX_PIN
  182. #define X_MAX_PIN -1
  183. #define Y_MAX_PIN -1
  184. #define Z_MAX_PIN -1
  185. #endif
  186. #if ENABLED(DISABLE_MIN_ENDSTOPS)
  187. #undef X_MIN_PIN
  188. #undef Y_MIN_PIN
  189. #undef Z_MIN_PIN
  190. #define X_MIN_PIN -1
  191. #define Y_MIN_PIN -1
  192. #define Z_MIN_PIN -1
  193. #endif
  194. #if ENABLED(DISABLE_Z_MIN_PROBE_ENDSTOP) || DISABLED(Z_MIN_PROBE_ENDSTOP) // Allow code to compile regardless of Z_MIN_PROBE_ENDSTOP setting.
  195. #undef Z_MIN_PROBE_PIN
  196. #define Z_MIN_PROBE_PIN -1
  197. #endif
  198. #if ENABLED(DISABLE_XMAX_ENDSTOP)
  199. #undef X_MAX_PIN
  200. #define X_MAX_PIN -1
  201. #endif
  202. #if ENABLED(DISABLE_XMIN_ENDSTOP)
  203. #undef X_MIN_PIN
  204. #define X_MIN_PIN -1
  205. #endif
  206. #if ENABLED(DISABLE_YMAX_ENDSTOP)
  207. #define Y_MAX_PIN -1
  208. #endif
  209. #if ENABLED(DISABLE_YMIN_ENDSTOP)
  210. #undef Y_MIN_PIN
  211. #define Y_MIN_PIN -1
  212. #endif
  213. #if ENABLED(DISABLE_ZMAX_ENDSTOP)
  214. #undef Z_MAX_PIN
  215. #define Z_MAX_PIN -1
  216. #endif
  217. #if ENABLED(DISABLE_ZMIN_ENDSTOP)
  218. #undef Z_MIN_PIN
  219. #define Z_MIN_PIN -1
  220. #endif
  221. #ifndef Y2_STEP_PIN
  222. #define Y2_STEP_PIN E1_STEP_PIN
  223. #define Y2_DIR_PIN E1_DIR_PIN
  224. #define Y2_ENABLE_PIN E1_ENABLE_PIN
  225. #endif
  226. #ifndef Z2_STEP_PIN
  227. #define Z2_STEP_PIN E1_STEP_PIN
  228. #define Z2_DIR_PIN E1_DIR_PIN
  229. #define Z2_ENABLE_PIN E1_ENABLE_PIN
  230. #endif
  231. #define SENSITIVE_PINS { 0, 1, \
  232. X_STEP_PIN, X_DIR_PIN, X_ENABLE_PIN, X_MIN_PIN, X_MAX_PIN, \
  233. Y_STEP_PIN, Y_DIR_PIN, Y_ENABLE_PIN, Y_MIN_PIN, Y_MAX_PIN, \
  234. Z_STEP_PIN, Z_DIR_PIN, Z_ENABLE_PIN, Z_MIN_PIN, Z_MAX_PIN, Z_MIN_PROBE_PIN, \
  235. PS_ON_PIN, HEATER_BED_PIN, FAN_PIN, \
  236. _E0_PINS _E1_PINS _E2_PINS _E3_PINS \
  237. analogInputToDigitalPin(TEMP_BED_PIN) \
  238. }
  239. #define HAS_DIGIPOTSS (DIGIPOTSS_PIN >= 0)
  240. #endif //__PINS_H