My Marlin configs for Fabrikator Mini and CTC i3 Pro B
Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

pins_ULTIMAKER_OLD.h 10.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
  4. *
  5. * Based on Sprinter and grbl.
  6. * Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
  7. *
  8. * This program is free software: you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation, either version 3 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program. If not, see <https://www.gnu.org/licenses/>.
  20. *
  21. */
  22. #pragma once
  23. /**
  24. * Ultimaker pin assignments (Old electronics)
  25. */
  26. /**
  27. * Rev B 3 JAN 2017
  28. *
  29. * Details on pin definitions for M3, M4 & M5 spindle control commands and for
  30. * the CASE_LIGHT_PIN are at the end of this file.
  31. *
  32. * This started out as an attempt to add pin definitions for M3, M4 & M5 spindle
  33. * control commands but quickly turned into a head scratcher as the sources for
  34. * the revisions provided inconsistent information.
  35. *
  36. * As best I can determine:
  37. * 1.5.3 boards should use the pins_ULTIMAKER.h file which means the BOARD_INFO_NAME
  38. * define in this file should say 1.5.3 rather than 1.5.4
  39. * This file is meant for 1.1 - 1.3 boards.
  40. * The endstops for the 1.0 boards use different definitions than on the 1.1 - 1.3
  41. * boards.
  42. *
  43. * I've added sections that have the 1.0 and 1.5.3 + endstop definitions so you can
  44. * easily switch if needed. I've also copied over the 1.5.3 + LCD definitions.
  45. *
  46. * To be 100% sure of the board you have:
  47. * 1. In Configuration_adv.h enable "PINS_DEBUGGING"
  48. * 2. Compile & uploade
  49. * 3. Enter the command "M43 W1 I1". This command will report that pin nmumber and
  50. * name of any pin that changes state.
  51. * 4. Using a 1k (approximately) resistor pull the endstops and some of the LCD pins
  52. * to ground and see what is reported.
  53. * 5. If the reported pin doesn't match the file then try a different board revision
  54. * and repeat steps 2 - 5
  55. */
  56. #define BOARD_REV_1_1_TO_1_3
  57. //#define BOARD_REV_1_0
  58. //#define BOARD_REV_1_5
  59. #include "env_validate.h"
  60. #ifdef BOARD_REV_1_1_TO_1_3
  61. #define BOARD_INFO_NAME "Ultimaker 1.1-1.3"
  62. #elif defined(BOARD_REV_1_0)
  63. #define BOARD_INFO_NAME "Ultimaker 1.0"
  64. #elif defined(BOARD_REV_1_5)
  65. #define BOARD_INFO_NAME "Ultimaker 1.5"
  66. #else
  67. #define BOARD_INFO_NAME "Ultimaker 1.5.4+"
  68. #endif
  69. #define DEFAULT_MACHINE_NAME "Ultimaker"
  70. #define DEFAULT_SOURCE_CODE_URL "github.com/Ultimaker/Marlin"
  71. //
  72. // Limit Switches
  73. //
  74. #if ENABLED(BOARD_REV_1_1_TO_1_3)
  75. #define X_MIN_PIN 15 // SW1
  76. #define X_MAX_PIN 14 // SW2
  77. #define Y_MIN_PIN 17 // SW3
  78. #define Y_MAX_PIN 16 // SW4
  79. #define Z_MIN_PIN 19 // SW5
  80. #define Z_MAX_PIN 18 // SW6
  81. #endif
  82. #if ENABLED(BOARD_REV_1_0)
  83. #if HAS_CUTTER
  84. #define X_STOP_PIN 13 // SW1 (didn't change) - also has a useable hardware PWM
  85. #define Y_STOP_PIN 12 // SW2
  86. #define Z_STOP_PIN 11 // SW3
  87. #else
  88. #define X_MIN_PIN 13 // SW1
  89. #define X_MAX_PIN 12 // SW2
  90. #define Y_MIN_PIN 11 // SW3
  91. #define Y_MAX_PIN 10 // SW4
  92. #define Z_MIN_PIN 9 // SW5
  93. #define Z_MAX_PIN 8 // SW6
  94. #endif
  95. #endif
  96. #if ENABLED(BOARD_REV_1_5)
  97. #define X_MIN_PIN 22
  98. #define X_MAX_PIN 24
  99. #define Y_MIN_PIN 26
  100. #define Y_MAX_PIN 28
  101. #define Z_MIN_PIN 30
  102. #define Z_MAX_PIN 32
  103. #endif
  104. //
  105. // Z Probe (when not Z_MIN_PIN)
  106. //
  107. #if !defined(Z_MIN_PROBE_PIN) && !BOTH(HAS_CUTTER, BOARD_REV_1_0)
  108. #define Z_MIN_PROBE_PIN Z_MAX_PIN
  109. #endif
  110. //
  111. // Steppers
  112. //
  113. #define X_STEP_PIN 25
  114. #define X_DIR_PIN 23
  115. #define X_ENABLE_PIN 27
  116. #define Y_STEP_PIN 31
  117. #define Y_DIR_PIN 33
  118. #define Y_ENABLE_PIN 29
  119. #define Z_STEP_PIN 37
  120. #define Z_DIR_PIN 39
  121. #define Z_ENABLE_PIN 35
  122. #if BOTH(HAS_CUTTER, BOARD_REV_1_1_TO_1_3) && EXTRUDERS == 1
  123. // Move E0 to the spare and get Spindle/Laser signals from E0
  124. #define E0_STEP_PIN 49
  125. #define E0_DIR_PIN 47
  126. #define E0_ENABLE_PIN 48
  127. #else
  128. #define E0_STEP_PIN 43
  129. #define E0_DIR_PIN 45
  130. #define E0_ENABLE_PIN 41
  131. #define E1_STEP_PIN 49
  132. #define E1_DIR_PIN 47
  133. #define E1_ENABLE_PIN 48
  134. #endif
  135. //
  136. // Temperature Sensors
  137. //
  138. #define TEMP_0_PIN 8 // Analog Input
  139. #define TEMP_1_PIN 1 // Analog Input
  140. //
  141. // Heaters / Fans
  142. //
  143. #define HEATER_0_PIN 2
  144. //#define HEATER_1_PIN 3 // used for case light Rev A said "1"
  145. #define HEATER_BED_PIN 4
  146. //
  147. // LCD / Controller
  148. //
  149. #if EITHER(BOARD_REV_1_0, BOARD_REV_1_1_TO_1_3)
  150. #define LCD_PINS_RS 24
  151. #define LCD_PINS_ENABLE 22
  152. #define LCD_PINS_D4 36
  153. #define LCD_PINS_D5 34
  154. #define LCD_PINS_D6 32
  155. #define LCD_PINS_D7 30
  156. #elif BOTH(BOARD_REV_1_5, HAS_WIRED_LCD)
  157. #define BEEPER_PIN 18
  158. #if IS_NEWPANEL
  159. #define LCD_PINS_RS 20
  160. #define LCD_PINS_ENABLE 17
  161. #define LCD_PINS_D4 16
  162. #define LCD_PINS_D5 21
  163. #define LCD_PINS_D6 5
  164. #define LCD_PINS_D7 6
  165. // Buttons directly attached
  166. #define BTN_EN1 40
  167. #define BTN_EN2 42
  168. #define BTN_ENC 19
  169. #define SD_DETECT_PIN 38
  170. #else // !IS_NEWPANEL - Old style panel with shift register
  171. // Buttons attached to a shift register
  172. #define SHIFT_CLK_PIN 38
  173. #define SHIFT_LD_PIN 42
  174. #define SHIFT_OUT_PIN 40
  175. #define SHIFT_EN_PIN 17
  176. #define LCD_PINS_RS 16
  177. #define LCD_PINS_ENABLE 5
  178. #define LCD_PINS_D4 6
  179. #define LCD_PINS_D5 21
  180. #define LCD_PINS_D6 20
  181. #define LCD_PINS_D7 19
  182. #endif // !IS_NEWPANEL
  183. #endif
  184. //
  185. // case light - see spindle section for more info on available hardware PWMs
  186. //
  187. #if !PIN_EXISTS(CASE_LIGHT) && ENABLED(BOARD_REV_1_5)
  188. #define CASE_LIGHT_PIN 7 // use PWM - MUST BE HARDWARE PWM
  189. #endif
  190. //
  191. // M3/M4/M5 - Spindle/Laser Control
  192. //
  193. #if HAS_CUTTER
  194. #if EITHER(BOARD_REV_1_0, BOARD_REV_1_5) // Use the last three SW positions
  195. #define SPINDLE_DIR_PIN 10 // 1.0: SW4 1.5: EXP3-6 ("10")
  196. #define SPINDLE_LASER_PWM_PIN 9 // 1.0: SW5 1.5: EXP3-7 ( "9") .. MUST BE HARDWARE PWM
  197. #define SPINDLE_LASER_ENA_PIN 8 // 1.0: SW6 1.5: EXP3-8 ( "8") .. Pin should have a pullup!
  198. #elif ENABLED(BOARD_REV_1_1_TO_1_3)
  199. /**
  200. * Only four hardware PWMs physically connected to anything on these boards:
  201. *
  202. * HEATER_0_PIN 2 silkscreen varies - usually "PWM 1" or "HEATER1"
  203. * HEATER_1_PIN 3 silkscreen varies - usually "PWM 2" or "HEATER2"
  204. * HEATER_BED_PIN 4 silkscreen varies - usually "PWM 3" or "HEATED BED"
  205. * E0_DIR_PIN 45
  206. *
  207. * If one of the heaters is used then special precautions will usually be needed.
  208. * They have an LED and resistor pullup to +24V which could damage 3.3V-5V ICs.
  209. */
  210. #if EXTRUDERS == 1
  211. #define SPINDLE_DIR_PIN 43
  212. #define SPINDLE_LASER_PWM_PIN 45 // Hardware PWM
  213. #define SPINDLE_LASER_ENA_PIN 41 // Pullup!
  214. #elif TEMP_SENSOR_BED == 0 // Can't use E0 so see if HEATER_BED_PIN is available
  215. #undef HEATER_BED_PIN
  216. #define SPINDLE_DIR_PIN 38 // Probably pin 4 on 10 pin connector closest to the E0 socket
  217. #define SPINDLE_LASER_PWM_PIN 4 // Hardware PWM - Special precautions usually needed.
  218. #define SPINDLE_LASER_ENA_PIN 40 // Pullup! (Probably pin 6 on the 10-pin
  219. // connector closest to the E0 socket)
  220. #endif
  221. #endif
  222. #endif
  223. /**
  224. * Where to get the spindle signals on the E0 socket
  225. *
  226. * spindle signal socket name socket name
  227. * -------
  228. * SPINDLE_LASER_ENA_PIN /ENABLE *| |O VMOT
  229. * MS1 O| |O GND
  230. * MS2 O| |O 2B
  231. * MS3 O| |O 2A
  232. * /RESET O| |O 1A
  233. * /SLEEP O| |O 1B
  234. * SPINDLE_DIR_PIN STEP O| |O VDD
  235. * SPINDLE_LASER_PWM_PIN DIR O| |O GND
  236. * -------
  237. * * - pin closest to MS1, MS2 & MS3 jumpers on the board
  238. *
  239. * Note: Socket names vary from vendor to vendor.
  240. */