Hello,
Need help with code for an art installation!
I need to light up an art installation consisting of 7 cubes who need to be illuminated with an led. Each box need to light up for like two seconds then two seconds break then the next box, this should run from no. 1 - 7 and then loop, except cube no. 5 should blink continually at any rate and independent from the other ones.
I have so far figured out a code for a running light like this;
id setup(){
pinMode(1, OUTPUT);
pinMode(2, OUTPUT);
pinMode(3, OUTPUT);
pinMode(4, OUTPUT);
pinMode(5, OUTPUT);
pinMode(6, OUTPUT);
}
void loop(){
digitalWrite(1,HIGH);
delay(2000);
digitalWrite(1,LOW);
delay(2000);
``digitalWrite(2,HIGH);
delay(2000);
digitalWrite(2,LOW);
delay(2000);
digitalWrite(3,HIGH);
delay(2000);
digitalWrite(3,LOW);
delay(2000);
digitalWrite(4,HIGH);
delay(2000);
digitalWrite(4,LOW);
delay(2000);
digitalWrite(5, HIGH);
delay(2000);
digitalWrite(5, LOW);
delay(2000);
digitalWrite(6, HIGH);
delay(2000);
digitalWrite(6, LOW);
delay(2000);
}
My question is how to add the flashing light to this code?
I don't really have experience with that stuff but figured out that the arduino uno can be a useful tool for it, i saw somewhere in the net a almost similar solution running light + flashing light but cant find it anymore, would really appreciate your help guys!