Prusa MINI Firmware overview
pins_MKS_BASE_14.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  * MKS BASE v1.4
26  */
27 
28 #if HOTENDS > 2 || E_STEPPERS > 2
29  #error "MKS BASE 1.4 only supports up to 2 hotends / E-steppers. Comment out this line to continue."
30 #endif
31 
32 #define BOARD_INFO_NAME "MKS BASE 1.4"
33 
34 //
35 // Heaters / Fans
36 //
37 #define MOSFET_D_PIN 7 // PH4 ** Pin16 ** PWM7 //E1
38 #define FAN_PIN 9 // PH6 ** Pin18 ** PWM9
39 
40 // Other Mods
41 #define CASE_LIGHT_PIN 11 // PB5 ** Pin24 ** PWM11
42 #define SERVO3_PIN 12 // PB6 ** Pin25 ** D12
43 #define PS_ON_PIN 2 // X+ // PE4 ** Pin6 ** PWM2 **MUST BE HARDWARE PWM
44 #define FILWIDTH_PIN 15 // Y+ // PJ0 ** Pin63 ** USART3_RX **Pin should have a pullup!
45 #define FIL_RUNOUT_PIN 19 // Z+ // PD2 ** Pin45 ** USART1_RX
46 
47 //
48 // M3/M4/M5 - Spindle/Laser Control
49 //
50 #define SPINDLE_LASER_PWM_PIN 2 // X+ // PE4 ** Pin6 ** PWM2 **MUST BE HARDWARE PWM
51 #define SPINDLE_LASER_ENA_PIN 15 // Y+ // PJ0 ** Pin63 ** USART3_RX **Pin should have a pullup!
52 #define SPINDLE_DIR_PIN 19 // Z+ // PD2 ** Pin45 ** USART1_RX
53 
54 //
55 // Microstepping pins
56 //
57 #define X_MS1_PIN 5 // PE3 ** Pin5 ** PWM5
58 #define X_MS2_PIN 6 // PH3 ** Pin15 ** PWM6
59 #define Y_MS1_PIN 59 // PF5 ** Pin92 ** A5
60 #define Y_MS2_PIN 58 // PF4 ** Pin93 ** A4
61 #define Z_MS1_PIN 22 // PA0 ** Pin78 ** D22
62 #define Z_MS2_PIN 39 // PG2 ** Pin70 ** D39
63 #define E0_MS1_PIN 64 // PK2 ** Pin87 ** A10
64 #define E0_MS2_PIN 63 // PK1 ** Pin88 ** A9
65 #define E1_MS1_PIN 57 // PF3 ** Pin94 ** A3
66 #define E1_MS2_PIN 4 // PG5 ** Pin1 ** PWM4
67 
68 #ifndef RGB_LED_R_PIN
69  #define RGB_LED_R_PIN 50
70 #endif
71 #ifndef RGB_LED_R_PIN
72  #define RGB_LED_G_PIN 51
73 #endif
74 #ifndef RGB_LED_R_PIN
75  #define RGB_LED_B_PIN 52
76 #endif
77 
78 #include "pins_RAMPS.h"
79 
80 /*
81  Available connectors on MKS BASE v1.4
82 
83  =======
84  | GND |
85  |-----| E0
86  | 10 | (10) PB4 ** Pin23 ** PWM10
87  |-----|
88  | GND |
89  |-----| E1
90  | 7 | ( 7) PH4 ** Pin16 ** PWM7
91  |-----|
92  | GND |
93  |-----| FAN
94  | 9 | ( 9) PH6 ** Pin18 ** PWM9
95  =======
96 
97  =======
98  | GND |
99  |-----| Heated Bed
100  | 8 | ( 8) PH5 ** Pin17 ** PWM8
101  =======
102 
103  ==========
104  | 12-24V |
105  |--------| Power
106  | GND |
107  ==========
108 
109  XS3 Connector
110  =================
111  | 65 | GND | 5V | (65) PK3 ** Pin86 ** A11
112  |----|-----|----|
113  | 66 | GND | 5V | (66) PK4 ** Pin85 ** A12
114  =================
115 
116  Servos Connector
117  =================
118  | 11 | GND | 5V | (11) PB5 ** Pin24 ** PWM11
119  |----|-----|----|
120  | 12 | GND | 5V | (12) PB6 ** Pin25 ** PWM12
121  =================
122 
123  ICSP
124  =================
125  | 5V | 51 | GND | (51) PB2 ** Pin21 ** SPI_MOSI
126  |----|----|-----|
127  | 50 | 52 | RST | (50) PB3 ** Pin22 ** SPI_MISO
128  ================= (52) PB1 ** Pin20 ** SPI_SCK
129 
130  XS6/AUX-1 Connector
131  ======================
132  | 5V | GND | NC | 20 | (20) PD1 ** Pin44 ** I2C_SDA
133  |----|-----|----|----|
134  | 50 | 51 | 52 | 21 | (50) PB3 ** Pin22 ** SPI_MISO
135  ====================== (51) PB2 ** Pin21 ** SPI_MOSI
136  (52) PB1 ** Pin20 ** SPI_SCK
137  (21) PD0 ** Pin43 ** I2C_SCL
138 
139  Temperature
140  ==================================
141  | GND | 69 | GND | 68 | GND | 67 |
142  ==================================
143  (69) PK7 ** Pin82 ** A15
144  (68) PK6 ** Pin83 ** A14
145  (67) PK5 ** Pin84 ** A13
146 
147  Limit Switches
148  ============
149  | 2 | GND | X+ ( 2) PE4 ** Pin6 ** PWM2
150  |----|-----|
151  | 3 | GND | X- ( 3) PE5 ** Pin7 ** PWM3
152  |----|-----|
153  | 15 | GND | Y+ (15) PJ0 ** Pin63 ** USART3_RX
154  |----|-----|
155  | 14 | GND | Y- (14) PJ1 ** Pin64 ** USART3_TX
156  |----|-----|
157  | 19 | GND | Z+ (19) PD2 ** Pin45 ** USART1_RX
158  |----|-----|
159  | 18 | GND | Z- (18) PD3 ** Pin46 ** USART1_TX
160  ============
161 
162  EXP1
163  ============
164  | 37 | 35 | (37) PC0 ** Pin53 ** D37
165  |-----|----| (35) PC2 ** Pin55 ** D35
166  | 17 | 16 | (17) PH0 ** Pin12 ** USART2_RX
167  |-----|----| (16) PH1 ** Pin13 ** USART2_TX
168  | 23 | 25 | (23) PA1 ** Pin77 ** D23
169  |-----|----| (25) PA3 ** Pin75 ** D25
170  | 27 | 29 | (27) PA5 ** Pin73 ** D27
171  |-----|----| (29) PA7 ** Pin71 ** D29
172  | GND | 5V |
173  ============
174 
175  EXP2
176  ============
177  | 50 | 52 | (50) PB3 ** Pin22 ** SPI_MISO
178  |-----|----| (52) PB1 ** Pin20 ** SPI_SCK
179  | 31 | 53 | (31) PC6 ** Pin59 ** D31
180  |-----|----| (53) PB0 ** Pin19 ** SPI_SS
181  | 33 | 51 | (33) PC4 ** Pin57 ** D33
182  |-----|----| (51) PB2 ** Pin21 ** SPI_MOSI
183  | 49 | 41 | (49) PL0 ** Pin35 ** D49
184  |-----|----| (41) PG0 ** Pin51 ** D41
185  | GND | NC |
186  ============
187 */
pins_RAMPS.h