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.

pins.h 58KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179
  1. #ifndef PINS_H
  2. #define PINS_H
  3. #define X_MS1_PIN -1
  4. #define X_MS2_PIN -1
  5. #define Y_MS1_PIN -1
  6. #define Y_MS2_PIN -1
  7. #define Z_MS1_PIN -1
  8. #define Z_MS2_PIN -1
  9. #define E0_MS1_PIN -1
  10. #define E0_MS2_PIN -1
  11. #define E1_MS1_PIN -1
  12. #define E1_MS2_PIN -1
  13. #define DIGIPOTSS_PIN -1
  14. #if MOTHERBOARD == 99
  15. #define KNOWN_BOARD 1
  16. #define X_STEP_PIN 2
  17. #define X_DIR_PIN 3
  18. #define X_ENABLE_PIN -1
  19. #define X_STOP_PIN 16
  20. #define Y_STEP_PIN 5
  21. #define Y_DIR_PIN 6
  22. #define Y_ENABLE_PIN -1
  23. #define Y_STOP_PIN 67
  24. #define Z_STEP_PIN 62
  25. #define Z_DIR_PIN 63
  26. #define Z_ENABLE_PIN -1
  27. #define Z_STOP_PIN 59
  28. #define E0_STEP_PIN 65
  29. #define E0_DIR_PIN 66
  30. #define E0_ENABLE_PIN -1
  31. #define SDPOWER -1
  32. #define SDSS 53
  33. #define LED_PIN -1
  34. #define FAN_PIN -1
  35. #define PS_ON_PIN 9
  36. #define KILL_PIN -1
  37. #define HEATER_0_PIN 13
  38. #define HEATER_1_PIN -1
  39. #define HEATER_2_PIN -1
  40. #define TEMP_0_PIN 6 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  41. #define TEMP_1_PIN -1 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  42. #define TEMP_2_PIN -1 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  43. #define HEATER_BED_PIN 4
  44. #define TEMP_BED_PIN 10
  45. #endif /* 99 */
  46. /****************************************************************************************
  47. * Gen7 v1.1, v1.2, v1.3 pin assignment
  48. *
  49. ****************************************************************************************/
  50. #if MOTHERBOARD == 12
  51. #define MOTHERBOARD 11
  52. #define GEN7_VERSION 13 // v1.3
  53. #endif
  54. #if MOTHERBOARD == 11
  55. #define KNOWN_BOARD
  56. #if !defined(__AVR_ATmega644P__) && !defined(__AVR_ATmega644__) && !defined(__AVR_ATmega1284P__)
  57. #error Oops! Make sure you have 'Gen7' selected from the 'Tools -> Boards' menu.
  58. #endif
  59. #ifndef GEN7_VERSION
  60. #define GEN7_VERSION 12 // v1.x
  61. #endif
  62. //x axis pins
  63. #define X_STEP_PIN 19
  64. #define X_DIR_PIN 18
  65. #define X_ENABLE_PIN 24
  66. #define X_STOP_PIN 7
  67. //y axis pins
  68. #define Y_STEP_PIN 23
  69. #define Y_DIR_PIN 22
  70. #define Y_ENABLE_PIN 24
  71. #define Y_STOP_PIN 5
  72. //z axis pins
  73. #define Z_STEP_PIN 26
  74. #define Z_DIR_PIN 25
  75. #define Z_ENABLE_PIN 24
  76. #define Z_MIN_PIN 1
  77. #define Z_MAX_PIN 0
  78. //extruder pins
  79. #define E0_STEP_PIN 28
  80. #define E0_DIR_PIN 27
  81. #define E0_ENABLE_PIN 24
  82. #define TEMP_0_PIN 1
  83. #define TEMP_1_PIN -1
  84. #define TEMP_2_PIN -1
  85. #define TEMP_BED_PIN 2
  86. #define HEATER_0_PIN 4
  87. #define HEATER_1_PIN -1
  88. #define HEATER_2_PIN -1
  89. #define HEATER_BED_PIN 3
  90. #define KILL_PIN -1
  91. #define SDPOWER -1
  92. #define SDSS -1 // SCL pin of I2C header
  93. #define LED_PIN -1
  94. #if (GEN7_VERSION >= 13)
  95. // Gen7 v1.3 removed the fan pin
  96. #define FAN_PIN -1
  97. #else
  98. #define FAN_PIN 31
  99. #endif
  100. #define PS_ON_PIN 15
  101. //All these generations of Gen7 supply thermistor power
  102. //via PS_ON, so ignore bad thermistor readings
  103. #define BOGUS_TEMPERATURE_FAILSAFE_OVERRIDE
  104. //our pin for debugging.
  105. #define DEBUG_PIN 0
  106. //our RS485 pins
  107. #define TX_ENABLE_PIN 12
  108. #define RX_ENABLE_PIN 13
  109. #endif
  110. /****************************************************************************************
  111. * Gen7 v1.4 pin assignment
  112. *
  113. ****************************************************************************************/
  114. #if MOTHERBOARD == 13
  115. #define GEN7_VERSION 14 // v1.4
  116. #endif
  117. #if MOTHERBOARD == 13
  118. #define KNOWN_BOARD
  119. #if !defined(__AVR_ATmega644P__) && !defined(__AVR_ATmega644__) && !defined(__AVR_ATmega1284P__)
  120. #error Oops! Make sure you have 'Gen7' selected from the 'Tools -> Boards' menu.
  121. #endif
  122. #ifndef GEN7_VERSION
  123. #define GEN7_VERSION 14 // v1.x
  124. #endif
  125. //x axis pins
  126. #define X_STEP_PIN 29
  127. #define X_DIR_PIN 28
  128. #define X_ENABLE_PIN 25
  129. #define X_STOP_PIN 0
  130. //y axis pins
  131. #define Y_STEP_PIN 27
  132. #define Y_DIR_PIN 26
  133. #define Y_ENABLE_PIN 25
  134. #define Y_STOP_PIN 1
  135. //z axis pins
  136. #define Z_STEP_PIN 23
  137. #define Z_DIR_PIN 22
  138. #define Z_ENABLE_PIN 25
  139. #define Z_STOP_PIN 2
  140. //extruder pins
  141. #define E0_STEP_PIN 19
  142. #define E0_DIR_PIN 18
  143. #define E0_ENABLE_PIN 25
  144. #define TEMP_0_PIN 1
  145. #define TEMP_1_PIN -1
  146. #define TEMP_2_PIN -1
  147. #define TEMP_BED_PIN 0
  148. #define HEATER_0_PIN 4
  149. #define HEATER_1_PIN -1
  150. #define HEATER_2_PIN -1
  151. #define HEATER_BED_PIN 3
  152. #define KILL_PIN -1
  153. #define SDPOWER -1
  154. #define SDSS -1 // SCL pin of I2C header
  155. #define LED_PIN -1
  156. #define FAN_PIN -1
  157. #define PS_ON_PIN 15
  158. //our pin for debugging.
  159. #define DEBUG_PIN 0
  160. //our RS485 pins
  161. #define TX_ENABLE_PIN 12
  162. #define RX_ENABLE_PIN 13
  163. #endif
  164. /*******************************************************************************
  165. *********
  166. * Gen7 Alfons3 pin assignment
  167. *
  168. ********************************************************************************
  169. ********/
  170. /* These Pins are assigned for the modified GEN7 Board from Alfons3 Please review the pins and adjust it for your needs*/
  171. #if MOTHERBOARD == 10
  172. #define KNOWN_BOARD
  173. #if !defined(__AVR_ATmega644P__) && !defined(__AVR_ATmega644__) && !defined(__AVR_ATmega1284P__)
  174. #error Oops! Make sure you have 'Gen7' selected from the 'Tools -> Boards' menu.
  175. #endif
  176. //x axis pins
  177. #define X_STEP_PIN 21 // different from standard GEN7
  178. #define X_DIR_PIN 20 // different from standard GEN7
  179. #define X_ENABLE_PIN 24
  180. #define X_STOP_PIN 0
  181. //y axis pins
  182. #define Y_STEP_PIN 23
  183. #define Y_DIR_PIN 22
  184. #define Y_ENABLE_PIN 24
  185. #define Y_STOP_PIN 1
  186. //z axis pins
  187. #define Z_STEP_PIN 26
  188. #define Z_DIR_PIN 25
  189. #define Z_ENABLE_PIN 24
  190. #define Z_STOP_PIN 2
  191. //extruder pins
  192. #define E0_STEP_PIN 28
  193. #define E0_DIR_PIN 27
  194. #define E0_ENABLE_PIN 24
  195. #define TEMP_0_PIN 2
  196. #define TEMP_1_PIN -1
  197. #define TEMP_2_PIN -1
  198. #define TEMP_BED_PIN 1 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 34 bed)
  199. #define HEATER_0_PIN 4
  200. #define HEATER_1_PIN -1
  201. #define HEATER_2_PIN -1
  202. #define HEATER_BED_PIN 3 // (bed)
  203. #define SDPOWER -1
  204. #define SDSS 31 // SCL pin of I2C header || CS Pin for SD Card support
  205. #define LED_PIN -1
  206. #define FAN_PIN -1
  207. #define PS_ON_PIN 19
  208. //our pin for debugging.
  209. #define DEBUG_PIN -1
  210. //our RS485 pins
  211. //#define TX_ENABLE_PIN 12
  212. //#define RX_ENABLE_PIN 13
  213. #define BEEPER -1
  214. #define SDCARDDETECT -1
  215. #define SUICIDE_PIN -1 //has to be defined; otherwise Power_off doesn't work
  216. #define KILL_PIN -1
  217. //Pins for 4bit LCD Support
  218. #define LCD_PINS_RS 18
  219. #define LCD_PINS_ENABLE 17
  220. #define LCD_PINS_D4 16
  221. #define LCD_PINS_D5 15
  222. #define LCD_PINS_D6 13
  223. #define LCD_PINS_D7 14
  224. //buttons are directly attached
  225. #define BTN_EN1 11
  226. #define BTN_EN2 10
  227. #define BTN_ENC 12 //the click
  228. #endif
  229. /****************************************************************************************
  230. * Arduino Mega pin assignment
  231. *
  232. ****************************************************************************************/
  233. #if MOTHERBOARD == 3 || MOTHERBOARD == 33 || MOTHERBOARD == 34 || MOTHERBOARD == 35 || MOTHERBOARD == 77 || MOTHERBOARD == 67
  234. #define KNOWN_BOARD 1
  235. //////////////////FIX THIS//////////////
  236. #ifndef __AVR_ATmega1280__
  237. #ifndef __AVR_ATmega2560__
  238. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  239. #endif
  240. #endif
  241. // uncomment one of the following lines for RAMPS v1.3 or v1.0, comment both for v1.2 or 1.1
  242. // #define RAMPS_V_1_3
  243. // #define RAMPS_V_1_0
  244. #if MOTHERBOARD == 33 || MOTHERBOARD == 34 || MOTHERBOARD == 35 || MOTHERBOARD == 77 || MOTHERBOARD == 67
  245. #define LARGE_FLASH true
  246. #if MOTHERBOARD == 77
  247. #define X_STEP_PIN 54
  248. #define X_DIR_PIN 55
  249. #define X_ENABLE_PIN 38
  250. #define X_MIN_PIN 3
  251. #define X_MAX_PIN -1 //2 //Max endstops default to disabled "-1", set to commented value to enable.
  252. #define Y_STEP_PIN 60
  253. #define Y_DIR_PIN 61
  254. #define Y_ENABLE_PIN 56
  255. #define Y_MIN_PIN 14
  256. #define Y_MAX_PIN -1 //15
  257. #define Z_STEP_PIN 46
  258. #define Z_DIR_PIN 48
  259. #define Z_ENABLE_PIN 63
  260. #define Z_MIN_PIN 18
  261. #define Z_MAX_PIN -1
  262. #define Z2_STEP_PIN 36
  263. #define Z2_DIR_PIN 34
  264. #define Z2_ENABLE_PIN 30
  265. #define E0_STEP_PIN 26
  266. #define E0_DIR_PIN 28
  267. #define E0_ENABLE_PIN 24
  268. #define E1_STEP_PIN 36
  269. #define E1_DIR_PIN 34
  270. #define E1_ENABLE_PIN 30
  271. #define SDPOWER -1
  272. #define SDSS 25//53
  273. #define LED_PIN 13
  274. #define BEEPER 33
  275. #else
  276. #define X_STEP_PIN 54
  277. #define X_DIR_PIN 55
  278. #define X_ENABLE_PIN 38
  279. #define X_MIN_PIN 3
  280. #define X_MAX_PIN 2
  281. #define Y_STEP_PIN 60
  282. #define Y_DIR_PIN 61
  283. #define Y_ENABLE_PIN 56
  284. #define Y_MIN_PIN 14
  285. #define Y_MAX_PIN 15
  286. #define Z_STEP_PIN 46
  287. #define Z_DIR_PIN 48
  288. #define Z_ENABLE_PIN 62
  289. #define Z_MIN_PIN 18
  290. #define Z_MAX_PIN 19
  291. #define Z2_STEP_PIN 36
  292. #define Z2_DIR_PIN 34
  293. #define Z2_ENABLE_PIN 30
  294. #define E0_STEP_PIN 26
  295. #define E0_DIR_PIN 28
  296. #define E0_ENABLE_PIN 24
  297. #define E1_STEP_PIN 36
  298. #define E1_DIR_PIN 34
  299. #define E1_ENABLE_PIN 30
  300. #define SDPOWER -1
  301. #define SDSS 53
  302. #define LED_PIN 13
  303. #endif
  304. #if MOTHERBOARD == 33 || MOTHERBOARD == 35 || MOTHERBOARD == 67
  305. #define FAN_PIN 9 // (Sprinter config)
  306. #else
  307. #define FAN_PIN 4 // IO pin. Buffer needed
  308. #endif
  309. #if MOTHERBOARD == 77
  310. #define FAN_PIN 8
  311. #endif
  312. #if MOTHERBOARD == 35
  313. #define CONTROLLERFAN_PIN 10 //Pin used for the fan to cool controller
  314. #endif
  315. #define PS_ON_PIN 12
  316. #if defined(REPRAP_DISCOUNT_SMART_CONTROLLER) || defined(G3D_PANEL)
  317. #define KILL_PIN 41
  318. #else
  319. #define KILL_PIN -1
  320. #endif
  321. #if MOTHERBOARD == 35
  322. #define HEATER_0_PIN 8
  323. #else
  324. #define HEATER_0_PIN 10 // EXTRUDER 1
  325. #endif
  326. #if MOTHERBOARD == 33 || MOTHERBOARD == 67
  327. #define HEATER_1_PIN -1
  328. #else
  329. #define HEATER_1_PIN 9 // EXTRUDER 2 (FAN On Sprinter)
  330. #endif
  331. #define HEATER_2_PIN -1
  332. #if MOTHERBOARD == 77
  333. #define HEATER_0_PIN 10
  334. #define HEATER_1_PIN 12
  335. #define HEATER_2_PIN 6
  336. #endif
  337. #define TEMP_0_PIN 13 // ANALOG NUMBERING
  338. #define TEMP_1_PIN 15 // ANALOG NUMBERING
  339. #define TEMP_2_PIN -1 // ANALOG NUMBERING
  340. #if MOTHERBOARD == 35
  341. #define HEATER_BED_PIN -1 // NO BED
  342. #else
  343. #if MOTHERBOARD == 77
  344. #define HEATER_BED_PIN 9 // BED
  345. #else
  346. #define HEATER_BED_PIN 8 // BED
  347. #endif
  348. #endif
  349. #define TEMP_BED_PIN 14 // ANALOG NUMBERING
  350. #ifdef NUM_SERVOS
  351. #define SERVO0_PIN 11
  352. #if NUM_SERVOS > 1
  353. #define SERVO1_PIN 6
  354. #endif
  355. #if NUM_SERVOS > 2
  356. #define SERVO2_PIN 5
  357. #endif
  358. #if NUM_SERVOS > 3
  359. #define SERVO3_PIN 4
  360. #endif
  361. #endif
  362. #ifdef ULTRA_LCD
  363. #ifdef NEWPANEL
  364. #define LCD_PINS_RS 16
  365. #define LCD_PINS_ENABLE 17
  366. #define LCD_PINS_D4 23
  367. #define LCD_PINS_D5 25
  368. #define LCD_PINS_D6 27
  369. #define LCD_PINS_D7 29
  370. #ifdef REPRAP_DISCOUNT_SMART_CONTROLLER
  371. #define BEEPER 37
  372. #define BTN_EN1 31
  373. #define BTN_EN2 33
  374. #define BTN_ENC 35
  375. #define SDCARDDETECT 49
  376. #elif defined(LCD_I2C_PANELOLU2)
  377. #define BTN_EN1 47 //reverse if the encoder turns the wrong way.
  378. #define BTN_EN2 43
  379. #define BTN_ENC 32
  380. #define SDSS 53
  381. #define SDCARDDETECT -1
  382. #define KILL_PIN 41
  383. #elif defined(LCD_I2C_VIKI)
  384. #define BTN_EN1 22 //reverse if the encoder turns the wrong way.
  385. #define BTN_EN2 7
  386. #define BTN_ENC -1
  387. #define SDSS 53
  388. #define SDCARDDETECT 49
  389. #else
  390. //arduino pin which triggers an piezzo beeper
  391. #define BEEPER 33 // Beeper on AUX-4
  392. //buttons are directly attached using AUX-2
  393. #ifdef REPRAPWORLD_KEYPAD
  394. #define BTN_EN1 64 // encoder
  395. #define BTN_EN2 59 // encoder
  396. #define BTN_ENC 63 // enter button
  397. #define SHIFT_OUT 40 // shift register
  398. #define SHIFT_CLK 44 // shift register
  399. #define SHIFT_LD 42 // shift register
  400. #else
  401. #define BTN_EN1 37
  402. #define BTN_EN2 35
  403. #define BTN_ENC 31 //the click
  404. #endif
  405. #ifdef G3D_PANEL
  406. #define SDCARDDETECT 49
  407. #else
  408. #define SDCARDDETECT -1 // Ramps does not use this port
  409. #endif
  410. #endif
  411. #if MOTHERBOARD == 77
  412. #define BEEPER -1
  413. #define LCD_PINS_RS 27
  414. #define LCD_PINS_ENABLE 29
  415. #define LCD_PINS_D4 37
  416. #define LCD_PINS_D5 35
  417. #define LCD_PINS_D6 33
  418. #define LCD_PINS_D7 31
  419. //buttons
  420. #define BTN_EN1 16
  421. #define BTN_EN2 17
  422. #define BTN_ENC 23 //the click
  423. #endif
  424. #else //old style panel with shift register
  425. //arduino pin witch triggers an piezzo beeper
  426. #define BEEPER 33 //No Beeper added
  427. //buttons are attached to a shift register
  428. // Not wired this yet
  429. //#define SHIFT_CLK 38
  430. //#define SHIFT_LD 42
  431. //#define SHIFT_OUT 40
  432. //#define SHIFT_EN 17
  433. #define LCD_PINS_RS 16
  434. #define LCD_PINS_ENABLE 17
  435. #define LCD_PINS_D4 23
  436. #define LCD_PINS_D5 25
  437. #define LCD_PINS_D6 27
  438. #define LCD_PINS_D7 29
  439. #endif
  440. #endif //ULTRA_LCD
  441. #else // RAMPS_V_1_1 or RAMPS_V_1_2 as default (MOTHERBOARD == 3)
  442. #define X_STEP_PIN 26
  443. #define X_DIR_PIN 28
  444. #define X_ENABLE_PIN 24
  445. #define X_MIN_PIN 3
  446. #define X_MAX_PIN -1 //2
  447. #define Y_STEP_PIN 38
  448. #define Y_DIR_PIN 40
  449. #define Y_ENABLE_PIN 36
  450. #define Y_MIN_PIN 16
  451. #define Y_MAX_PIN -1 //17
  452. #define Z_STEP_PIN 44
  453. #define Z_DIR_PIN 46
  454. #define Z_ENABLE_PIN 42
  455. #define Z_MIN_PIN 18
  456. #define Z_MAX_PIN -1 //19
  457. #define E0_STEP_PIN 32
  458. #define E0_DIR_PIN 34
  459. #define E0_ENABLE_PIN 30
  460. #define SDPOWER 48
  461. #define SDSS 53
  462. #define LED_PIN 13
  463. #define PS_ON_PIN -1
  464. #define KILL_PIN -1
  465. #ifdef RAMPS_V_1_0 // RAMPS_V_1_0
  466. #define HEATER_0_PIN 12 // RAMPS 1.0
  467. #define HEATER_BED_PIN -1 // RAMPS 1.0
  468. #define FAN_PIN 11 // RAMPS 1.0
  469. #else // RAMPS_V_1_1 or RAMPS_V_1_2
  470. #define HEATER_0_PIN 10 // RAMPS 1.1
  471. #define HEATER_BED_PIN 8 // RAMPS 1.1
  472. #define FAN_PIN 9 // RAMPS 1.1
  473. #endif
  474. #define HEATER_1_PIN -1
  475. #define HEATER_2_PIN -1
  476. #define TEMP_0_PIN 2 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  477. #define TEMP_1_PIN -1
  478. #define TEMP_2_PIN -1
  479. #define TEMP_BED_PIN 1 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  480. #endif // MOTHERBOARD == 33 || MOTHERBOARD == 34 || MOTHERBOARD == 35 || MOTHERBOARD == 77
  481. // SPI for Max6675 Thermocouple
  482. #ifndef SDSUPPORT
  483. // these pins are defined in the SD library if building with SD support
  484. #define MAX_SCK_PIN 52
  485. #define MAX_MISO_PIN 50
  486. #define MAX_MOSI_PIN 51
  487. #define MAX6675_SS 53
  488. #else
  489. #define MAX6675_SS 49
  490. #endif
  491. #endif //MOTHERBOARD == 3 || MOTHERBOARD == 33 || MOTHERBOARD == 34 || MOTHERBOARD == 35 || MOTHERBOARD == 77
  492. /****************************************************************************************
  493. * Duemilanove w/ ATMega328P pin assignment
  494. *
  495. ****************************************************************************************/
  496. #if MOTHERBOARD == 4
  497. #define KNOWN_BOARD 1
  498. #ifndef __AVR_ATmega328P__
  499. #error Oops! Make sure you have 'Arduino Duemilanove w/ ATMega328' selected from the 'Tools -> Boards' menu.
  500. #endif
  501. #define X_STEP_PIN 19
  502. #define X_DIR_PIN 18
  503. #define X_ENABLE_PIN -1
  504. #define X_STOP_PIN 17
  505. #define Y_STEP_PIN 10
  506. #define Y_DIR_PIN 7
  507. #define Y_ENABLE_PIN -1
  508. #define Y_STOP_PIN 8
  509. #define Z_STEP_PIN 13
  510. #define Z_DIR_PIN 3
  511. #define Z_ENABLE_PIN 2
  512. #define Z_STOP_PIN 4
  513. #define E0_STEP_PIN 11
  514. #define E0_DIR_PIN 12
  515. #define E0_ENABLE_PIN -1
  516. #define SDPOWER -1
  517. #define SDSS -1
  518. #define LED_PIN -1
  519. #define FAN_PIN 5
  520. #define PS_ON_PIN -1
  521. #define KILL_PIN -1
  522. #define HEATER_0_PIN 6
  523. #define HEATER_1_PIN -1
  524. #define HEATER_2_PIN -1
  525. #define TEMP_0_PIN 0 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  526. #define TEMP_1_PIN -1
  527. #define TEMP_2_PIN -1
  528. #define HEATER_BED_PIN -1
  529. #define TEMP_BED_PIN -1
  530. #endif
  531. /****************************************************************************************
  532. * Elefu RA Board Pin Assignments
  533. *
  534. ****************************************************************************************/
  535. #if MOTHERBOARD == 21
  536. #define KNOWN_BOARD 1
  537. #ifndef __AVR_ATmega2560__
  538. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  539. #endif
  540. #define X_STEP_PIN 49
  541. #define X_DIR_PIN 13
  542. #define X_ENABLE_PIN 48
  543. #define X_MIN_PIN 35
  544. #define X_MAX_PIN -1 //34
  545. #define Y_STEP_PIN 11
  546. #define Y_DIR_PIN 9
  547. #define Y_ENABLE_PIN 12
  548. #define Y_MIN_PIN 33
  549. #define Y_MAX_PIN -1 //32
  550. #define Z_STEP_PIN 7
  551. #define Z_DIR_PIN 6
  552. #define Z_ENABLE_PIN 8
  553. #define Z_MIN_PIN 31
  554. #define Z_MAX_PIN -1 //30
  555. #define E2_STEP_PIN 43
  556. #define E2_DIR_PIN 47
  557. #define E2_ENABLE_PIN 42
  558. #define E1_STEP_PIN 18
  559. #define E1_DIR_PIN 19
  560. #define E1_ENABLE_PIN 38
  561. #define E0_STEP_PIN 40
  562. #define E0_DIR_PIN 41
  563. #define E0_ENABLE_PIN 37
  564. #define SDPOWER -1
  565. #define LED_PIN -1 //Use +12V Aux port for LED Ring
  566. #define FAN_PIN 16 //5V PWM
  567. #define PS_ON_PIN 10 //Set to -1 if using a manual switch on the PWRSW Connector
  568. #define SLEEP_WAKE_PIN 26 //This feature still needs work
  569. #define HEATER_0_PIN 45 //12V PWM1
  570. #define HEATER_1_PIN 46 //12V PWM2
  571. #define HEATER_2_PIN 17 //12V PWM3
  572. #define HEATER_BED_PIN 44 //DOUBLE 12V PWM
  573. #define TEMP_0_PIN 3 //ANALOG NUMBERING
  574. #define TEMP_1_PIN 2 //ANALOG NUMBERING
  575. #define TEMP_2_PIN 1 //ANALOG NUMBERING
  576. #define TEMP_BED_PIN 0 //ANALOG NUMBERING
  577. #define BEEPER 36
  578. #define KILL_PIN -1
  579. // M240 Triggers a camera by emulating a Canon RC-1 Remote
  580. // Data from: http://www.doc-diy.net/photo/rc-1_hacked/
  581. #define PHOTOGRAPH_PIN 29
  582. #ifdef RA_CONTROL_PANEL
  583. #define SDSS 53
  584. #define SDCARDDETECT 28
  585. #define BTN_EN1 14
  586. #define BTN_EN2 39
  587. #define BTN_ENC 15 //the click
  588. #define BLEN_C 2
  589. #define BLEN_B 1
  590. #define BLEN_A 0
  591. //encoder rotation values
  592. #define encrot0 0
  593. #define encrot1 2
  594. #define encrot2 3
  595. #define encrot3 1
  596. #endif //RA_CONTROL_PANEL
  597. #ifdef RA_DISCO
  598. //variables for which pins the TLC5947 is using
  599. #define TLC_CLOCK_PIN 25
  600. #define TLC_BLANK_PIN 23
  601. #define TLC_XLAT_PIN 22
  602. #define TLC_DATA_PIN 24
  603. //We also need to define pin to port number mapping for the 2560 to match the pins listed above. If you change the TLC pins, update this as well per the 2560 datasheet!
  604. //This currently only works with the RA Board.
  605. #define TLC_CLOCK_BIT 3 //bit 3 on port A
  606. #define TLC_CLOCK_PORT &PORTA //bit 3 on port A
  607. #define TLC_BLANK_BIT 1 //bit 1 on port A
  608. #define TLC_BLANK_PORT &PORTA //bit 1 on port A
  609. #define TLC_DATA_BIT 2 //bit 2 on port A
  610. #define TLC_DATA_PORT &PORTA //bit 2 on port A
  611. #define TLC_XLAT_BIT 0 //bit 0 on port A
  612. #define TLC_XLAT_PORT &PORTA //bit 0 on port A
  613. //change this to match your situation. Lots of TLCs takes up the arduino SRAM very quickly, so be careful
  614. //Leave it at at least 1 if you have enabled RA_LIGHTING
  615. //The number of TLC5947 boards chained together for use with the animation, additional ones will repeat the animation on them, but are not individually addressable and mimic those before them. You can leave the default at 2 even if you only have 1 TLC5947 module.
  616. #define NUM_TLCS 2
  617. //These TRANS_ARRAY values let you change the order the LEDs on the lighting modules will animate for chase functions.
  618. //Modify them according to your specific situation.
  619. //NOTE: the array should be 8 long for every TLC you have. These defaults assume (2) TLCs.
  620. #define TRANS_ARRAY {0, 1, 2, 3, 4, 5, 6, 7, 15, 14, 13, 12, 11, 10, 9, 8} //forwards
  621. //#define TRANS_ARRAY {7, 6, 5, 4, 3, 2, 1, 0, 8, 9, 10, 11, 12, 13, 14, 15} //backwards
  622. #endif //RA_LIGHTING
  623. #endif /* Ra Board */
  624. /****************************************************************************************
  625. * Gen6 pin assignment
  626. *
  627. ****************************************************************************************/
  628. #if MOTHERBOARD == 5 || MOTHERBOARD == 51
  629. #define KNOWN_BOARD 1
  630. #ifndef __AVR_ATmega644P__
  631. #ifndef __AVR_ATmega1284P__
  632. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu.
  633. #endif
  634. #endif
  635. //x axis pins
  636. #define X_STEP_PIN 15
  637. #define X_DIR_PIN 18
  638. #define X_ENABLE_PIN 19
  639. #define X_STOP_PIN 20
  640. //y axis pins
  641. #define Y_STEP_PIN 23
  642. #define Y_DIR_PIN 22
  643. #define Y_ENABLE_PIN 24
  644. #define Y_STOP_PIN 25
  645. //z axis pins
  646. #define Z_STEP_PIN 27
  647. #define Z_DIR_PIN 28
  648. #define Z_ENABLE_PIN 29
  649. #define Z_STOP_PIN 30
  650. //extruder pins
  651. #define E0_STEP_PIN 4 //Edited @ EJE Electronics 20100715
  652. #define E0_DIR_PIN 2 //Edited @ EJE Electronics 20100715
  653. #define E0_ENABLE_PIN 3 //Added @ EJE Electronics 20100715
  654. #define TEMP_0_PIN 5 //changed @ rkoeppl 20110410
  655. #define TEMP_1_PIN -1 //changed @ rkoeppl 20110410
  656. #define TEMP_2_PIN -1 //changed @ rkoeppl 20110410
  657. #define HEATER_0_PIN 14 //changed @ rkoeppl 20110410
  658. #define HEATER_1_PIN -1
  659. #define HEATER_2_PIN -1
  660. #if MOTHERBOARD == 5
  661. #define HEATER_BED_PIN -1 //changed @ rkoeppl 20110410
  662. #define TEMP_BED_PIN -1 //changed @ rkoeppl 20110410
  663. #else
  664. #define HEATER_BED_PIN 1 //changed @ rkoeppl 20110410
  665. #define TEMP_BED_PIN 0 //changed @ rkoeppl 20110410
  666. #endif
  667. #define SDPOWER -1
  668. #define SDSS 17
  669. #define LED_PIN -1 //changed @ rkoeppl 20110410
  670. #define FAN_PIN -1 //changed @ rkoeppl 20110410
  671. #define PS_ON_PIN -1 //changed @ rkoeppl 20110410
  672. #define KILL_PIN -1 //changed @ drakelive 20120830
  673. //our pin for debugging.
  674. #define DEBUG_PIN 0
  675. //our RS485 pins
  676. #define TX_ENABLE_PIN 12
  677. #define RX_ENABLE_PIN 13
  678. #endif
  679. /****************************************************************************************
  680. * Sanguinololu pin assignment
  681. *
  682. ****************************************************************************************/
  683. #if MOTHERBOARD == 64
  684. #define STB
  685. #endif
  686. #if MOTHERBOARD == 63 || MOTHERBOARD == 66
  687. #define MELZI
  688. #endif
  689. #if MOTHERBOARD == 65
  690. #define AZTEEG_X1
  691. #endif
  692. #if MOTHERBOARD == 62 || MOTHERBOARD == 63 || MOTHERBOARD == 64 || MOTHERBOARD == 65 || MOTHERBOARD == 66
  693. #undef MOTHERBOARD
  694. #define MOTHERBOARD 6
  695. #define SANGUINOLOLU_V_1_2
  696. #endif
  697. #if MOTHERBOARD == 6
  698. #define KNOWN_BOARD 1
  699. #ifndef __AVR_ATmega644P__
  700. #ifndef __AVR_ATmega1284P__
  701. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu.
  702. #endif
  703. #endif
  704. #define X_STEP_PIN 15
  705. #define X_DIR_PIN 21
  706. #define X_STOP_PIN 18
  707. #define Y_STEP_PIN 22
  708. #define Y_DIR_PIN 23
  709. #define Y_STOP_PIN 19
  710. #define Z_STEP_PIN 3
  711. #define Z_DIR_PIN 2
  712. #define Z_STOP_PIN 20
  713. #define E0_STEP_PIN 1
  714. #define E0_DIR_PIN 0
  715. #define LED_PIN -1
  716. #define FAN_PIN -1
  717. #if FAN_PIN == 12 || FAN_PIN ==13
  718. #define FAN_SOFT_PWM
  719. #endif
  720. #ifdef MELZI
  721. #define LED_PIN 27 /* On some broken versions of the Sanguino libraries the pin definitions are wrong, which then needs LED_PIN as pin 28. But you better upgrade your Sanguino libraries! See #368. */
  722. #define FAN_PIN 4 // Works for Panelolu2 too
  723. #endif
  724. #ifdef STB
  725. #define FAN_PIN 4
  726. // Uncomment this if you have the first generation (V1.10) of STBs board
  727. #define LCD_PIN_BL 17 // LCD backlight LED
  728. #endif
  729. #ifdef AZTEEG_X1
  730. #define FAN_PIN 4
  731. #endif
  732. #define PS_ON_PIN -1
  733. #define KILL_PIN -1
  734. #define HEATER_0_PIN 13 // (extruder)
  735. #define HEATER_1_PIN -1
  736. #define HEATER_2_PIN -1
  737. #ifdef SANGUINOLOLU_V_1_2
  738. #define HEATER_BED_PIN 12 // (bed)
  739. #define X_ENABLE_PIN 14
  740. #define Y_ENABLE_PIN 14
  741. #define Z_ENABLE_PIN 26
  742. #define E0_ENABLE_PIN 14
  743. #ifdef LCD_I2C_PANELOLU2
  744. #define FAN_PIN 4 // Uses Transistor1 (PWM) on Panelolu2's Sanguino Adapter Board to drive the fan
  745. #endif
  746. #else
  747. #define HEATER_BED_PIN 14 // (bed)
  748. #define X_ENABLE_PIN -1
  749. #define Y_ENABLE_PIN -1
  750. #define Z_ENABLE_PIN -1
  751. #define E0_ENABLE_PIN -1
  752. #endif
  753. #define TEMP_0_PIN 7 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 33 extruder)
  754. #define TEMP_1_PIN -1
  755. #define TEMP_2_PIN -1
  756. #define TEMP_BED_PIN 6 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 34 bed)
  757. #define SDPOWER -1
  758. #define SDSS 31
  759. /* On some broken versions of the Sanguino libraries the pin definitions are wrong, which then needs SDSS as pin 24. But you better upgrade your Sanguino libraries! See #368. */
  760. //#define SDSS 24
  761. #ifdef ULTRA_LCD
  762. #ifdef NEWPANEL
  763. //we have no buzzer installed
  764. #define BEEPER -1
  765. //LCD Pins
  766. #ifdef DOGLCD
  767. // Pins for DOGM SPI LCD Support
  768. #define DOGLCD_A0 30
  769. #define DOGLCD_CS 29
  770. // GLCD features
  771. #define LCD_CONTRAST 1
  772. // Uncomment screen orientation
  773. // #define LCD_SCREEN_ROT_0
  774. // #define LCD_SCREEN_ROT_90
  775. #define LCD_SCREEN_ROT_180
  776. // #define LCD_SCREEN_ROT_270
  777. #else // standard Hitachi LCD controller
  778. #define LCD_PINS_RS 4
  779. #define LCD_PINS_ENABLE 17
  780. #define LCD_PINS_D4 30
  781. #define LCD_PINS_D5 29
  782. #define LCD_PINS_D6 28
  783. #define LCD_PINS_D7 27
  784. #endif
  785. //The encoder and click button
  786. #define BTN_EN1 11
  787. #define BTN_EN2 10
  788. #ifdef LCD_I2C_PANELOLU2
  789. #ifdef MELZI
  790. #define BTN_ENC 29 //the click switch
  791. #define SDSS 30 //to use the SD card reader on the Panelolu2 rather than the melzi board
  792. #else
  793. #define BTN_ENC 30 //the click switch
  794. #endif
  795. #else
  796. #define BTN_ENC 16 //the click switch
  797. #endif //Panelolu2
  798. //not connected to a pin
  799. #define SDCARDDETECT -1
  800. #endif //Newpanel
  801. #endif //Ultipanel
  802. #ifdef MAKRPANEL
  803. #define BEEPER 29
  804. // Pins for DOGM SPI LCD Support
  805. #define DOGLCD_A0 30
  806. #define DOGLCD_CS 17
  807. #define LCD_PIN_BL 28 // backlight LED on PA3
  808. // GLCD features
  809. #define LCD_CONTRAST 1
  810. // Uncomment screen orientation
  811. #define LCD_SCREEN_ROT_0
  812. // #define LCD_SCREEN_ROT_90
  813. // #define LCD_SCREEN_ROT_180
  814. // #define LCD_SCREEN_ROT_270
  815. //The encoder and click button
  816. #define BTN_EN1 11
  817. #define BTN_EN2 10
  818. #define BTN_ENC 16 //the click switch
  819. //not connected to a pin
  820. #define SDCARDDETECT -1
  821. #endif //Makrpanel
  822. #endif
  823. #if MOTHERBOARD == 7
  824. #define KNOWN_BOARD
  825. /*****************************************************************
  826. * Ultimaker pin assignment
  827. ******************************************************************/
  828. #ifndef __AVR_ATmega1280__
  829. #ifndef __AVR_ATmega2560__
  830. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  831. #endif
  832. #endif
  833. #define LARGE_FLASH true
  834. #define X_STEP_PIN 25
  835. #define X_DIR_PIN 23
  836. #define X_MIN_PIN 22
  837. #define X_MAX_PIN 24
  838. #define X_ENABLE_PIN 27
  839. #define Y_STEP_PIN 31
  840. #define Y_DIR_PIN 33
  841. #define Y_MIN_PIN 26
  842. #define Y_MAX_PIN 28
  843. #define Y_ENABLE_PIN 29
  844. #define Z_STEP_PIN 37
  845. #define Z_DIR_PIN 39
  846. #define Z_MIN_PIN 30
  847. #define Z_MAX_PIN 32
  848. #define Z_ENABLE_PIN 35
  849. #define HEATER_BED_PIN 4
  850. #define TEMP_BED_PIN 10
  851. #define HEATER_0_PIN 2
  852. #define TEMP_0_PIN 8
  853. #define HEATER_1_PIN 3
  854. #define TEMP_1_PIN 9
  855. #define HEATER_2_PIN -1
  856. #define TEMP_2_PIN -1
  857. #define E0_STEP_PIN 43
  858. #define E0_DIR_PIN 45
  859. #define E0_ENABLE_PIN 41
  860. #define E1_STEP_PIN 49
  861. #define E1_DIR_PIN 47
  862. #define E1_ENABLE_PIN 48
  863. #define SDPOWER -1
  864. #define SDSS 53
  865. #define LED_PIN 13
  866. #define FAN_PIN 7
  867. #define PS_ON_PIN 12
  868. #define KILL_PIN -1
  869. #define SUICIDE_PIN 54 //PIN that has to be turned on right after start, to keep power flowing.
  870. #ifdef ULTRA_LCD
  871. #ifdef NEWPANEL
  872. //arduino pin witch triggers an piezzo beeper
  873. #define BEEPER 18
  874. #define LCD_PINS_RS 20
  875. #define LCD_PINS_ENABLE 17
  876. #define LCD_PINS_D4 16
  877. #define LCD_PINS_D5 21
  878. #define LCD_PINS_D6 5
  879. #define LCD_PINS_D7 6
  880. //buttons are directly attached
  881. #define BTN_EN1 40
  882. #define BTN_EN2 42
  883. #define BTN_ENC 19 //the click
  884. #define SDCARDDETECT 38
  885. #else //old style panel with shift register
  886. //arduino pin witch triggers an piezzo beeper
  887. #define BEEPER 18
  888. //buttons are attached to a shift register
  889. #define SHIFT_CLK 38
  890. #define SHIFT_LD 42
  891. #define SHIFT_OUT 40
  892. #define SHIFT_EN 17
  893. #define LCD_PINS_RS 16
  894. #define LCD_PINS_ENABLE 5
  895. #define LCD_PINS_D4 6
  896. #define LCD_PINS_D5 21
  897. #define LCD_PINS_D6 20
  898. #define LCD_PINS_D7 19
  899. #define SDCARDDETECT -1
  900. #endif
  901. #endif //ULTRA_LCD
  902. #endif
  903. #if MOTHERBOARD == 71
  904. #define KNOWN_BOARD
  905. /*****************************************************************
  906. * Ultimaker pin assignment (Old electronics)
  907. ******************************************************************/
  908. #ifndef __AVR_ATmega1280__
  909. #ifndef __AVR_ATmega2560__
  910. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  911. #endif
  912. #endif
  913. #define LARGE_FLASH true
  914. #define X_STEP_PIN 25
  915. #define X_DIR_PIN 23
  916. #define X_MIN_PIN 15
  917. #define X_MAX_PIN 14
  918. #define X_ENABLE_PIN 27
  919. #define Y_STEP_PIN 31
  920. #define Y_DIR_PIN 33
  921. #define Y_MIN_PIN 17
  922. #define Y_MAX_PIN 16
  923. #define Y_ENABLE_PIN 29
  924. #define Z_STEP_PIN 37
  925. #define Z_DIR_PIN 39
  926. #define Z_MIN_PIN 19
  927. #define Z_MAX_PIN 18
  928. #define Z_ENABLE_PIN 35
  929. #define HEATER_BED_PIN -1
  930. #define TEMP_BED_PIN -1
  931. #define HEATER_0_PIN 2
  932. #define TEMP_0_PIN 8
  933. #define HEATER_1_PIN 1
  934. #define TEMP_1_PIN 1
  935. #define HEATER_2_PIN -1
  936. #define TEMP_2_PIN -1
  937. #define E0_STEP_PIN 43
  938. #define E0_DIR_PIN 45
  939. #define E0_ENABLE_PIN 41
  940. #define E1_STEP_PIN -1
  941. #define E1_DIR_PIN -1
  942. #define E1_ENABLE_PIN -1
  943. #define SDPOWER -1
  944. #define SDSS -1
  945. #define LED_PIN -1
  946. #define FAN_PIN -1
  947. #define PS_ON_PIN -1
  948. #define KILL_PIN -1
  949. #define SUICIDE_PIN -1 //PIN that has to be turned on right after start, to keep power flowing.
  950. #define LCD_PINS_RS 24
  951. #define LCD_PINS_ENABLE 22
  952. #define LCD_PINS_D4 36
  953. #define LCD_PINS_D5 34
  954. #define LCD_PINS_D6 32
  955. #define LCD_PINS_D7 30
  956. #endif
  957. /****************************************************************************************
  958. * RUMBA pin assignment
  959. *
  960. ****************************************************************************************/
  961. #if MOTHERBOARD == 80
  962. #define KNOWN_BOARD 1
  963. #ifndef __AVR_ATmega2560__
  964. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  965. #endif
  966. #define X_STEP_PIN 17
  967. #define X_DIR_PIN 16
  968. #define X_ENABLE_PIN 48
  969. #define X_MIN_PIN 37
  970. #define X_MAX_PIN 36
  971. #define Y_STEP_PIN 54
  972. #define Y_DIR_PIN 47
  973. #define Y_ENABLE_PIN 55
  974. #define Y_MIN_PIN 35
  975. #define Y_MAX_PIN 34
  976. #define Z_STEP_PIN 57
  977. #define Z_DIR_PIN 56
  978. #define Z_ENABLE_PIN 62
  979. #define Z_MIN_PIN 33
  980. #define Z_MAX_PIN 32
  981. #define E0_STEP_PIN 23
  982. #define E0_DIR_PIN 22
  983. #define E0_ENABLE_PIN 24
  984. #define E1_STEP_PIN 26
  985. #define E1_DIR_PIN 25
  986. #define E1_ENABLE_PIN 27
  987. #define E2_STEP_PIN 29
  988. #define E2_DIR_PIN 28
  989. #define E2_ENABLE_PIN 39
  990. #define LED_PIN 13
  991. #define FAN_PIN 7
  992. //additional FAN1 PIN (e.g. useful for electronics fan or light on/off) on PIN 8
  993. #define PS_ON_PIN 45
  994. #define KILL_PIN 46
  995. #if (TEMP_SENSOR_0==0)
  996. #define TEMP_0_PIN -1
  997. #define HEATER_0_PIN -1
  998. #else
  999. #define HEATER_0_PIN 2 // EXTRUDER 1
  1000. #if (TEMP_SENSOR_0==-1)
  1001. #define TEMP_0_PIN 6 // ANALOG NUMBERING - connector *K1* on RUMBA thermocouple ADD ON is used
  1002. #else
  1003. #define TEMP_0_PIN 15 // ANALOG NUMBERING - default connector for thermistor *T0* on rumba board is used
  1004. #endif
  1005. #endif
  1006. #if (TEMP_SENSOR_1==0)
  1007. #define TEMP_1_PIN -1
  1008. #define HEATER_1_PIN -1
  1009. #else
  1010. #define HEATER_1_PIN 3 // EXTRUDER 2
  1011. #if (TEMP_SENSOR_1==-1)
  1012. #define TEMP_1_PIN 5 // ANALOG NUMBERING - connector *K2* on RUMBA thermocouple ADD ON is used
  1013. #else
  1014. #define TEMP_1_PIN 14 // ANALOG NUMBERING - default connector for thermistor *T1* on rumba board is used
  1015. #endif
  1016. #endif
  1017. #if (TEMP_SENSOR_2==0)
  1018. #define TEMP_2_PIN -1
  1019. #define HEATER_2_PIN -1
  1020. #else
  1021. #define HEATER_2_PIN 6 // EXTRUDER 3
  1022. #if (TEMP_SENSOR_2==-1)
  1023. #define TEMP_2_PIN 7 // ANALOG NUMBERING - connector *K3* on RUMBA thermocouple ADD ON is used <-- this can not be used when TEMP_SENSOR_BED is defined as thermocouple
  1024. #else
  1025. #define TEMP_2_PIN 13 // ANALOG NUMBERING - default connector for thermistor *T2* on rumba board is used
  1026. #endif
  1027. #endif
  1028. //optional for extruder 4 or chamber: #define TEMP_X_PIN 12 // ANALOG NUMBERING - default connector for thermistor *T3* on rumba board is used
  1029. //optional FAN1 can be used as 4th heater output: #define HEATER_3_PIN 8 // EXTRUDER 4
  1030. #if (TEMP_SENSOR_BED==0)
  1031. #define TEMP_BED_PIN -1
  1032. #define HEATER_BED_PIN -1
  1033. #else
  1034. #define HEATER_BED_PIN 9 // BED
  1035. #if (TEMP_SENSOR_BED==-1)
  1036. #define TEMP_BED_PIN 7 // ANALOG NUMBERING - connector *K3* on RUMBA thermocouple ADD ON is used <-- this can not be used when TEMP_SENSOR_2 is defined as thermocouple
  1037. #else
  1038. #define TEMP_BED_PIN 11 // ANALOG NUMBERING - default connector for thermistor *THB* on rumba board is used
  1039. #endif
  1040. #endif
  1041. #define SDPOWER -1
  1042. #define SDSS 53
  1043. #define SDCARDDETECT 49
  1044. #define BEEPER 44
  1045. #define LCD_PINS_RS 19
  1046. #define LCD_PINS_ENABLE 42
  1047. #define LCD_PINS_D4 18
  1048. #define LCD_PINS_D5 38
  1049. #define LCD_PINS_D6 41
  1050. #define LCD_PINS_D7 40
  1051. #define BTN_EN1 11
  1052. #define BTN_EN2 12
  1053. #define BTN_ENC 43
  1054. #endif //MOTHERBOARD==80
  1055. /****************************************************************************************
  1056. * Teensylu 0.7 / Printrboard pin assignments (AT90USB1286)
  1057. * Requires the Teensyduino software with Teensy++ 2.0 selected in Arduino IDE!
  1058. http://www.pjrc.com/teensy/teensyduino.html
  1059. * See http://reprap.org/wiki/Printrboard for more info
  1060. ****************************************************************************************/
  1061. #if MOTHERBOARD == 8 || MOTHERBOARD == 81
  1062. #define KNOWN_BOARD 1
  1063. #define AT90USB 1286 // Disable MarlinSerial etc.
  1064. #ifndef __AVR_AT90USB1286__
  1065. #error Oops! Make sure you have 'Teensy++ 2.0' selected from the 'Tools -> Boards' menu.
  1066. #endif
  1067. #define LARGE_FLASH true
  1068. #define X_STEP_PIN 0
  1069. #define X_DIR_PIN 1
  1070. #define X_ENABLE_PIN 39
  1071. #define Y_STEP_PIN 2
  1072. #define Y_DIR_PIN 3
  1073. #define Y_ENABLE_PIN 38
  1074. #define Z_STEP_PIN 4
  1075. #define Z_DIR_PIN 5
  1076. #define Z_ENABLE_PIN 23
  1077. #define E0_STEP_PIN 6
  1078. #define E0_DIR_PIN 7
  1079. #define E0_ENABLE_PIN 19
  1080. #define HEATER_0_PIN 21 // Extruder
  1081. #define HEATER_1_PIN -1
  1082. #define HEATER_2_PIN -1
  1083. #define HEATER_BED_PIN 20 // Bed
  1084. #define FAN_PIN 22 // Fan
  1085. // You may need to change FAN_PIN to 16 because Marlin isn't using fastio.h
  1086. // for the fan and Teensyduino uses a different pin mapping.
  1087. #if MOTHERBOARD == 8 // Teensylu
  1088. #define X_STOP_PIN 13
  1089. #define Y_STOP_PIN 14
  1090. #define Z_STOP_PIN 15
  1091. #define TEMP_0_PIN 7 // Extruder / Analog pin numbering
  1092. #define TEMP_BED_PIN 6 // Bed / Analog pin numbering
  1093. #else // Printrboard
  1094. #define X_STOP_PIN 35
  1095. #define Y_STOP_PIN 8
  1096. #define Z_STOP_PIN 36
  1097. #define TEMP_0_PIN 1 // Extruder / Analog pin numbering
  1098. #define TEMP_BED_PIN 0 // Bed / Analog pin numbering
  1099. #endif
  1100. #define TEMP_1_PIN -1
  1101. #define TEMP_2_PIN -1
  1102. #define SDPOWER -1
  1103. #define SDSS 8
  1104. #define LED_PIN -1
  1105. #define PS_ON_PIN -1
  1106. #define KILL_PIN -1
  1107. #define ALARM_PIN -1
  1108. #ifndef SDSUPPORT
  1109. // these pins are defined in the SD library if building with SD support
  1110. #define SCK_PIN 9
  1111. #define MISO_PIN 11
  1112. #define MOSI_PIN 10
  1113. #endif
  1114. #endif // MOTHERBOARD == 8 (Teensylu) or 81 (Printrboard)
  1115. /****************************************************************************************
  1116. * Brainwave 1.0 pin assignments (AT90USB646)
  1117. * Requires hardware bundle for Arduino:
  1118. https://github.com/unrepentantgeek/brainwave-arduino
  1119. ****************************************************************************************/
  1120. #if MOTHERBOARD == 82
  1121. #define KNOWN_BOARD 1
  1122. #define AT90USB 646 // Disable MarlinSerial etc.
  1123. #ifndef __AVR_AT90USB646__
  1124. #error Oops! Make sure you have 'Brainwave' selected from the 'Tools -> Boards' menu.
  1125. #endif
  1126. #define X_STEP_PIN 27
  1127. #define X_DIR_PIN 29
  1128. #define X_ENABLE_PIN 28
  1129. #define X_STOP_PIN 7
  1130. #define X_ATT_PIN 26
  1131. #define Y_STEP_PIN 31
  1132. #define Y_DIR_PIN 33
  1133. #define Y_ENABLE_PIN 32
  1134. #define Y_STOP_PIN 6
  1135. #define Y_ATT_PIN 30
  1136. #define Z_STEP_PIN 17
  1137. #define Z_DIR_PIN 19
  1138. #define Z_ENABLE_PIN 18
  1139. #define Z_STOP_PIN 5
  1140. #define Z_ATT_PIN 16
  1141. #define E0_STEP_PIN 21
  1142. #define E0_DIR_PIN 23
  1143. #define E0_ENABLE_PIN 22
  1144. #define E0_ATT_PIN 20
  1145. #define HEATER_0_PIN 4 // Extruder
  1146. #define HEATER_1_PIN -1
  1147. #define HEATER_2_PIN -1
  1148. #define HEATER_BED_PIN 38 // Bed
  1149. #define FAN_PIN 3 // Fan
  1150. #define TEMP_0_PIN 7 // Extruder / Analog pin numbering
  1151. #define TEMP_1_PIN -1
  1152. #define TEMP_2_PIN -1
  1153. #define TEMP_BED_PIN 6 // Bed / Analog pin numbering
  1154. #define SDPOWER -1
  1155. #define SDSS -1
  1156. #define LED_PIN 39
  1157. #define PS_ON_PIN -1
  1158. #define KILL_PIN -1
  1159. #define ALARM_PIN -1
  1160. #ifndef SDSUPPORT
  1161. // these pins are defined in the SD library if building with SD support
  1162. #define SCK_PIN 9
  1163. #define MISO_PIN 11
  1164. #define MOSI_PIN 10
  1165. #endif
  1166. #endif // MOTHERBOARD == 82 (Brainwave)
  1167. /****************************************************************************************
  1168. * Gen3+ pin assignment
  1169. *
  1170. ****************************************************************************************/
  1171. #if MOTHERBOARD == 9
  1172. #define MOTHERBOARD 6 /*TODO: Figure out, Why is this done?*/
  1173. #define KNOWN_BOARD 1
  1174. #ifndef __AVR_ATmega644P__
  1175. #ifndef __AVR_ATmega1284P__
  1176. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu.
  1177. #endif
  1178. #endif
  1179. #define X_STEP_PIN 15
  1180. #define X_DIR_PIN 18
  1181. #define X_STOP_PIN 20
  1182. #define Y_STEP_PIN 23
  1183. #define Y_DIR_PIN 22
  1184. #define Y_STOP_PIN 25
  1185. #define Z_STEP_PIN 27
  1186. #define Z_DIR_PIN 28
  1187. #define Z_STOP_PIN 30
  1188. #define E_STEP_PIN 17
  1189. #define E_DIR_PIN 21
  1190. #define LED_PIN -1
  1191. #define FAN_PIN -1
  1192. #define PS_ON_PIN 14
  1193. #define KILL_PIN -1
  1194. #define HEATER_0_PIN 12 // (extruder)
  1195. #define HEATER_1_PIN 16 // (bed)
  1196. #define X_ENABLE_PIN 19
  1197. #define Y_ENABLE_PIN 24
  1198. #define Z_ENABLE_PIN 29
  1199. #define E_ENABLE_PIN 13
  1200. #define TEMP_0_PIN 0 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 33 extruder)
  1201. #define TEMP_1_PIN 5 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 34 bed)
  1202. #define TEMP_2_PIN -1
  1203. #define SDPOWER -1
  1204. #define SDSS 4
  1205. #define HEATER_2_PIN -1
  1206. #endif
  1207. /****************************************************************************************
  1208. * Open Motion controller with enable based extruders
  1209. *
  1210. * ATMega644
  1211. *
  1212. * +---\/---+
  1213. * (D 0) PB0 1| |40 PA0 (AI 0 / D31)
  1214. * (D 1) PB1 2| |39 PA1 (AI 1 / D30)
  1215. * INT2 (D 2) PB2 3| |38 PA2 (AI 2 / D29)
  1216. * PWM (D 3) PB3 4| |37 PA3 (AI 3 / D28)
  1217. * PWM (D 4) PB4 5| |36 PA4 (AI 4 / D27)
  1218. * MOSI (D 5) PB5 6| |35 PA5 (AI 5 / D26)
  1219. * MISO (D 6) PB6 7| |34 PA6 (AI 6 / D25)
  1220. * SCK (D 7) PB7 8| |33 PA7 (AI 7 / D24)
  1221. * RST 9| |32 AREF
  1222. * VCC 10| |31 GND
  1223. * GND 11| |30 AVCC
  1224. * XTAL2 12| |29 PC7 (D 23)
  1225. * XTAL1 13| |28 PC6 (D 22)
  1226. * RX0 (D 8) PD0 14| |27 PC5 (D 21) TDI
  1227. * TX0 (D 9) PD1 15| |26 PC4 (D 20) TDO
  1228. * INT0 RX1 (D 10) PD2 16| |25 PC3 (D 19) TMS
  1229. * INT1 TX1 (D 11) PD3 17| |24 PC2 (D 18) TCK
  1230. * PWM (D 12) PD4 18| |23 PC1 (D 17) SDA
  1231. * PWM (D 13) PD5 19| |22 PC0 (D 16) SCL
  1232. * PWM (D 14) PD6 20| |21 PD7 (D 15) PWM
  1233. * +--------+
  1234. *
  1235. ****************************************************************************************/
  1236. #if MOTHERBOARD == 90 //Alpha OMCA board
  1237. #define KNOWN_BOARD 1
  1238. #ifndef __AVR_ATmega644__
  1239. #error Oops! Make sure you have 'SanguinoA' selected from the 'Tools -> Boards' menu.
  1240. #endif
  1241. #define X_STEP_PIN 21
  1242. #define X_DIR_PIN 20
  1243. #define X_ENABLE_PIN 24
  1244. #define X_STOP_PIN 0
  1245. #define Y_STEP_PIN 23
  1246. #define Y_DIR_PIN 22
  1247. #define Y_ENABLE_PIN 24
  1248. #define Y_STOP_PIN 1
  1249. #define Z_STEP_PIN 26
  1250. #define Z_DIR_PIN 25
  1251. #define Z_ENABLE_PIN 24
  1252. #define Z_STOP_PIN 2
  1253. #define E0_STEP_PIN 28
  1254. #define E0_DIR_PIN 27
  1255. #define E0_ENABLE_PIN 24
  1256. #define E1_STEP_PIN -1 // 19
  1257. #define E1_DIR_PIN -1 // 18
  1258. #define E1_ENABLE_PIN 24
  1259. #define E2_STEP_PIN -1 // 17
  1260. #define E2_DIR_PIN -1 // 16
  1261. #define E2_ENABLE_PIN 24
  1262. #define SDPOWER -1
  1263. #define SDSS 11
  1264. #define SDCARDDETECT -1 // 10 optional also used as mode pin
  1265. #define LED_PIN -1
  1266. #define FAN_PIN 3
  1267. #define PS_ON_PIN -1
  1268. #define KILL_PIN -1
  1269. #define HEATER_0_PIN 4
  1270. #define HEATER_1_PIN -1 // 12
  1271. #define HEATER_2_PIN -1 // 13
  1272. #define TEMP_0_PIN 0 //D27 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  1273. #define TEMP_1_PIN -1 // 1
  1274. #define TEMP_2_PIN -1 // 2
  1275. #define HEATER_BED_PIN -1 // 14/15
  1276. #define TEMP_BED_PIN -1 // 1,2 or I2C
  1277. /* Unused (1) (2) (3) 4 5 6 7 8 9 10 11 12 13 (14) (15) (16) 17 (18) (19) (20) (21) (22) (23) 24 (25) (26) (27) 28 (29) (30) (31) */
  1278. #endif
  1279. #if MOTHERBOARD == 91 // Final OMCA board -- REF http://sanguino.cc/hardware
  1280. #define KNOWN_BOARD 1
  1281. #if !defined(__AVR_ATmega644P__) && !defined(__AVR_ATmega644__)
  1282. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu. (Final OMCA board)
  1283. #endif
  1284. #define X_STEP_PIN 26
  1285. #define X_DIR_PIN 25
  1286. #define X_ENABLE_PIN 10
  1287. #define X_STOP_PIN 0
  1288. #define Y_STEP_PIN 28
  1289. #define Y_DIR_PIN 27
  1290. #define Y_ENABLE_PIN 10
  1291. #define Y_STOP_PIN 1
  1292. #define Z_STEP_PIN 23
  1293. #define Z_DIR_PIN 22
  1294. #define Z_ENABLE_PIN 10
  1295. #define Z_STOP_PIN 2
  1296. #define E0_STEP_PIN 24
  1297. #define E0_DIR_PIN 21
  1298. #define E0_ENABLE_PIN 10
  1299. /* future proofing */
  1300. #define __FS 20
  1301. #define __FD 19
  1302. #define __GS 18
  1303. #define __GD 13
  1304. #define UNUSED_PWM 14 /* PWM on LEFT connector */
  1305. #define E1_STEP_PIN -1 // 21
  1306. #define E1_DIR_PIN -1 // 20
  1307. #define E1_ENABLE_PIN -1 // 19
  1308. #define E2_STEP_PIN -1 // 21
  1309. #define E2_DIR_PIN -1 // 20
  1310. #define E2_ENABLE_PIN -1 // 18
  1311. #define SDPOWER -1
  1312. #define SDSS 11
  1313. #define SDCARDDETECT -1 // 10 optional also used as mode pin
  1314. #define LED_PIN -1
  1315. #define FAN_PIN 14 /* PWM on MIDDLE connector */
  1316. #define PS_ON_PIN -1
  1317. #define KILL_PIN -1
  1318. #define HEATER_0_PIN 3 /*DONE PWM on RIGHT connector */
  1319. #define HEATER_1_PIN -1
  1320. #define HEATER_2_PIN -1
  1321. #define HEATER_1_PIN -1
  1322. #define HEATER_2_PIN -1
  1323. #define TEMP_0_PIN 0 // ANALOG INPUT NUMBERING
  1324. #define TEMP_1_PIN 1 // ANALOG
  1325. #define TEMP_2_PIN -1 // 2
  1326. #define HEATER_BED_PIN 4
  1327. #define TEMP_BED_PIN 2 // 1,2 or I2C
  1328. #define I2C_SCL 16
  1329. #define I2C_SDA 17
  1330. #endif
  1331. #if MOTHERBOARD == 301
  1332. #define KNOWN_BOARD
  1333. /*****************************************************************
  1334. * Rambo Pin Assignments
  1335. ******************************************************************/
  1336. #ifndef __AVR_ATmega2560__
  1337. #error Oops! Make sure you have 'Arduino Mega 2560' selected from the 'Tools -> Boards' menu.
  1338. #endif
  1339. #define LARGE_FLASH true
  1340. #define X_STEP_PIN 37
  1341. #define X_DIR_PIN 48
  1342. #define X_MIN_PIN 12
  1343. #define X_MAX_PIN 24
  1344. #define X_ENABLE_PIN 29
  1345. #define X_MS1_PIN 40
  1346. #define X_MS2_PIN 41
  1347. #define Y_STEP_PIN 36
  1348. #define Y_DIR_PIN 49
  1349. #define Y_MIN_PIN 11
  1350. #define Y_MAX_PIN 23
  1351. #define Y_ENABLE_PIN 28
  1352. #define Y_MS1_PIN 69
  1353. #define Y_MS2_PIN 39
  1354. #define Z_STEP_PIN 35
  1355. #define Z_DIR_PIN 47
  1356. #define Z_MIN_PIN 10
  1357. #define Z_MAX_PIN 30
  1358. #define Z_ENABLE_PIN 27
  1359. #define Z_MS1_PIN 68
  1360. #define Z_MS2_PIN 67
  1361. #define HEATER_BED_PIN 3
  1362. #define TEMP_BED_PIN 2
  1363. #define HEATER_0_PIN 9
  1364. #define TEMP_0_PIN 0
  1365. #define HEATER_1_PIN 7
  1366. #define TEMP_1_PIN 1
  1367. #ifdef BARICUDA
  1368. #define HEATER_2_PIN 6
  1369. #else
  1370. #define HEATER_2_PIN -1
  1371. #endif
  1372. #define TEMP_2_PIN -1
  1373. #define E0_STEP_PIN 34
  1374. #define E0_DIR_PIN 43
  1375. #define E0_ENABLE_PIN 26
  1376. #define E0_MS1_PIN 65
  1377. #define E0_MS2_PIN 66
  1378. #define E1_STEP_PIN 33
  1379. #define E1_DIR_PIN 42
  1380. #define E1_ENABLE_PIN 25
  1381. #define E1_MS1_PIN 63
  1382. #define E1_MS2_PIN 64
  1383. #define DIGIPOTSS_PIN 38
  1384. #define DIGIPOT_CHANNELS {4,5,3,0,1} // X Y Z E0 E1 digipot channels to stepper driver mapping
  1385. #define SDPOWER -1
  1386. #define SDSS 53
  1387. #define LED_PIN 13
  1388. #define FAN_PIN 8
  1389. #define PS_ON_PIN 4
  1390. #define KILL_PIN -1 //80 with Smart Controller LCD
  1391. #define SUICIDE_PIN -1 //PIN that has to be turned on right after start, to keep power flowing.
  1392. #ifdef ULTRA_LCD
  1393. #define KILL_PIN 80
  1394. #ifdef NEWPANEL
  1395. //arduino pin which triggers an piezzo beeper
  1396. #define BEEPER 79 // Beeper on AUX-4
  1397. #define LCD_PINS_RS 70
  1398. #define LCD_PINS_ENABLE 71
  1399. #define LCD_PINS_D4 72
  1400. #define LCD_PINS_D5 73
  1401. #define LCD_PINS_D6 74
  1402. #define LCD_PINS_D7 75
  1403. //buttons are directly attached using AUX-2
  1404. #define BTN_EN1 76
  1405. #define BTN_EN2 77
  1406. #define BTN_ENC 78 //the click
  1407. #define BLEN_C 2
  1408. #define BLEN_B 1
  1409. #define BLEN_A 0
  1410. #define SDCARDDETECT 81 // Ramps does not use this port
  1411. //encoder rotation values
  1412. #define encrot0 0
  1413. #define encrot1 2
  1414. #define encrot2 3
  1415. #define encrot3 1
  1416. #else //old style panel with shift register
  1417. //arduino pin witch triggers an piezzo beeper
  1418. #define BEEPER 33 No Beeper added
  1419. //buttons are attached to a shift register
  1420. // Not wired this yet
  1421. // #define SHIFT_CLK 38
  1422. // #define SHIFT_LD 42
  1423. // #define SHIFT_OUT 40
  1424. // #define SHIFT_EN 17
  1425. #define LCD_PINS_RS 75
  1426. #define LCD_PINS_ENABLE 17
  1427. #define LCD_PINS_D4 23
  1428. #define LCD_PINS_D5 25
  1429. #define LCD_PINS_D6 27
  1430. #define LCD_PINS_D7 29
  1431. //encoder rotation values
  1432. #define encrot0 0
  1433. #define encrot1 2
  1434. #define encrot2 3
  1435. #define encrot3 1
  1436. //bits in the shift register that carry the buttons for:
  1437. // left up center down right red
  1438. #define BL_LE 7
  1439. #define BL_UP 6
  1440. #define BL_MI 5
  1441. #define BL_DW 4
  1442. #define BL_RI 3
  1443. #define BL_ST 2
  1444. #define BLEN_B 1
  1445. #define BLEN_A 0
  1446. #endif
  1447. #endif //ULTRA_LCD
  1448. #endif
  1449. /****************************************************************************************
  1450. * MegaTronics
  1451. *
  1452. ****************************************************************************************/
  1453. #if MOTHERBOARD == 70
  1454. #define KNOWN_BOARD 1
  1455. #ifndef __AVR_ATmega2560__
  1456. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  1457. #endif
  1458. #define LARGE_FLASH true
  1459. #define X_STEP_PIN 26
  1460. #define X_DIR_PIN 28
  1461. #define X_ENABLE_PIN 24
  1462. #define X_MIN_PIN 41
  1463. #define X_MAX_PIN 37
  1464. #define Y_STEP_PIN 60 // A6
  1465. #define Y_DIR_PIN 61 // A7
  1466. #define Y_ENABLE_PIN 22
  1467. #define Y_MIN_PIN 14
  1468. #define Y_MAX_PIN 15
  1469. #define Z_STEP_PIN 54 // A0
  1470. #define Z_DIR_PIN 55 // A1
  1471. #define Z_ENABLE_PIN 56 // A2
  1472. #define Z_MIN_PIN 18
  1473. #define Z_MAX_PIN 19
  1474. #define E0_STEP_PIN 31
  1475. #define E0_DIR_PIN 32
  1476. #define E0_ENABLE_PIN 38
  1477. #define E1_STEP_PIN 34
  1478. #define E1_DIR_PIN 36
  1479. #define E1_ENABLE_PIN 30
  1480. #define SDPOWER -1
  1481. #define SDSS 53
  1482. #define LED_PIN 13
  1483. #define FAN_PIN 7 // IO pin. Buffer needed
  1484. #define PS_ON_PIN 12
  1485. #define KILL_PIN -1
  1486. #define HEATER_0_PIN 9 // EXTRUDER 1
  1487. #define HEATER_1_PIN 8 // EXTRUDER 2 (FAN On Sprinter)
  1488. #define HEATER_2_PIN -1
  1489. #if TEMP_SENSOR_0 == -1
  1490. #define TEMP_0_PIN 8 // ANALOG NUMBERING
  1491. #else
  1492. #define TEMP_0_PIN 13 // ANALOG NUMBERING
  1493. #endif
  1494. #define TEMP_1_PIN 15 // ANALOG NUMBERING
  1495. #define TEMP_2_PIN -1 // ANALOG NUMBERING
  1496. #define HEATER_BED_PIN 10 // BED
  1497. #define TEMP_BED_PIN 14 // ANALOG NUMBERING
  1498. #define BEEPER 33 // Beeper on AUX-4
  1499. #ifdef ULTRA_LCD
  1500. #ifdef NEWPANEL
  1501. //arduino pin which triggers an piezzo beeper
  1502. #define LCD_PINS_RS 16
  1503. #define LCD_PINS_ENABLE 17
  1504. #define LCD_PINS_D4 23
  1505. #define LCD_PINS_D5 25
  1506. #define LCD_PINS_D6 27
  1507. #define LCD_PINS_D7 29
  1508. //buttons are directly attached using AUX-2
  1509. #define BTN_EN1 59
  1510. #define BTN_EN2 64
  1511. #define BTN_ENC 43 //the click
  1512. #define BLEN_C 2
  1513. #define BLEN_B 1
  1514. #define BLEN_A 0
  1515. #define SDCARDDETECT -1 // Ramps does not use this port
  1516. //encoder rotation values
  1517. #define encrot0 0
  1518. #define encrot1 2
  1519. #define encrot2 3
  1520. #define encrot3 1
  1521. #endif
  1522. #endif //ULTRA_LCD
  1523. #endif
  1524. /****************************************************************************************
  1525. * MegaTronics v2.0
  1526. *
  1527. ****************************************************************************************/
  1528. #if MOTHERBOARD == 701
  1529. #define KNOWN_BOARD 1
  1530. #ifndef __AVR_ATmega2560__
  1531. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  1532. #endif
  1533. #define LARGE_FLASH true
  1534. #define X_STEP_PIN 26
  1535. #define X_DIR_PIN 27
  1536. #define X_ENABLE_PIN 25
  1537. #define X_MIN_PIN 37
  1538. #define X_MAX_PIN 40 //2 //Max endstops default to disabled "-1", set to commented value to enable.
  1539. #define Y_STEP_PIN 4 // A6
  1540. #define Y_DIR_PIN 54 // A0
  1541. #define Y_ENABLE_PIN 5
  1542. #define Y_MIN_PIN 41
  1543. #define Y_MAX_PIN 38 //15
  1544. #define Z_STEP_PIN 56 // A2
  1545. #define Z_DIR_PIN 60 // A6
  1546. #define Z_ENABLE_PIN 55 // A1
  1547. #define Z_MIN_PIN 18
  1548. #define Z_MAX_PIN 19
  1549. #define E0_STEP_PIN 35
  1550. #define E0_DIR_PIN 36
  1551. #define E0_ENABLE_PIN 34
  1552. #define E1_STEP_PIN 29
  1553. #define E1_DIR_PIN 39
  1554. #define E1_ENABLE_PIN 28
  1555. #define E2_STEP_PIN 23
  1556. #define E2_DIR_PIN 24
  1557. #define E2_ENABLE_PIN 22
  1558. #define SDPOWER -1
  1559. #define SDSS 53
  1560. #define LED_PIN 13
  1561. #define FAN_PIN 7
  1562. #define FAN2_PIN 6
  1563. #define PS_ON_PIN 12
  1564. #define KILL_PIN -1
  1565. #define HEATER_0_PIN 9 // EXTRUDER 1
  1566. #define HEATER_1_PIN 8 // EXTRUDER 2
  1567. #define HEATER_2_PIN -1
  1568. #if TEMP_SENSOR_0 == -1
  1569. #define TEMP_0_PIN 4 // ANALOG NUMBERING
  1570. #else
  1571. #define TEMP_0_PIN 13 // ANALOG NUMBERING
  1572. #endif
  1573. #if TEMP_SENSOR_1 == -1
  1574. #define TEMP_1_PIN 8 // ANALOG NUMBERING
  1575. #else
  1576. #define TEMP_1_PIN 15 // ANALOG NUMBERING
  1577. #endif
  1578. #define TEMP_2_PIN -1 // ANALOG NUMBERING
  1579. #define HEATER_BED_PIN 10 // BED
  1580. #if TEMP_SENSOR_BED == -1
  1581. #define TEMP_BED_PIN 8 // ANALOG NUMBERING
  1582. #else
  1583. #define TEMP_BED_PIN 14 // ANALOG NUMBERING
  1584. #endif
  1585. #define BEEPER 64
  1586. #define LCD_PINS_RS 14
  1587. #define LCD_PINS_ENABLE 15
  1588. #define LCD_PINS_D4 30
  1589. #define LCD_PINS_D5 31
  1590. #define LCD_PINS_D6 32
  1591. #define LCD_PINS_D7 33
  1592. //buttons are directly attached using keypad
  1593. #define BTN_EN1 61
  1594. #define BTN_EN2 59
  1595. #define BTN_ENC 43 //the click
  1596. #define BLEN_C 2
  1597. #define BLEN_B 1
  1598. #define BLEN_A 0
  1599. #define SDCARDDETECT -1 // Megatronics does not use this port
  1600. //encoder rotation values
  1601. #define encrot0 0
  1602. #define encrot1 2
  1603. #define encrot2 3
  1604. #define encrot3 1
  1605. #endif
  1606. /****************************************************************************************
  1607. * Minitronics v1.0
  1608. *
  1609. ****************************************************************************************/
  1610. #if MOTHERBOARD == 702
  1611. #define KNOWN_BOARD 1
  1612. #ifndef __AVR_ATmega1281__
  1613. #error Oops! Make sure you have 'Minitronics ' selected from the 'Tools -> Boards' menu.
  1614. #endif
  1615. #define LARGE_FLASH true
  1616. #define X_STEP_PIN 48
  1617. #define X_DIR_PIN 47
  1618. #define X_ENABLE_PIN 49
  1619. #define X_MIN_PIN 5
  1620. #define X_MAX_PIN -1 //2 //Max endstops default to disabled "-1", set to commented value to enable.
  1621. #define Y_STEP_PIN 39 // A6
  1622. #define Y_DIR_PIN 40 // A0
  1623. #define Y_ENABLE_PIN 38
  1624. #define Y_MIN_PIN 2
  1625. #define Y_MAX_PIN -1 //15
  1626. #define Z_STEP_PIN 42 // A2
  1627. #define Z_DIR_PIN 43 // A6
  1628. #define Z_ENABLE_PIN 41 // A1
  1629. #define Z_MIN_PIN 6
  1630. #define Z_MAX_PIN -1
  1631. #define E0_STEP_PIN 45
  1632. #define E0_DIR_PIN 44
  1633. #define E0_ENABLE_PIN 27
  1634. #define E1_STEP_PIN 36
  1635. #define E1_DIR_PIN 35
  1636. #define E1_ENABLE_PIN 37
  1637. #define E2_STEP_PIN -1
  1638. #define E2_DIR_PIN -1
  1639. #define E2_ENABLE_PIN -1
  1640. #define SDPOWER -1
  1641. #define SDSS 16
  1642. #define LED_PIN 46
  1643. #define FAN_PIN 9
  1644. #define FAN2_PIN -1
  1645. #define PS_ON_PIN -1
  1646. #define KILL_PIN -1
  1647. #define HEATER_0_PIN 7 // EXTRUDER 1
  1648. #define HEATER_1_PIN 8 // EXTRUDER 2
  1649. #define HEATER_2_PIN -1
  1650. #define TEMP_0_PIN 7 // ANALOG NUMBERING
  1651. #define TEMP_1_PIN 6 // ANALOG NUMBERING
  1652. #define TEMP_2_PIN -1 // ANALOG NUMBERING
  1653. #define HEATER_BED_PIN 3 // BED
  1654. #define TEMP_BED_PIN 6 // ANALOG NUMBERING
  1655. #define BEEPER -1
  1656. #define LCD_PINS_RS -1
  1657. #define LCD_PINS_ENABLE -1
  1658. #define LCD_PINS_D4 -1
  1659. #define LCD_PINS_D5 -1
  1660. #define LCD_PINS_D6 -1
  1661. #define LCD_PINS_D7 -1
  1662. //buttons are directly attached using keypad
  1663. #define BTN_EN1 -1
  1664. #define BTN_EN2 -1
  1665. #define BTN_ENC -1 //the click
  1666. #define BLEN_C 2
  1667. #define BLEN_B 1
  1668. #define BLEN_A 0
  1669. #define SDCARDDETECT -1 // Megatronics does not use this port
  1670. //encoder rotation values
  1671. #define encrot0 0
  1672. #define encrot1 2
  1673. #define encrot2 3
  1674. #define encrot3 1
  1675. #endif
  1676. #ifndef KNOWN_BOARD
  1677. #error Unknown MOTHERBOARD value in configuration.h
  1678. #endif
  1679. //List of pins which to ignore when asked to change by gcode, 0 and 1 are RX and TX, do not mess with those!
  1680. #define _E0_PINS E0_STEP_PIN, E0_DIR_PIN, E0_ENABLE_PIN, HEATER_0_PIN,
  1681. #if EXTRUDERS > 1
  1682. #define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN, HEATER_1_PIN,
  1683. #else
  1684. #define _E1_PINS
  1685. #endif
  1686. #if EXTRUDERS > 2
  1687. #define _E2_PINS E2_STEP_PIN, E2_DIR_PIN, E2_ENABLE_PIN, HEATER_2_PIN,
  1688. #else
  1689. #define _E2_PINS
  1690. #endif
  1691. #ifdef X_STOP_PIN
  1692. #if X_HOME_DIR < 0
  1693. #define X_MIN_PIN X_STOP_PIN
  1694. #define X_MAX_PIN -1
  1695. #else
  1696. #define X_MIN_PIN -1
  1697. #define X_MAX_PIN X_STOP_PIN
  1698. #endif
  1699. #endif
  1700. #ifdef Y_STOP_PIN
  1701. #if Y_HOME_DIR < 0
  1702. #define Y_MIN_PIN Y_STOP_PIN
  1703. #define Y_MAX_PIN -1
  1704. #else
  1705. #define Y_MIN_PIN -1
  1706. #define Y_MAX_PIN Y_STOP_PIN
  1707. #endif
  1708. #endif
  1709. #ifdef Z_STOP_PIN
  1710. #if Z_HOME_DIR < 0
  1711. #define Z_MIN_PIN Z_STOP_PIN
  1712. #define Z_MAX_PIN -1
  1713. #else
  1714. #define Z_MIN_PIN -1
  1715. #define Z_MAX_PIN Z_STOP_PIN
  1716. #endif
  1717. #endif
  1718. #ifdef DISABLE_MAX_ENDSTOPS
  1719. #define X_MAX_PIN -1
  1720. #define Y_MAX_PIN -1
  1721. #define Z_MAX_PIN -1
  1722. #endif
  1723. #ifdef DISABLE_MIN_ENDSTOPS
  1724. #define X_MIN_PIN -1
  1725. #define Y_MIN_PIN -1
  1726. #define Z_MIN_PIN -1
  1727. #endif
  1728. #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, PS_ON_PIN, \
  1729. HEATER_BED_PIN, FAN_PIN, \
  1730. _E0_PINS _E1_PINS _E2_PINS \
  1731. analogInputToDigitalPin(TEMP_0_PIN), analogInputToDigitalPin(TEMP_1_PIN), analogInputToDigitalPin(TEMP_2_PIN), analogInputToDigitalPin(TEMP_BED_PIN) }
  1732. #endif