Arduino UNO ESP8266 WiFi Module
Arduino UNO ESP8266 WiFi Module
by JaiS45
This instructable will show you how to connect an ESP8266 WiFi Module to an Arduino UNO.
EDIT : For info on how to install the ESP8266 library, see here.
Step 1: Wiring
Wire the ESP8266 Module, the Arduino UNO, and the breadboard as seen in the image.
When complete the pins should be connected as follows (ESP8266 pin-out is shown for reference):
Step 2: Flashing
1. To ash your ESP8266 module, rst check that the GPIO0 pin on the ESP8266 is connected to the
FLASH button on the breadboard.
2. If there is a program currently running on your Arduino, upload an empty project le to the Arduino
to avoid interference while ashing WiFi module.
3. Open the attached Arduino project and re pla ce t he S S ID a nd PAS S W O RD at the top with your
WiFi-network info
4. Open your serial monitor (ctrl+shift+m), set the baud rate to 115200, and the line formatting option
to "Both NL & CR"
5. Press the RST button while holding down the FLASH button on the breadboard - you should see a
blue light on the Wi-Fi module and the TX led on the Arduino will light up. You must upload code
while the TX led is lit.
6. Now, compile and upload code (see video for procedure and expected results).
7. Record the IP printed in the serial monitor for use in step 3. If the ash fails try the above steps
again. If the serial monitor is printing "." repeatedly, you have entered your WiFi information
incorrectly.
Step 3: Usage
Now, for normal operation, co nne ct GPIO0 t o t he IP address from step 2 in your browser. Alternatively,
3. 3V ra il on the breadboard. This can be done by connect directly to the ESP8266's WiFi network on
moving the wire connecting GPIO0 to the button over your laptop and navigate to IP 192.168.4.1 in your
to the positive rail of the breadboard. browser (in my experience this is far less reliable,
using a shared network is preferred).
To connect to your ESP8266 module, ensure you are
connected to the same network as it is, and go to the
it worked fine for the first couple of minutes, but lost control after. Did I do something wrong?
sounds like your wifi connection is dropping! the script i provided will not attempt a reconnect after
a dropped connection, but you could pretty easily add in some logic for that in the loop(). i'd do a
little googling to see what functionality the esp8266 package offers and add a check/reconnect
step!
I'll try that, thank you!
I need ESP8266WIFI.h library. I am getting error that esp8266wifi.h - No such library is found
Where can I find the ESP8266WIFI library? Could you give a link to .zip file for the library?