|
@@ -0,0 +1,167 @@
|
|
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
|
+#ifndef TARGET_STM32F1
|
|
25
|
+ #error "Oops! Select an STM32F1 board in 'Tools > Board.'"
|
|
26
|
+#endif
|
|
27
|
+
|
|
28
|
+#define BOARD_INFO_NAME "BIGTREE SKR Mini E3 V1.2"
|
|
29
|
+
|
|
30
|
+// Release PB3/PB4 (E0 STP/DIR) from JTAG pins
|
|
31
|
+#define DISABLE_JTAG
|
|
32
|
+
|
|
33
|
+// Ignore temp readings during development.
|
|
34
|
+//#define BOGUS_TEMPERATURE_GRACE_PERIOD 2000
|
|
35
|
+
|
|
36
|
+#define FLASH_EEPROM_EMULATION
|
|
37
|
+#define EEPROM_PAGE_SIZE uint16(0x800) // 2KB
|
|
38
|
+#define EEPROM_START_ADDRESS uint32(0x8000000 + 256 * 1024 - 2 * EEPROM_PAGE_SIZE)
|
|
39
|
+#undef E2END
|
|
40
|
+#define E2END (EEPROM_PAGE_SIZE - 1) // 2KB
|
|
41
|
+
|
|
42
|
+//
|
|
43
|
+// Servos
|
|
44
|
+//
|
|
45
|
+#define SERVO0_PIN PA1
|
|
46
|
+
|
|
47
|
+//
|
|
48
|
+// Limit Switches
|
|
49
|
+//
|
|
50
|
+#define X_STOP_PIN PC0
|
|
51
|
+#define Y_STOP_PIN PC1
|
|
52
|
+#define Z_STOP_PIN PC2
|
|
53
|
+
|
|
54
|
+//
|
|
55
|
+// Z Probe must be this pins
|
|
56
|
+//
|
|
57
|
+#define Z_MIN_PROBE_PIN PC14
|
|
58
|
+
|
|
59
|
+//
|
|
60
|
+// Filament Runout Sensor
|
|
61
|
+//
|
|
62
|
+#ifndef FIL_RUNOUT_PIN
|
|
63
|
+ #define FIL_RUNOUT_PIN PC12
|
|
64
|
+#endif
|
|
65
|
+
|
|
66
|
+//
|
|
67
|
+// Steppers
|
|
68
|
+//
|
|
69
|
+#define X_ENABLE_PIN PB14
|
|
70
|
+#define X_STEP_PIN PB13
|
|
71
|
+#define X_DIR_PIN PB12
|
|
72
|
+
|
|
73
|
+#define Y_ENABLE_PIN PB11
|
|
74
|
+#define Y_STEP_PIN PB10
|
|
75
|
+#define Y_DIR_PIN PB2
|
|
76
|
+
|
|
77
|
+#define Z_ENABLE_PIN PB1
|
|
78
|
+#define Z_STEP_PIN PB0
|
|
79
|
+#define Z_DIR_PIN PC5
|
|
80
|
+
|
|
81
|
+#define E0_ENABLE_PIN PD2
|
|
82
|
+#define E0_STEP_PIN PB3
|
|
83
|
+#define E0_DIR_PIN PB4
|
|
84
|
+
|
|
85
|
+#if HAS_TMC220x
|
|
86
|
+ /**
|
|
87
|
+ * TMC2208/TMC2209 stepper drivers
|
|
88
|
+ */
|
|
89
|
+ //
|
|
90
|
+ // Software serial
|
|
91
|
+ //
|
|
92
|
+ #define X_SERIAL_TX_PIN PB15
|
|
93
|
+ #define X_SERIAL_RX_PIN PB15
|
|
94
|
+
|
|
95
|
+ #define Y_SERIAL_TX_PIN PC6
|
|
96
|
+ #define Y_SERIAL_RX_PIN PC6
|
|
97
|
+
|
|
98
|
+ #define Z_SERIAL_TX_PIN PC10
|
|
99
|
+ #define Z_SERIAL_RX_PIN PC10
|
|
100
|
+
|
|
101
|
+ #define E0_SERIAL_TX_PIN PC11
|
|
102
|
+ #define E0_SERIAL_RX_PIN PC11
|
|
103
|
+#endif
|
|
104
|
+
|
|
105
|
+//
|
|
106
|
+// Temperature Sensors
|
|
107
|
+//
|
|
108
|
+#define TEMP_0_PIN PA0 // Analog Input
|
|
109
|
+#define TEMP_BED_PIN PC3 // Analog Input
|
|
110
|
+
|
|
111
|
+//
|
|
112
|
+// Heaters / Fans
|
|
113
|
+//
|
|
114
|
+#define HEATER_0_PIN PC8 // EXTRUDER
|
|
115
|
+#define HEATER_BED_PIN PC9 // BED
|
|
116
|
+#define FAN_PIN PA8
|
|
117
|
+
|
|
118
|
+//
|
|
119
|
+// USB connect control
|
|
120
|
+//
|
|
121
|
+#define USB_CONNECT_PIN PC13
|
|
122
|
+#define USB_CONNECT_INVERTING false
|
|
123
|
+
|
|
124
|
+#define NEOPIXEL_PIN PC7 // LED driving pin
|
|
125
|
+
|
|
126
|
+#define SD_DETECT_PIN PC4
|
|
127
|
+
|
|
128
|
+/**
|
|
129
|
+ * _____
|
|
130
|
+ * 5V | · · | GND
|
|
131
|
+ * (LCD_EN) PB7 | · · | PB8 (LCD_RS)
|
|
132
|
+ * (LCD_D4) PB9 | · · | PA10 (BTN_EN2)
|
|
133
|
+ * RESET | · · | PA9 (BTN_EN1)
|
|
134
|
+ * (BTN_ENC) PB6 | · · | PB5 (BEEPER)
|
|
135
|
+ * -----
|
|
136
|
+ * EXP1
|
|
137
|
+ */
|
|
138
|
+#if HAS_SPI_LCD
|
|
139
|
+ #define BEEPER_PIN PB5
|
|
140
|
+ #define BTN_ENC PB6
|
|
141
|
+
|
|
142
|
+ #if ENABLED(CR10_STOCKDISPLAY)
|
|
143
|
+ #define LCD_PINS_RS PB8
|
|
144
|
+
|
|
145
|
+ #define BTN_EN1 PA9
|
|
146
|
+ #define BTN_EN2 PA10
|
|
147
|
+
|
|
148
|
+ #define LCD_PINS_ENABLE PB7
|
|
149
|
+ #define LCD_PINS_D4 PB9
|
|
150
|
+
|
|
151
|
+ #else
|
|
152
|
+ #error "Only CR10_STOCKDISPLAY is currently supported on the BIGTREE_SKR_MINI_E3 V1.2."
|
|
153
|
+ #endif
|
|
154
|
+
|
|
155
|
+#endif // HAS_SPI_LCD
|
|
156
|
+
|
|
157
|
+//
|
|
158
|
+// SD Support
|
|
159
|
+//
|
|
160
|
+#define HAS_ONBOARD_SD
|
|
161
|
+
|
|
162
|
+#ifndef SDCARD_CONNECTION
|
|
163
|
+ #define SDCARD_CONNECTION ONBOARD
|
|
164
|
+#endif
|
|
165
|
+
|
|
166
|
+#define ON_BOARD_SPI_DEVICE 1 //SPI1
|
|
167
|
+#define ONBOARD_SD_CS_PIN PA4 // Chip select for "System" SD card
|