Chat freely about anything...

User avatar
By afishinthesea22
#48175 I got an ESP hooked up to my arduino, and I can control it over a serial terminal from my laptop, but when I try to control it with an arduino program it does nothing. The little blue LED flashes every time I send a command to it from the laptop, but when the arduino sends commands the blue LED doesn't ever light up. Since It's hooked up to the arduino all the time and I'm simply holding the reset button when I want to send commands from my laptop, I know that the problem isn't a loose connection or swapped rx/tx or a similar hardware issue. Any advice? Here's my arduino code:

#include <Wire.h> // Serial library

void setup() {

Serial.begin(115200); // Communication with ESP8266 via 5V/3.3V level shifter
Serial.setTimeout(5000); // Set the timeout value for the ESP8266
delay(5000); // Delay to complete setup

}

void loop() {

Serial.println("AT"); // Send "AT" to the ESP 10 times/second
delay(100);
}
User avatar
By schufti
#48207 This should work on a arduino mini pro but won't work on an arduino uno or nano.
You can't share rx/tx pins of the atmega328 between esp and usb/serial converter (or from usb/serial converter between atmega328 and esp etc), you are shorting two active outputs.
Its working with the atmega328 held in reset because this takes one chip out of the szenario.