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 66KB

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