Thursday, 24 March 2016

Problem Solved :- ESP8266 with Software Serial ( Firmware Upgarding )

\


There was a problem faced by one my viewer in interfacing ESP8266 wifi module with Arduino UNO. In UNO, he was using Software Serial for communication with the module. Problem was that older version of ESP8266 was having default baud rate of 115200 and Software Serial doesn't work at this high baud rate. Software Serial perfectly works at 9600 baud rate. So the Solution is that, we need to change the baud rate of our ESP8266 wifi module.

One of the solution is that we can change the Baud Rate by giving AT command,

AT+CIOBAUD= Required Baud Rate

We can change the baud rate to 9600 by just writing AT+CIOBAUD=9600. And our problem is solved. But what I found is that, in my module this command was not at all working. I don't know the reason but it may be because of older firmware may not have this command defined in it. 

So first go for this step. If Your Baud Rate get changed, than no need to read this blog further. The response after entering this command will be something like this.

But If you face the similar problem which I have faced i.e. The command is not at all working on your module, than you need to go for firmware upgrading of your wifi module.
Firmware Upgrading
Firmware upgrading is not at all difficult. Just 2-3 steps and 2-3 minutes and you are done with it. First of all you need to download these necessary files before proceeding further.
After that, Open esp8266_flasher in that folder. And than select the bin file i.e. the firmware version you want to update, and also provide the COM port. It will be same port on which your Arduino is connected. Than click the download button.
It will take a minute while flashing your module. And after it complete its work, than you are ready to play with this module at 9600 Baud rate using Software Serial. And the good news is that, in this firmware, you can change the baud rate by the command AT+CIOBAUD to you required baud rate.
You can definitely watch my video in which I'm flashing my own module. I have made it in two Languages,
ENGLISH

HINDI

Files for upgrading ESP8266 firmware click here.
#techiesms

2 comments:

  1. well i stumbled across this while looking for info about buffering data before uploading to thingspeak... but anyway, any serial communication from an arduino on a 8 or 16mhz core clock cycle at 115200 baud is going to be a little unreliable. not going into specifics but the timing is ~8% off (under normal conditions).

    another answer, if your using serial comms a lot is to get some 8.34mhz crystals, that will allow an arduino to generate serial clocks a lot closer to ideal values.

    ReplyDelete
  2. i got error or msg like this "ets Jan 8 2013,rst cause:2, boot mode:(1,5)
    ". after upgrade the firmware and no AT command supported

    ReplyDelete