Bläddra i källkod

✨ Add ZRIB v53, patch G35 Z drop, related issues (#23636)

Bones 2 år sedan
förälder
incheckning
076d8e83ea
Inget konto är kopplat till bidragsgivarens mejladress

+ 3
- 0
Marlin/Configuration.h Visa fil

@@ -437,6 +437,9 @@
437 437
  *     5 : 100kΩ  ATC Semitec 104GT-2/104NT-4-R025H42G - Used in ParCan, J-Head, and E3D, SliceEngineering 300°C
438 438
  *   501 : 100kΩ  Zonestar - Tronxy X3A
439 439
  *   502 : 100kΩ  Zonestar - used by hot bed in Zonestar Průša P802M
440
+ *   503 : 100kΩ  Zonestar (Z8XM2) Heated Bed thermistor
441
+ *   504 : 100kΩ  Zonestar P802QR2 (Part# QWG-104F-B3950) Hotend Thermistor
442
+ *   505 : 100kΩ  Zonestar P802QR2 (Part# QWG-104F-3950) Bed Thermistor
440 443
  *   512 : 100kΩ  RPW-Ultra hotend
441 444
  *     6 : 100kΩ  EPCOS - Not as accurate as table #1 (created using a fluke thermocouple)
442 445
  *     7 : 100kΩ  Honeywell 135-104LAG-J01

+ 1
- 0
Marlin/src/core/boards.h Visa fil

@@ -115,6 +115,7 @@
115 115
 #define BOARD_RAMPS_S_12_EFFB         1159  // Ramps S 1.2 by Sakul.cz (Power outputs: Hotend, Fan0, Fan1, Bed)
116 116
 #define BOARD_LONGER3D_LK1_PRO        1160  // Longer LK1 PRO / Alfawise U20 Pro (PRO version)
117 117
 #define BOARD_LONGER3D_LKx_PRO        1161  // Longer LKx PRO / Alfawise Uxx Pro (PRO version)
118
+#define BOARD_ZRIB_V53                1162  // Zonestar zrib V5.3 (Chinese RAMPS replica)
118 119
 
119 120
 //
120 121
 // RAMBo and derivatives

+ 3
- 1
Marlin/src/gcode/bedlevel/G35.cpp Visa fil

@@ -106,7 +106,9 @@ void GcodeSuite::G35() {
106 106
     // In BLTOUCH HS mode, the probe travels in a deployed state.
107 107
     // Users of G35 might have a badly misaligned bed, so raise Z by the
108 108
     // length of the deployed pin (BLTOUCH stroke < 7mm)
109
-    do_blocking_move_to_z(Z_CLEARANCE_BETWEEN_PROBES + TERN0(BLTOUCH, bltouch.z_extra_clearance()));
109
+
110
+    // Unsure if this is even required. The probe seems to lift correctly after probe done.
111
+    do_blocking_move_to_z(SUM_TERN(BLTOUCH, Z_CLEARANCE_BETWEEN_PROBES, bltouch.z_extra_clearance()));
110 112
     const float z_probed_height = probe.probe_at_point(tramming_points[i], PROBE_PT_RAISE, 0, true);
111 113
 
112 114
     if (isnan(z_probed_height)) {

+ 2
- 1
Marlin/src/lcd/marlinui.cpp Visa fil

@@ -704,7 +704,8 @@ void MarlinUI::init() {
704 704
     TERN_(HAS_MARLINUI_MENU, refresh());
705 705
 
706 706
     #if HAS_ENCODER_ACTION
707
-      if (clear_buttons) buttons = 0;
707
+      if (clear_buttons)
708
+        TERN_(HAS_ADC_BUTTONS, keypad_buttons =) buttons = 0;
708 709
       next_button_update_ms = millis() + 500;
709 710
     #else
710 711
       UNUSED(clear_buttons);

+ 4
- 0
Marlin/src/lcd/thermistornames.h Visa fil

@@ -70,6 +70,10 @@
70 70
   #define THERMISTOR_NAME "Zonestar (P802M Hot Bed)"
71 71
 #elif THERMISTOR_ID == 503
72 72
   #define THERMISTOR_NAME "Zonestar (Z8XM2 Bed)"
73
+#elif THERMISTOR_ID == 504
74
+  #define THERMISTOR_NAME "Zonestar (P802QR2 Hot End)"
75
+#elif THERMISTOR_ID == 505
76
+  #define THERMISTOR_NAME "Zonestar (P802QR2 Bed)"
73 77
 #elif THERMISTOR_ID == 512
74 78
   #define THERMISTOR_NAME "RPW-Ultra"
75 79
 #elif THERMISTOR_ID == 6

+ 93
- 0
Marlin/src/module/thermistor/thermistor_504.h Visa fil

@@ -0,0 +1,93 @@
1
+/**
2
+ * Marlin 3D Printer Firmware
3
+ * Copyright (C) 2022 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
+// QWG 104F B3950 thermistor
25
+constexpr temp_entry_t temptable_504[] PROGMEM = {
26
+  { OV(  15), 330 },
27
+  { OV(  17), 315 },
28
+  { OV(  19), 300 },
29
+  { OV(  20), 295 },
30
+  { OV(  21), 290 },
31
+  { OV(  23), 285 },
32
+  { OV(  25), 280 },
33
+  { OV(  27), 275 },
34
+  { OV(  28), 270 },
35
+  { OV(  31), 265 },
36
+  { OV(  33), 260 },
37
+  { OV(  35), 255 },
38
+  { OV(  38), 250 },
39
+  { OV(  41), 245 },
40
+  { OV(  44), 240 },
41
+  { OV(  48), 235 },
42
+  { OV(  52), 230 },
43
+  { OV(  56), 225 },
44
+  { OV(  61), 220 },
45
+  { OV(  66), 215 },
46
+  { OV(  78), 210 },
47
+  { OV(  92), 205 },
48
+  { OV( 100), 200 },
49
+  { OV( 109), 195 },
50
+  { OV( 120), 190 },
51
+  { OV( 143), 185 },
52
+  { OV( 148), 180 },
53
+  { OV( 156), 175 },
54
+  { OV( 171), 170 },
55
+  { OV( 187), 165 },
56
+  { OV( 205), 160 },
57
+  { OV( 224), 155 },
58
+  { OV( 268), 150 },
59
+  { OV( 293), 145 },
60
+  { OV( 320), 140 },
61
+  { OV( 348), 135 },
62
+  { OV( 379), 130 },
63
+  { OV( 411), 125 },
64
+  { OV( 445), 120 },
65
+  { OV( 480), 115 },
66
+  { OV( 516), 110 },
67
+  { OV( 553), 105 },
68
+  { OV( 591), 100 },
69
+  { OV( 628),  95 },
70
+  { OV( 665),  90 },
71
+  { OV( 702),  85 },
72
+  { OV( 737),  80 },
73
+  { OV( 770),  75 },
74
+  { OV( 801),  70 },
75
+  { OV( 830),  65 },
76
+  { OV( 857),  60 },
77
+  { OV( 881),  55 },
78
+  { OV( 903),  50 },
79
+  { OV( 922),  45 },
80
+  { OV( 939),  40 },
81
+  { OV( 954),  35 },
82
+  { OV( 966),  30 },
83
+  { OV( 977),  25 },
84
+  { OV( 985),  23 },
85
+  { OV( 993),  20 },
86
+  { OV( 999),  18 },
87
+  { OV(1004),  15 },
88
+  { OV(1008),  12 },
89
+  { OV(1012),   8 },
90
+  { OV(1016),   5 },
91
+  { OV(1020),   0 },
92
+  { OV(1023),  -5 }
93
+};

+ 82
- 0
Marlin/src/module/thermistor/thermistor_505.h Visa fil

@@ -0,0 +1,82 @@
1
+/**
2
+ * Marlin 3D Printer Firmware
3
+ * Copyright (C) 2022 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
+// ZONESTAR hotbed QWG-104F-3950 thermistor
25
+constexpr temp_entry_t temptable_505[] PROGMEM = {
26
+  { OV(   1), 938 },
27
+  { OV(   8), 320 },
28
+  { OV(  16), 300 },
29
+  { OV(  27), 290 },
30
+  { OV(  36), 272 },
31
+  { OV(  47), 258 },
32
+  { OV(  56), 248 },
33
+  { OV(  68), 245 },
34
+  { OV(  78), 237 },
35
+  { OV(  89), 228 },
36
+  { OV(  99), 221 },
37
+  { OV( 110), 215 },
38
+  { OV( 120), 209 },
39
+  { OV( 131), 204 },
40
+  { OV( 141), 199 },
41
+  { OV( 151), 195 },
42
+  { OV( 161), 190 },
43
+  { OV( 171), 187 },
44
+  { OV( 181), 183 },
45
+  { OV( 201), 179 },
46
+  { OV( 221), 170 },
47
+  { OV( 251), 165 },
48
+  { OV( 261), 160 },
49
+  { OV( 321), 150 },
50
+  { OV( 361), 144 },
51
+  { OV( 401), 140 },
52
+  { OV( 421), 133 },
53
+  { OV( 451), 130 },
54
+  { OV( 551), 120 },
55
+  { OV( 571), 117 },
56
+  { OV( 596), 110 },
57
+  { OV( 626), 105 },
58
+  { OV( 666), 100 },
59
+  { OV( 677),  95 },
60
+  { OV( 697),  90 },
61
+  { OV( 717),  85 },
62
+  { OV( 727),  79 },
63
+  { OV( 750),  72 },
64
+  { OV( 789),  69 },
65
+  { OV( 819),  65 },
66
+  { OV( 861),  57 },
67
+  { OV( 870),  55 },
68
+  { OV( 881),  51 },
69
+  { OV( 911),  45 },
70
+  { OV( 922),  39 },
71
+  { OV( 968),  28 },
72
+  { OV( 977),  25 },
73
+  { OV( 985),  23 },
74
+  { OV( 993),  20 },
75
+  { OV( 999),  18 },
76
+  { OV(1004),  15 },
77
+  { OV(1008),  12 },
78
+  { OV(1012),   8 },
79
+  { OV(1016),   5 },
80
+  { OV(1020),   0 },
81
+  { OV(1023),  -5 }
82
+};

+ 6
- 0
Marlin/src/module/thermistor/thermistors.h Visa fil

@@ -78,6 +78,12 @@ typedef struct { int16_t value; celsius_t celsius; } temp_entry_t;
78 78
 #if ANY_THERMISTOR_IS(503) // Zonestar (Z8XM2) Heated Bed thermistor
79 79
   #include "thermistor_503.h"
80 80
 #endif
81
+#if ANY_THERMISTOR_IS(504) // Zonestar (P802QR2 Hot End) thermistors
82
+  #include "thermistor_504.h"
83
+#endif
84
+#if ANY_THERMISTOR_IS(505) // Zonestar (P802QR2 Bed) thermistor
85
+  #include "thermistor_505.h"
86
+#endif
81 87
 #if ANY_THERMISTOR_IS(512) // 100k thermistor in RPW-Ultra hotend, Pull-up = 4.7 kOhm, "unknown model"
82 88
   #include "thermistor_512.h"
83 89
 #endif

+ 2
- 0
Marlin/src/pins/pins.h Visa fil

@@ -123,6 +123,8 @@
123 123
   #include "ramps/pins_ZRIB_V20.h"              // ATmega2560, ATmega1280                 env:mega2560 env:mega1280
124 124
 #elif MB(ZRIB_V52)
125 125
   #include "ramps/pins_ZRIB_V52.h"              // ATmega2560, ATmega1280                 env:mega2560 env:mega1280
126
+#elif MB(ZRIB_V53)
127
+  #include "ramps/pins_ZRIB_V53.h"              // ATmega2560, ATmega1280                 env:mega2560 env:mega1280
126 128
 #elif MB(FELIX2)
127 129
   #include "ramps/pins_FELIX2.h"                // ATmega2560, ATmega1280                 env:mega2560 env:mega1280
128 130
 #elif MB(RIGIDBOARD)

+ 108
- 108
Marlin/src/pins/ramps/pins_ZRIB_V52.h Visa fil

@@ -49,111 +49,111 @@
49 49
 
50 50
 #include "pins_MKS_BASE_common.h" // ... RAMPS
51 51
 
52
-/*
53
-  Available connectors on MKS BASE v1.4 (Basically same as ZRIB V5.2)
54
-
55
-   =======
56
-   | GND |
57
-   |-----|   E0
58
-   |  10 |                (10)  PB4 ** Pin23 ** PWM10
59
-   |-----|
60
-   | GND |
61
-   |-----|   E1
62
-   |  7  |                ( 7)  PH4 ** Pin16 ** PWM7
63
-   |-----|
64
-   | GND |
65
-   |-----|   FAN
66
-   |  9  |                ( 9)  PH6 ** Pin18 ** PWM9
67
-   =======
68
-
69
-   =======
70
-   | GND |
71
-   |-----|   Heated Bed
72
-   |  8  |                ( 8)  PH5 ** Pin17 ** PWM8
73
-   =======
74
-
75
-   ==========
76
-   | 12-24V |
77
-   |--------|   Power
78
-   |  GND   |
79
-   ==========
80
-
81
-  XS3 Connector
82
-   =================
83
-   | 65 | GND | 5V |      (65)  PK3 ** Pin86 ** A11
84
-   |----|-----|----|
85
-   | 66 | GND | 5V |      (66)  PK4 ** Pin85 ** A12
86
-   =================
87
-
88
-  Servos Connector
89
-   =================
90
-   | 11 | GND | 5V |      (11)  PB5 ** Pin24 ** PWM11
91
-   |----|-----|----|
92
-   | 12 | GND | 5V |      (12)  PB6 ** Pin25 ** PWM12
93
-   =================
94
-
95
-  ICSP
96
-   =================
97
-   | 5V | 51 | GND |      (51)  PB2 ** Pin21 ** SPI_MOSI
98
-   |----|----|-----|
99
-   | 50 | 52 | RST |      (50)  PB3 ** Pin22 ** SPI_MISO
100
-   =================      (52)  PB1 ** Pin20 ** SPI_SCK
101
-
102
-  XS6/AUX-1 Connector
103
-   ======================
104
-   | 5V | GND | NC | 20 | (20)  PD1 ** Pin44 ** I2C_SDA
105
-   |----|-----|----|----|
106
-   | 50 |  51 | 52 | 21 | (50)  PB3 ** Pin22 ** SPI_MISO
107
-   ====================== (51)  PB2 ** Pin21 ** SPI_MOSI
108
-                          (52)  PB1 ** Pin20 ** SPI_SCK
109
-                          (21)  PD0 ** Pin43 ** I2C_SCL
110
-
111
-  Temperature
112
-   ==================================
113
-   | GND | 69 | GND | 68 | GND | 67 |
114
-   ==================================
115
-                          (69)  PK7 ** Pin82 ** A15
116
-                          (68)  PK6 ** Pin83 ** A14
117
-                          (67)  PK5 ** Pin84 ** A13
118
-
119
-  Limit Switches
120
-   ============
121
-   |  2 | GND | X+        ( 2)  PE4 ** Pin6  ** PWM2
122
-   |----|-----|
123
-   |  3 | GND | X-        ( 3)  PE5 ** Pin7  ** PWM3
124
-   |----|-----|
125
-   | 15 | GND | Y+        (15)  PJ0 ** Pin63 ** USART3_RX
126
-   |----|-----|
127
-   | 14 | GND | Y-        (14)  PJ1 ** Pin64 ** USART3_TX
128
-   |----|-----|
129
-   | 19 | GND | Z+        (19)  PD2 ** Pin45 ** USART1_RX
130
-   |----|-----|
131
-   | 18 | GND | Z-        (18)  PD3 ** Pin46 ** USART1_TX
132
-   ============
133
-
134
-  EXP1
135
-   ============
136
-   |  37 | 35 |           (37)  PC0 ** Pin53 ** D37
137
-   |-----|----|           (35)  PC2 ** Pin55 ** D35
138
-   |  17 | 16 |           (17)  PH0 ** Pin12 ** USART2_RX
139
-   |-----|----|           (16)  PH1 ** Pin13 ** USART2_TX
140
-   |  23 | 25 |           (23)  PA1 ** Pin77 ** D23
141
-   |-----|----|           (25)  PA3 ** Pin75 ** D25
142
-   |  27 | 29 |           (27)  PA5 ** Pin73 ** D27
143
-   |-----|----|           (29)  PA7 ** Pin71 ** D29
144
-   | GND | 5V |
145
-   ============
146
-
147
-  EXP2
148
-   ============
149
-   |  50 | 52 |           (50)  PB3 ** Pin22 ** SPI_MISO
150
-   |-----|----|           (52)  PB1 ** Pin20 ** SPI_SCK
151
-   |  31 | 53 |           (31)  PC6 ** Pin59 ** D31
152
-   |-----|----|           (53)  PB0 ** Pin19 ** SPI_SS
153
-   |  33 | 51 |           (33)  PC4 ** Pin57 ** D33
154
-   |-----|----|           (51)  PB2 ** Pin21 ** SPI_MOSI
155
-   |  49 | 41 |           (49)  PL0 ** Pin35 ** D49
156
-   |-----|----|           (41)  PG0 ** Pin51 ** D41
157
-   | GND | NC |
158
-   ============
159
-*/
52
+/**
53
+ * Available connectors on MKS BASE v1.4 (Basically same as ZRIB V5.2)
54
+ *
55
+ *  =======
56
+ *  | GND |
57
+ *  |-----|   E0
58
+ *  |  10 |                (10)  PB4 ** Pin23 ** PWM10
59
+ *  |-----|
60
+ *  | GND |
61
+ *  |-----|   E1
62
+ *  |  7  |                ( 7)  PH4 ** Pin16 ** PWM7
63
+ *  |-----|
64
+ *  | GND |
65
+ *  |-----|   FAN
66
+ *  |  9  |                ( 9)  PH6 ** Pin18 ** PWM9
67
+ *  =======
68
+ *
69
+ *  =======
70
+ *  | GND |
71
+ *  |-----|   Heated Bed
72
+ *  |  8  |                ( 8)  PH5 ** Pin17 ** PWM8
73
+ *  =======
74
+ *
75
+ *  ==========
76
+ *  | 12-24V |
77
+ *  |--------|   Power
78
+ *  |  GND   |
79
+ *  ==========
80
+ *
81
+ * XS3 Connector
82
+ *  =================
83
+ *  | 65 | GND | 5V |      (65)  PK3 ** Pin86 ** A11
84
+ *  |----|-----|----|
85
+ *  | 66 | GND | 5V |      (66)  PK4 ** Pin85 ** A12
86
+ *  =================
87
+ *
88
+ * Servos Connector
89
+ *  =================
90
+ *  | 11 | GND | 5V |      (11)  PB5 ** Pin24 ** PWM11
91
+ *  |----|-----|----|
92
+ *  | 12 | GND | 5V |      (12)  PB6 ** Pin25 ** PWM12
93
+ *  =================
94
+ *
95
+ * ICSP
96
+ *  =================
97
+ *  | 5V | 51 | GND |      (51)  PB2 ** Pin21 ** SPI_MOSI
98
+ *  |----|----|-----|
99
+ *  | 50 | 52 | RST |      (50)  PB3 ** Pin22 ** SPI_MISO
100
+ *  =================      (52)  PB1 ** Pin20 ** SPI_SCK
101
+ *
102
+ * XS6/AUX-1 Connector
103
+ *  ======================
104
+ *  | 5V | GND | NC | 20 | (20)  PD1 ** Pin44 ** I2C_SDA
105
+ *  |----|-----|----|----|
106
+ *  | 50 |  51 | 52 | 21 | (50)  PB3 ** Pin22 ** SPI_MISO
107
+ *  ====================== (51)  PB2 ** Pin21 ** SPI_MOSI
108
+ *                         (52)  PB1 ** Pin20 ** SPI_SCK
109
+ *                         (21)  PD0 ** Pin43 ** I2C_SCL
110
+ *
111
+ * Temperature
112
+ *  ==================================
113
+ *  | GND | 69 | GND | 68 | GND | 67 |
114
+ *  ==================================
115
+ *                         (69)  PK7 ** Pin82 ** A15
116
+ *                         (68)  PK6 ** Pin83 ** A14
117
+ *                         (67)  PK5 ** Pin84 ** A13
118
+ *
119
+ * Limit Switches
120
+ *  ============
121
+ *  |  2 | GND | X+        ( 2)  PE4 ** Pin6  ** PWM2
122
+ *  |----|-----|
123
+ *  |  3 | GND | X-        ( 3)  PE5 ** Pin7  ** PWM3
124
+ *  |----|-----|
125
+ *  | 15 | GND | Y+        (15)  PJ0 ** Pin63 ** USART3_RX
126
+ *  |----|-----|
127
+ *  | 14 | GND | Y-        (14)  PJ1 ** Pin64 ** USART3_TX
128
+ *  |----|-----|
129
+ *  | 19 | GND | Z+        (19)  PD2 ** Pin45 ** USART1_RX
130
+ *  |----|-----|
131
+ *  | 18 | GND | Z-        (18)  PD3 ** Pin46 ** USART1_TX
132
+ *  ============
133
+ *
134
+ * EXP1
135
+ *  ============
136
+ *  |  37 | 35 |           (37)  PC0 ** Pin53 ** D37
137
+ *  |-----|----|           (35)  PC2 ** Pin55 ** D35
138
+ *  |  17 | 16 |           (17)  PH0 ** Pin12 ** USART2_RX
139
+ *  |-----|----|           (16)  PH1 ** Pin13 ** USART2_TX
140
+ *  |  23 | 25 |           (23)  PA1 ** Pin77 ** D23
141
+ *  |-----|----|           (25)  PA3 ** Pin75 ** D25
142
+ *  |  27 | 29 |           (27)  PA5 ** Pin73 ** D27
143
+ *  |-----|----|           (29)  PA7 ** Pin71 ** D29
144
+ *  | GND | 5V |
145
+ *  ============
146
+ *
147
+ * EXP2
148
+ *  ============
149
+ *  |  50 | 52 |           (50)  PB3 ** Pin22 ** SPI_MISO
150
+ *  |-----|----|           (52)  PB1 ** Pin20 ** SPI_SCK
151
+ *  |  31 | 53 |           (31)  PC6 ** Pin59 ** D31
152
+ *  |-----|----|           (53)  PB0 ** Pin19 ** SPI_SS
153
+ *  |  33 | 51 |           (33)  PC4 ** Pin57 ** D33
154
+ *  |-----|----|           (51)  PB2 ** Pin21 ** SPI_MOSI
155
+ *  |  49 | 41 |           (49)  PL0 ** Pin35 ** D49
156
+ *  |-----|----|           (41)  PG0 ** Pin51 ** D41
157
+ *  | GND | NC |
158
+ *  ============
159
+ */

+ 511
- 0
Marlin/src/pins/ramps/pins_ZRIB_V53.h Visa fil

@@ -0,0 +1,511 @@
1
+/**
2
+ * Marlin 3D Printer Firmware
3
+ * Copyright (c) 2022 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
+ * ZRIB V5.3 Based on MKS BASE v1.4 with A4982 stepper drivers and digital micro-stepping
26
+ */
27
+
28
+#include "env_validate.h"
29
+
30
+#if HOTENDS > 2
31
+  #error "ZRIB V5.3 only supports up to 2 hotends. Comment out this line to continue."
32
+#elif E_STEPPERS > 3
33
+  #error "ZRIB V5.3 only supports up to 3 E-steppers. Comment out this line to continue."
34
+#endif
35
+
36
+#define BOARD_INFO_NAME "ZRIB V5.3"
37
+
38
+//
39
+// PIN 12 Connector
40
+//
41
+#define PIN_12_PIN                            12
42
+
43
+//
44
+// XS1 Connector
45
+//
46
+#define XS1_01_PIN                            42
47
+#define XS1_03_PIN                            43
48
+#define XS1_05_PIN                            44
49
+#define XS1_07_PIN                            45
50
+#define XS1_08_PIN                            47
51
+
52
+//
53
+// XS6 Connector
54
+//
55
+#define XS6_01_PIN                            20
56
+#define XS6_03_PIN                            52
57
+#define XS6_05_PIN                            51
58
+#define XS6_07_PIN                            50
59
+#define XS6_08_PIN                            21
60
+
61
+//
62
+// Servos / XS3 Connector
63
+//
64
+#ifndef SERVO0_PIN
65
+  #define SERVO0_PIN                          11  // Analog Output
66
+#endif
67
+#ifndef SERVO1_PIN
68
+  #define SERVO1_PIN                          12  // Analog Output
69
+#endif
70
+
71
+//
72
+// Limit Switches
73
+//
74
+#ifndef X_STOP_PIN
75
+  #ifndef X_MIN_PIN
76
+    #define X_MIN_PIN                          3
77
+  #endif
78
+  #ifndef X_MAX_PIN
79
+    #define X_MAX_PIN                          2
80
+  #endif
81
+#endif
82
+#ifndef Y_STOP_PIN
83
+  #ifndef Y_MIN_PIN
84
+    #define Y_MIN_PIN                         14
85
+  #endif
86
+  #ifndef Y_MAX_PIN
87
+    #define Y_MAX_PIN                         15
88
+  #endif
89
+#endif
90
+#ifndef Z_STOP_PIN
91
+  #ifndef Z_MIN_PIN
92
+    #define Z_MIN_PIN                         18
93
+  #endif
94
+  #ifndef Z_MAX_PIN
95
+    #define Z_MAX_PIN                         19
96
+  #endif
97
+#endif
98
+
99
+//
100
+// Z Probe (when not Z_MIN_PIN)
101
+//
102
+#ifndef Z_MIN_PROBE_PIN
103
+  #define Z_MIN_PROBE_PIN                     19
104
+#endif
105
+
106
+//
107
+// Steppers
108
+//
109
+#define X_STEP_PIN                            54
110
+#define X_DIR_PIN                             55
111
+#define X_ENABLE_PIN                          38
112
+
113
+#define Y_STEP_PIN                            60
114
+#define Y_DIR_PIN                             61
115
+#define Y_ENABLE_PIN                          56
116
+
117
+#define Z_STEP_PIN                            46
118
+#define Z_DIR_PIN                             48
119
+#define Z_ENABLE_PIN                          62
120
+
121
+#if NUM_Z_STEPPER_DRIVERS == 2
122
+  #define Z2_STEP_PIN                         26  // E0 connector
123
+  #define Z2_DIR_PIN                          28
124
+  #define Z2_ENABLE_PIN                       24
125
+
126
+  #define E0_STEP_PIN                         36  // E1 connector
127
+  #define E0_DIR_PIN                          34
128
+  #define E0_ENABLE_PIN                       30
129
+
130
+  #define E1_STEP_PIN                          4  // E2 connector
131
+  #define E1_DIR_PIN                           5
132
+  #define E1_ENABLE_PIN                       22
133
+#else
134
+  #define E0_STEP_PIN                         26
135
+  #define E0_DIR_PIN                          28
136
+  #define E0_ENABLE_PIN                       24
137
+
138
+  #define E1_STEP_PIN                         36
139
+  #define E1_DIR_PIN                          34
140
+  #define E1_ENABLE_PIN                       30
141
+
142
+  #define E2_STEP_PIN                          4
143
+  #define E2_DIR_PIN                           5
144
+  #define E2_ENABLE_PIN                       22
145
+#endif
146
+
147
+//
148
+// Temperature Sensors
149
+//
150
+#ifndef TEMP_0_PIN
151
+  #define TEMP_0_PIN                          13  // Analog Input
152
+#endif
153
+#ifndef TEMP_1_PIN
154
+  #define TEMP_1_PIN                          15  // Analog Input
155
+#endif
156
+#ifndef TEMP_BED_PIN
157
+  #define TEMP_BED_PIN                        14  // Analog Input
158
+#endif
159
+
160
+//
161
+// Heaters / Fans Connectors
162
+//
163
+
164
+#define HEATER_0_PIN                          10
165
+#define HEATER_1_PIN                           7
166
+#define FAN_PIN                                9
167
+#define HEATER_BED_PIN                         8
168
+#define FAN1_PIN                               6
169
+
170
+//
171
+// Misc. Functions
172
+//
173
+#ifndef SDSS
174
+  #define SDSS                                53
175
+#endif
176
+
177
+#define LED_PIN                               13
178
+
179
+#ifndef FIL_RUNOUT_PIN
180
+  #define FIL_RUNOUT_PIN              XS1_01_PIN
181
+#endif
182
+
183
+#ifndef PS_ON_PIN
184
+  #define PS_ON_PIN                   XS1_03_PIN
185
+#endif
186
+
187
+#if HAS_TMC_UART
188
+  /**
189
+   * TMC2209 stepper drivers
190
+   *
191
+   * Hardware serial communication ports.
192
+   * If undefined software serial is used according to the pins below
193
+   *
194
+   * Serial2 -- AUX-4 Pin 18 (D16 TX2) and AUX-4 Pin 17 (D17 RX2)
195
+   * Serial1 -- Pins D18 and D19 are used for Z-MIN and Z-MAX
196
+   */
197
+  //#define X_HARDWARE_SERIAL Serial1
198
+  //#define X2_HARDWARE_SERIAL Serial1
199
+  //#define Y_HARDWARE_SERIAL Serial1
200
+  //#define Y2_HARDWARE_SERIAL Serial1
201
+  //#define Z_HARDWARE_SERIAL Serial1
202
+  //#define Z2_HARDWARE_SERIAL Serial1
203
+  //#define E0_HARDWARE_SERIAL Serial1
204
+  //#define E1_HARDWARE_SERIAL Serial1
205
+  //#define E2_HARDWARE_SERIAL Serial1
206
+  //#define E3_HARDWARE_SERIAL Serial1
207
+  //#define E4_HARDWARE_SERIAL Serial1
208
+
209
+  #ifndef X_SERIAL_TX_PIN
210
+    #define X_SERIAL_TX_PIN           XS1_08_PIN
211
+  #endif
212
+  #ifndef X_SERIAL_RX_PIN
213
+    #define X_SERIAL_RX_PIN           PIN_12_PIN
214
+  #endif
215
+  #ifndef X2_SERIAL_TX_PIN
216
+    #define X2_SERIAL_TX_PIN                  -1
217
+  #endif
218
+  #ifndef X2_SERIAL_RX_PIN
219
+    #define X2_SERIAL_RX_PIN                  -1
220
+  #endif
221
+
222
+  #ifndef Y_SERIAL_TX_PIN
223
+    #define Y_SERIAL_TX_PIN           XS1_08_PIN
224
+  #endif
225
+  #ifndef Y_SERIAL_RX_PIN
226
+    #define Y_SERIAL_RX_PIN           PIN_12_PIN
227
+  #endif
228
+  #ifndef Y2_SERIAL_TX_PIN
229
+    #define Y2_SERIAL_TX_PIN                  -1
230
+  #endif
231
+  #ifndef Y2_SERIAL_RX_PIN
232
+    #define Y2_SERIAL_RX_PIN                  -1
233
+  #endif
234
+
235
+  #ifndef Z_SERIAL_TX_PIN
236
+    #define Z_SERIAL_TX_PIN           XS1_08_PIN
237
+  #endif
238
+  #ifndef Z_SERIAL_RX_PIN
239
+    #define Z_SERIAL_RX_PIN           PIN_12_PIN
240
+  #endif
241
+  #ifndef Z2_SERIAL_TX_PIN
242
+    #define Z2_SERIAL_TX_PIN          XS1_08_PIN
243
+  #endif
244
+  #ifndef Z2_SERIAL_RX_PIN
245
+    #define Z2_SERIAL_RX_PIN          PIN_12_PIN
246
+  #endif
247
+
248
+  #ifndef E0_SERIAL_TX_PIN
249
+    #define E0_SERIAL_TX_PIN                  -1
250
+  #endif
251
+  #ifndef E0_SERIAL_RX_PIN
252
+    #define E0_SERIAL_RX_PIN                  -1
253
+  #endif
254
+  #ifndef E1_SERIAL_TX_PIN
255
+    #define E1_SERIAL_TX_PIN                  -1
256
+  #endif
257
+  #ifndef E1_SERIAL_RX_PIN
258
+    #define E1_SERIAL_RX_PIN                  -1
259
+  #endif
260
+  #ifndef E2_SERIAL_TX_PIN
261
+    #define E2_SERIAL_TX_PIN                  -1
262
+  #endif
263
+  #ifndef E2_SERIAL_RX_PIN
264
+    #define E2_SERIAL_RX_PIN                  -1
265
+  #endif
266
+  #ifndef E3_SERIAL_TX_PIN
267
+    #define E3_SERIAL_TX_PIN                  -1
268
+  #endif
269
+  #ifndef E3_SERIAL_RX_PIN
270
+    #define E3_SERIAL_RX_PIN                  -1
271
+  #endif
272
+  #ifndef E4_SERIAL_TX_PIN
273
+    #define E4_SERIAL_TX_PIN                  -1
274
+  #endif
275
+  #ifndef E4_SERIAL_RX_PIN
276
+    #define E4_SERIAL_RX_PIN                  -1
277
+  #endif
278
+  #ifndef E5_SERIAL_TX_PIN
279
+    #define E5_SERIAL_TX_PIN                  -1
280
+  #endif
281
+  #ifndef E5_SERIAL_RX_PIN
282
+    #define E5_SERIAL_RX_PIN                  -1
283
+  #endif
284
+  #ifndef E6_SERIAL_TX_PIN
285
+    #define E6_SERIAL_TX_PIN                  -1
286
+  #endif
287
+  #ifndef E6_SERIAL_RX_PIN
288
+    #define E6_SERIAL_RX_PIN                  -1
289
+  #endif
290
+  #ifndef E7_SERIAL_TX_PIN
291
+    #define E7_SERIAL_TX_PIN                  -1
292
+  #endif
293
+  #ifndef E7_SERIAL_RX_PIN
294
+    #define E7_SERIAL_RX_PIN                  -1
295
+  #endif
296
+#endif
297
+
298
+/**
299
+ * LCD adapter. NOTE: These come in two variants. The socket keys can be
300
+ * on either side, and may be backwards on some displays.
301
+ *         ------                     ------
302
+ *    D37 |10  9 | D35    (MISO) D50 |10  9 | D52 (SCK)
303
+ *    D17 | 8  7 | D16           D31 | 8  7 | D53
304
+ *    D23   6  5   D25           D33   6  5   D51 (MOSI)
305
+ *    D27 | 4  3 | D29           D49 | 4  3 | D41
306
+ *    GND | 2  1 | 5V            GND | 2  1 | --
307
+ *         ------                     ------
308
+ *          EXP1                       EXP2
309
+ */
310
+
311
+#ifndef EXP1_03_PIN
312
+  #define EXP1_03_PIN                         29
313
+  #define EXP1_04_PIN                         27
314
+  #define EXP1_05_PIN                         25
315
+  #define EXP1_06_PIN                         23
316
+  #define EXP1_07_PIN                         16
317
+  #define EXP1_08_PIN                         17
318
+  #define EXP1_09_PIN                         35
319
+  #define EXP1_10_PIN                         37
320
+
321
+  #define EXP2_03_PIN                         41
322
+  #define EXP2_04_PIN                         49
323
+  #define EXP2_05_PIN                 XS6_05_PIN
324
+  #define EXP2_06_PIN                         33
325
+  #define EXP2_07_PIN                         53
326
+  #define EXP2_08_PIN                         31
327
+  #define EXP2_09_PIN                 XS6_03_PIN
328
+  #define EXP2_10_PIN                 XS6_07_PIN
329
+#endif
330
+
331
+//////////////////////////
332
+// LCDs and Controllers //
333
+//////////////////////////
334
+
335
+#if ENABLED(ZONESTAR_12864LCD)
336
+  #define LCDSCREEN_NAME "ZONESTAR LCD12864"
337
+  #define LCD_SDSS                            16
338
+  #define LCD_PINS_RS                         16  // ST7920_CS_PIN  LCD_PIN_RS     (PIN4 of LCD module)
339
+  #define LCD_PINS_ENABLE                     23  // ST7920_DAT_PIN LCD_PIN_R/W    (PIN5 of LCD module)
340
+  #define LCD_PINS_D4                         17  // ST7920_CLK_PIN LCD_PIN_ENABLE (PIN6 of LCD module)
341
+  #define BTN_EN2                             25
342
+  #define BTN_EN1                             27
343
+  #define BTN_ENC                             29
344
+  #define BEEPER_PIN                          37
345
+  #define KILL_PIN                            35
346
+#elif ENABLED(REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
347
+  #define LCDSCREEN_NAME "Reprap LCD12864"
348
+  // Use EXP1 & EXP2 connector
349
+  #define LCD_PINS_RS                         16  // ST7920_CS_PIN  LCD_PIN_RS
350
+  #define LCD_PINS_ENABLE                     17  // ST7920_DAT_PIN LCD_PIN_ENABLE
351
+  #define LCD_PINS_D4                         23  // ST7920_CLK_PIN LCD_PIN_R/W
352
+  #define BTN_EN1                             31
353
+  #define BTN_EN2                             33
354
+  #define BTN_ENC                             35
355
+  #define BEEPER_PIN                          37
356
+  #define KILL_PIN                            41
357
+#endif
358
+
359
+//================================================================================
360
+// OLED 128x64
361
+//================================================================================
362
+
363
+#if EITHER(ZONESTAR_12864OLED, ZONESTAR_12864OLED_SSD1306)
364
+  #define LCDSCREEN_NAME "ZONESTAR 12864OLED"
365
+  #define LCD_SDSS                            16
366
+  #define LCD_PINS_RS                         23  // RESET Pull low for 1s to init
367
+  #define LCD_PINS_DC                         17
368
+  #define DOGLCD_CS                           16  // CS
369
+  #define BTN_EN2                             25
370
+  #define BTN_EN1                             27
371
+  #define BTN_ENC                             29
372
+  #define BEEPER_PIN                          -1
373
+  #define KILL_PIN                            -1
374
+  #if EITHER(OLED_HW_IIC, OLED_HW_SPI)
375
+    #error "Oops! You must choose SW SPI for ZRIB V53 board and connect the OLED screen to EXP1 connector."
376
+  #else                                           // SW_SPI
377
+    #define DOGLCD_A0                LCD_PINS_DC
378
+    #define DOGLCD_MOSI                       35  // SDA
379
+    #define DOGLCD_SCK                        37  // SCK
380
+  #endif
381
+#endif // OLED 128x64
382
+
383
+//================================================================================
384
+// LCD 2004 KEYPAD
385
+//================================================================================
386
+
387
+#if ENABLED(ZONESTAR_LCD)
388
+  #define LCDSCREEN_NAME "LCD2004 ADCKEY"
389
+  #define LCD_PINS_RS                EXP1_07_PIN
390
+  #define LCD_PINS_ENABLE            EXP1_08_PIN
391
+  #define LCD_PINS_D4                EXP1_06_PIN
392
+  #define LCD_PINS_D5                EXP1_05_PIN
393
+  #define LCD_PINS_D6                EXP1_04_PIN
394
+  #define LCD_PINS_D7                EXP1_03_PIN
395
+  #define ADC_KEYPAD_PIN                      10  // A10 for ADCKEY
396
+  #define BEEPER_PIN                 EXP1_10_PIN
397
+#endif
398
+
399
+/**
400
+ * ZRIB V5.3 Main Board
401
+ *
402
+ * Available connectors on ZRIB V5.3
403
+ *
404
+ *  =======
405
+ *  | GND |
406
+ *  |-----|   E0
407
+ *  |  10 |                (10)  PB4 ** Pin23 ** PWM10
408
+ *  |-----|
409
+ *  | GND |
410
+ *  |-----|   E1
411
+ *  |  7  |                ( 7)  PH4 ** Pin16 ** PWM7
412
+ *  |-----|
413
+ *  | GND |
414
+ *  |-----|   FAN
415
+ *  |  9  |                ( 9)  PH6 ** Pin18 ** PWM9
416
+ *  =======
417
+ *  =======
418
+ *  | GND |
419
+ *  |-----|   Heated Bed
420
+ *  |  8  |                ( 8)  PH5 ** Pin17 ** PWM8
421
+ *  =======
422
+ *  ==========
423
+ *  | 12-24V |
424
+ *  |--------|   Power
425
+ *  |  GND   |
426
+ *  ==========
427
+ * XS3 Connector
428
+ *  =================
429
+ *  | 65 | GND | 5V |      (65)  PK3 ** Pin86 ** A11
430
+ *  |----|-----|----|
431
+ *  | 66 | GND | 5V |      (66)  PK4 ** Pin85 ** A12
432
+ *  =================
433
+ * XS3/Servos Connector
434
+ *  =================
435
+ *  | 11 | GND | 5V |      (11)  PB5 ** Pin24 ** PWM11
436
+ *  |----|-----|----|
437
+ *  | 12 | GND | 5V |      (12)  PB6 ** Pin25 ** PWM12
438
+ *  =================
439
+ * ICSP
440
+ *  =================
441
+ *  | 5V | 51 | GND |      (51)  PB2 ** Pin21 ** SPI_MOSI
442
+ *  |----|----|-----|
443
+ *  | 50 | 52 | RST |      (50)  PB3 ** Pin22 ** SPI_MISO
444
+ *  =================      (52)  PB1 ** Pin20 ** SPI_SCK
445
+ * XS6 Connector
446
+ *  ======================
447
+ *  | 5V | GND | NC | 20 | (20)  PD1 ** Pin44 ** I2C_SDA
448
+ *  |----|-----|----|----|
449
+ *  | 50 |  51 | 52 | 21 | (50)  PB3 ** Pin22 ** SPI_MISO
450
+ *  ====================== (51)  PB2 ** Pin21 ** SPI_MOSI
451
+ *                         (52)  PB1 ** Pin20 ** SPI_SCK
452
+ *                         (21)  PD0 ** Pin43 ** I2C_SCL
453
+ * XS1 Connector
454
+ *  ======================
455
+ *  | 5V | GND | NC | 47 | (47)  PL2 ** Pin37 ** D47
456
+ *  |----|-----|----|----|
457
+ *  | 42 |  43 | 44 | 45 | (45)  PL4 ** Pin39 ** D45
458
+ *  ====================== (44)  PL5 ** Pin40 ** D44
459
+ *                         (43)  PL6 ** Pin41 ** D43
460
+ *                         (42)  PL7 ** Pin42 ** D42
461
+ * Temperature
462
+ *  ==================================
463
+ *  | GND | 69 | GND | 68 | GND | 67 |
464
+ *  ==================================
465
+ *                         (69)  PK7 ** Pin82 ** A15
466
+ *                         (68)  PK6 ** Pin83 ** A14
467
+ *                         (67)  PK5 ** Pin84 ** A13
468
+ * Limit Switches
469
+ *  ============
470
+ *  |  2 | GND | X+        ( 2)  PE4 ** Pin6  ** PWM2
471
+ *  |----|-----|
472
+ *  |  3 | GND | X-        ( 3)  PE5 ** Pin7  ** PWM3
473
+ *  |----|-----|
474
+ *  | 15 | GND | Y+        (15)  PJ0 ** Pin63 ** USART3_RX
475
+ *  |----|-----|
476
+ *  | 14 | GND | Y-        (14)  PJ1 ** Pin64 ** USART3_TX
477
+ *  |----|-----|
478
+ *  | 19 | GND | Z+        (19)  PD2 ** Pin45 ** USART1_RX
479
+ *  |----|-----|
480
+ *  | 18 | GND | Z-        (18)  PD3 ** Pin46 ** USART1_TX
481
+ *  ============
482
+ * EXP1
483
+ *  ============
484
+ *  |  37 | 35 |           (37)  PC0 ** Pin53 ** D37
485
+ *  |-----|----|           (35)  PC2 ** Pin55 ** D35
486
+ *  |  17 | 16 |           (17)  PH0 ** Pin12 ** USART2_RX
487
+ *  |-----|----|           (16)  PH1 ** Pin13 ** USART2_TX
488
+ *  |  23 | 25 |           (23)  PA1 ** Pin77 ** D23
489
+ *  |-----|----|           (25)  PA3 ** Pin75 ** D25
490
+ *  |  27 | 29 |           (27)  PA5 ** Pin73 ** D27
491
+ *  |-----|----|           (29)  PA7 ** Pin71 ** D29
492
+ *  | GND | 5V |
493
+ *  ============
494
+ * EXP2
495
+ *  ============
496
+ *  |  50 | 52 |           (50)  PB3 ** Pin22 ** SPI_MISO
497
+ *  |-----|----|           (52)  PB1 ** Pin20 ** SPI_SCK
498
+ *  |  31 | 53 |           (31)  PC6 ** Pin59 ** D31
499
+ *  |-----|----|           (53)  PB0 ** Pin19 ** SPI_SS
500
+ *  |  33 | 51 |           (33)  PC4 ** Pin57 ** D33
501
+ *  |-----|----|           (51)  PB2 ** Pin21 ** SPI_MOSI
502
+ *  |  49 | 41 |           (49)  PL0 ** Pin35 ** D49
503
+ *  |-----|----|           (41)  PG0 ** Pin51 ** D41
504
+ *  | GND | NC |
505
+ *  ============
506
+ *
507
+ * PIN 12
508
+ *   ======
509
+ *   | 12 |                (12)  PB6 ** Pin25 ** D12
510
+ *   ======
511
+*/

+ 1
- 1
Marlin/src/pins/stm32f1/pins_CREALITY_V4210.h Visa fil

@@ -1,6 +1,6 @@
1 1
 /**
2 2
  * Marlin 3D Printer Firmware
3
- * Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
3
+ * Copyright (C) 2021 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
4 4
  *
5 5
  * Based on Sprinter and grbl.
6 6
  * Copyright (C) 2011 Camiel Gubbels / Erik van der Zalm

Laddar…
Avbryt
Spara