The ESP8266 module is a cheap Wireless module.It has SOC(system on chip) that is capable of providing wifi to any micro controller/microprocessor .There are two ways the esp8266 can be used .
Esp8266 needs a external 3.3 v for working properly .If you are using esp8266 with arduino, try not to provide power from arduino . As arduino maximum current providing capacity is 40mA while esp8266 draws 250mA. This is most likely the problem lies whenever uploading the new firmware or when you are using the esp8266
For beginners its advised to go with node mcu board's available in market .There are two types of board's one with RGB led & Ldr sensor and other with just breakout pins .This board has built in voltage regulator that handles the proper power.
This is the best way for flashing the esp01 buy this module and get free from messy wires in future .
Its very handy and very quick .
Note:The module do not enter the programming board directly .For this you need to solder the jumper on it .Please refer the photo for this .The jumper is solder between gpio 0 and gnd pin.when not using in programming mode shift the jumper to the empty pin.
With this module you can separately give 5v to arduino and 3.3 v to esp8266 at the same time .This is the beauty of this module .
Esp rx pin also need 3.3v .If you try to put arduino tx to esp rx .The esp module can get damage .To prevent this from happening you can do two things .
1. Voltage divider
use 20k and 10k resistor to achive this . Please check the connection in photo
vcc & chpd of esp is connected to 3.3v
Gpio 0 & gnd of esp is conencted to gnd
Rx of esp is connected TX arduino directly
Tx of esp is connected to arduino rx via voltage divider
2. Level shifter
Please check the connection in photo
2. Esp 8266-12 module
I found daflabs instructables best for this module so far
https://www.instructables.com/id/Getting-Started-with-the-ESP8266-ESP-12/
I used Arduino instead of cp2102 module, and I had no issue in communication.
The connection will remain mostly same for esp8266-12 to run it in flash mode.
GPIO0 -> LOW
GPIO2 -> HIGH
GPIO15 -> LOW
boot_v1.2.bin --0x00000
user1.1024.new2.bin --0x01000
blank.bin --0x7e000
blank.bin --0x3fe000
esp_init_data_default.bin --0x3fc000
There are two software to install the bin file on soc of esp8266 ,The second method is by using esp flash download .
1.)Download the software from the below link
http://bbs.espressif.com/viewtopic.php?t=25
2.)Now just browse the bin file you want to upload on esp and do not change any of the settings except the com port and change baud rate to 115200 and click on start .you will see an uploading status .Have some patience until it says finish.
1.)Power esp 8266 from external power supply .please avoid using arduino or computer for vcc.
2.)check the circuit thrice and always while uploading firmware try to manually reset esp8266 by making chpd gnd for some time and put it back to vcc .
3.)make sure you use either a buck or a 3.3 regulator. esp8266 needs constant current too.
4.)Note: http://www.allaboutcircuits.com/projects/update-the-firmware-in-your-esp8266-wi-fi-module/ another link that might help you to solve the problems with esp module.if non of the above
method works...