Ver código fonte

✨ Eryone Ery32 mini (STM32F103VET6) board (#22956)

Augusto Zanellato 3 anos atrás
pai
commit
a6a838084d
Nenhuma conta vinculada ao e-mail do autor do commit

+ 1
- 0
Marlin/src/core/boards.h Ver arquivo

@@ -355,6 +355,7 @@
355 355
 #define BOARD_ZONESTAR_ZM3E2          4055  // Zonestar ZM3E2    (STM32F103RCT6)
356 356
 #define BOARD_ZONESTAR_ZM3E4          4056  // Zonestar ZM3E4 V1 (STM32F103VCT6)
357 357
 #define BOARD_ZONESTAR_ZM3E4V2        4057  // Zonestar ZM3E4 V2 (STM32F103VCT6)
358
+#define BOARD_ERYONE_ERY32_MINI       4058  // Eryone Ery32 mini (STM32F103VET6)
358 359
 
359 360
 //
360 361
 // ARM Cortex-M4F

+ 2
- 0
Marlin/src/pins/pins.h Ver arquivo

@@ -579,6 +579,8 @@
579 579
   #include "stm32f1/pins_ZM3E4_V1_0.h"          // STM32F1                                env:STM32F103VC_ZM3E4_USB env:STM32F103VC_ZM3E4_USB_maple
580 580
 #elif MB(ZONESTAR_ZM3E4V2)
581 581
   #include "stm32f1/pins_ZM3E4_V2_0.h"          // STM32F1                                env:STM32F103VE_ZM3E4V2_USB env:STM32F103VE_ZM3E4V2_USB_maple
582
+#elif MB(ERYONE_ERY32_MINI)
583
+  #include "stm32f1/pins_ERYONE_ERY32_MINI.h"   // STM32F103VET6                          env:ERYONE_ERY32_MINI_maple
582 584
 
583 585
 //
584 586
 // ARM Cortex-M4F

+ 195
- 0
Marlin/src/pins/stm32f1/pins_ERYONE_ERY32_MINI.h Ver arquivo

@@ -0,0 +1,195 @@
1
+/**
2
+ * Marlin 3D Printer Firmware
3
+ * Copyright (c) 2021 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 <https://www.gnu.org/licenses/>.
20
+ *
21
+ */
22
+#pragma once
23
+
24
+/**
25
+ * Eryone Ery32 mini (STM32F103VET6) board pin assignments
26
+ */
27
+
28
+#include "env_validate.h"
29
+
30
+#if HOTENDS > 2 || E_STEPPERS > 2
31
+  #error "Eryone Ery32 mini supports up to 2 hotends / E-steppers. Comment out this line to continue."
32
+#endif
33
+
34
+#ifndef BOARD_INFO_NAME
35
+  #define BOARD_INFO_NAME "ERYONE Ery32 mini"
36
+#endif
37
+
38
+//#define DISABLE_DEBUG
39
+#define DISABLE_JTAG
40
+//#define ENABLE_SPI3
41
+#define FLASH_EEPROM_EMULATION
42
+#define FAN_SOFT_PWM
43
+
44
+#if ENABLED(FLASH_EEPROM_EMULATION)
45
+  #define EEPROM_PAGE_SIZE     (0x800U)           // 2KB
46
+  #define EEPROM_START_ADDRESS (0x8000000UL + (STM32_FLASH_SIZE) * 1024UL - (EEPROM_PAGE_SIZE) * 2UL)
47
+  #define MARLIN_EEPROM_SIZE (EEPROM_PAGE_SIZE)
48
+#endif
49
+
50
+//
51
+// Servos
52
+//
53
+#define SERVO0_PIN                          PA12
54
+
55
+//
56
+// Limit Switches
57
+// 
58
+#define X_STOP_PIN                          PD8
59
+#define Y_STOP_PIN                          PD15
60
+#define Z_MIN_PIN                           PA11
61
+//#define Z_MAX_PIN                         PB1
62
+
63
+//
64
+// Steppers
65
+//
66
+#define X_STEP_PIN                          PB15
67
+#define X_DIR_PIN                           PB14
68
+#define X_ENABLE_PIN                        PD10
69
+
70
+#define Y_STEP_PIN                          PD14
71
+#define Y_DIR_PIN                           PD13
72
+#define Y_ENABLE_PIN                        PC6
73
+
74
+#define Z_STEP_PIN                          PC8
75
+#define Z_DIR_PIN                           PC7
76
+#define Z_ENABLE_PIN                        PA8
77
+
78
+#define E0_STEP_PIN                         PE13
79
+#define E0_DIR_PIN                          PE14
80
+#define E0_ENABLE_PIN                       PB13
81
+
82
+//#define E1_STEP_PIN                       PD13
83
+//#define E1_DIR_PIN                        PD12
84
+//#define E1_ENABLE_PIN                     PC6
85
+
86
+//
87
+// Heaters 0,1 / Fans / Bed
88
+//
89
+#define HEATER_0_PIN                        PD11
90
+
91
+#if ENABLED(FET_ORDER_EFB)                        // Hotend, Fan, Bed
92
+  #define HEATER_BED_PIN                    PD12
93
+#elif ENABLED(FET_ORDER_EEF)                      // Hotend, Hotend, Fan
94
+  #define HEATER_1_PIN                      PD4
95
+#elif ENABLED(FET_ORDER_EEB)                      // Hotend, Hotend, Bed
96
+  #define HEATER_1_PIN                      PD4
97
+  #define HEATER_BED_PIN                    PD12
98
+#elif ENABLED(FET_ORDER_EFF)                      // Hotend, Fan, Fan
99
+  #define FAN1_PIN                          PD12
100
+#elif DISABLED(FET_ORDER_SF)                      // Not Spindle, Fan (i.e., "EFBF" or "EFBE")
101
+  #define HEATER_BED_PIN                    PD12
102
+  #if EITHER(HAS_MULTI_HOTEND, HEATERS_PARALLEL)
103
+    #define HEATER_1_PIN                    PB9
104
+  #else
105
+    #define FAN1_PIN                        PB9
106
+  #endif
107
+#endif
108
+
109
+#ifndef FAN_PIN
110
+  #if EITHER(FET_ORDER_EFB, FET_ORDER_EFF)        // Hotend, Fan, Bed or Hotend, Fan, Fan
111
+    #define FAN_PIN                         PB5
112
+  #elif EITHER(FET_ORDER_EEF, FET_ORDER_SF)       // Hotend, Hotend, Fan or Spindle, Fan
113
+    #define FAN_PIN                         PD12
114
+  #elif ENABLED(FET_ORDER_EEB)                    // Hotend, Hotend, Bed
115
+    #define FAN_PIN                         -1    // IO pin. Buffer needed
116
+  #else                                           // Non-specific are "EFB" (i.e., "EFBF" or "EFBE")
117
+    #define FAN_PIN                         PB5
118
+  #endif
119
+#endif
120
+
121
+//
122
+// Misc. Functions
123
+//
124
+//#define PS_ON_PIN                         PB9
125
+
126
+#if HAS_TMC_UART
127
+  /**
128
+   * TMC2208/TMC2209 stepper drivers
129
+   *
130
+   * Hardware serial communication ports.
131
+   * If undefined software serial is used according to the pins below
132
+   */
133
+  #define X_HARDWARE_SERIAL  MSerial4
134
+  #define Y_HARDWARE_SERIAL  MSerial4
135
+  #define Z_HARDWARE_SERIAL  MSerial4
136
+  #define E0_HARDWARE_SERIAL MSerial4
137
+  #ifndef X_SLAVE_ADDRESS
138
+    #define X_SLAVE_ADDRESS                    2
139
+  #endif
140
+  #ifndef Y_SLAVE_ADDRESS
141
+    #define Y_SLAVE_ADDRESS                    3
142
+  #endif
143
+  #ifndef Z_SLAVE_ADDRESS
144
+    #define Z_SLAVE_ADDRESS                    1
145
+  #endif
146
+  #ifndef E0_SLAVE_ADDRESS
147
+    #define E0_SLAVE_ADDRESS                   0
148
+  #endif
149
+#endif
150
+//
151
+// Temperature Sensors
152
+//
153
+#define TEMP_BED_PIN                        PC2   //TB
154
+#define TEMP_0_PIN                          PC1   //TH1
155
+//#define TEMP_1_PIN                        PC3   //TH2
156
+#define TEMP_BOARD_PIN                      PC3
157
+#ifndef TEMP_SENSOR_BOARD
158
+  #define TEMP_SENSOR_BOARD                   13
159
+#endif
160
+#define FIL_RUNOUT_PIN                      PA10  // MT_DET
161
+
162
+//
163
+// LCD Pins
164
+//
165
+#if HAS_WIRED_LCD
166
+  #define BEEPER_PIN                        PE12
167
+  #define BTN_ENC                           PE11
168
+  #define LCD_PINS_ENABLE                   PE10
169
+  #define LCD_PINS_RS                       PE9
170
+  #define BTN_EN1                           PE4
171
+  #define BTN_EN2                           PE3
172
+  #define LCD_PINS_D4                       PE8
173
+  #define LCD_PINS_D5                       PE7
174
+  #define LCD_PINS_D6                       PB2
175
+  #define LCD_PINS_D7                       PB1
176
+  
177
+  #if ENABLED(REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
178
+    #define BTN_ENC_EN               LCD_PINS_D7  // Detect the presence of the encoder
179
+  #endif
180
+
181
+  #define BOARD_ST7920_DELAY_1                50
182
+  #define BOARD_ST7920_DELAY_2                50
183
+  #define BOARD_ST7920_DELAY_3                50
184
+
185
+#endif // HAS_WIRED_LCD
186
+
187
+//
188
+// SD Card
189
+//
190
+#define ENABLE_SPI1
191
+#define SD_DETECT_PIN                       PA4
192
+#define SCK_PIN                             PA5
193
+#define MISO_PIN                            PA6
194
+#define MOSI_PIN                            PA7
195
+#define SS_PIN                              PC4

+ 14
- 0
buildroot/share/PlatformIO/ldscripts/eryone_ery32_mini.ld Ver arquivo

@@ -0,0 +1,14 @@
1
+MEMORY
2
+{
3
+  ram (rwx) : ORIGIN = 0x20000000, LENGTH =  64K -  4K
4
+  rom (rx)  : ORIGIN = 0x08004000, LENGTH = 512K - 16K
5
+}
6
+
7
+/* Provide memory region aliases for common.inc */
8
+REGION_ALIAS("REGION_TEXT", rom);
9
+REGION_ALIAS("REGION_DATA", ram);
10
+REGION_ALIAS("REGION_BSS", ram);
11
+REGION_ALIAS("REGION_RODATA", rom);
12
+
13
+/* Let common.inc handle the real work. */
14
+INCLUDE common.inc

+ 2
- 2
buildroot/share/PlatformIO/variants/marlin_MEEB_3DP/ld/mem-flash.inc Ver arquivo

@@ -1,5 +1,5 @@
1 1
 MEMORY
2 2
 {
3
-  ram (rwx) : ORIGIN = 0x20000C00, LENGTH = 61K
4
-  rom (rx)  : ORIGIN = 0x08005000, LENGTH = 492K
3
+  ram (rwx) : ORIGIN = 0x20000C00, LENGTH = 64K - 3K
4
+  rom (rx)  : ORIGIN = 0x08005000, LENGTH = 512K - 20K
5 5
 }

+ 19
- 0
ini/stm32f1-maple.ini Ver arquivo

@@ -400,3 +400,22 @@ board                = genericSTM32F103VE
400 400
 board_build.ldscript = ZONESTAR_ZM3E_512K.ld
401 401
 build_flags          = ${ZONESTAR_ZM3E_maple.build_flags} -DTONE_TIMER=1 -DTONE_CHANNEL=2
402 402
 board_upload.maximum_size = 499712
403
+
404
+#
405
+# ERYONE ERY32 Mini (STM32F103VET6)
406
+#
407
+[env:ERYONE_ERY32_MINI_maple]
408
+platform             = ${common_stm32f1.platform}
409
+extends              = common_stm32f1
410
+board                = genericSTM32F103VE
411
+build_flags          = ${common_stm32f1.build_flags}
412
+  -ffunction-sections -fdata-sections -nostdlib -MMD
413
+  -DMCU_STM32F103VE -DARDUINO_GENERIC_STM32F103V -DARDUINO_ARCH_STM32F1 -O0
414
+  -DDEBUG_LEVEL=DEBUG_NONE -DCONFIG_MAPLE_MINI_NO_DISABLE_DEBUG=1
415
+  -DSS_TIMER=4
416
+board_build.variant  = MARLIN_F103Vx
417
+board_build.ldscript = eryone_ery32_mini.ld
418
+board_build.address  = 0x08004000
419
+build_unflags        = ${common_stm32f1.build_unflags}
420
+extra_scripts        = ${common_stm32f1.extra_scripts}
421
+  buildroot/share/PlatformIO/scripts/custom_board.py

Carregando…
Cancelar
Salvar