🎨 Fix L64xx enable, clean up conditionals

This commit is contained in:
Scott Lahteine
2021-09-21 06:25:13 -05:00
parent a37580e4e8
commit ea3df94213
14 changed files with 256 additions and 356 deletions

View File

@ -56,10 +56,10 @@ void GcodeSuite::M150() {
#if ENABLED(NEOPIXEL_LED)
const int8_t index = parser.intval('I', -1);
#if ENABLED(NEOPIXEL2_SEPARATE)
int8_t brightness, unit = parser.intval('S', -1);
int8_t brightness = neo.brightness(), unit = parser.intval('S', -1);
switch (unit) {
case -1: neo2.neoindex = index; // fall-thru
case 0: neo.neoindex = index; brightness = neo.brightness(); break;
case 0: neo.neoindex = index; break;
case 1: neo2.neoindex = index; brightness = neo2.brightness(); break;
}
#else