Secondary menu

ESP8266

Documenting my adventures with the ESP8266 wifi module.  

First things first, solder on the pins.  I wanted to be able to use the module on a bredboard, so since the outer 2 pairs are all that is needed I soldered like so:

The pins in the back are just to hold the board level while solering.  Pro Tip there.  I also found that one pin in particular has to be pulled to VCC in order for the module to "come alive", so I added a little jumper wire:

Next, I connected it to a Leonardo clone.  I decided to use the Leonardo since it's 0,1 serial are seperate from the usb-serial, makes debugging easier.

The wiring is basically from Seeed's guide at http://www.seeedstudio.com/wiki/WiFi_Serial_Transceiver_Module.  I was not able to get Seeed's code to work though.  I would get the "Can not connect to the WiFi" message 5 times and that's it.  imjosh's code at https://github.com/imjosh/espBasicExample/blob/master/espBasicExample.ino also failed, but copying the "serial loop mode for diag" section up to the connection fail section I was able to make ti connect by manually issuing AT commands.  In both cases I modified the programs to use the Leonardo's Serial and Serial1.

Since I had success with a manual config, I think the issue may lay in the brute force methods and lack of validation that this code uses.  When I get some time soon I'm going to start over from scratch and try to duplicate my manual config method and add in that validation.    

UPDATES:

I was able to have some better success by removing the delays in the serial loops.  It seems it was filling the buffer faster than the code was reading it and timing out.  I also now have some better documentation and example sessions:

Command Doc  Socket Client   Socket Server (incomplete example)   AP and Socket Client

 

Posted by
Chris Weiss's picture
Chris Weiss
on Tuesday, September 23rd, 2014
Filed under arduino
| More