just playing around i have 2 fan hooked up to a relay set and using this sketch.
my question is, why doe the arduino turn the 2nd fan on just before powering off fan #1 and visversa
should'nt it turn it off wait 2 seconds turn on #2?
// the setup function runs once when you press reset or power the board
void setup() {
// initialize digital pin 13 as an output.
pinMode(12, OUTPUT);
pinMode(11, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(12, HIGH); // turn the LED on (HIGH is the voltage level)
delay(10000); // wait for a second
digitalWrite(12, LOW); // turn the LED off by making the voltage LOW
delay(2000);
digitalWrite(11, HIGH); // turn the LED on (HIGH is the voltage level)
delay(10000); // wait for a second
digitalWrite(11, LOW); // turn the LED off by making the voltage LOW
delay(2000); // wait for a second
}