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_TRONXY_V3_1_0.h 9.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2019 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
  4. *
  5. * Based on Sprinter and grbl.
  6. * Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
  7. *
  8. * This program is free software: you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation, either version 3 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  20. *
  21. */
  22. #pragma once
  23. /**
  24. * Arduino Mega for Tronxy X5S-2E, etc.
  25. */
  26. #ifndef __AVR_ATmega2560__
  27. #error "Oops! Select 'Arduino/Genuino Mega or Mega 2560' in 'Tools > Board.'"
  28. #endif
  29. #if HOTENDS > 2 || E_STEPPERS > 2
  30. #error "TRONXY-V3-1.0 supports only 2 hotends/E-steppers. Comment out this line to continue."
  31. #endif
  32. #define BOARD_NAME "TRONXY-V3-1.0"
  33. //
  34. // Servos
  35. //
  36. #define SERVO1_PIN 12 // 2560 PIN 25/PB6
  37. //
  38. // Import RAMPS 1.4 pins
  39. //
  40. #include "pins_RAMPS.h"
  41. /**
  42. * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  43. *
  44. * ===== AUX-1 connector =====
  45. *
  46. * 2 4 6 8
  47. * #----------------#
  48. * #2 | ° ° ° ° |
  49. * #1 | ° ° ° ° |
  50. * NOTCH #------ ------#
  51. * 1 3 5 7
  52. *
  53. * ###################################
  54. * # Pin | ATMEGA2560 Pin | Arduino #
  55. * ###################################
  56. * # 1 | VCC | + #
  57. * # 2 | VCC | + #
  58. * # 3 | GND | - #
  59. * # 4 | GND | - #
  60. * # 5 | N/C | #
  61. * # 6 | 3 / PE1 (TXD0) | D1 #
  62. * # 7 | N/C | #
  63. * # 8 | 2 / PE0 (RXD0) | D0 #
  64. * ###################################
  65. *
  66. * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  67. *
  68. * ===== Limit Switch connectors =====
  69. *
  70. * ############## X+ #################
  71. * X+ # Pin | ATMEGA2560 Pin | Arduino #
  72. * 1 2 3 ###################################
  73. * #- --- -# # 1 | 6 / PE4 (INT4) | D2 #
  74. * | ° ° ° | # 2 | GND | - #
  75. * #-------# # 3 | VCC | + #
  76. * ###################################
  77. *
  78. * ############## X- #################
  79. * X- # Pin | ATMEGA2560 Pin | Arduino #
  80. * 1 2 3 ###################################
  81. * #- --- -# # 1 | 7 / PE5 (INT5) | D3 #
  82. * | ° ° ° | # 2 | GND | - #
  83. * #-------# # 3 | VCC | + #
  84. * ###################################
  85. *
  86. * ############## Y+ #################
  87. * Y+ # Pin | ATMEGA2560 Pin | Arduino #
  88. * 1 2 3 ###################################
  89. * #- --- -# # 1 | 63/PJ0 (PCINT9) | D15 #
  90. * | ° ° ° | # 2 | GND | - #
  91. * #-------# # 3 | VCC | + #
  92. * ###################################
  93. *
  94. * ############## Y- #################
  95. * Y- # Pin | ATMEGA2560 Pin | Arduino #
  96. * 1 2 3 ###################################
  97. * #- --- -# # 1 | 64/PJ1 (PCINT10)| D14 #
  98. * | ° ° ° | # 2 | GND | - #
  99. * #-------# # 3 | VCC | + #
  100. * ###################################
  101. *
  102. * ############## Z+ #################
  103. * Z+ # Pin | ATMEGA2560 Pin | Arduino #
  104. * 1 2 3 ###################################
  105. * #- --- -# # 1 | 45 / PD2 (INT2) | D19 #
  106. * | ° ° ° | # 2 | GND | - #
  107. * #-------# # 3 | VCC | + #
  108. * ###################################
  109. *
  110. * ############## Z- #################
  111. * Z- # Pin | ATMEGA2560 Pin | Arduino #
  112. * 1 2 3 ###################################
  113. * #- --- -# # 1 | 46 / PD3 (INT3) | D18 #
  114. * | ° ° ° | # 2 | GND | - #
  115. * #-------# # 3 | VCC | + #
  116. * ###################################
  117. *
  118. * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  119. *
  120. * ===== EXP1/EXP2 connectors =====
  121. *
  122. * (NOTE ORDER) EXP2 EXP1
  123. * 2 4 6 8 10 2 4 6 8 10
  124. * #-------------------# #-------------------#
  125. * #2 | ° ° ° ° ° | #2 | ° ° ° ° ° |
  126. * #1 | ° ° ° ° ° | #1 | ° ° ° ° ° |
  127. * NOTCH #-------- -------# NOTCH #-------- -------#
  128. * 1 3 5 7 9 1 3 5 7 9
  129. *
  130. * ############# EXP1 ################
  131. * # Pin | ATMEGA2560 Pin | Arduino #
  132. * ###################################
  133. * # 1 | 53 / PC0 | D37 #
  134. * # 2 | 55 / PC2 | D35 #
  135. * # 3 | 12 / PH0 (RXD2) | D17 #
  136. * # 4 | 13 / PH1 (TXD2) | D16 #
  137. * # 5 | 77 / PA1 | D23 #
  138. * # 6 | 75 / PA3 | D25 #
  139. * # 7 | 73 / PA5 | D27 #
  140. * # 8 | 71 / PA7 | D29 #
  141. * # 9 | GND | - #
  142. * # 10 | VCC | + #
  143. * ###################################
  144. *
  145. * ############# EXP2 ################
  146. * # Pin | ATMEGA2560 Pin | Arduino #
  147. * ###################################
  148. * # 1 | 22 / PB3 (MISO) | D50 #
  149. * # 2 | 20 / PB1 (SCK) | D52 #
  150. * # 3 | 59 / PC6 | D31 #
  151. * # 4 | N/C | #
  152. * # 5 | 57 / PC4 | D33 #
  153. * # 6 | 21 / PB2 (MOSI) | D51 #
  154. * # 7 | N/C | #
  155. * # 8 | 30 / !RESET | RESET #
  156. * # 9 | GND | - #
  157. * # 10 | 51 / PG0 | D41 #
  158. * ###################################
  159. *
  160. * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  161. *
  162. * ===== ICSP connector =====
  163. *
  164. * 2 4 6
  165. * #---------#
  166. * | ° ° ° |
  167. * | ° ° ° |
  168. * #---------#
  169. * 1 3 5
  170. *
  171. * ##################################
  172. * # Pin | ATMEGA2560 Pin | Arduino #
  173. * ##################################
  174. * # 1 | 22 / PB3 (MISO)| 50 #
  175. * # 2 | VCC | + #
  176. * # 3 | 20 / PB1 (SCK) | 52 #
  177. * # 4 | 21 / PB2 (MOSI)| 51 #
  178. * # 5 | 30 / !RESET | RESET #
  179. * # 6 | GND | - #
  180. * ##################################
  181. *
  182. * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  183. *
  184. * ===== SERVOS connector =====
  185. *
  186. * 2 4 6
  187. * #---------#
  188. * | ° ° ° |
  189. * | ° ° ° |
  190. * #---------#
  191. * 1 3 5
  192. *
  193. * ##################################
  194. * # Pin | ATMEGA2560 Pin | Arduino #
  195. * ##################################
  196. * # 1 | 25 / PB6 (OC1B)| D12 #
  197. * # 2 | 24 / PB5 (OC1A)| D11 #
  198. * # 3 | GND | - #
  199. * # 4 | GND | - #
  200. * # 5 | VCC | + #
  201. * # 6 | VCC | + #
  202. * ##################################
  203. *
  204. * NOTE: Pins 1 and 2 are the ones closest to the "L" and "PWR" LEDs.
  205. *
  206. * NOTE: Check servo wiring before connecting, for example:
  207. * + Airtronics (non-Z) use: Red = +; Black = -; Black & White, White or Orange = signal.
  208. * + Airtronics-Z use: Red = +; Black = -; Blue = signal.
  209. * + Futaba use: Red = +; Black = -; White = signal.
  210. * + Hitec use: Red = +; Black = -; Yellow = signal.
  211. * + JR use: Red = +; Brown = -; Orange = signal.
  212. *
  213. * NOTE: Test your servo limits:
  214. * Due to effects of component tolerances and/or age, the usable range of S-values for individual servos may be less than the settable 0-255 range. For example:
  215. * 1. One servo may have a fully usable range of M280 P0 S0 through M280 P0 S255.
  216. * 2. A different servo (of the same brand and model) may have a usable range of only M280 P0 S0 through M280 P0 S165 after which you experience binding.
  217. *
  218. * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  219. *
  220. * ===== Thermistor connectors =====
  221. *
  222. * (NOTE ORDER) TH2 TH1 TB
  223. * 1 2 1 2 1 2
  224. * #- -# #- -# #- -#
  225. * | ° ° | | ° ° | | ° ° |
  226. * #-----# #-----# #-----#
  227. *
  228. * ############## TB #################
  229. * # Pin | ATMEGA2560 Pin | Arduino #
  230. * ###################################
  231. * # 1 | GND | - #
  232. * # 2 | 83 / PK6 (ADC14)| A14 #
  233. * ###################################
  234. *
  235. * ############## TH1 ################
  236. * # Pin | ATMEGA2560 Pin | Arduino #
  237. * ###################################
  238. * # 1 | GND | - #
  239. * # 2 | 84 / PK5 (ADC13)| A13 #
  240. * ###################################
  241. *
  242. * ############## TH2 ################
  243. * # Pin | ATMEGA2560 Pin | Arduino #
  244. * ###################################
  245. * # 1 | GND | - #
  246. * # 2 | 82 / PK7 (ADC15)| A15 #
  247. * ###################################
  248. *
  249. * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  250. *
  251. * ===== XS3 connector =====
  252. *
  253. * 2 4 6
  254. * #---------#
  255. * | ° ° ° |
  256. * | ° ° ° |
  257. * #---------#
  258. * 1 3 5
  259. *
  260. * ##################################
  261. * # Pin | ATMEGA2560 Pin | Arduino #
  262. * ##################################
  263. * # 1 | 85 / ADC12 | A12 #
  264. * # 2 | 86 / ADC11 | A11 #
  265. * # 3 | GND | - #
  266. * # 4 | GND | - #
  267. * # 5 | VCC | + #
  268. * # 6 | VCC | + #
  269. * ##################################
  270. *
  271. * NOTE: Pins 1 and 2 are the ones closest to the "L" and "PWR" LEDs.
  272. *
  273. * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  274. */