A simple example of send HTTP packet by AT command

ESP_Faye
Posts: 1640
Joined: Mon Oct 27, 2014 11:08 am

A simple example of send HTTP packet by AT command

Postby ESP_Faye » Mon Jun 08, 2015 11:43 am

:!: :!: :!:

How to send HTTP packet based on esp_iot_sdk http://bbs.espressif.com/viewtopic.php?f=21&t=232

How to send HTTP packet by AT command
1. AT+CWMODE=3 // set softAP+station mode

2. AT+CWJAP="SSID","password" // ESP8266 station connect to router

3. create a TCP connection and send HTTP packet which is marked in red, notice that the new line [(0x0d 0x0a) or (CR LF)] is needed.

Code: Select all

GET / HTTP/1.1
User-Agent: curl/7.37.0
Host: cn.bing.com
Accept: */*


SEND_HTTP_TEST.png
SEND_HTTP_TEST.png (3.82 KiB) Viewed 9217 times



4.HTTP result
SEND_HTTP_TEST_RESULT.png
SEND_HTTP_TEST_RESULT.png (4.02 KiB) Viewed 9217 times


Thanks for your interest in ESP8266 !

Who is online

Users browsing this forum: No registered users and 0 guests