1

I have been using ESP8266 wifi module with Arduino as FTDI. The power for ESP8266 comes from LM317 5V - 3.3v regulated supply(I am sure 5V is powerful enough to give upto 1A of current).

The RX of ESP8266 is connected to RX of Arduino via a voltage divider to ensure 3.3V logic level. But still, I am not getting any response to AT command, though my laptop and phone wifi have successfully connected to AI-Thinker... SSID(which is an open hotspot from ESP8266).

I am also having some garbage values on the serial port immediately after I turn on the power supply to ESP8266. I have tested all baud rates available in Arduino IDE v1.0.5 with no results.

The resistor values for lm317 are R1 = 125 Ohm, R2 = 225 Ohm with which I am getting around 3.2 Volts.

The connections are as follows:-


-----Arduino UNO-----

RESET ------------ GND


Arduino UNO ----- ESP8266

TX ------------------- TX

RX ---5V to 3.3v--- RX

GND ----------------- GND


ESP8266 --------- LM317(5V to 3.3V)

VCC --------------- 3.3V

GND --------------- GND

CH_PD ------------ 3.3V



EDIT - 1: I have bought a new ESP8266, and even it doesn't responds to any AT commands, thought there is some difference in the previous ESP8266 output and this new ESP8266 output.

The difference is a sort of good news to me, it sends ready after sending some garbage at 115200 baud on boot which never happened with previous one(ESP8266).

Is anyone having some clue why there is no response to AT commands? May it be a issue with TX line?


EDIT - 2: I have also used another Arduino with same connections doubting the TX pin on Arduino, but with same luck, bad luck. Still, nothing got changed.


EDIT - 3: I am shifting 5v to 3.3v by using three 100 ohm resistors.

  • Comments are not for extended discussion; this conversation has been moved to chat. – Nick Gammon Jun 9 '17 at 7:43
  • I think, the blue led should blink even at wrong bauds. Correct me If I am wrong. – Devesh Saini Jun 10 '17 at 19:17
  • blue led blinks only when sending some data, not receiving. – Devesh Saini Jun 15 '17 at 18:32
0

Connect TX of arduino to esp8266 RX, and arduino RX to esp8266 TX.

See this link for more info.

  • Comments are not for extended discussion; this conversation has been moved to chat. – Nick Gammon Jun 13 '17 at 8:05
  • The rather extensive set of comments (now moved to chat) should be added to the answer, if indeed they help answer the question. This is not a forum-type situation here on Stack Exchange. – Nick Gammon Jun 13 '17 at 8:06
0

First of all your connectons are wrong: -----Arduino UNO-----

RESET ------------ GND (Why)

Arduino UNO ----- ESP8266

TX ------------------- RX

RX ------------------- TX

(RX is the recieving end, TX is the transmitting end, one should allways connect a transmitter to a reciever both directions, never a transmitter to transmitter or reciever to reciever, and use a logic level shifter)

GND ----------------- GND

ESP8266 --------- LM317(5V to 3.3V) (only for Vcc)

VCC --------------- 3.3V

GND --------------- GND

CH_PD ------------ 3.3V

In these cases you should use a logic level shifter like 74LVC245 or sparkfun level converter and not a voltage regulator. If you must use lm317 connect it correctly, diodes, capacitors and an adjusting potmeter or resistor. Typical application found in the datasheet on p. 10

baudrate should be 57600 on the esp8266.

glhf :)

  • When we are doing TX-RX, RX-TX, we are trying to communicate between Arduino MCU and ESP8266, that's why these pins are labelled so. But, in case, we are bypassing the Arduino MCU, we do it this way TX-TX, RX-RX. By bypassing Arduino MCU, our TX and RX on arduino gets reversed i.e. they become RX and TX of computer(if we attach a computer with USB cable)with which we can communicate between a computer and ESP8266 bypassing Arduino – Devesh Saini Jun 11 '17 at 10:53
  • Second thing, I think the ESP8266 is getting enough power as it is showing as wifi hotspot in my laptop and phone as well as sending some bits and then ready in serial console, so maybe nothing to do with LM317, i think. – Devesh Saini Jun 11 '17 at 10:56
  • Third thing, Arduino: RESET --- GND because that's a way to bypass Arduino MCU, we could have done physically removing its ATMEGA328p from the board but that's not a elegant way of doing this. – Devesh Saini Jun 11 '17 at 11:04
0

Which version of arduino IDE are you using? I use 1.6.12 and works, it does not work for 1.8 versions. Also ensure 3.3v power input for the esp8266 separately from arduino power. I suggest using a PC power supply (color orange is 3.3v).

0

The problem was with my logic level shifting.

Any Arduino pin can provide only upto 40mA of current. What current you are trying to draw is:-

5 Volts / 100 Ohm = 50mA

which is clearly more current than what an UNO can provide. Your ESP also adds up its own resistance meaning even more current draw requirement from RX pin.

Instead of using three 100 ohm resistors, use some high valued resistors such as 1K ohm resistors(or even higher value) in the voltage divider circuit so that no much current pass through it, consuming less power affordable by the Arduino RX pin.

Remark: If you don't know how logic level shifting works with voltage divider circuit, click here.

-1

First of all do not use any resistors(try it) for RX pin. Connect it directly.

Second connect RST pin of ESP8266 to 3.3V power supply.

And also try to use arduino directly with esp8266 once. Do not use lm317 or any other separate power supply. Use 3.3 volt power supply of arduino.

And i dont know why you have connected RESET pin of Arduino to GND. Please answer me that.

  • I have already tried to connect arduino RX to ESP8266 RX without resistors(voltage divider circuit), but it didn't worked either. Second, I have not tried RST pin of ESP8266 to 3.3V, I am going to try it now and report back soon. – Devesh Saini Jun 7 '17 at 11:36
  • I also used arduino directly without lm317, it does not shows any hotspot until an external power supply to Arduino is given. I gave arduino 5V external supply, and the hotspot showed again, but this time also, no response to AT command, but garbage on starting. – Devesh Saini Jun 7 '17 at 11:39
  • why are you making things complicated. Connect 3.3V of arduino to esp8266 Vcc port. And you obviously have to provide external power supply to arduino. Connect it to PC using USB Cable. And Connect RST pin to 3.3V. Use a breadboard. – SONIA JOHNSON Jun 7 '17 at 11:48
  • I have used 3.3V of arduino to esp8266 directly. Given, external power supply to arduino, connected arduino to pc and connected RST pin of ESP8266 to 3.3V. I am still geting garbage at serial on starting and no AT response. – Devesh Saini Jun 7 '17 at 12:01
  • 3
    @SONIAJOHNSON You need to power the ESP8266 separately from the Arduino - it required a higher current than the Arduino 3V3 pin is capable of supplying. Also, ESP8266 RX pin does seem to be voltage sensitive, requiring a voltage divider or converter to reduce voltage to 3V3. – Holmez Jun 7 '17 at 14:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.