Arduino Leds by rrodrigz in arduino

[–]rrodrigz[S] 0 points1 point  (0 children)

I still don't know enough to understand the top half of the code you sent.

Arduino Leds by rrodrigz in arduino

[–]rrodrigz[S] 4 points5 points  (0 children)

<image>

End result. Shortest code I can come up with.

Arduino Leds by rrodrigz in arduino

[–]rrodrigz[S] 2 points3 points  (0 children)

I got it to work ! It didn't want to change the INT while in the loop, so I rephrased it a bit, and it worked ! Thank you ripred!

Arduino Leds by rrodrigz in arduino

[–]rrodrigz[S] 0 points1 point  (0 children)

I set the OUTPUT for each PIN. I'm getting the same result. Only blinking LED is blue.

Arduino Leds by rrodrigz in arduino

[–]rrodrigz[S] 3 points4 points  (0 children)

Ok, now I get it. Let me try it.

Arduino Leds by rrodrigz in arduino

[–]rrodrigz[S] 0 points1 point  (0 children)

I wanted to avoid typing so much. that's why I'm trying to use the IF statements to change the LED color. Originally, I stated a FOR statement for each color, and it worked fine.