Prusa MINI Firmware overview
Main Page
Modules
Classes
Files
File List
File Members
pins_MIGHTYBOARD_REVE.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
* Mightyboard Rev.E pin assignments
26
* also works for Rev D boards. It's all rev E despite what the silk screen says
27
*/
28
29
/**
30
* Rev B 2 JAN 2017
31
*
32
* Added pin definitions for:
33
* M3, M4 & M5 spindle control commands
34
* case light
35
*
36
* Corrected pin assignment for EX2_HEAT_PIN pin. Changed it from 9 to 11. The port
37
* number (B5) agrees with the schematic but B5 is assigned to logical pin 11.
38
*/
39
40
#if !defined(__AVR_ATmega1280__) && !defined(__AVR_ATmega2560__)
41
#error "Oops! Select 'Mega 1280' or 'Mega 2560' in 'Tools > Board.'"
42
#endif
43
44
#define BOARD_INFO_NAME "Mightyboard"
45
#define DEFAULT_MACHINE_NAME "MB Replicator"
46
47
//
48
// Servos
49
//
50
#define SERVO0_PIN 36 // C1 (1280-EX1)
51
#define SERVO1_PIN 37 // C0 (1280-EX2)
52
#define SERVO2_PIN 40 // G1 (1280-EX3)
53
#define SERVO3_PIN 41 // G0 (1280-EX4)
54
55
//
56
// Limit Switches
57
//
58
#define X_MIN_PIN 49 // L0
59
#define X_MAX_PIN 48 // L1
60
#define Y_MIN_PIN 47 // L2
61
#define Y_MAX_PIN 46 // L3
62
#define Z_MIN_PIN 43 // L6
63
#define Z_MAX_PIN 42 // L7
64
65
//
66
// Z Probe (when not Z_MIN_PIN)
67
//
68
#ifndef Z_MIN_PROBE_PIN
69
#define Z_MIN_PROBE_PIN 42
70
#endif
71
72
//
73
// Filament Runout Pins
74
//
75
#ifndef FIL_RUNOUT_PIN
76
#define FIL_RUNOUT_PIN 49
77
#endif
78
#ifndef FIL_RUNOUT2_PIN
79
#define FIL_RUNOUT2_PIN 47
80
#endif
81
82
//
83
// Steppers
84
//
85
#define X_STEP_PIN 55 // F1
86
#define X_DIR_PIN 54 // F0
87
#define X_ENABLE_PIN 56 // F2
88
89
#define Y_STEP_PIN 59 // F5
90
#define Y_DIR_PIN 58 // F4
91
#define Y_ENABLE_PIN 60 // F6
92
93
#define Z_STEP_PIN 63 // K1
94
#define Z_DIR_PIN 62 // K0
95
#define Z_ENABLE_PIN 64 // K2
96
97
#define E0_STEP_PIN 25 // A3
98
#define E0_DIR_PIN 24 // A2
99
#define E0_ENABLE_PIN 26 // A4
100
101
#define E1_STEP_PIN 29 // A7
102
#define E1_DIR_PIN 28 // A6
103
#define E1_ENABLE_PIN 39 // G2
104
105
//
106
// I2C Digipots - MCP4018
107
// Address 5E (2F << 1)
108
// Set from 0 - 127 with stop bit.
109
// (Ex. 3F << 1 | 1)
110
//
111
#define DIGIPOTS_I2C_SCL 76 // J5
112
#define DIGIPOTS_I2C_SDA_X 57 // F3
113
#define DIGIPOTS_I2C_SDA_Y 61 // F7
114
#define DIGIPOTS_I2C_SDA_Z 65 // K3
115
#define DIGIPOTS_I2C_SDA_E0 27 // A5
116
#define DIGIPOTS_I2C_SDA_E1 77 // J6
117
118
#ifndef DIGIPOT_I2C_ADDRESS_A
119
#define DIGIPOT_I2C_ADDRESS_A 0x2F // unshifted slave address (5E <- 2F << 1)
120
#endif
121
122
//
123
// Temperature Sensors
124
//
125
// K7 - 69 / ADC15 - 15
126
#define TEMP_BED_PIN 15
127
128
// SPI for Max6675 or Max31855 Thermocouple
129
// Uses a separate SPI bus
130
//
131
// 3 E5 DO (SO)
132
// 5 E3 CS1
133
// 2 E4 CS2
134
// 78 E2 SCK
135
//
136
#define THERMO_SCK_PIN 78 // E2
137
#define THERMO_DO_PIN 3 // E5
138
#define THERMO_CS1_PIN 5 // E3
139
#define THERMO_CS2_PIN 2 // E4
140
141
#define MAX6675_SS_PIN THERMO_CS1_PIN
142
#define MAX6675_SS2_PIN THERMO_CS2_PIN
143
#define MAX6675_SCK_PIN THERMO_SCK_PIN
144
#define MAX6675_DO_PIN THERMO_DO_PIN
145
146
//
147
// Augmentation for auto-assigning plugs
148
//
149
// Two thermocouple connectors allows for either
150
// 2 extruders or 1 extruder and a heated bed.
151
// With no heated bed, an additional 24V fan is possible.
152
//
153
154
// Labels from the schematic:
155
#define EX1_HEAT_PIN 6 // H3
156
#define EX1_FAN_PIN 7 // H4
157
#define EX2_HEAT_PIN 11 // B5
158
#define EX2_FAN_PIN 12 // B6
159
#define HBP_PIN 45 // L4
160
#define EXTRA_FET_PIN 44 // L5
161
162
#if HOTENDS > 1
163
#if TEMP_SENSOR_BED
164
#define IS_EEB
165
#else
166
#define IS_EEF
167
#endif
168
#elif TEMP_SENSOR_BED
169
#define IS_EFB
170
#else
171
#define IS_EFF
172
#endif
173
174
//
175
// Heaters / Fans (24V)
176
//
177
#define HEATER_0_PIN EX1_HEAT_PIN
178
179
#if ENABLED(IS_EFB) // Hotend, Fan, Bed
180
#define HEATER_BED_PIN HBP_PIN
181
#elif ENABLED(IS_EEF) // Hotend, Hotend, Fan
182
#define HEATER_1_PIN EX2_HEAT_PIN
183
#elif ENABLED(IS_EEB) // Hotend, Hotend, Bed
184
#define HEATER_1_PIN EX2_HEAT_PIN
185
#define HEATER_BED_PIN HBP_PIN
186
#elif ENABLED(IS_EFF) // Hotend, Fan, Fan
187
#define FAN1_PIN HBP_PIN
188
#endif
189
190
#ifndef FAN_PIN
191
#if EITHER(IS_EFB, IS_EFF) // Hotend, Fan, Bed or Hotend, Fan, Fan
192
#define FAN_PIN EX2_HEAT_PIN
193
#elif EITHER(IS_EEF, IS_SF) // Hotend, Hotend, Fan or Spindle, Fan
194
#define FAN_PIN HBP_PIN
195
#else
196
#define FAN_PIN EXTRA_FET_PIN
197
#endif
198
#endif
199
200
//
201
// Misc. Functions
202
//
203
#define LED_PIN 13 // B7
204
#define CUTOFF_RESET_PIN 16 // H1
205
#define CUTOFF_TEST_PIN 17 // H0
206
207
//
208
// LCD / Controller
209
//
210
#if HAS_SPI_LCD
211
212
#if ENABLED(REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
213
214
#define LCD_PINS_RS 33 // C4: LCD-STROBE
215
#define LCD_PINS_ENABLE 72 // J2: LEFT
216
#define LCD_PINS_D4 35 // C2: LCD-CLK
217
#define LCD_PINS_D5 32 // C5: RLED
218
#define LCD_PINS_D6 34 // C3: LCD-DATA
219
#define LCD_PINS_D7 31 // C6: GLED
220
221
#define BTN_EN2 75 // J4, UP
222
#define BTN_EN1 73 // J3, DOWN
223
//STOP button connected as KILL_PIN
224
#define KILL_PIN 14 // J1, RIGHT
225
//KILL - not connected
226
227
#define BEEPER_PIN 8 // H5, SD_WP
228
229
//on board leds
230
#define STAT_LED_RED_LED SERVO0_PIN // C1 (1280-EX1, DEBUG2)
231
#define STAT_LED_BLUE_PIN SERVO1_PIN // C0 (1280-EX2, DEBUG3)
232
233
#else
234
// Replicator uses a 3-wire SR controller with HD44780
235
#define SR_DATA_PIN 34 // C3
236
#define SR_CLK_PIN 35 // C2
237
#define SR_STROBE_PIN 33 // C4
238
239
#define BTN_UP 75 // J4
240
#define BTN_DWN 73 // J3
241
#define BTN_LFT 72 // J2
242
#define BTN_RT 14 // J1
243
244
// Disable encoder
245
#undef BTN_EN1
246
#undef BTN_EN2
247
248
#define BEEPER_PIN 4 // G5
249
250
#define STAT_LED_RED_PIN 32 // C5
251
#define STAT_LED_BLUE_PIN 31 // C6 (Actually green)
252
253
#endif
254
255
#define BTN_CENTER 15 // J0
256
#define BTN_ENC BTN_CENTER
257
258
#endif // HAS_SPI_LCD
259
260
//
261
// SD Card
262
//
263
#define SDSS 53 // B0
264
#define SD_DETECT_PIN 9 // H6
265
266
//
267
//TMC 2208
268
//
269
#if HAS_DRIVER(TMC2208)
270
/**
271
* TMC2208 stepper drivers
272
*
273
* Hardware serial communication ports.
274
* If undefined software serial is used according to the pins below
275
*/
276
#define X_HARDWARE_SERIAL Serial2
277
#define Y_HARDWARE_SERIAL Serial1
278
279
/**
280
* Software serial
281
*/
282
283
#define X_SERIAL_TX_PIN 16
284
#define X_SERIAL_RX_PIN 17
285
286
#define Y_SERIAL_TX_PIN 18
287
#define Y_SERIAL_RX_PIN 19
288
289
#define Z_SERIAL_TX_PIN 41
290
#define Z_SERIAL_RX_PIN 66
291
292
#define E0_SERIAL_TX_PIN 40
293
#define E0_SERIAL_RX_PIN 67
294
295
#define E1_SERIAL_TX_PIN 37
296
#define E1_SERIAL_RX_PIN 68
297
298
#endif
Prusa-Firmware-Buddy-Private1
lib
Marlin
Marlin
src
pins
mega
pins_MIGHTYBOARD_REVE.h
Generated by
1.8.16