Key Takeaway : First WiFi project with ATtension commands. Generally ESP-01 comes with default ESP8266 AT firmware which has complete TCP/IP stack. This firmware takes care of DHCP as well.AT commands are used to control GSM phone or Modem.
How ESP-01 gets IP address ? ESP-01 firmware is set by default as DHCP(Dynamic Host Configuration Protocol) client. It broadcasts the DHCP Discover message after power-on . You may refer to following link to understand this process.
If you observe the traffic using FREE Wireshark tool,You will notice ARP from ESP8266 to itself immediately after getting IP address. It is followed by Gratuitous ARP which has both source & destination IPs are same. This is a good method to check IP conflicts.
After this IGMPv2 (Internet Group Management Protocol) membership report. A membership report message is sent by a host whenever it joins a multicast group, and when responding to Membership Queries sent by an IGMP router.
- AT+command? to know the existing value e.g. AT+CWJAP?
- AT+command=val to set new value e.g. AT+CWJAP=ssid,password
- AT+command to execute a command if no parameter required e.g. AT+CWLAP
- Here CWLAP to get available local access points and CWJAP to connect to local access point and
Step1: To configure ESP as a server first we must enable multiple connections to it using CIPMUX i.e. AT+CIPMUX=1
Step2: Then we should configure the server using command CIPSERVER i.e Configure as Server
- par=1 (open server)
- par=0 (close server)
e.g. : AT+CIPSERVER=1,5678
Step3: The IP address can be obtained by CIFSR i.e. AT+CIFSR.
Take a note of MAC addresses (From Actual experiment Not in the above picture), I noticed only one bit b1 changed .
Step4: Now suppose if the STAIP is 192.168.1.207 as shown above, Check the connectivity using ping 192.168.1.207 from command prompt of Windows.
Step6: Now to send data over the link use the command AT+CIPSEND=0,4. Here ‘4’ indicates the number of characters to be send. You will get a > sign . Type four characters blindly at this. After typing a message will be displayed saying SEND OK . These characters are received in the terminal window
We may use Wireshark tool to capture this .
Step7: In the end, to close the link between browser and ESP, the command AT+CIPCLOSE=0 should be used
Are you curious about ESP8266 NodeMCU ? Lets look at NodeMCU with DHT11
If you liked this article , Please support by sharing in your network.