Browse Source

Rename status led pins

Scott Lahteine 8 years ago
parent
commit
fba0b67f7d

+ 6
- 8
Marlin/Marlin_main.cpp View File

@@ -8719,8 +8719,8 @@ void prepare_move_to_destination() {
8719 8719
       bool new_led = (max_temp > 55.0) ? true : (max_temp < 54.0) ? false : red_led;
8720 8720
       if (new_led != red_led) {
8721 8721
         red_led = new_led;
8722
-        digitalWrite(STAT_LED_RED, new_led ? HIGH : LOW);
8723
-        digitalWrite(STAT_LED_BLUE, new_led ? LOW : HIGH);
8722
+        WRITE(STAT_LED_RED_PIN, new_led ? HIGH : LOW);
8723
+        WRITE(STAT_LED_BLUE_PIN, new_led ? LOW : HIGH);
8724 8724
       }
8725 8725
     }
8726 8726
   }
@@ -9200,14 +9200,12 @@ void setup() {
9200 9200
 
9201 9201
   setup_homepin();
9202 9202
 
9203
-  #ifdef STAT_LED_RED
9204
-    pinMode(STAT_LED_RED, OUTPUT);
9205
-    digitalWrite(STAT_LED_RED, LOW); // turn it off
9203
+  #if PIN_EXISTS(STAT_LED_RED)
9204
+    OUT_WRITE(STAT_LED_RED_PIN, LOW); // turn it off
9206 9205
   #endif
9207 9206
 
9208
-  #ifdef STAT_LED_BLUE
9209
-    pinMode(STAT_LED_BLUE, OUTPUT);
9210
-    digitalWrite(STAT_LED_BLUE, LOW); // turn it off
9207
+  #if PIN_EXISTS(STAT_LED_BLUE)
9208
+    OUT_WRITE(STAT_LED_BLUE_PIN, LOW); // turn it off
9211 9209
   #endif
9212 9210
 
9213 9211
   lcd_init();

+ 2
- 4
Marlin/pins_A4JP.h View File

@@ -149,8 +149,6 @@
149 149
 
150 150
   #define SD_DETECT_PIN -1 // Pin 72 if using easy adapter board
151 151
 
152
-  #if ENABLED(TEMP_STAT_LEDS)
153
-    #define STAT_LED_RED      22
154
-    #define STAT_LED_BLUE     32
155
-  #endif
152
+  #define STAT_LED_RED_PIN  22
153
+  #define STAT_LED_BLUE_PIN 32
156 154
 #endif // VIKI2/miniVIKI

+ 6
- 6
Marlin/pins_AZTEEG_X3.h View File

@@ -42,15 +42,15 @@
42 42
   #define BTN_ENC           12
43 43
 
44 44
   #if ENABLED(TEMP_STAT_LEDS)
45
-    #undef STAT_LED_RED
46
-    #undef STAT_LED_BLUE
47
-    #define STAT_LED_RED    64
48
-    #define STAT_LED_BLUE   63
45
+    #undef STAT_LED_RED_PIN
46
+    #undef STAT_LED_BLUE_PIN
47
+    #define STAT_LED_RED_PIN    64
48
+    #define STAT_LED_BLUE_PIN   63
49 49
   #endif
50 50
 
51 51
 #elif ENABLED(TEMP_STAT_LEDS)
52 52
 
53
-  #define STAT_LED_RED       6
54
-  #define STAT_LED_BLUE     11
53
+  #define STAT_LED_RED_PIN       6
54
+  #define STAT_LED_BLUE_PIN     11
55 55
 
56 56
 #endif

+ 2
- 2
Marlin/pins_AZTEEG_X3_PRO.h View File

@@ -117,6 +117,6 @@
117 117
   #undef SD_DETECT_PIN
118 118
   #define SD_DETECT_PIN    49 // For easy adapter board
119 119
 #else
120
-  #define STAT_LED_RED     32
121
-  #define STAT_LED_BLUE    35
120
+  #define STAT_LED_RED_PIN     32
121
+  #define STAT_LED_BLUE_PIN    35
122 122
 #endif

+ 2
- 2
Marlin/pins_CNCONTROLS_11.h View File

@@ -115,5 +115,5 @@
115 115
 //
116 116
 // Misc. Functions
117 117
 //
118
-#define STAT_LED_BLUE      -1
119
-#define STAT_LED_RED       31
118
+#define STAT_LED_BLUE_PIN      -1
119
+#define STAT_LED_RED_PIN       31

+ 2
- 2
Marlin/pins_CNCONTROLS_12.h View File

@@ -111,8 +111,8 @@
111 111
 //#define UI1              43
112 112
 //#define UI2              37
113 113
 
114
-#define STAT_LED_BLUE      -1
115
-#define STAT_LED_RED       10 // TOOL_0_PWM_PIN
114
+#define STAT_LED_BLUE_PIN      -1
115
+#define STAT_LED_RED_PIN       10 // TOOL_0_PWM_PIN
116 116
 
117 117
 //
118 118
 // SD Card

+ 2
- 2
Marlin/pins_MKS_13.h View File

@@ -120,9 +120,9 @@
120 120
   #define BEEPER_PIN      25
121 121
 
122 122
   // yellow               RED-LED
123
-  #define STAT_LED_RED    16
123
+  #define STAT_LED_RED_PIN    16
124 124
 
125 125
   // white                BLUE-LED
126
-  #define STAT_LED_BLUE   17
126
+  #define STAT_LED_BLUE_PIN   17
127 127
 
128 128
 #endif

+ 2
- 2
Marlin/pins_PRINTRBOARD.h View File

@@ -132,7 +132,7 @@
132 132
   #define SDSS 45
133 133
   #define SD_DETECT_PIN -1 // FastIO (Manual says 72 I'm not certain cause I can't test)
134 134
   #if ENABLED(TEMP_STAT_LEDS)
135
-    #define STAT_LED_RED      12 //Non-FastIO
136
-    #define STAT_LED_BLUE     10 //Non-FastIO
135
+    #define STAT_LED_RED_PIN      12 //Non-FastIO
136
+    #define STAT_LED_BLUE_PIN     10 //Non-FastIO
137 137
   #endif
138 138
 #endif

+ 2
- 2
Marlin/pins_PRINTRBOARD_REVF.h View File

@@ -131,7 +131,7 @@
131 131
   #define SD_DETECT_PIN -1 // FastIO (Manual says 72 I'm not certain cause I can't test)
132 132
 
133 133
   #if ENABLED(TEMP_STAT_LEDS)
134
-    #define STAT_LED_RED      12 //Non-FastIO
135
-    #define STAT_LED_BLUE     10 //Non-FastIO
134
+    #define STAT_LED_RED_PIN      12 //Non-FastIO
135
+    #define STAT_LED_BLUE_PIN     10 //Non-FastIO
136 136
   #endif
137 137
 #endif

+ 2
- 2
Marlin/pins_RAMBO.h View File

@@ -170,8 +170,8 @@
170 170
       #define SD_DETECT_PIN -1 // Pin 72 if using easy adapter board
171 171
 
172 172
       #if ENABLED(TEMP_STAT_LEDS)
173
-        #define STAT_LED_RED      22
174
-        #define STAT_LED_BLUE     32
173
+        #define STAT_LED_RED_PIN      22
174
+        #define STAT_LED_BLUE_PIN     32
175 175
       #endif
176 176
 
177 177
     #else

+ 2
- 2
Marlin/pins_RAMPS.h View File

@@ -281,8 +281,8 @@
281 281
       #define KILL_PIN         31
282 282
 
283 283
       #if ENABLED(TEMP_STAT_LEDS)
284
-        #define STAT_LED_RED   32
285
-        #define STAT_LED_BLUE  35
284
+        #define STAT_LED_RED_PIN   32
285
+        #define STAT_LED_BLUE_PIN  35
286 286
       #endif
287 287
     #elif ENABLED(ELB_FULL_GRAPHIC_CONTROLLER)
288 288
       #define BTN_EN1 35  // reverse if the encoder turns the wrong way.

Loading…
Cancel
Save