Bläddra i källkod

Malyan M200 fix E0_AUTO_FAN_PIN (#9580)

Fixes #8794
Scott Lahteine 7 år sedan
förälder
incheckning
3e384b60ce
Inget konto är kopplat till bidragsgivarens mejladress

+ 9
- 0
Marlin/src/config/examples/Malyan/M200/Configuration.h Visa fil

107
 #define SERIAL_PORT 0
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
  * This setting determines the communication speed of the printer.
119
  * This setting determines the communication speed of the printer.
111
  *
120
  *
112
  * 250000 works in most cases, but you might try a lower speed if
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 Visa fil

214
  * Multiple extruders can be assigned to the same pin in which case
214
  * Multiple extruders can be assigned to the same pin in which case
215
  * the fan will turn on when any selected extruder is above the threshold.
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
 #define E1_AUTO_FAN_PIN -1
218
 #define E1_AUTO_FAN_PIN -1
219
 #define E2_AUTO_FAN_PIN -1
219
 #define E2_AUTO_FAN_PIN -1
220
 #define E3_AUTO_FAN_PIN -1
220
 #define E3_AUTO_FAN_PIN -1

+ 30
- 10
Marlin/src/pins/pins.h Visa fil

550
 //
550
 //
551
 // Assign auto fan pins if needed
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
 #endif
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
 #endif
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
 #endif
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
 #endif
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
 #endif
587
 #endif
568
 
588
 
569
 // List of pins which to ignore when asked to change by gcode, 0 and 1 are RX and TX, do not mess with those!
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 Visa fil

79
 // This board has only the controller fan and the extruder fan
79
 // This board has only the controller fan and the extruder fan
80
 // If someone hacks to put a direct power fan on the controller, PB3 could
80
 // If someone hacks to put a direct power fan on the controller, PB3 could
81
 // be used as a separate print cooling fan.
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
 #define FAN1_PIN           PB3 // FAN2 header on board - CONTROLLER FAN
87
 #define FAN1_PIN           PB3 // FAN2 header on board - CONTROLLER FAN
86
 #define FAN2_PIN           -1 // FAN3 header on board - EXTRUDER0 FAN
88
 #define FAN2_PIN           -1 // FAN3 header on board - EXTRUDER0 FAN

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

1
-/*
1
+/**
2
  * Marlin 3D Printer Firmware
2
  * Marlin 3D Printer Firmware
3
  * Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
3
  * Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
4
  *
4
  *
60
 
60
 
61
 #define HEATER_0_PIN        7
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
 #define CONTROLLER_FAN_PIN  2
64
 #define CONTROLLER_FAN_PIN  2
65
 
65
 
66
 #define TEMP_0_PIN          7   // Analog Input
66
 #define TEMP_0_PIN          7   // Analog Input

+ 3
- 15
Marlin/src/pins/pins_THE_BORG.h Visa fil

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

Laddar…
Avbryt
Spara