These days I was trying to make an project using Esp8266. I want to control something by Esp8266 and I can get the data from the Internet. Thanks to the book named Internet of things with ESP8266, I can make this idea come true! I’d to show how to do below. But I will not show in details, for more details, you can refer the book.
Although this book recommend us to use a temperature and humidity sensor named DHT11, but I chose another sensor named AM2320. There are libraries for both of the two sensors. So do not worry, you will not lose much time on the sensor. Here is a website about AM2320 that you can refer to. I use the ESP WROOM-02 from switch science, which takes me a lot of time to get the SDA and SCL. And at last, I found that they are corresponded with pin 4 and pin7.
So what I have to do is to connect the ESP8266 with AM2320, get the data about temperature and humidity, and then upload it to the cloud so that I can know it anywhere I can get access to the Internet. Here, I use the freeboard as recommended in the book. At last, I will show you the result by a picture. Also, you can refer it in this website.