ISSUE #18: Corrected problem with setLEDs() caused by changes in the previous version
This commit is contained in:
@@ -1,3 +1,5 @@
|
|||||||
|
- ISSUE #18: Corrected problem with setLEDs() caused by changes in the previous version.
|
||||||
|
|
||||||
Version 2.0.0
|
Version 2.0.0
|
||||||
|
|
||||||
- Support for the TM1640;
|
- Support for the TM1640;
|
||||||
|
|||||||
@@ -82,11 +82,11 @@ void TM1638::setLEDs(word leds)
|
|||||||
for (int i = 0; i < displays; i++) {
|
for (int i = 0; i < displays; i++) {
|
||||||
byte color = 0;
|
byte color = 0;
|
||||||
|
|
||||||
if (leds & (1 << i) != 0) {
|
if ((leds & (1 << i)) != 0) {
|
||||||
color |= TM1638_COLOR_RED;
|
color |= TM1638_COLOR_RED;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (leds & (1 << (i + 8)) != 0) {
|
if ((leds & (1 << (i + 8))) != 0) {
|
||||||
color |= TM1638_COLOR_GREEN;
|
color |= TM1638_COLOR_GREEN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user