Browse Source

Fix Neopixel set_color (#18544)

vanilla_fb_2.0.x
ManuelMcLure 5 years ago
committed by GitHub
parent
commit
db0436cc61
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      Marlin/src/feature/leds/neopixel.cpp

2
Marlin/src/feature/leds/neopixel.cpp

@ -53,7 +53,7 @@ Adafruit_NeoPixel Marlin_NeoPixel::adaneo1(NEOPIXEL_PIXELS, NEOPIXEL_PIN, NEOPIX
#endif #endif
void Marlin_NeoPixel::set_color(const uint32_t color) { void Marlin_NeoPixel::set_color(const uint32_t color) {
if (get_neo_index() < 0) { if (get_neo_index() >= 0) {
set_pixel_color(get_neo_index(), color); set_pixel_color(get_neo_index(), color);
set_neo_index(-1); set_neo_index(-1);
} }

Loading…
Cancel
Save