I know you already posted code but i had this done before i saw that. Check this out and see if everything looks logical. Thanks
void setup();
{
pinMode(13, OUTPUT); //outer two leds
pinMode(12, OUTPUT); //middle two leds
pinMode(7, OUTPUT); //inner two leds
pinMode(8, INPUT); //switch
digitalWrite(13, HIGH);// blink LEDs once to signal power on
digitalWrite(12, HIGH);
digitalWrite(7, HIGH);
delay(2000);
digitalWrite(13, HIGH);// blink LEDs once to signal power on
digitalWrite(12, HIGH);
digitalWrite(7, HIGH);
delay(2000);
}
if(8=HIGH) //if switch is on (mode 1)
{
delay(14400000); // Wait 4 hours for sleep to start
}
else // is switch is off(mode 2)
{
delay(300000); //Wait 5 mins for sleep to start for nap
}
void loop() //do blinking after delay
{
digitalWrite(13, HIGH);
delay(500);
digitalWrite(13, LOW); //Blink outer two leds that are connected to the same output
delay(500);
digitalWrite(13, HIGH);
delay(500);
digitalWrite(13, LOW);
delay(500);
digitalWrite(12, HIGH);
delay(500);
digitalWrite(12, LOW); //Blink middle two leds that are connected to the same output
delay(500);
digitalWrite(12, HIGH);
delay(500);
digitalWrite(12, LOW);
delay(500);
digitalWrite(7, HIGH);
delay(500);
digitalWrite(7, LOW); //Blink inner two leds that are connected to the same output
delay(500);
digitalWrite(7, HIGH);
delay(500);
digitalWrite(7, LOW);
delay(500);
delay(600000); //Wait 10 minutes
}