Go Down

Topic: What would cause the delay in turning on the LED? (Read 616 times) previous topic - next topic



I don't know why there is such a delay in my Arduino executing code. On my actual Arduino Duemilanove board, it turns the LED on instantly when I supply power to the Arduino Duemilanove board. However, on my standalone circuit, as you can see in the video, it turns on real briefly, then turns off for a couple seconds, then finally turns on.

Video demonstration:


As you probably can tell, the larger LED to the left is connected to power directly, not the Arduino chip. And sorry for the blurriness.

Do I have the capacitor hooked up right?

The reason I'm asking all of this is because my next project is going to require instant code execution upon power being supplied to my circuit.

Oh, here's the sketch just to show how simple it is:

Code: [Select]

#define LED 13  // LED connected to
                // digital pin 13

void setup()
  pinMode(LED, OUTPUT);  // sets the digital
                         // pin as output

void loop()
    digitalWrite(LED, HIGH);  // turn the LED on


1  Is is the bootloader - perhaps you could modify it, or program without a bootloader
2  You have nothing connected to the reset - I thought there is supposed to be a pull up.


This is the standard 1 second bootloader delay - I would expect the Duemilanove to do this too unless a non-standard bootloader is installed on it.  Perhaps you have optiboot on it?
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131