Sie sind auf Seite 1von 8

Food

Living

Outside

Play

Technology

Workshop

ESP8266 Wi fi module explain and connection


by matej.blagsic on January 3, 2015

Table of Contents
ESP8266 Wi fi module explain and connection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Intro: ESP8266 Wi fi module explain and connection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Step 1: THE ESP8266 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Step 2: THE FTDI232R . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Step 3: CONNECTING THE PARTS TOGETHER . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Step 4: A little bit of hardware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Step 5: Connecting to the computer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Step 6: Talking to the ESP8266 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Step 7: COMMUNICATION WITH 5 VOLT DEVICES . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Step 8: OTHER . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Related Instructables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Advertisements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

http://www.instructables.com/id/ESP8266-Wi-fi-module-explain-and-connection/

Intro: ESP8266 Wi fi module explain and connection


Hi.
I am Matej and in this instructable I'm going to show you how to use the ESP8266 Wi-fi module. I know that there is a lot of videos and forums telling how to use this
device, but none of them were colorfull or easy enaugh to understand. I also didn't manage to make the device work by following other's people steps. I hope that you will
find this tutorial usefull.
I also apologize for any misspelling.
*A little update. As promised, I made another instructable. This is about much easier wireless comunication, the Bluetooth. I Combine Bluetooth AND ULTRASONIC
SENSOR. I also used this in my car for a school project. Make sure to check that one out :) *

Step 1: THE ESP8266


To make everything work, you need to understand what each part does and what is the pinout for that part.
I'll start with the ESP8266. As shown in the picture, ESP8266 has 8 pins, 4 in the row of 2. The first pin on the top left is GND. The two pins right from the GND are GPIO
2 and 0. I'm not going to use these pins, as they are not impirtant for the operation. The pin on the top right side is the RX pin and the pin on the lower left is TX. These
are the pins for comunication. The middle pins on the bottom are CH_PD(chip power-down) and RST(reset).
The main thing to remember is, that this device works with 3.3V;even the RX and TX pins. Arduino or many USB to serial converters work with 5V. The
solution for this project is in the next step.

http://www.instructables.com/id/ESP8266-Wi-fi-module-explain-and-connection/

Step 2: THE FTDI232R


For this project I used this FTDI232R module. I bought it from ebay to have a reliable USB to serial converter. I didn't noticed it when I bought this part, but when I got it I
saw, that it has a jumper to switch the operation from 5V to 3.3V. This makes everything easy, as we can connect the two parts together as it will be shown in the later
picture.
I also soldered an extra connector for the 3.3V power to make connecting easy.
If your device doesn't have this option, than I will tell you how to work with 5v devices in the next few steps.

(I bought this ft232r and came in a nice package


http://www.ebay.com/itm/400800529480?ru=http%3A%2F%2Fwww.ebay.com%2Fsch%2Fm.html%3F_ssn%3Dsseariver2009%26_armrs%3D1%26_from%3DR40%26_sacat%3
)

http://www.instructables.com/id/ESP8266-Wi-fi-module-explain-and-connection/

Step 3: CONNECTING THE PARTS TOGETHER


The picture shows how to connect the two parts together.
The CH_PD and the RST pins must be high(connected to 3.3V) to have a normal operation.
If you have any questions about the connections or that your part isn't working, write in the comments :)

Step 4: A little bit of hardware


As you have already noticed, those 8 pins of the ESP8266 are not breadboard friendly. So that's why I made an adapter with female and male headers. I hope that the
pictures describe it well.

http://www.instructables.com/id/ESP8266-Wi-fi-module-explain-and-connection/

Step 5: Connecting to the computer


The pictures are showing the final resault. if you connected everything right, like I sowed you before, you're good to go.
To connect the FTDI232R to the computer, I used this USB mini cable. Than I installed the drivers and connected power to the ESP8266.

http://www.instructables.com/id/ESP8266-Wi-fi-module-explain-and-connection/

Step 6: Talking to the ESP8266


To comunicate with the ESP8266, I used Arduino IDE( http://arduino.cc/en/main/software ) and don't be confused of the version 1.5.8. I have Arduino DUE, so I need
that version.
So, when you open the IDE, choose the correct serial port for your FTDI and click on the Serial monitor.
Once you have opened the Serial monitor, you must set the first option to NL & CR and the baud rate. When it comes to baud rate you have 2 choises. I bought this
esp8266 around 3 weeks ago. Therefore, it has firmware 902 apart from older esp8266 that have firmware 900. For this newer model, the default baud rate is 9600, for
the older is 115200.
Once you set that, type in the box AT and it sould return OK. This device comunicates via AT comments( http://www.electrodragon.com/w/Wi07c )
(every command step is a separate picture)
To check firmware type AT+GMR
To set the module to accept connections type AT+CWMODE=3(my was already in this mode, as shown in the picture)
To search Wi fi networks around type AT+CWLAP
It will display Wi fi networks around you
To connect to a network type AT+CWJAP="Wifi SSID","password"
To find your IP adress type AT+CIFSR
After every command it returns you OK
You can also see it transmiting Wi fi signal on the last picture.

http://www.instructables.com/id/ESP8266-Wi-fi-module-explain-and-connection/

Step 7: COMMUNICATION WITH 5 VOLT DEVICES


So, if you have a communicator like ftdi, that doesn't have an option to set the logic voltage, do the following.
Almost every USB to serial converter has built-in voltage regulator for 3.3 volts(the chip operates with that). So, you can find that pin or a pad and connect it to the pins
like normal. FOr the communication is a liitle bit trickier.
The signal from the esp8266 from TX pin is 3.3V which is enaugh for the communicator. But the 5v from the TX of the communicator can kill the esp8266!!!!!!
Therefore you must build a voltage devider. If you don't know what that is; it's a simple construction made of resistor. In our case, we will use 1k and 2k resistor. We
connect these two in series with TX pin of the communicator to 1k resistor and GND to the 2k resistor. The junction between the resistor is connected to the
RX of the ESP8266.
The picture describes this perfect.

http://www.instructables.com/id/ESP8266-Wi-fi-module-explain-and-connection/

Step 8: OTHER
You can also watch this guy who also explained how to update the firmware for older models. He did all the same, but I showed it much slower and colorfull. Credits to
him as well. ( https://www.youtube.com/watch?v=9QZkCQSHnko )
Now I'm working with connecting ESP8266 to Arduino(Uno or Due) for email notifier and making use of a little ethernet board, to make wifi spot.
If you have any questions you can write down in the comments. I will respond to as much as I can.
Thank you for watching :)

Related Instructables

ESP8266 WiFi
ESP8266 WiFi
temperature and relay switch by
humidity sensor EasyIoT
by EasyIoT

ESP8266 WiFI
water leak
sensor by
EasyIoT

Use ESP8266 to
Internet enabled
AC Appliances
by shinteo

Blink for
ESP8266 native,
like arduino
using Windows
by jbeemster

ESP8266 mini
Tutorial by
GreatScottLab

Advertisements

Comments
3 comments

Add Comment

matej.blagsic says:

Jan 5, 2015. 12:29 AM REPLY


This adapter is far more better. It has pins labeled good. But the reason why I didn't buy anything like this is because I actually forgot when I was shopping
for the esp8266 and not a lot of people sell this kind of thing here in Europe (or it has a ridiculous price).
Sure I recommend one of these .

rajbex says:

Jan 4, 2015. 4:47 PM REPLY


Here is a better breadboard adapter for the ESP-01 module that makes the prototyping little easier. It has pin names printed next to them.
https://www.tindie.com/products/rajbex/esp8266-breadboard-adapter/

matej.blagsic says:

Jan 4, 2015. 8:27 AM REPLY


It's almost 1000 views. Thank you all for watching and I hope that you made something great with that. And remember, have fun :)

http://www.instructables.com/id/ESP8266-Wi-fi-module-explain-and-connection/

Das könnte Ihnen auch gefallen