]> git.piffa.net Git - sketchbook_andrea/blobdiff - programming/loops/loop_3_multi_led/loop_3_multi_led.ino
photosensor
[sketchbook_andrea] / programming / loops / loop_3_multi_led / loop_3_multi_led.ino
index e736eb0d5db146d3a30e941fe305492020501fa3..bb7e7ce41ac7d70ba3240084f785157629bbbc7b 100644 (file)
@@ -26,7 +26,7 @@ void setup() {
 
 void loop() {
   // loop from the lowest pin to the highest:
-  for (int thisPin = 2; thisPin <= 9; thisPin++) {
+  for (int thisPin = 2; thisPin < 9; thisPin++) {
     // turn the pin on:
     digitalWrite(thisPin, HIGH);  
     delay(timer);                  
@@ -35,7 +35,7 @@ void loop() {
   }
 
   // loop from the highest pin to the lowest:
-  for (int thisPin = 9; thisPin >= 2; thisPin--) {
+  for (int thisPin = 9; thisPin > 2; thisPin--) {
     // turn the pin on:
     digitalWrite(thisPin, HIGH);
     delay(timer);