Merge pull request #4 from gedankenexperimenter/upper-bound-red

Change the upper bound to match the lower bound
pull/365/head
Jesse Vincent 7 years ago committed by GitHub
commit 70e1082352
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -10,7 +10,7 @@ void LEDChaseEffect::update(void) {
::LEDControl.setCrgbAt(pos, {0, 0, 0}); ::LEDControl.setCrgbAt(pos, {0, 0, 0});
pos += chase_sign; pos += chase_sign;
if (pos >= LED_COUNT || pos <= 0) { if (pos >= (LED_COUNT - 1) || pos <= 0) {
chase_sign = -chase_sign; chase_sign = -chase_sign;
} }
::LEDControl.setCrgbAt(pos, {0, 0, 255}); ::LEDControl.setCrgbAt(pos, {0, 0, 255});

Loading…
Cancel
Save