My Marlin configs for Fabrikator Mini and CTC i3 Pro B
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950
  1. #ifndef PINS_H
  2. #define PINS_H
  3. #if MOTHERBOARD == 99
  4. #define KNOWN_BOARD 1
  5. #define X_STEP_PIN 2
  6. #define X_DIR_PIN 3
  7. #define X_ENABLE_PIN -1
  8. #define X_MIN_PIN -1
  9. #define X_MAX_PIN 16
  10. #define Y_STEP_PIN 5
  11. #define Y_DIR_PIN 6
  12. #define Y_ENABLE_PIN -1
  13. #define Y_MIN_PIN 67
  14. #define Y_MAX_PIN -1
  15. #define Z_STEP_PIN 62
  16. #define Z_DIR_PIN 63
  17. #define Z_ENABLE_PIN -1
  18. #define Z_MIN_PIN 59
  19. #define Z_MAX_PIN -1
  20. #define E0_STEP_PIN 65
  21. #define E0_DIR_PIN 66
  22. #define E0_ENABLE_PIN -1
  23. #define SDPOWER -1
  24. #define SDSS 53
  25. #define LED_PIN -1
  26. #define FAN_PIN -1
  27. #define PS_ON_PIN 9
  28. #define KILL_PIN -1
  29. #define HEATER_0_PIN 13
  30. #define HEATER_1_PIN -1
  31. #define HEATER_2_PIN -1
  32. #define TEMP_0_PIN 6 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  33. #define TEMP_1_PIN -1 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  34. #define TEMP_2_PIN -1 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  35. #define HEATER_BED_PIN 4
  36. #define TEMP_BED_PIN 10
  37. #endif /* 99 */
  38. /****************************************************************************************
  39. * Gen7 v1.1, v1.2, v1.3 pin assignment
  40. *
  41. ****************************************************************************************/
  42. #if MOTHERBOARD == 12
  43. #define MOTHERBOARD 11
  44. #define GEN7_V_1_3
  45. #endif
  46. #if MOTHERBOARD == 11
  47. #define KNOWN_BOARD
  48. #if !defined(__AVR_ATmega644P__) && !defined(__AVR_ATmega644__) && !defined(__AVR_ATmega1284P__)
  49. #error Oops! Make sure you have 'Gen7' selected from the 'Tools -> Boards' menu.
  50. #endif
  51. //x axis pins
  52. #define X_STEP_PIN 19
  53. #define X_DIR_PIN 18
  54. #define X_ENABLE_PIN 24
  55. #define X_MIN_PIN 7
  56. #define X_MAX_PIN -1
  57. //y axis pins
  58. #define Y_STEP_PIN 23
  59. #define Y_DIR_PIN 22
  60. #define Y_ENABLE_PIN 24
  61. #define Y_MIN_PIN 5
  62. #define Y_MAX_PIN -1
  63. //z axis pins
  64. #define Z_STEP_PIN 26
  65. #define Z_DIR_PIN 25
  66. #define Z_ENABLE_PIN 24
  67. #define Z_MIN_PIN 1
  68. #define Z_MAX_PIN
  69. //extruder pins
  70. #define E0_STEP_PIN 28
  71. #define E0_DIR_PIN 27
  72. #define E0_ENABLE_PIN 24
  73. #define TEMP_0_PIN 1
  74. #define TEMP_1_PIN -1
  75. #define TEMP_2_PIN -1
  76. #define TEMP_BED_PIN 2
  77. #define HEATER_0_PIN 4
  78. #define HEATER_1_PIN -1
  79. #define HEATER_2_PIN -1
  80. #define HEATER_BED_PIN 3
  81. #define SDPOWER -1
  82. #define SDSS -1 // SCL pin of I2C header
  83. #define LED_PIN -1
  84. #ifdef GEN7_V_1_3
  85. // Gen7 v1.3 removed the fan pin
  86. #define FAN_PIN -1
  87. #else
  88. #define FAN_PIN 31
  89. #endif
  90. #define PS_ON_PIN 15
  91. // Gen 1.3 and earlier supplied thermistor power via PS_ON
  92. // Need to ignore the bad thermistor readings on those units
  93. #define BOGUS_TEMPERATURE_FAILSAFE_OVERRIDE
  94. //our pin for debugging.
  95. #define DEBUG_PIN 0
  96. //our RS485 pins
  97. #define TX_ENABLE_PIN 12
  98. #define RX_ENABLE_PIN 13
  99. #endif
  100. /*******************************************************************************
  101. *********
  102. * Gen7 Alfons3 pin assignment
  103. *
  104. ********************************************************************************
  105. ********/
  106. /* These Pins are assigned for the modified GEN7 Board from Alfons3 Please review the pins and adjust it for your needs*/
  107. #if MOTHERBOARD == 10
  108. #define KNOWN_BOARD
  109. #if !defined(__AVR_ATmega644P__) && !defined(__AVR_ATmega644__) && !defined(__AVR_ATmega1284P__)
  110. #error Oops! Make sure you have 'Gen7' selected from the 'Tools -> Boards' menu.
  111. #endif
  112. //x axis pins
  113. #define X_STEP_PIN 21 //different from stanard GEN7
  114. #define X_DIR_PIN 20 //different from stanard GEN7
  115. #define X_ENABLE_PIN 24
  116. #define X_MIN_PIN 0
  117. #define X_MAX_PIN -1
  118. //y axis pins
  119. #define Y_STEP_PIN 23
  120. #define Y_DIR_PIN 22
  121. #define Y_ENABLE_PIN 24
  122. #define Y_MIN_PIN 1
  123. #define Y_MAX_PIN -1
  124. //z axis pins
  125. #define Z_STEP_PIN 26
  126. #define Z_DIR_PIN 25
  127. #define Z_ENABLE_PIN 24
  128. #define Z_MIN_PIN 2
  129. #define Z_MAX_PIN -1
  130. //extruder pins
  131. #define E0_STEP_PIN 28
  132. #define E0_DIR_PIN 27
  133. #define E0_ENABLE_PIN 24
  134. #define TEMP_0_PIN 2
  135. #define TEMP_1_PIN -1
  136. #define TEMP_2_PIN -1
  137. #define TEMP_BED_PIN 1 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 34 bed)
  138. #define HEATER_0_PIN 4
  139. #define HEATER_1_PIN -1
  140. #define HEATER_2_PIN -1
  141. #define HEATER_BED_PIN 3 // (bed)
  142. #define SDPOWER -1
  143. #define SDSS 31 // SCL pin of I2C header || CS Pin for SD Card support
  144. #define LED_PIN -1
  145. #define FAN_PIN -1
  146. #define PS_ON_PIN 19
  147. //our pin for debugging.
  148. #define DEBUG_PIN -1
  149. //our RS485 pins
  150. //#define TX_ENABLE_PIN 12
  151. //#define RX_ENABLE_PIN 13
  152. #define BEEPER -1
  153. #define SDCARDDETECT -1
  154. #define SUICIDE_PIN -1 //has to be defined; otherwise Power_off doesn't work
  155. //Pins for 4bit LCD Support
  156. #define LCD_PINS_RS 18
  157. #define LCD_PINS_ENABLE 17
  158. #define LCD_PINS_D4 16
  159. #define LCD_PINS_D5 15
  160. #define LCD_PINS_D6 13
  161. #define LCD_PINS_D7 14
  162. //buttons are directly attached
  163. #define BTN_EN1 11
  164. #define BTN_EN2 10
  165. #define BTN_ENC 12 //the click
  166. #define BLEN_C 2
  167. #define BLEN_B 1
  168. #define BLEN_A 0
  169. #define encrot0 0
  170. #define encrot1 2
  171. #define encrot2 3
  172. #define encrot3 1
  173. #endif
  174. /****************************************************************************************
  175. * Arduino Mega pin assignment
  176. *
  177. ****************************************************************************************/
  178. #if MOTHERBOARD == 3 || MOTHERBOARD == 33 || MOTHERBOARD == 34
  179. #define KNOWN_BOARD 1
  180. //////////////////FIX THIS//////////////
  181. #ifndef __AVR_ATmega1280__
  182. #ifndef __AVR_ATmega2560__
  183. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  184. #endif
  185. #endif
  186. // uncomment one of the following lines for RAMPS v1.3 or v1.0, comment both for v1.2 or 1.1
  187. // #define RAMPS_V_1_3
  188. // #define RAMPS_V_1_0
  189. #ifdef MOTHERBOARD == 33 || MOTHERBOARD == 34
  190. #define X_STEP_PIN 54
  191. #define X_DIR_PIN 55
  192. #define X_ENABLE_PIN 38
  193. #define X_MIN_PIN 3
  194. #define X_MAX_PIN 2 //2 //Max endstops default to disabled "-1", set to commented value to enable.
  195. #define Y_STEP_PIN 60
  196. #define Y_DIR_PIN 61
  197. #define Y_ENABLE_PIN 56
  198. #define Y_MIN_PIN 14
  199. #define Y_MAX_PIN 15 //15
  200. #define Z_STEP_PIN 46
  201. #define Z_DIR_PIN 48
  202. #define Z_ENABLE_PIN 62
  203. #define Z_MIN_PIN 18
  204. #define Z_MAX_PIN 19
  205. #define E0_STEP_PIN 26
  206. #define E0_DIR_PIN 28
  207. #define E0_ENABLE_PIN 24
  208. #define E1_STEP_PIN 36
  209. #define E1_DIR_PIN 34
  210. #define E1_ENABLE_PIN 30
  211. #define SDPOWER -1
  212. #define SDSS 53
  213. #define LED_PIN 13
  214. #if MOTHERBOARD == 33
  215. #define FAN_PIN 9 // (Sprinter config)
  216. #else
  217. #define FAN_PIN 4 // IO pin. Buffer needed
  218. #endif
  219. #define PS_ON_PIN 12
  220. #define KILL_PIN -1
  221. #define HEATER_0_PIN 10 // EXTRUDER 1
  222. #if MOTHERBOARD == 33
  223. #define HEATER_1_PIN -1
  224. #else
  225. #define HEATER_1_PIN 9 // EXTRUDER 2 (FAN On Sprinter)
  226. #endif
  227. #define HEATER_2_PIN -1
  228. #define TEMP_0_PIN 13 // ANALOG NUMBERING
  229. #define TEMP_1_PIN 15 // ANALOG NUMBERING
  230. #define TEMP_2_PIN -1 // ANALOG NUMBERING
  231. #define HEATER_BED_PIN 8 // BED
  232. #define TEMP_BED_PIN 14 // ANALOG NUMBERING
  233. #ifdef ULTRA_LCD
  234. #ifdef NEWPANEL
  235. //arduino pin which triggers an piezzo beeper
  236. #define BEEPER 33 // Beeper on AUX-4
  237. #define LCD_PINS_RS 16
  238. #define LCD_PINS_ENABLE 17
  239. #define LCD_PINS_D4 23
  240. #define LCD_PINS_D5 25
  241. #define LCD_PINS_D6 27
  242. #define LCD_PINS_D7 29
  243. //buttons are directly attached using AUX-2
  244. #define BTN_EN1 44
  245. #define BTN_EN2 42
  246. #define BTN_ENC 64 //the click
  247. #define BLEN_C 2
  248. #define BLEN_B 1
  249. #define BLEN_A 0
  250. #define SDCARDDETECT 31 // Ramps does not use this port
  251. //encoder rotation values
  252. #define encrot0 0
  253. #define encrot1 2
  254. #define encrot2 3
  255. #define encrot3 1
  256. #else //old style panel with shift register
  257. //arduino pin witch triggers an piezzo beeper
  258. #define BEEPER 33 No Beeper added
  259. //buttons are attached to a shift register
  260. // Not wired this yet
  261. //#define SHIFT_CLK 38
  262. //#define SHIFT_LD 42
  263. //#define SHIFT_OUT 40
  264. //#define SHIFT_EN 17
  265. #define LCD_PINS_RS 16
  266. #define LCD_PINS_ENABLE 17
  267. #define LCD_PINS_D4 23
  268. #define LCD_PINS_D5 25
  269. #define LCD_PINS_D6 27
  270. #define LCD_PINS_D7 29
  271. //encoder rotation values
  272. #define encrot0 0
  273. #define encrot1 2
  274. #define encrot2 3
  275. #define encrot3 1
  276. //bits in the shift register that carry the buttons for:
  277. // left up center down right red
  278. #define BL_LE 7
  279. #define BL_UP 6
  280. #define BL_MI 5
  281. #define BL_DW 4
  282. #define BL_RI 3
  283. #define BL_ST 2
  284. #define BLEN_B 1
  285. #define BLEN_A 0
  286. #endif
  287. #endif //ULTRA_LCD
  288. #else // RAMPS_V_1_1 or RAMPS_V_1_2 as default
  289. #define X_STEP_PIN 26
  290. #define X_DIR_PIN 28
  291. #define X_ENABLE_PIN 24
  292. #define X_MIN_PIN 3
  293. #define X_MAX_PIN -1 //2
  294. #define Y_STEP_PIN 38
  295. #define Y_DIR_PIN 40
  296. #define Y_ENABLE_PIN 36
  297. #define Y_MIN_PIN 16
  298. #define Y_MAX_PIN -1 //17
  299. #define Z_STEP_PIN 44
  300. #define Z_DIR_PIN 46
  301. #define Z_ENABLE_PIN 42
  302. #define Z_MIN_PIN 18
  303. #define Z_MAX_PIN -1 //19
  304. #define E0_STEP_PIN 32
  305. #define E0_DIR_PIN 34
  306. #define E0_ENABLE_PIN 30
  307. #define SDPOWER 48
  308. #define SDSS 53
  309. #define LED_PIN 13
  310. #define PS_ON_PIN -1
  311. #define KILL_PIN -1
  312. #ifdef RAMPS_V_1_0 // RAMPS_V_1_0
  313. #define HEATER_0_PIN 12 // RAMPS 1.0
  314. #define HEATER_BED_PIN -1 // RAMPS 1.0
  315. #define FAN_PIN 11 // RAMPS 1.0
  316. #else // RAMPS_V_1_1 or RAMPS_V_1_2
  317. #define HEATER_0_PIN 10 // RAMPS 1.1
  318. #define HEATER_BED_PIN 8 // RAMPS 1.1
  319. #define FAN_PIN 9 // RAMPS 1.1
  320. #endif
  321. #define HEATER_1_PIN -1
  322. #define HEATER_2_PIN -1
  323. #define TEMP_0_PIN 2 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  324. #define TEMP_1_PIN -1
  325. #define TEMP_2_PIN -1
  326. #define TEMP_BED_PIN 1 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  327. #endif
  328. // SPI for Max6675 Thermocouple
  329. #ifndef SDSUPPORT
  330. // these pins are defined in the SD library if building with SD support
  331. #define MAX_SCK_PIN 52
  332. #define MAX_MISO_PIN 50
  333. #define MAX_MOSI_PIN 51
  334. #define MAX6675_SS 53
  335. #else
  336. #define MAX6675_SS 49
  337. #endif
  338. #endif
  339. /****************************************************************************************
  340. * Duemilanove w/ ATMega328P pin assignment
  341. *
  342. ****************************************************************************************/
  343. #if MOTHERBOARD == 4
  344. #define KNOWN_BOARD 1
  345. #ifndef __AVR_ATmega328P__
  346. #error Oops! Make sure you have 'Arduino Duemilanove w/ ATMega328' selected from the 'Tools -> Boards' menu.
  347. #endif
  348. #define X_STEP_PIN 19
  349. #define X_DIR_PIN 18
  350. #define X_ENABLE_PIN -1
  351. #define X_MIN_PIN 17
  352. #define X_MAX_PIN -1
  353. #define Y_STEP_PIN 10
  354. #define Y_DIR_PIN 7
  355. #define Y_ENABLE_PIN -1
  356. #define Y_MIN_PIN 8
  357. #define Y_MAX_PIN -1
  358. #define Z_STEP_PIN 13
  359. #define Z_DIR_PIN 3
  360. #define Z_ENABLE_PIN 2
  361. #define Z_MIN_PIN 4
  362. #define Z_MAX_PIN -1
  363. #define E0_STEP_PIN 11
  364. #define E0_DIR_PIN 12
  365. #define E0_ENABLE_PIN -1
  366. #define SDPOWER -1
  367. #define SDSS -1
  368. #define LED_PIN -1
  369. #define FAN_PIN 5
  370. #define PS_ON_PIN -1
  371. #define KILL_PIN -1
  372. #define HEATER_0_PIN 6
  373. #define HEATER_1_PIN -1
  374. #define HEATER_2_PIN -1
  375. #define TEMP_0_PIN 0 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  376. #define TEMP_1_PIN -1
  377. #define TEMP_2_PIN -1
  378. #define HEATER_BED_PIN -1
  379. #define TEMP_BED_PIN -1
  380. #endif
  381. /****************************************************************************************
  382. * Gen6 pin assignment
  383. *
  384. ****************************************************************************************/
  385. #if MOTHERBOARD == 5 || MOTHERBOARD == 51
  386. #define KNOWN_BOARD 1
  387. #ifndef __AVR_ATmega644P__
  388. #ifndef __AVR_ATmega1284P__
  389. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu.
  390. #endif
  391. #endif
  392. //x axis pins
  393. #define X_STEP_PIN 15
  394. #define X_DIR_PIN 18
  395. #define X_ENABLE_PIN 19
  396. #define X_MIN_PIN 20
  397. #define X_MAX_PIN -1
  398. //y axis pins
  399. #define Y_STEP_PIN 23
  400. #define Y_DIR_PIN 22
  401. #define Y_ENABLE_PIN 24
  402. #define Y_MIN_PIN 25
  403. #define Y_MAX_PIN -1
  404. //z axis pins
  405. #define Z_STEP_PIN 27
  406. #define Z_DIR_PIN 28
  407. #define Z_ENABLE_PIN 29
  408. #define Z_MIN_PIN 30
  409. #define Z_MAX_PIN -1
  410. //extruder pins
  411. #define E0_STEP_PIN 4 //Edited @ EJE Electronics 20100715
  412. #define E0_DIR_PIN 2 //Edited @ EJE Electronics 20100715
  413. #define E0_ENABLE_PIN 3 //Added @ EJE Electronics 20100715
  414. #define TEMP_0_PIN 5 //changed @ rkoeppl 20110410
  415. #define TEMP_1_PIN -1 //changed @ rkoeppl 20110410
  416. #define TEMP_2_PIN -1 //changed @ rkoeppl 20110410
  417. #define HEATER_0_PIN 14 //changed @ rkoeppl 20110410
  418. #define HEATER_1_PIN -1
  419. #define HEATER_2_PIN -1
  420. #if MOTHERBOARD == 5
  421. #define HEATER_BED_PIN -1 //changed @ rkoeppl 20110410
  422. #define TEMP_BED_PIN -1 //changed @ rkoeppl 20110410
  423. #else
  424. #define HEATER_BED_PIN 1 //changed @ rkoeppl 20110410
  425. #define TEMP_BED_PIN 0 //changed @ rkoeppl 20110410
  426. #endif
  427. #define SDPOWER -1
  428. #define SDSS 17
  429. #define LED_PIN -1 //changed @ rkoeppl 20110410
  430. #define FAN_PIN -1 //changed @ rkoeppl 20110410
  431. #define PS_ON_PIN -1 //changed @ rkoeppl 20110410
  432. //our pin for debugging.
  433. #define DEBUG_PIN 0
  434. //our RS485 pins
  435. #define TX_ENABLE_PIN 12
  436. #define RX_ENABLE_PIN 13
  437. #endif
  438. /****************************************************************************************
  439. * Sanguinololu pin assignment
  440. *
  441. ****************************************************************************************/
  442. #if MOTHERBOARD == 62
  443. #undef MOTHERBOARD
  444. #define MOTHERBOARD 6
  445. #define SANGUINOLOLU_V_1_2
  446. #endif
  447. #if MOTHERBOARD == 6
  448. #define KNOWN_BOARD 1
  449. #ifndef __AVR_ATmega644P__
  450. #ifndef __AVR_ATmega1284P__
  451. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu.
  452. #endif
  453. #endif
  454. #define X_STEP_PIN 15
  455. #define X_DIR_PIN 21
  456. #define X_MIN_PIN 18
  457. #define X_MAX_PIN -1
  458. #define Y_STEP_PIN 22
  459. #define Y_DIR_PIN 23
  460. #define Y_MIN_PIN 19
  461. #define Y_MAX_PIN -1
  462. #define Z_STEP_PIN 3
  463. #define Z_DIR_PIN 2
  464. #define Z_MIN_PIN 20
  465. #define Z_MAX_PIN -1
  466. #define E0_STEP_PIN 1
  467. #define E0_DIR_PIN 0
  468. #define LED_PIN -1
  469. #define FAN_PIN -1
  470. #define PS_ON_PIN -1
  471. #define KILL_PIN -1
  472. #define HEATER_0_PIN 13 // (extruder)
  473. #define HEATER_1_PIN -1
  474. #define HEATER_2_PIN -1
  475. #ifdef SANGUINOLOLU_V_1_2
  476. #define HEATER_BED_PIN 12 // (bed)
  477. #define X_ENABLE_PIN 14
  478. #define Y_ENABLE_PIN 14
  479. #define Z_ENABLE_PIN 26
  480. #define E0_ENABLE_PIN 14
  481. #else
  482. #define HEATER_BED_PIN 14 // (bed)
  483. #define X_ENABLE_PIN -1
  484. #define Y_ENABLE_PIN -1
  485. #define Z_ENABLE_PIN -1
  486. #define E0_ENABLE_PIN -1
  487. #endif
  488. #define TEMP_0_PIN 7 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 33 extruder)
  489. #define TEMP_1_PIN -1
  490. #define TEMP_2_PIN -1
  491. #define TEMP_BED_PIN 6 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 34 bed)
  492. #define SDPOWER -1
  493. #define SDSS 31
  494. #endif
  495. #if MOTHERBOARD == 7
  496. #define KNOWN_BOARD
  497. /*****************************************************************
  498. * Ultimaker pin assignment
  499. ******************************************************************/
  500. #ifndef __AVR_ATmega1280__
  501. #ifndef __AVR_ATmega2560__
  502. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  503. #endif
  504. #endif
  505. #define X_STEP_PIN 25
  506. #define X_DIR_PIN 23
  507. #define X_MIN_PIN 22
  508. #define X_MAX_PIN 24
  509. #define X_ENABLE_PIN 27
  510. #define Y_STEP_PIN 31
  511. #define Y_DIR_PIN 33
  512. #define Y_MIN_PIN 26
  513. #define Y_MAX_PIN 28
  514. #define Y_ENABLE_PIN 29
  515. #define Z_STEP_PIN 37
  516. #define Z_DIR_PIN 39
  517. #define Z_MIN_PIN 30
  518. #define Z_MAX_PIN 32
  519. #define Z_ENABLE_PIN 35
  520. #define HEATER_BED_PIN 4
  521. #define TEMP_BED_PIN 10
  522. #define HEATER_0_PIN 2
  523. #define TEMP_0_PIN 8
  524. #define HEATER_1_PIN 3
  525. #define TEMP_1_PIN 9
  526. #define HEATER_2_PIN -1
  527. #define TEMP_2_PIN -1
  528. #define E0_STEP_PIN 43
  529. #define E0_DIR_PIN 45
  530. #define E0_ENABLE_PIN 41
  531. #define E1_STEP_PIN 49
  532. #define E1_DIR_PIN 47
  533. #define E1_ENABLE_PIN 51
  534. #define SDPOWER -1
  535. #define SDSS 53
  536. #define LED_PIN 13
  537. #define FAN_PIN 7
  538. #define PS_ON_PIN 12
  539. #define KILL_PIN -1
  540. #define SUICIDE_PIN 54 //PIN that has to be turned on right after start, to keep power flowing.
  541. #ifdef ULTRA_LCD
  542. #ifdef NEWPANEL
  543. //arduino pin witch triggers an piezzo beeper
  544. #define BEEPER 18
  545. #define LCD_PINS_RS 20
  546. #define LCD_PINS_ENABLE 17
  547. #define LCD_PINS_D4 16
  548. #define LCD_PINS_D5 21
  549. #define LCD_PINS_D6 5
  550. #define LCD_PINS_D7 6
  551. //buttons are directly attached
  552. #define BTN_EN1 40
  553. #define BTN_EN2 42
  554. #define BTN_ENC 19 //the click
  555. #define BLEN_C 2
  556. #define BLEN_B 1
  557. #define BLEN_A 0
  558. #define SDCARDDETECT 38
  559. //encoder rotation values
  560. #define encrot0 0
  561. #define encrot1 2
  562. #define encrot2 3
  563. #define encrot3 1
  564. #else //old style panel with shift register
  565. //arduino pin witch triggers an piezzo beeper
  566. #define BEEPER 18
  567. //buttons are attached to a shift register
  568. #define SHIFT_CLK 38
  569. #define SHIFT_LD 42
  570. #define SHIFT_OUT 40
  571. #define SHIFT_EN 17
  572. #define LCD_PINS_RS 16
  573. #define LCD_PINS_ENABLE 5
  574. #define LCD_PINS_D4 6
  575. #define LCD_PINS_D5 21
  576. #define LCD_PINS_D6 20
  577. #define LCD_PINS_D7 19
  578. //encoder rotation values
  579. #define encrot0 0
  580. #define encrot1 2
  581. #define encrot2 3
  582. #define encrot3 1
  583. //bits in the shift register that carry the buttons for:
  584. // left up center down right red
  585. #define BL_LE 7
  586. #define BL_UP 6
  587. #define BL_MI 5
  588. #define BL_DW 4
  589. #define BL_RI 3
  590. #define BL_ST 2
  591. #define BLEN_B 1
  592. #define BLEN_A 0
  593. #endif
  594. #endif //ULTRA_LCD
  595. #endif
  596. #if MOTHERBOARD == 71
  597. #define KNOWN_BOARD
  598. /*****************************************************************
  599. * Ultimaker pin assignment (Old electronics)
  600. ******************************************************************/
  601. #ifndef __AVR_ATmega1280__
  602. #ifndef __AVR_ATmega2560__
  603. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  604. #endif
  605. #endif
  606. #define X_STEP_PIN 25
  607. #define X_DIR_PIN 23
  608. #define X_MIN_PIN 15
  609. #define X_MAX_PIN 14
  610. #define X_ENABLE_PIN 27
  611. #define Y_STEP_PIN 31
  612. #define Y_DIR_PIN 33
  613. #define Y_MIN_PIN 17
  614. #define Y_MAX_PIN 16
  615. #define Y_ENABLE_PIN 29
  616. #define Z_STEP_PIN 37
  617. #define Z_DIR_PIN 39
  618. #define Z_MIN_PIN 19
  619. #define Z_MAX_PIN 18
  620. #define Z_ENABLE_PIN 35
  621. #define HEATER_BED_PIN -1
  622. #define TEMP_BED_PIN -1
  623. #define HEATER_0_PIN 2
  624. #define TEMP_0_PIN 8
  625. #define HEATER_1_PIN 1
  626. #define TEMP_1_PIN 1
  627. #define HEATER_2_PIN -1
  628. #define TEMP_2_PIN -1
  629. #define E0_STEP_PIN 43
  630. #define E0_DIR_PIN 45
  631. #define E0_ENABLE_PIN 41
  632. #define E1_STEP_PIN -1
  633. #define E1_DIR_PIN -1
  634. #define E1_ENABLE_PIN -1
  635. #define SDPOWER -1
  636. #define SDSS -1
  637. #define LED_PIN -1
  638. #define FAN_PIN -1
  639. #define PS_ON_PIN -1
  640. #define KILL_PIN -1
  641. #define SUICIDE_PIN -1 //PIN that has to be turned on right after start, to keep power flowing.
  642. #define LCD_PINS_RS 24
  643. #define LCD_PINS_ENABLE 22
  644. #define LCD_PINS_D4 36
  645. #define LCD_PINS_D5 34
  646. #define LCD_PINS_D6 32
  647. #define LCD_PINS_D7 30
  648. #endif
  649. /****************************************************************************************
  650. * Teensylu 0.7 pin assingments (ATMEGA90USB)
  651. * Requires the Teensyduino software with Teensy2.0++ selected in arduino IDE!
  652. ****************************************************************************************/
  653. #if MOTHERBOARD == 8
  654. #define MOTHERBOARD 8
  655. #define KNOWN_BOARD 1
  656. #define X_STEP_PIN 0
  657. #define X_DIR_PIN 1
  658. #define X_ENABLE_PIN 39
  659. #define X_MIN_PIN 13
  660. #define X_MAX_PIN -1
  661. #define Y_STEP_PIN 2
  662. #define Y_DIR_PIN 3
  663. #define Y_ENABLE_PIN 38
  664. #define Y_MIN_PIN 14
  665. #define Y_MAX_PIN -1
  666. #define Z_STEP_PIN 4
  667. #define Z_DIR_PIN 5
  668. #define Z_ENABLE_PIN 23
  669. #define Z_MIN_PIN 15
  670. #define Z_MAX_PIN -1
  671. #define E0_STEP_PIN 6
  672. #define E0_DIR_PIN 7
  673. #define E0_ENABLE_PIN 19
  674. #define HEATER_0_PIN 21 // Extruder
  675. #define HEATER_1_PIN -1
  676. #define HEATER_2_PIN -1
  677. #define HEATER_BED_PIN 20 // Bed
  678. #define FAN_PIN 22 // Fan
  679. #define TEMP_0_PIN 7 // Extruder
  680. #define TEMP_1_PIN -1
  681. #define TEMP_2_PIN -1
  682. #define TEMP_BED_PIN 6 // Bed
  683. #define SDPOWER -1
  684. #define SDSS 8
  685. #define LED_PIN -1
  686. #define PS_ON_PIN -1
  687. #define KILL_PIN -1
  688. #define ALARM_PIN -1
  689. #ifndef SDSUPPORT
  690. // these pins are defined in the SD library if building with SD support
  691. #define SCK_PIN 9
  692. #define MISO_PIN 11
  693. #define MOSI_PIN 10
  694. #endif
  695. #endif
  696. /****************************************************************************************
  697. * Gen3+ pin assignment
  698. *
  699. ****************************************************************************************/
  700. #if MOTHERBOARD == 9
  701. #define MOTHERBOARD 6
  702. #define KNOWN_BOARD 1
  703. #ifndef __AVR_ATmega644P__
  704. #ifndef __AVR_ATmega1284P__
  705. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu.
  706. #endif
  707. #endif
  708. #define X_STEP_PIN 15
  709. #define X_DIR_PIN 18
  710. #define X_MIN_PIN 20
  711. #define X_MAX_PIN -1
  712. #define Y_STEP_PIN 23
  713. #define Y_DIR_PIN 22
  714. #define Y_MIN_PIN 25
  715. #define Y_MAX_PIN -1
  716. #define Z_STEP_PIN 27
  717. #define Z_DIR_PIN 28
  718. #define Z_MIN_PIN 30
  719. #define Z_MAX_PIN -1
  720. #define E_STEP_PIN 17
  721. #define E_DIR_PIN 21
  722. #define LED_PIN -1
  723. #define FAN_PIN -1
  724. #define PS_ON_PIN 14
  725. #define KILL_PIN -1
  726. #define HEATER_0_PIN 12 // (extruder)
  727. #define HEATER_1_PIN 16 // (bed)
  728. #define X_ENABLE_PIN 19
  729. #define Y_ENABLE_PIN 24
  730. #define Z_ENABLE_PIN 29
  731. #define E_ENABLE_PIN 13
  732. #define TEMP_0_PIN 0 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 33 extruder)
  733. #define TEMP_1_PIN 5 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 34 bed)
  734. #define TEMP_2_PIN -1
  735. #define SDPOWER -1
  736. #define SDSS 4
  737. #define HEATER_2_PIN -1
  738. #endif
  739. #ifndef KNOWN_BOARD
  740. #error Unknown MOTHERBOARD value in configuration.h
  741. #endif
  742. //List of pins which to ignore when asked to change by gcode, 0 and 1 are RX and TX, do not mess with those!
  743. #define _E0_PINS E0_STEP_PIN, E0_DIR_PIN, E0_ENABLE_PIN
  744. #if EXTRUDERS == 3
  745. #define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN
  746. #define _E2_PINS E2_STEP_PIN, E2_DIR_PIN, E2_ENABLE_PIN
  747. #elif EXTRUDERS == 2
  748. #define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN
  749. #define _E2_PINS -1
  750. #elif EXTRUDERS == 1
  751. #define _E1_PINS -1
  752. #define _E2_PINS -1
  753. #else
  754. #error Unsupported number of extruders
  755. #endif
  756. #define SENSITIVE_PINS {0, 1, X_STEP_PIN, X_DIR_PIN, X_ENABLE_PIN, X_MIN_PIN, X_MAX_PIN, Y_STEP_PIN, Y_DIR_PIN, Y_ENABLE_PIN, Y_MIN_PIN, Y_MAX_PIN, Z_STEP_PIN, Z_DIR_PIN, Z_ENABLE_PIN, Z_MIN_PIN, Z_MAX_PIN, LED_PIN, PS_ON_PIN, \
  757. HEATER_0_PIN, HEATER_1_PIN, HEATER_2_PIN, \
  758. HEATER_BED_PIN, FAN_PIN, \
  759. _E0_PINS, _E1_PINS, _E2_PINS, \
  760. TEMP_0_PIN, TEMP_1_PIN, TEMP_2_PIN, TEMP_BED_PIN }
  761. #endif