S
S
Sprite1052014-07-21 16:05:21
Arduino
Sprite105, 2014-07-21 16:05:21

Why is the Arduino uno rebooting by itself?

The essence of the problem:
Arduino reboots every 30 seconds, regardless of which sketch is installed (even basik->blink) ...
The sketch itself:

int incomingByte;  // входящие данные
int  LED = 11;      // LED подключен к 11 пину
int  LED2 = 12;
void setup() {
  Serial.begin(9600); // инициализация порта
  pinMode(LED, OUTPUT);
   pinMode(LED2, OUTPUT);
}
 
void loop() {
  if (Serial.available() > 0) {  //если пришли данные
    incomingByte = Serial.read(); // считываем байт
    if(incomingByte == '1') {
       digitalWrite(LED, HIGH); // если 0, то включаем LED
    }
     if(incomingByte == '3') {
       digitalWrite(LED, LOW);  // если 1, то выключаем LED
    }
     if(incomingByte == '2') {
       digitalWrite(LED2, HIGH);  // если 1, то выключаем LED
    }
     if(incomingByte == '4') {
       digitalWrite(LED2, LOW);  // если 1, то выключаем LED
    }
  }
}

I control from android via bluetooth
The program on android looks like this:
7a7b06b6b2dd4356b2d912301c92bf4c.png
The program sends the numbers 1 or 3 to the arduino ...
The program works, the LED lights up, but every 20-30 seconds the board reboots.
I bought a new microcontroller, inserted it into Uno, flashed it and uploaded blink - everything works without reboots, uploaded my sketch - it reboots back ..
Help me identify the problem, for 2 days I can not understand what I was wrong ...

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
Ivan, 2014-07-21
@0neS

Arduino reboots every 30 seconds no matter which sketch is installed

To get started, decide.
And then read the article atroshin.ru/ru/content/avtomaticheskaya-perezagruz...

A
andjel, 2015-01-19
@andjel

I don’t know if it’s relevant or not: how is Bluetooth Android connected to Arduino? Through a computer's Bluetooth?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question