Prusa MINI Firmware overview
pins_GT2560_V3.h
Go to the documentation of this file.
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 /**
25  * GT2560 V3.0 pin assignment
26  */
27 
28 #if !defined(__AVR_ATmega1280__) && !defined(__AVR_ATmega2560__)
29  #error "Oops! Select 'Arduino/Genuino Mega or Mega 2560' in 'Tools > Board.'"
30 #endif
31 
32 #ifndef BOARD_INFO_NAME
33  #define BOARD_INFO_NAME "GT2560 V3.0"
34 #endif
35 
36 //
37 // Servos
38 //
39 #define SERVO0_PIN 11 //13 untested 3Dtouch
40 
41 //
42 // Limit Switches
43 //
44 #ifndef X_STOP_PIN
45  #ifndef X_MIN_PIN
46  #define X_MIN_PIN 24
47  #endif
48  #ifndef X_MAX_PIN
49  #define X_MAX_PIN 22
50  #endif
51 #endif
52 #ifndef Y_STOP_PIN
53  #ifndef Y_MIN_PIN
54  #define Y_MIN_PIN 28
55  #endif
56  #ifndef Y_MAX_PIN
57  #define Y_MAX_PIN 26
58  #endif
59 #endif
60 #ifndef Z_STOP_PIN
61  #ifndef Z_MIN_PIN
62  #define Z_MIN_PIN 30
63  #endif
64  #ifndef Z_MAX_PIN
65  #define Z_MAX_PIN 32
66  #endif
67 #endif
68 
69 //
70 // Z Probe (when not Z_MIN_PIN)
71 //
72 #ifndef Z_MIN_PROBE_PIN
73  #define Z_MIN_PROBE_PIN 32
74 #endif
75 
76 //
77 // Runout Sensor
78 //
79 #ifndef FIL_RUNOUT_PIN
80  #define FIL_RUNOUT_PIN 66
81 #endif
82 #ifndef FIL_RUNOUT2_PIN
83  #define FIL_RUNOUT2_PIN 67
84 #endif
85 
86 //
87 // Power Recovery
88 //
89 #define POWER_LOSS_PIN 69 // Pin to detect power loss
90 #define POWER_LOSS_STATE LOW
91 
92 //
93 // Steppers
94 //
95 #define X_STEP_PIN 37
96 #define X_DIR_PIN 39
97 #define X_ENABLE_PIN 35
98 
99 #define Y_STEP_PIN 31
100 #define Y_DIR_PIN 33
101 #define Y_ENABLE_PIN 29
102 
103 #define Z_STEP_PIN 25
104 #define Z_DIR_PIN 23
105 #define Z_ENABLE_PIN 27
106 
107 #define E0_STEP_PIN 46
108 #define E0_DIR_PIN 44
109 #define E0_ENABLE_PIN 12
110 
111 #define E1_STEP_PIN 49
112 #define E1_DIR_PIN 47
113 #define E1_ENABLE_PIN 48
114 
115 //
116 // Temperature Sensors
117 //
118 #define TEMP_0_PIN 11 // Analog Input
119 #define TEMP_1_PIN 9 // Analog Input
120 #define TEMP_2_PIN 1 // Analog Input
121 #define TEMP_BED_PIN 10 // Analog Input
122 
123 //
124 // Heaters / Fans
125 //
126 #define HEATER_0_PIN 10
127 #define HEATER_1_PIN 3
128 #define HEATER_2_PIN 1
129 #define HEATER_BED_PIN 4
130 #define FAN_PIN 9
131 //#define FAN1_PIN 8
132 //#define FAN2_PIN 7
133 
134 //
135 // Misc. Functions
136 //
137 #define SD_DETECT_PIN 38
138 #define SDSS 53
139 #define LED_PIN 6
140 #define PS_ON_PIN 12
141 #define SUICIDE_PIN 54 // This pin must be enabled at boot to keep power flowing
142 
143 #ifndef CASE_LIGHT_PIN
144  #define CASE_LIGHT_PIN 6 // 21
145 #endif
146 
147 //
148 // LCD Controller
149 //
150 #define BEEPER_PIN 18
151 
152 #ifndef LCD_PINS_RS
153  #define LCD_PINS_RS 20
154 #endif
155 #ifndef LCD_PINS_ENABLE
156  #define LCD_PINS_ENABLE 17
157 #endif
158 #ifndef LCD_PINS_D4
159  #define LCD_PINS_D4 16
160 #endif
161 #ifndef LCD_PINS_D5
162  #define LCD_PINS_D5 21
163 #endif
164 #ifndef LCD_PINS_D6
165  #define LCD_PINS_D6 5
166 #endif
167 #ifndef LCD_PINS_D7
168  #define LCD_PINS_D7 36
169 #endif
170 
171 #if ENABLED(NEWPANEL)
172  #ifndef BTN_EN1
173  #define BTN_EN1 42
174  #endif
175  #ifndef BTN_EN2
176  #define BTN_EN2 40
177  #endif
178  #ifndef BTN_ENC
179  #define BTN_ENC 19
180  #endif
181 #endif