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

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541
  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. //arduino pin witch triggers an piezzo beeper
  1078. #define BEEPER 18
  1079. #define LCD_PINS_RS 20
  1080. #define LCD_PINS_ENABLE 15
  1081. #define LCD_PINS_D4 14
  1082. #define LCD_PINS_D5 21
  1083. #define LCD_PINS_D6 5
  1084. #define LCD_PINS_D7 6
  1085. //buttons are directly attached
  1086. #define BTN_EN1 40
  1087. #define BTN_EN2 41
  1088. #define BTN_ENC 19 //the click
  1089. #define BLEN_C 2
  1090. #define BLEN_B 1
  1091. #define BLEN_A 0
  1092. #define SDCARDDETECT 39
  1093. #endif//MOTHERBOARD == 72
  1094. /****************************************************************************************
  1095. * RUMBA pin assignment
  1096. *
  1097. ****************************************************************************************/
  1098. #if MOTHERBOARD == 80
  1099. #define KNOWN_BOARD 1
  1100. #ifndef __AVR_ATmega2560__
  1101. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  1102. #endif
  1103. #define X_STEP_PIN 17
  1104. #define X_DIR_PIN 16
  1105. #define X_ENABLE_PIN 48
  1106. #define X_MIN_PIN 37
  1107. #define X_MAX_PIN 36
  1108. #define Y_STEP_PIN 54
  1109. #define Y_DIR_PIN 47
  1110. #define Y_ENABLE_PIN 55
  1111. #define Y_MIN_PIN 35
  1112. #define Y_MAX_PIN 34
  1113. #define Z_STEP_PIN 57
  1114. #define Z_DIR_PIN 56
  1115. #define Z_ENABLE_PIN 62
  1116. #define Z_MIN_PIN 33
  1117. #define Z_MAX_PIN 32
  1118. #define E0_STEP_PIN 23
  1119. #define E0_DIR_PIN 22
  1120. #define E0_ENABLE_PIN 24
  1121. #define E1_STEP_PIN 26
  1122. #define E1_DIR_PIN 25
  1123. #define E1_ENABLE_PIN 27
  1124. #define E2_STEP_PIN 29
  1125. #define E2_DIR_PIN 28
  1126. #define E2_ENABLE_PIN 39
  1127. #define LED_PIN 13
  1128. #define FAN_PIN 7
  1129. //additional FAN1 PIN (e.g. useful for electronics fan or light on/off) on PIN 8
  1130. #define PS_ON_PIN 45
  1131. #define KILL_PIN 46
  1132. #if (TEMP_SENSOR_0==0)
  1133. #define TEMP_0_PIN -1
  1134. #define HEATER_0_PIN -1
  1135. #else
  1136. #define HEATER_0_PIN 2 // EXTRUDER 1
  1137. #if (TEMP_SENSOR_0==-1)
  1138. #define TEMP_0_PIN 6 // ANALOG NUMBERING - connector *K1* on RUMBA thermocouple ADD ON is used
  1139. #else
  1140. #define TEMP_0_PIN 15 // ANALOG NUMBERING - default connector for thermistor *T0* on rumba board is used
  1141. #endif
  1142. #endif
  1143. #if (TEMP_SENSOR_1==0)
  1144. #define TEMP_1_PIN -1
  1145. #define HEATER_1_PIN -1
  1146. #else
  1147. #define HEATER_1_PIN 3 // EXTRUDER 2
  1148. #if (TEMP_SENSOR_1==-1)
  1149. #define TEMP_1_PIN 5 // ANALOG NUMBERING - connector *K2* on RUMBA thermocouple ADD ON is used
  1150. #else
  1151. #define TEMP_1_PIN 14 // ANALOG NUMBERING - default connector for thermistor *T1* on rumba board is used
  1152. #endif
  1153. #endif
  1154. #if (TEMP_SENSOR_2==0)
  1155. #define TEMP_2_PIN -1
  1156. #define HEATER_2_PIN -1
  1157. #else
  1158. #define HEATER_2_PIN 6 // EXTRUDER 3
  1159. #if (TEMP_SENSOR_2==-1)
  1160. #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
  1161. #else
  1162. #define TEMP_2_PIN 13 // ANALOG NUMBERING - default connector for thermistor *T2* on rumba board is used
  1163. #endif
  1164. #endif
  1165. //optional for extruder 4 or chamber: #define TEMP_X_PIN 12 // ANALOG NUMBERING - default connector for thermistor *T3* on rumba board is used
  1166. //optional FAN1 can be used as 4th heater output: #define HEATER_3_PIN 8 // EXTRUDER 4
  1167. #if (TEMP_SENSOR_BED==0)
  1168. #define TEMP_BED_PIN -1
  1169. #define HEATER_BED_PIN -1
  1170. #else
  1171. #define HEATER_BED_PIN 9 // BED
  1172. #if (TEMP_SENSOR_BED==-1)
  1173. #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
  1174. #else
  1175. #define TEMP_BED_PIN 11 // ANALOG NUMBERING - default connector for thermistor *THB* on rumba board is used
  1176. #endif
  1177. #endif
  1178. #define SDPOWER -1
  1179. #define SDSS 53
  1180. #define SDCARDDETECT 49
  1181. #define BEEPER 44
  1182. #define LCD_PINS_RS 19
  1183. #define LCD_PINS_ENABLE 42
  1184. #define LCD_PINS_D4 18
  1185. #define LCD_PINS_D5 38
  1186. #define LCD_PINS_D6 41
  1187. #define LCD_PINS_D7 40
  1188. #define BTN_EN1 11
  1189. #define BTN_EN2 12
  1190. #define BTN_ENC 43
  1191. #endif //MOTHERBOARD==80
  1192. /****************************************************************************************
  1193. * Teensylu 0.7 / Printrboard pin assignments (AT90USB1286)
  1194. * Requires the Teensyduino software with Teensy++ 2.0 selected in Arduino IDE!
  1195. http://www.pjrc.com/teensy/teensyduino.html
  1196. * See http://reprap.org/wiki/Printrboard for more info
  1197. ****************************************************************************************/
  1198. #if MOTHERBOARD == 8 || MOTHERBOARD == 81
  1199. #define KNOWN_BOARD 1
  1200. #define AT90USB 1286 // Disable MarlinSerial etc.
  1201. #ifndef __AVR_AT90USB1286__
  1202. #error Oops! Make sure you have 'Teensy++ 2.0' selected from the 'Tools -> Boards' menu.
  1203. #endif
  1204. #define LARGE_FLASH true
  1205. #define X_STEP_PIN 0
  1206. #define X_DIR_PIN 1
  1207. #define X_ENABLE_PIN 39
  1208. #define Y_STEP_PIN 2
  1209. #define Y_DIR_PIN 3
  1210. #define Y_ENABLE_PIN 38
  1211. #define Z_STEP_PIN 4
  1212. #define Z_DIR_PIN 5
  1213. #define Z_ENABLE_PIN 23
  1214. #define E0_STEP_PIN 6
  1215. #define E0_DIR_PIN 7
  1216. #define E0_ENABLE_PIN 19
  1217. #define HEATER_0_PIN 21 // Extruder
  1218. #define HEATER_1_PIN -1
  1219. #define HEATER_2_PIN -1
  1220. #define HEATER_BED_PIN 20 // Bed
  1221. #define FAN_PIN 22 // Fan
  1222. // You may need to change FAN_PIN to 16 because Marlin isn't using fastio.h
  1223. // for the fan and Teensyduino uses a different pin mapping.
  1224. #if MOTHERBOARD == 8 // Teensylu
  1225. #define X_STOP_PIN 13
  1226. #define Y_STOP_PIN 14
  1227. #define Z_STOP_PIN 15
  1228. #define TEMP_0_PIN 7 // Extruder / Analog pin numbering
  1229. #define TEMP_BED_PIN 6 // Bed / Analog pin numbering
  1230. #else // Printrboard
  1231. #define X_STOP_PIN 35
  1232. #define Y_STOP_PIN 8
  1233. #define Z_STOP_PIN 36
  1234. #define TEMP_0_PIN 1 // Extruder / Analog pin numbering
  1235. #define TEMP_BED_PIN 0 // Bed / Analog pin numbering
  1236. #endif
  1237. #define TEMP_1_PIN -1
  1238. #define TEMP_2_PIN -1
  1239. #define SDPOWER -1
  1240. #define SDSS 8
  1241. #define LED_PIN -1
  1242. #define PS_ON_PIN -1
  1243. #define KILL_PIN -1
  1244. #define ALARM_PIN -1
  1245. #ifndef SDSUPPORT
  1246. // these pins are defined in the SD library if building with SD support
  1247. #define SCK_PIN 9
  1248. #define MISO_PIN 11
  1249. #define MOSI_PIN 10
  1250. #endif
  1251. #endif // MOTHERBOARD == 8 (Teensylu) or 81 (Printrboard)
  1252. /****************************************************************************************
  1253. * Brainwave 1.0 pin assignments (AT90USB646)
  1254. * Requires hardware bundle for Arduino:
  1255. https://github.com/unrepentantgeek/brainwave-arduino
  1256. ****************************************************************************************/
  1257. #if MOTHERBOARD == 82
  1258. #define KNOWN_BOARD 1
  1259. #define AT90USB 646 // Disable MarlinSerial etc.
  1260. #ifndef __AVR_AT90USB646__
  1261. #error Oops! Make sure you have 'Brainwave' selected from the 'Tools -> Boards' menu.
  1262. #endif
  1263. #define X_STEP_PIN 27
  1264. #define X_DIR_PIN 29
  1265. #define X_ENABLE_PIN 28
  1266. #define X_STOP_PIN 7
  1267. #define X_ATT_PIN 26
  1268. #define Y_STEP_PIN 31
  1269. #define Y_DIR_PIN 33
  1270. #define Y_ENABLE_PIN 32
  1271. #define Y_STOP_PIN 6
  1272. #define Y_ATT_PIN 30
  1273. #define Z_STEP_PIN 17
  1274. #define Z_DIR_PIN 19
  1275. #define Z_ENABLE_PIN 18
  1276. #define Z_STOP_PIN 5
  1277. #define Z_ATT_PIN 16
  1278. #define E0_STEP_PIN 21
  1279. #define E0_DIR_PIN 23
  1280. #define E0_ENABLE_PIN 22
  1281. #define E0_ATT_PIN 20
  1282. #define HEATER_0_PIN 4 // Extruder
  1283. #define HEATER_1_PIN -1
  1284. #define HEATER_2_PIN -1
  1285. #define HEATER_BED_PIN 38 // Bed
  1286. #define FAN_PIN 3 // Fan
  1287. #define TEMP_0_PIN 7 // Extruder / Analog pin numbering
  1288. #define TEMP_1_PIN -1
  1289. #define TEMP_2_PIN -1
  1290. #define TEMP_BED_PIN 6 // Bed / Analog pin numbering
  1291. #define SDPOWER -1
  1292. #define SDSS -1
  1293. #define LED_PIN 39
  1294. #define PS_ON_PIN -1
  1295. #define KILL_PIN -1
  1296. #define ALARM_PIN -1
  1297. #ifndef SDSUPPORT
  1298. // these pins are defined in the SD library if building with SD support
  1299. #define SCK_PIN 9
  1300. #define MISO_PIN 11
  1301. #define MOSI_PIN 10
  1302. #endif
  1303. #endif // MOTHERBOARD == 82 (Brainwave)
  1304. //
  1305. // SAV Mk-I
  1306. // -----------------------------------------------------------------------------------
  1307. /****************************************************************************************
  1308. * SAV MkI pin assignments (AT90USB1286)
  1309. * Requires the Teensyduino software with Teensy++ 2.0 selected in Arduino IDE!
  1310. http://www.pjrc.com/teensy/teensyduino.html
  1311. RepRap Clone Wars project board.
  1312. ****************************************************************************************/
  1313. #if MOTHERBOARD == 83 // SAV Mk-I
  1314. #define KNOWN_BOARD 1
  1315. #define AT90USB 1286 // Disable MarlinSerial etc.
  1316. #ifndef __AVR_AT90USB1286__
  1317. #error Oops! Make sure you have 'Teensy++ 2.0' selected from the 'Tools -> Boards' menu.
  1318. #endif
  1319. #define LARGE_FLASH true
  1320. #define X_STEP_PIN 0
  1321. #define X_DIR_PIN 1
  1322. #define X_ENABLE_PIN 39
  1323. #define Y_STEP_PIN 2
  1324. #define Y_DIR_PIN 3
  1325. #define Y_ENABLE_PIN 38
  1326. #define Z_STEP_PIN 4
  1327. #define Z_DIR_PIN 5
  1328. #define Z_ENABLE_PIN 23
  1329. #define E0_STEP_PIN 6
  1330. #define E0_DIR_PIN 7
  1331. #define E0_ENABLE_PIN 19
  1332. #define HEATER_0_PIN 21 // Extruder
  1333. #define HEATER_1_PIN -1
  1334. #define HEATER_2_PIN -1
  1335. #define HEATER_BED_PIN 20 // Bed
  1336. #define FAN_PIN 16 // Fan -- from Teensyduino environment.
  1337. // For the fan and Teensyduino uses a different pin mapping.
  1338. #define X_STOP_PIN 13
  1339. #define Y_STOP_PIN 14
  1340. #define Z_STOP_PIN 15
  1341. #define TEMP_0_PIN 7 // Extruder / Analog pin numbering
  1342. #define TEMP_BED_PIN 6 // Bed / Analog pin numbering
  1343. #define TEMP_1_PIN -1
  1344. #define TEMP_2_PIN -1
  1345. #define SDPOWER -1
  1346. #define SDSS 20 // PB0 - 8 in marlin env.
  1347. #define LED_PIN -1
  1348. #define PS_ON_PIN -1
  1349. #define KILL_PIN -1
  1350. #define ALARM_PIN -1
  1351. #define SDCARDDETECT -1
  1352. #ifndef SDSUPPORT
  1353. // these pins are defined in the SD library if building with SD support
  1354. #define SCK_PIN 9
  1355. #define MISO_PIN 11
  1356. #define MOSI_PIN 10
  1357. #endif
  1358. #define BEEPER -1
  1359. #define LCD_PINS_RS -1
  1360. #define LCD_PINS_ENABLE -1
  1361. #define LCD_PINS_D4 -1
  1362. #define LCD_PINS_D5 -1
  1363. #define LCD_PINS_D6 -1
  1364. #define LCD_PINS_D7 -1
  1365. #define BTN_EN1 -1
  1366. #define BTN_EN2 -1
  1367. #define BTN_ENC -1
  1368. // For LCD SHIFT register LCD
  1369. #define SR_DATA_PIN 0
  1370. #define SR_CLK_PIN 1
  1371. #endif // MOTHERBOARD == 83
  1372. /****************************************************************************************
  1373. * Gen3+ pin assignment
  1374. *
  1375. ****************************************************************************************/
  1376. #if MOTHERBOARD == 9
  1377. #define MOTHERBOARD 6 /*TODO: Figure out, Why is this done?*/
  1378. #define KNOWN_BOARD 1
  1379. #ifndef __AVR_ATmega644P__
  1380. #ifndef __AVR_ATmega1284P__
  1381. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu.
  1382. #endif
  1383. #endif
  1384. #define X_STEP_PIN 15
  1385. #define X_DIR_PIN 18
  1386. #define X_STOP_PIN 20
  1387. #define Y_STEP_PIN 23
  1388. #define Y_DIR_PIN 22
  1389. #define Y_STOP_PIN 25
  1390. #define Z_STEP_PIN 27
  1391. #define Z_DIR_PIN 28
  1392. #define Z_STOP_PIN 30
  1393. #define E_STEP_PIN 17
  1394. #define E_DIR_PIN 21
  1395. #define LED_PIN -1
  1396. #define FAN_PIN -1
  1397. #define PS_ON_PIN 14
  1398. #define KILL_PIN -1
  1399. #define HEATER_0_PIN 12 // (extruder)
  1400. #define HEATER_1_PIN 16 // (bed)
  1401. #define X_ENABLE_PIN 19
  1402. #define Y_ENABLE_PIN 24
  1403. #define Z_ENABLE_PIN 29
  1404. #define E_ENABLE_PIN 13
  1405. #define TEMP_0_PIN 0 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 33 extruder)
  1406. #define TEMP_1_PIN 5 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!! (pin 34 bed)
  1407. #define TEMP_2_PIN -1
  1408. #define SDPOWER -1
  1409. #define SDSS 4
  1410. #define HEATER_2_PIN -1
  1411. #endif
  1412. /****************************************************************************************
  1413. * Open Motion controller with enable based extruders
  1414. *
  1415. * ATMega644
  1416. *
  1417. * +---\/---+
  1418. * (D 0) PB0 1| |40 PA0 (AI 0 / D31)
  1419. * (D 1) PB1 2| |39 PA1 (AI 1 / D30)
  1420. * INT2 (D 2) PB2 3| |38 PA2 (AI 2 / D29)
  1421. * PWM (D 3) PB3 4| |37 PA3 (AI 3 / D28)
  1422. * PWM (D 4) PB4 5| |36 PA4 (AI 4 / D27)
  1423. * MOSI (D 5) PB5 6| |35 PA5 (AI 5 / D26)
  1424. * MISO (D 6) PB6 7| |34 PA6 (AI 6 / D25)
  1425. * SCK (D 7) PB7 8| |33 PA7 (AI 7 / D24)
  1426. * RST 9| |32 AREF
  1427. * VCC 10| |31 GND
  1428. * GND 11| |30 AVCC
  1429. * XTAL2 12| |29 PC7 (D 23)
  1430. * XTAL1 13| |28 PC6 (D 22)
  1431. * RX0 (D 8) PD0 14| |27 PC5 (D 21) TDI
  1432. * TX0 (D 9) PD1 15| |26 PC4 (D 20) TDO
  1433. * INT0 RX1 (D 10) PD2 16| |25 PC3 (D 19) TMS
  1434. * INT1 TX1 (D 11) PD3 17| |24 PC2 (D 18) TCK
  1435. * PWM (D 12) PD4 18| |23 PC1 (D 17) SDA
  1436. * PWM (D 13) PD5 19| |22 PC0 (D 16) SCL
  1437. * PWM (D 14) PD6 20| |21 PD7 (D 15) PWM
  1438. * +--------+
  1439. *
  1440. ****************************************************************************************/
  1441. #if MOTHERBOARD == 90 //Alpha OMCA board
  1442. #define KNOWN_BOARD 1
  1443. #ifndef __AVR_ATmega644__
  1444. #error Oops! Make sure you have 'SanguinoA' selected from the 'Tools -> Boards' menu.
  1445. #endif
  1446. #define X_STEP_PIN 21
  1447. #define X_DIR_PIN 20
  1448. #define X_ENABLE_PIN 24
  1449. #define X_STOP_PIN 0
  1450. #define Y_STEP_PIN 23
  1451. #define Y_DIR_PIN 22
  1452. #define Y_ENABLE_PIN 24
  1453. #define Y_STOP_PIN 1
  1454. #define Z_STEP_PIN 26
  1455. #define Z_DIR_PIN 25
  1456. #define Z_ENABLE_PIN 24
  1457. #define Z_STOP_PIN 2
  1458. #define E0_STEP_PIN 28
  1459. #define E0_DIR_PIN 27
  1460. #define E0_ENABLE_PIN 24
  1461. #define E1_STEP_PIN -1 // 19
  1462. #define E1_DIR_PIN -1 // 18
  1463. #define E1_ENABLE_PIN 24
  1464. #define E2_STEP_PIN -1 // 17
  1465. #define E2_DIR_PIN -1 // 16
  1466. #define E2_ENABLE_PIN 24
  1467. #define SDPOWER -1
  1468. #define SDSS 11
  1469. #define SDCARDDETECT -1 // 10 optional also used as mode pin
  1470. #define LED_PIN -1
  1471. #define FAN_PIN 3
  1472. #define PS_ON_PIN -1
  1473. #define KILL_PIN -1
  1474. #define HEATER_0_PIN 4
  1475. #define HEATER_1_PIN -1 // 12
  1476. #define HEATER_2_PIN -1 // 13
  1477. #define TEMP_0_PIN 0 //D27 // MUST USE ANALOG INPUT NUMBERING NOT DIGITAL OUTPUT NUMBERING!!!!!!!!!
  1478. #define TEMP_1_PIN -1 // 1
  1479. #define TEMP_2_PIN -1 // 2
  1480. #define HEATER_BED_PIN -1 // 14/15
  1481. #define TEMP_BED_PIN -1 // 1,2 or I2C
  1482. /* 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) */
  1483. #endif
  1484. #if MOTHERBOARD == 91 // Final OMCA board -- REF http://sanguino.cc/hardware
  1485. #define KNOWN_BOARD 1
  1486. #if !defined(__AVR_ATmega644P__) && !defined(__AVR_ATmega644__)
  1487. #error Oops! Make sure you have 'Sanguino' selected from the 'Tools -> Boards' menu. (Final OMCA board)
  1488. #endif
  1489. #define X_STEP_PIN 26
  1490. #define X_DIR_PIN 25
  1491. #define X_ENABLE_PIN 10
  1492. #define X_STOP_PIN 0
  1493. #define Y_STEP_PIN 28
  1494. #define Y_DIR_PIN 27
  1495. #define Y_ENABLE_PIN 10
  1496. #define Y_STOP_PIN 1
  1497. #define Z_STEP_PIN 23
  1498. #define Z_DIR_PIN 22
  1499. #define Z_ENABLE_PIN 10
  1500. #define Z_STOP_PIN 2
  1501. #define E0_STEP_PIN 24
  1502. #define E0_DIR_PIN 21
  1503. #define E0_ENABLE_PIN 10
  1504. /* future proofing */
  1505. #define __FS 20
  1506. #define __FD 19
  1507. #define __GS 18
  1508. #define __GD 13
  1509. #define UNUSED_PWM 14 /* PWM on LEFT connector */
  1510. #define E1_STEP_PIN -1 // 21
  1511. #define E1_DIR_PIN -1 // 20
  1512. #define E1_ENABLE_PIN -1 // 19
  1513. #define E2_STEP_PIN -1 // 21
  1514. #define E2_DIR_PIN -1 // 20
  1515. #define E2_ENABLE_PIN -1 // 18
  1516. #define SDPOWER -1
  1517. #define SDSS 11
  1518. #define SDCARDDETECT -1 // 10 optional also used as mode pin
  1519. #define LED_PIN -1
  1520. #define FAN_PIN 14 /* PWM on MIDDLE connector */
  1521. #define PS_ON_PIN -1
  1522. #define KILL_PIN -1
  1523. #define HEATER_0_PIN 3 /*DONE PWM on RIGHT connector */
  1524. #define HEATER_1_PIN -1
  1525. #define HEATER_2_PIN -1
  1526. #define HEATER_1_PIN -1
  1527. #define HEATER_2_PIN -1
  1528. #define TEMP_0_PIN 0 // ANALOG INPUT NUMBERING
  1529. #define TEMP_1_PIN 1 // ANALOG
  1530. #define TEMP_2_PIN -1 // 2
  1531. #define HEATER_BED_PIN 4
  1532. #define TEMP_BED_PIN 2 // 1,2 or I2C
  1533. #define I2C_SCL 16
  1534. #define I2C_SDA 17
  1535. #endif
  1536. #if MOTHERBOARD == 301
  1537. #define KNOWN_BOARD
  1538. /*****************************************************************
  1539. * Rambo Pin Assignments
  1540. ******************************************************************/
  1541. #ifndef __AVR_ATmega2560__
  1542. #error Oops! Make sure you have 'Arduino Mega 2560' selected from the 'Tools -> Boards' menu.
  1543. #endif
  1544. #define LARGE_FLASH true
  1545. #define X_STEP_PIN 37
  1546. #define X_DIR_PIN 48
  1547. #define X_MIN_PIN 12
  1548. #define X_MAX_PIN 24
  1549. #define X_ENABLE_PIN 29
  1550. #define X_MS1_PIN 40
  1551. #define X_MS2_PIN 41
  1552. #define Y_STEP_PIN 36
  1553. #define Y_DIR_PIN 49
  1554. #define Y_MIN_PIN 11
  1555. #define Y_MAX_PIN 23
  1556. #define Y_ENABLE_PIN 28
  1557. #define Y_MS1_PIN 69
  1558. #define Y_MS2_PIN 39
  1559. #define Z_STEP_PIN 35
  1560. #define Z_DIR_PIN 47
  1561. #define Z_MIN_PIN 10
  1562. #define Z_MAX_PIN 30
  1563. #define Z_ENABLE_PIN 27
  1564. #define Z_MS1_PIN 68
  1565. #define Z_MS2_PIN 67
  1566. #define HEATER_BED_PIN 3
  1567. #define TEMP_BED_PIN 2
  1568. #define HEATER_0_PIN 9
  1569. #define TEMP_0_PIN 0
  1570. #define HEATER_1_PIN 7
  1571. #define TEMP_1_PIN 1
  1572. #ifdef BARICUDA
  1573. #define HEATER_2_PIN 6
  1574. #else
  1575. #define HEATER_2_PIN -1
  1576. #endif
  1577. #define TEMP_2_PIN -1
  1578. #define E0_STEP_PIN 34
  1579. #define E0_DIR_PIN 43
  1580. #define E0_ENABLE_PIN 26
  1581. #define E0_MS1_PIN 65
  1582. #define E0_MS2_PIN 66
  1583. #define E1_STEP_PIN 33
  1584. #define E1_DIR_PIN 42
  1585. #define E1_ENABLE_PIN 25
  1586. #define E1_MS1_PIN 63
  1587. #define E1_MS2_PIN 64
  1588. #define DIGIPOTSS_PIN 38
  1589. #define DIGIPOT_CHANNELS {4,5,3,0,1} // X Y Z E0 E1 digipot channels to stepper driver mapping
  1590. #define SDPOWER -1
  1591. #define SDSS 53
  1592. #define LED_PIN 13
  1593. #define FAN_PIN 8
  1594. #define PS_ON_PIN 4
  1595. #define KILL_PIN -1 //80 with Smart Controller LCD
  1596. #define SUICIDE_PIN -1 //PIN that has to be turned on right after start, to keep power flowing.
  1597. #ifdef ULTRA_LCD
  1598. #define KILL_PIN 80
  1599. #ifdef NEWPANEL
  1600. //arduino pin which triggers an piezzo beeper
  1601. #define BEEPER 79 // Beeper on AUX-4
  1602. #define LCD_PINS_RS 70
  1603. #define LCD_PINS_ENABLE 71
  1604. #define LCD_PINS_D4 72
  1605. #define LCD_PINS_D5 73
  1606. #define LCD_PINS_D6 74
  1607. #define LCD_PINS_D7 75
  1608. //buttons are directly attached using AUX-2
  1609. #define BTN_EN1 76
  1610. #define BTN_EN2 77
  1611. #define BTN_ENC 78 //the click
  1612. #define BLEN_C 2
  1613. #define BLEN_B 1
  1614. #define BLEN_A 0
  1615. #define SDCARDDETECT 81 // Ramps does not use this port
  1616. //encoder rotation values
  1617. #define encrot0 0
  1618. #define encrot1 2
  1619. #define encrot2 3
  1620. #define encrot3 1
  1621. #else //old style panel with shift register
  1622. //arduino pin witch triggers an piezzo beeper
  1623. #define BEEPER 33 No Beeper added
  1624. //buttons are attached to a shift register
  1625. // Not wired this yet
  1626. // #define SHIFT_CLK 38
  1627. // #define SHIFT_LD 42
  1628. // #define SHIFT_OUT 40
  1629. // #define SHIFT_EN 17
  1630. #define LCD_PINS_RS 75
  1631. #define LCD_PINS_ENABLE 17
  1632. #define LCD_PINS_D4 23
  1633. #define LCD_PINS_D5 25
  1634. #define LCD_PINS_D6 27
  1635. #define LCD_PINS_D7 29
  1636. //encoder rotation values
  1637. #define encrot0 0
  1638. #define encrot1 2
  1639. #define encrot2 3
  1640. #define encrot3 1
  1641. //bits in the shift register that carry the buttons for:
  1642. // left up center down right red
  1643. #define BL_LE 7
  1644. #define BL_UP 6
  1645. #define BL_MI 5
  1646. #define BL_DW 4
  1647. #define BL_RI 3
  1648. #define BL_ST 2
  1649. #define BLEN_B 1
  1650. #define BLEN_A 0
  1651. #endif
  1652. #endif //ULTRA_LCD
  1653. #endif
  1654. /****************************************************************************************
  1655. * MegaTronics
  1656. *
  1657. ****************************************************************************************/
  1658. #if MOTHERBOARD == 70
  1659. #define KNOWN_BOARD 1
  1660. #ifndef __AVR_ATmega2560__
  1661. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  1662. #endif
  1663. #define LARGE_FLASH true
  1664. #define X_STEP_PIN 26
  1665. #define X_DIR_PIN 28
  1666. #define X_ENABLE_PIN 24
  1667. #define X_MIN_PIN 41
  1668. #define X_MAX_PIN 37
  1669. #define Y_STEP_PIN 60 // A6
  1670. #define Y_DIR_PIN 61 // A7
  1671. #define Y_ENABLE_PIN 22
  1672. #define Y_MIN_PIN 14
  1673. #define Y_MAX_PIN 15
  1674. #define Z_STEP_PIN 54 // A0
  1675. #define Z_DIR_PIN 55 // A1
  1676. #define Z_ENABLE_PIN 56 // A2
  1677. #define Z_MIN_PIN 18
  1678. #define Z_MAX_PIN 19
  1679. #define E0_STEP_PIN 31
  1680. #define E0_DIR_PIN 32
  1681. #define E0_ENABLE_PIN 38
  1682. #define E1_STEP_PIN 34
  1683. #define E1_DIR_PIN 36
  1684. #define E1_ENABLE_PIN 30
  1685. #define SDPOWER -1
  1686. #define SDSS 53
  1687. #define LED_PIN 13
  1688. #define FAN_PIN 7 // IO pin. Buffer needed
  1689. #define PS_ON_PIN 12
  1690. #define KILL_PIN -1
  1691. #define HEATER_0_PIN 9 // EXTRUDER 1
  1692. #define HEATER_1_PIN 8 // EXTRUDER 2 (FAN On Sprinter)
  1693. #define HEATER_2_PIN -1
  1694. #if TEMP_SENSOR_0 == -1
  1695. #define TEMP_0_PIN 8 // ANALOG NUMBERING
  1696. #else
  1697. #define TEMP_0_PIN 13 // ANALOG NUMBERING
  1698. #endif
  1699. #define TEMP_1_PIN 15 // ANALOG NUMBERING
  1700. #define TEMP_2_PIN -1 // ANALOG NUMBERING
  1701. #define HEATER_BED_PIN 10 // BED
  1702. #define TEMP_BED_PIN 14 // ANALOG NUMBERING
  1703. #define BEEPER 33 // Beeper on AUX-4
  1704. #ifdef ULTRA_LCD
  1705. #ifdef NEWPANEL
  1706. //arduino pin which triggers an piezzo beeper
  1707. #define LCD_PINS_RS 16
  1708. #define LCD_PINS_ENABLE 17
  1709. #define LCD_PINS_D4 23
  1710. #define LCD_PINS_D5 25
  1711. #define LCD_PINS_D6 27
  1712. #define LCD_PINS_D7 29
  1713. //buttons are directly attached using AUX-2
  1714. #define BTN_EN1 59
  1715. #define BTN_EN2 64
  1716. #define BTN_ENC 43 //the click
  1717. #define BLEN_C 2
  1718. #define BLEN_B 1
  1719. #define BLEN_A 0
  1720. #define SDCARDDETECT -1 // Ramps does not use this port
  1721. //encoder rotation values
  1722. #define encrot0 0
  1723. #define encrot1 2
  1724. #define encrot2 3
  1725. #define encrot3 1
  1726. #endif
  1727. #endif //ULTRA_LCD
  1728. #endif
  1729. /****************************************************************************************
  1730. * MegaTronics v2.0
  1731. *
  1732. ****************************************************************************************/
  1733. #if MOTHERBOARD == 701
  1734. #define KNOWN_BOARD 1
  1735. #ifndef __AVR_ATmega2560__
  1736. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  1737. #endif
  1738. #define LARGE_FLASH true
  1739. #define X_STEP_PIN 26
  1740. #define X_DIR_PIN 27
  1741. #define X_ENABLE_PIN 25
  1742. #define X_MIN_PIN 37
  1743. #define X_MAX_PIN 40 //2 //Max endstops default to disabled "-1", set to commented value to enable.
  1744. #define Y_STEP_PIN 4 // A6
  1745. #define Y_DIR_PIN 54 // A0
  1746. #define Y_ENABLE_PIN 5
  1747. #define Y_MIN_PIN 41
  1748. #define Y_MAX_PIN 38 //15
  1749. #define Z_STEP_PIN 56 // A2
  1750. #define Z_DIR_PIN 60 // A6
  1751. #define Z_ENABLE_PIN 55 // A1
  1752. #define Z_MIN_PIN 18
  1753. #define Z_MAX_PIN 19
  1754. #define E0_STEP_PIN 35
  1755. #define E0_DIR_PIN 36
  1756. #define E0_ENABLE_PIN 34
  1757. #define E1_STEP_PIN 29
  1758. #define E1_DIR_PIN 39
  1759. #define E1_ENABLE_PIN 28
  1760. #define E2_STEP_PIN 23
  1761. #define E2_DIR_PIN 24
  1762. #define E2_ENABLE_PIN 22
  1763. #define SDPOWER -1
  1764. #define SDSS 53
  1765. #define LED_PIN 13
  1766. #define FAN_PIN 7
  1767. #define FAN2_PIN 6
  1768. #define PS_ON_PIN 12
  1769. #define KILL_PIN -1
  1770. #define HEATER_0_PIN 9 // EXTRUDER 1
  1771. #define HEATER_1_PIN 8 // EXTRUDER 2
  1772. #define HEATER_2_PIN -1
  1773. #if TEMP_SENSOR_0 == -1
  1774. #define TEMP_0_PIN 4 // ANALOG NUMBERING
  1775. #else
  1776. #define TEMP_0_PIN 13 // ANALOG NUMBERING
  1777. #endif
  1778. #if TEMP_SENSOR_1 == -1
  1779. #define TEMP_1_PIN 8 // ANALOG NUMBERING
  1780. #else
  1781. #define TEMP_1_PIN 15 // ANALOG NUMBERING
  1782. #endif
  1783. #define TEMP_2_PIN -1 // ANALOG NUMBERING
  1784. #define HEATER_BED_PIN 10 // BED
  1785. #if TEMP_SENSOR_BED == -1
  1786. #define TEMP_BED_PIN 8 // ANALOG NUMBERING
  1787. #else
  1788. #define TEMP_BED_PIN 14 // ANALOG NUMBERING
  1789. #endif
  1790. #define BEEPER 64
  1791. #define LCD_PINS_RS 14
  1792. #define LCD_PINS_ENABLE 15
  1793. #define LCD_PINS_D4 30
  1794. #define LCD_PINS_D5 31
  1795. #define LCD_PINS_D6 32
  1796. #define LCD_PINS_D7 33
  1797. //buttons are directly attached using keypad
  1798. #define BTN_EN1 61
  1799. #define BTN_EN2 59
  1800. #define BTN_ENC 43 //the click
  1801. #define BLEN_C 2
  1802. #define BLEN_B 1
  1803. #define BLEN_A 0
  1804. #define SDCARDDETECT -1 // Megatronics does not use this port
  1805. //encoder rotation values
  1806. #define encrot0 0
  1807. #define encrot1 2
  1808. #define encrot2 3
  1809. #define encrot3 1
  1810. #endif
  1811. /****************************************************************************************
  1812. * Minitronics v1.0
  1813. *
  1814. ****************************************************************************************/
  1815. #if MOTHERBOARD == 702
  1816. #define KNOWN_BOARD 1
  1817. #ifndef __AVR_ATmega1281__
  1818. #error Oops! Make sure you have 'Minitronics ' selected from the 'Tools -> Boards' menu.
  1819. #endif
  1820. #define LARGE_FLASH true
  1821. #define X_STEP_PIN 48
  1822. #define X_DIR_PIN 47
  1823. #define X_ENABLE_PIN 49
  1824. #define X_MIN_PIN 5
  1825. #define X_MAX_PIN -1 //2 //Max endstops default to disabled "-1", set to commented value to enable.
  1826. #define Y_STEP_PIN 39 // A6
  1827. #define Y_DIR_PIN 40 // A0
  1828. #define Y_ENABLE_PIN 38
  1829. #define Y_MIN_PIN 2
  1830. #define Y_MAX_PIN -1 //15
  1831. #define Z_STEP_PIN 42 // A2
  1832. #define Z_DIR_PIN 43 // A6
  1833. #define Z_ENABLE_PIN 41 // A1
  1834. #define Z_MIN_PIN 6
  1835. #define Z_MAX_PIN -1
  1836. #define E0_STEP_PIN 45
  1837. #define E0_DIR_PIN 44
  1838. #define E0_ENABLE_PIN 27
  1839. #define E1_STEP_PIN 36
  1840. #define E1_DIR_PIN 35
  1841. #define E1_ENABLE_PIN 37
  1842. #define E2_STEP_PIN -1
  1843. #define E2_DIR_PIN -1
  1844. #define E2_ENABLE_PIN -1
  1845. #define SDPOWER -1
  1846. #define SDSS 16
  1847. #define LED_PIN 46
  1848. #define FAN_PIN 9
  1849. #define FAN2_PIN -1
  1850. #define PS_ON_PIN -1
  1851. #define KILL_PIN -1
  1852. #define HEATER_0_PIN 7 // EXTRUDER 1
  1853. #define HEATER_1_PIN 8 // EXTRUDER 2
  1854. #define HEATER_2_PIN -1
  1855. #define TEMP_0_PIN 7 // ANALOG NUMBERING
  1856. #define TEMP_1_PIN 6 // ANALOG NUMBERING
  1857. #define TEMP_2_PIN -1 // ANALOG NUMBERING
  1858. #define HEATER_BED_PIN 3 // BED
  1859. #define TEMP_BED_PIN 6 // ANALOG NUMBERING
  1860. #define BEEPER -1
  1861. #define LCD_PINS_RS -1
  1862. #define LCD_PINS_ENABLE -1
  1863. #define LCD_PINS_D4 -1
  1864. #define LCD_PINS_D5 -1
  1865. #define LCD_PINS_D6 -1
  1866. #define LCD_PINS_D7 -1
  1867. //buttons are directly attached using keypad
  1868. #define BTN_EN1 -1
  1869. #define BTN_EN2 -1
  1870. #define BTN_ENC -1 //the click
  1871. #define BLEN_C 2
  1872. #define BLEN_B 1
  1873. #define BLEN_A 0
  1874. #define SDCARDDETECT -1 // Megatronics does not use this port
  1875. //encoder rotation values
  1876. #define encrot0 0
  1877. #define encrot1 2
  1878. #define encrot2 3
  1879. #define encrot3 1
  1880. #endif
  1881. /****************************************************************************************
  1882. * Cheaptronic v1.0
  1883. *
  1884. ****************************************************************************************/
  1885. #if MOTHERBOARD == 2
  1886. #define KNOWN_BOARD 1
  1887. #ifndef __AVR_ATmega2560__
  1888. #error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
  1889. #endif
  1890. #define LARGE_FLASH true
  1891. //X motor stepper
  1892. #define X_STEP_PIN 14
  1893. #define X_DIR_PIN 15
  1894. #define X_ENABLE_PIN 24
  1895. //X endstop
  1896. #define X_MIN_PIN 3
  1897. #define X_MAX_PIN -1
  1898. //Y motor stepper
  1899. #define Y_STEP_PIN 35
  1900. #define Y_DIR_PIN 36
  1901. #define Y_ENABLE_PIN 31
  1902. //Y endstop
  1903. #define Y_MIN_PIN 2
  1904. #define Y_MAX_PIN -1
  1905. //Z motor stepper
  1906. #define Z_STEP_PIN 40
  1907. #define Z_DIR_PIN 41
  1908. #define Z_ENABLE_PIN 37
  1909. //Z endstop
  1910. #define Z_MIN_PIN 5
  1911. #define Z_MAX_PIN -1
  1912. //Extruder 0 stepper
  1913. #define E0_STEP_PIN 26
  1914. #define E0_DIR_PIN 28
  1915. #define E0_ENABLE_PIN 25
  1916. //Extruder 1 stepper
  1917. #define E1_STEP_PIN 33
  1918. #define E1_DIR_PIN 34
  1919. #define E1_ENABLE_PIN 30
  1920. #define SDPOWER -1
  1921. #define SDSS -1
  1922. #define LED_PIN -1
  1923. //FAN
  1924. #define FAN_PIN -1
  1925. #define PS_ON_PIN -1
  1926. #define KILL_PIN -1
  1927. #define HEATER_0_PIN 19 // EXTRUDER 1
  1928. #define HEATER_1_PIN 23 // EXTRUDER 2
  1929. //HeatedBad
  1930. #define HEATER_BED_PIN 22
  1931. //Cheaptronic v1.0 hasent EXTRUDER 3
  1932. #define HEATER_2_PIN -1
  1933. //Temperature sensors
  1934. #define TEMP_0_PIN 15
  1935. #define TEMP_1_PIN 14
  1936. #define TEMP_2_PIN -1
  1937. #define TEMP_BED_PIN 13
  1938. //Cheaptronic v1.0 dont support LCD
  1939. #define LCD_PINS_RS -1
  1940. #define LCD_PINS_ENABLE -1
  1941. #define LCD_PINS_D4 -1
  1942. #define LCD_PINS_D5 -1
  1943. #define LCD_PINS_D6 -1
  1944. #define LCD_PINS_D7 -1
  1945. //Cheaptronic v1.0 dont support keypad
  1946. #define BTN_EN1 -1
  1947. #define BTN_EN2 -1
  1948. #define BTN_ENC -1
  1949. #define BLEN_C 2
  1950. #define BLEN_B 1
  1951. #define BLEN_A 0
  1952. //Cheaptronic v1.0 does not use this port
  1953. #define SDCARDDETECT -1
  1954. //encoder rotation values
  1955. #define encrot0 0
  1956. #define encrot1 2
  1957. #define encrot2 3
  1958. #define encrot3 1
  1959. #endif
  1960. #ifndef KNOWN_BOARD
  1961. #error Unknown MOTHERBOARD value in configuration.h
  1962. #endif
  1963. //List of pins which to ignore when asked to change by gcode, 0 and 1 are RX and TX, do not mess with those!
  1964. #define _E0_PINS E0_STEP_PIN, E0_DIR_PIN, E0_ENABLE_PIN, HEATER_0_PIN,
  1965. #if EXTRUDERS > 1
  1966. #define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN, HEATER_1_PIN,
  1967. #else
  1968. #define _E1_PINS
  1969. #endif
  1970. #if EXTRUDERS > 2
  1971. #define _E2_PINS E2_STEP_PIN, E2_DIR_PIN, E2_ENABLE_PIN, HEATER_2_PIN,
  1972. #else
  1973. #define _E2_PINS
  1974. #endif
  1975. #ifdef X_STOP_PIN
  1976. #if X_HOME_DIR < 0
  1977. #define X_MIN_PIN X_STOP_PIN
  1978. #define X_MAX_PIN -1
  1979. #else
  1980. #define X_MIN_PIN -1
  1981. #define X_MAX_PIN X_STOP_PIN
  1982. #endif
  1983. #endif
  1984. #ifdef Y_STOP_PIN
  1985. #if Y_HOME_DIR < 0
  1986. #define Y_MIN_PIN Y_STOP_PIN
  1987. #define Y_MAX_PIN -1
  1988. #else
  1989. #define Y_MIN_PIN -1
  1990. #define Y_MAX_PIN Y_STOP_PIN
  1991. #endif
  1992. #endif
  1993. #ifdef Z_STOP_PIN
  1994. #if Z_HOME_DIR < 0
  1995. #define Z_MIN_PIN Z_STOP_PIN
  1996. #define Z_MAX_PIN -1
  1997. #else
  1998. #define Z_MIN_PIN -1
  1999. #define Z_MAX_PIN Z_STOP_PIN
  2000. #endif
  2001. #endif
  2002. #ifdef DISABLE_MAX_ENDSTOPS
  2003. #define X_MAX_PIN -1
  2004. #define Y_MAX_PIN -1
  2005. #define Z_MAX_PIN -1
  2006. #endif
  2007. #ifdef DISABLE_MIN_ENDSTOPS
  2008. #define X_MIN_PIN -1
  2009. #define Y_MIN_PIN -1
  2010. #define Z_MIN_PIN -1
  2011. #endif
  2012. #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, \
  2013. HEATER_BED_PIN, FAN_PIN, \
  2014. _E0_PINS _E1_PINS _E2_PINS \
  2015. analogInputToDigitalPin(TEMP_0_PIN), analogInputToDigitalPin(TEMP_1_PIN), analogInputToDigitalPin(TEMP_2_PIN), analogInputToDigitalPin(TEMP_BED_PIN) }
  2016. #endif