Pages: [1]   Go Down
Author Topic: What would cause the delay in turning on the LED?  (Read 446 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 85
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,

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:
#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
}
Logged

UK, Southwest
Offline Offline
Full Member
***
Karma: 5
Posts: 138
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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.
Logged

0
Offline Offline
Shannon Member
****
Karma: 199
Posts: 11639
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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?
Logged

[ I won't respond to messages, use the forum please ]

Pages: [1]   Go Up
Jump to: