I just use a simple program which is blinking a led (not on pin 13) nothing fancy, it works fine as long as the computer is connected but if a disconnect the usb cable and connect an external power supply (9v) then all the arduino does is blink the on onboard on pin 13
First I noticed that with a bigger application but since it was driving crazy I stripped it bits by bits to end with... almost nothing and the issue persists, for reference here is my current test case (I even dropped everything and started back from the blink example to be sure):
Code: Select all
int led = 5;
// the setup routine runs once when you press reset:
void setup() {
// initialize the digital pin as an output.
pinMode(led, OUTPUT);
pinMode(4, OUTPUT);
digitalWrite(4, LOW);
}
// the loop routine runs over and over again forever:
void loop() {
digitalWrite(led, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(led, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
any idea what might happen ?
Ps: I just tried with the standard blink example and it does not work either, after unplugging and plugging back power the led blinks but not how it should, it looks like it is trying to send data...
Edit: I just tried with another arduino I have and this one works as expected, after boot the on board led flash quickly, then stops and the 1s on/1s off starts. It looks like on my other board the bootloader is somehow stuck (I suppose the fast blinking led is the bootloader doing its thing).