浏览代码

Malyan M200 fix E0_AUTO_FAN_PIN (#9580)

Fixes #8794
Scott Lahteine 7 年前
父节点
当前提交
3e384b60ce
没有帐户链接到提交者的电子邮件

+ 9
- 0
Marlin/src/config/examples/Malyan/M200/Configuration.h 查看文件

@@ -107,6 +107,15 @@
107 107
 #define SERIAL_PORT 0
108 108
 
109 109
 /**
110
+ * Select a secondary serial port on the board to use for communication with the host.
111
+ * This allows the connection of wireless adapters (for instance) to non-default port pins.
112
+ * Serial port -1 is the USB emulated serial port, if avaialble.
113
+ *
114
+ * :[-1, 0, 1, 2, 3, 4, 5, 6, 7]
115
+ */
116
+#define SERIAL_PORT_2 -1
117
+
118
+/**
110 119
  * This setting determines the communication speed of the printer.
111 120
  *
112 121
  * 250000 works in most cases, but you might try a lower speed if

+ 1
- 1
Marlin/src/config/examples/Malyan/M200/Configuration_adv.h 查看文件

@@ -214,7 +214,7 @@
214 214
  * Multiple extruders can be assigned to the same pin in which case
215 215
  * the fan will turn on when any selected extruder is above the threshold.
216 216
  */
217
-#define E0_AUTO_FAN_PIN PB8
217
+//#define E0_AUTO_FAN_PIN -1
218 218
 #define E1_AUTO_FAN_PIN -1
219 219
 #define E2_AUTO_FAN_PIN -1
220 220
 #define E3_AUTO_FAN_PIN -1

+ 30
- 10
Marlin/src/pins/pins.h 查看文件

@@ -550,20 +550,40 @@
550 550
 //
551 551
 // Assign auto fan pins if needed
552 552
 //
553
-#if !defined(E0_AUTO_FAN_PIN) && defined(ORIG_E0_AUTO_FAN_PIN)
554
-  #define E0_AUTO_FAN_PIN ORIG_E0_AUTO_FAN_PIN
553
+#ifndef E0_AUTO_FAN_PIN
554
+  #ifdef ORIG_E0_AUTO_FAN_PIN
555
+    #define E0_AUTO_FAN_PIN ORIG_E0_AUTO_FAN_PIN
556
+  #else
557
+    #define E0_AUTO_FAN_PIN -1
558
+  #endif
555 559
 #endif
556
-#if !defined(E1_AUTO_FAN_PIN) && defined(ORIG_E1_AUTO_FAN_PIN)
557
-  #define E1_AUTO_FAN_PIN ORIG_E1_AUTO_FAN_PIN
560
+#ifndef E1_AUTO_FAN_PIN
561
+  #ifdef ORIG_E1_AUTO_FAN_PIN
562
+    #define E1_AUTO_FAN_PIN ORIG_E1_AUTO_FAN_PIN
563
+  #else
564
+    #define E1_AUTO_FAN_PIN -1
565
+  #endif
558 566
 #endif
559
-#if !defined(E2_AUTO_FAN_PIN) && defined(ORIG_E2_AUTO_FAN_PIN)
560
-  #define E2_AUTO_FAN_PIN ORIG_E2_AUTO_FAN_PIN
567
+#ifndef E2_AUTO_FAN_PIN
568
+  #ifdef ORIG_E2_AUTO_FAN_PIN
569
+    #define E2_AUTO_FAN_PIN ORIG_E2_AUTO_FAN_PIN
570
+  #else
571
+    #define E2_AUTO_FAN_PIN -1
572
+  #endif
561 573
 #endif
562
-#if !defined(E3_AUTO_FAN_PIN) && defined(ORIG_E3_AUTO_FAN_PIN)
563
-  #define E3_AUTO_FAN_PIN ORIG_E3_AUTO_FAN_PIN
574
+#ifndef E3_AUTO_FAN_PIN
575
+  #ifdef ORIG_E3_AUTO_FAN_PIN
576
+    #define E3_AUTO_FAN_PIN ORIG_E3_AUTO_FAN_PIN
577
+  #else
578
+    #define E3_AUTO_FAN_PIN -1
579
+  #endif
564 580
 #endif
565
-#if !defined(E4_AUTO_FAN_PIN) && defined(ORIG_E4_AUTO_FAN_PIN)
566
-  #define E4_AUTO_FAN_PIN ORIG_E4_AUTO_FAN_PIN
581
+#ifndef E4_AUTO_FAN_PIN
582
+  #ifdef ORIG_E4_AUTO_FAN_PIN
583
+    #define E4_AUTO_FAN_PIN ORIG_E4_AUTO_FAN_PIN
584
+  #else
585
+    #define E4_AUTO_FAN_PIN -1
586
+  #endif
567 587
 #endif
568 588
 
569 589
 // List of pins which to ignore when asked to change by gcode, 0 and 1 are RX and TX, do not mess with those!

+ 5
- 3
Marlin/src/pins/pins_MALYAN_M200.h 查看文件

@@ -79,8 +79,10 @@
79 79
 // This board has only the controller fan and the extruder fan
80 80
 // If someone hacks to put a direct power fan on the controller, PB3 could
81 81
 // be used as a separate print cooling fan.
82
-// FAN_PIN is commented out because in configuration_adv, we have
83
-// it set to E0_AUTO_FAN_PIN
84
-// #define FAN_PIN            PB8 // FAN1 header on board - PRINT FAN
82
+#define ORIG_E0_AUTO_FAN_PIN PB8
83
+
84
+// FAN_PIN is commented out here because the M200 example
85
+// Configuration_adv.h does NOT override E0_AUTO_FAN_PIN.
86
+//#define FAN_PIN            PB8 // FAN1 header on board - PRINT FAN
85 87
 #define FAN1_PIN           PB3 // FAN2 header on board - CONTROLLER FAN
86 88
 #define FAN2_PIN           -1 // FAN3 header on board - EXTRUDER0 FAN

+ 2
- 2
Marlin/src/pins/pins_SILVER_GATE.h 查看文件

@@ -1,4 +1,4 @@
1
-/*
1
+/**
2 2
  * Marlin 3D Printer Firmware
3 3
  * Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
4 4
  *
@@ -60,7 +60,7 @@
60 60
 
61 61
 #define HEATER_0_PIN        7
62 62
 
63
-#define E0_AUTO_FAN_PIN     3
63
+#define ORIG_E0_AUTO_FAN_PIN 3  // Use this by NOT overriding E0_AUTO_FAN_PIN
64 64
 #define CONTROLLER_FAN_PIN  2
65 65
 
66 66
 #define TEMP_0_PIN          7   // Analog Input

+ 3
- 15
Marlin/src/pins/pins_THE_BORG.h 查看文件

@@ -48,7 +48,6 @@
48 48
 
49 49
 #define _STM32_PIN(_PORT,_PIN) ((_PORT * 16) + _PIN)
50 50
 
51
-
52 51
 //
53 52
 // Limit Switches
54 53
 //
@@ -60,6 +59,7 @@
60 59
 #define Z_MAX_PIN          _STM32_PIN(PORTG, 0)
61 60
 #define E_MIN_PIN          _STM32_PIN(PORTE, 2)
62 61
 #define E_MAX_PIN          _STM32_PIN(PORTE, 3)
62
+
63 63
 //
64 64
 // Z Probe (when not Z_MIN_PIN)
65 65
 //
@@ -70,7 +70,6 @@
70 70
 //
71 71
 // Steppers
72 72
 //
73
-
74 73
 #define STEPPER_ENABLE_PIN _STM32_PIN(PORTE, 0)
75 74
 
76 75
 #define X_STEP_PIN         _STM32_PIN(PORTC, 6) //96, 39 in arduino
@@ -106,11 +105,6 @@
106 105
 #define Z2_ENABLE_PIN      _STM32_PIN(PORTC, 15)
107 106
 
108 107
 
109
-
110
-
111
-
112
-
113
-
114 108
 #define SCK_PIN            _STM32_PIN(PORTA, 5)
115 109
 #define MISO_PIN           _STM32_PIN(PORTA, 6)
116 110
 #define MOSI_PIN           _STM32_PIN(PORTA, 7)
@@ -123,9 +117,6 @@
123 117
 #define SPI6_MISO_PIN      _STM32_PIN(PORTG, 12)
124 118
 #define SPI6_MOSI_PIN      _STM32_PIN(PORTG, 14)
125 119
 
126
-
127
-
128
-
129 120
 //
130 121
 // Temperature Sensors
131 122
 //
@@ -139,7 +130,6 @@
139 130
 
140 131
 #define TEMP_5_PIN         _STM32_PIN(PORTE, 12)  // Analog Input, Probe temp
141 132
 
142
-
143 133
 //
144 134
 // Heaters / Fans
145 135
 //
@@ -151,7 +141,7 @@
151 141
 #define FAN1_PIN           _STM32_PIN(PORTA, 0)
152 142
 #define FAN2_PIN           _STM32_PIN(PORTA, 1)
153 143
 
154
-//#define E0_AUTO_FAN_PIN  _STM32_PIN(PORTA, 1)
144
+#define ORIG_E0_AUTO_FAN_PIN  _STM32_PIN(PORTA, 1) // Use this by NOT overriding E0_AUTO_FAN_PIN
155 145
 
156 146
 //
157 147
 // Misc. Functions
@@ -184,14 +174,12 @@
184 174
 #define PWR_LOSS           _STM32_PIN(PORTG, 5)         //Power loss / nAC_FAULT
185 175
 
186 176
 //
187
-//MAX7219_DEBUG
177
+// MAX7219_DEBUG
188 178
 //
189 179
 #define MAX7219_CLK_PIN    _STM32_PIN(PORTG, 10)     //EXP1-1
190 180
 #define MAX7219_DIN_PIN    _STM32_PIN(PORTD, 7)      //EXP1-3
191 181
 #define MAX7219_LOAD_PIN   _STM32_PIN(PORTD, 1)     //EXP1-5
192 182
 
193
-//#define NEOPIXEL_PIN    4
194
-
195 183
 //
196 184
 // LCD / Controller
197 185
 //

正在加载...
取消
保存