ESP8266 AT Commands and Arduino Connection

If your are new to ESP then this is the place where you can start.ESP8266 is self contained wifi-networking chip which gives us various wifi functions for our projects.It has its own SOC i.e System on Chip and GPIO pins which  can be used for various application.Each ESP comes with a set of AT commands which we can use to communicate with the chip.An ESP can be flased with a firmware using a FTDI or an Arduino as serial communicator.In this article we will see the pinout diagram of  ESP8266, How to wire ESP with Arduino and some Basic AT commands for Beginners.

ESP8266 Pinout Diagram

ESP8266 Pinout Diagram
ESP8266 Pinout Diagram
  1.  GND – Circuit Ground
  2. TXD – UART0 Transmit
  3. GPIO2 – General Purpose I/O
  4. CH_PD – Chip Enable(Active High)
  5. GPIO0 – General Purpose I/O
  6. RST – Reset(Active Low)
  7. RXD – UART0 Receive
  8. VCC – Circuit Power(+3.3v DC)

ESP8266 Arduino Wiring

ESP8266 Arduino Connections
ESP8266 Arduino Connections

ESP8266 works on 3.3v, so we use the 3.3v pin on Arduino to power the ESP8266 by connecting it to VCC.Also, the RX pin needs to be pulled down to 3.3v, this is done by using 3 x 10k ohm resistors.

ESP8266 Basic AT Commands

         AT Commands                                  Description                        Example

  1. AT                                                           general test
  2. AT+RST                                                 restart the module
  3. AT+CWLIF                                           check join devices’ IP
  4. AT+GMR                                               check firmware version
  5. AT+CWMODE=<mode>                   wifi mode                                  1= Sta, 2= AP, 3=both, Sta is the default mode                                                             of router, AP is a normal mode for devices
  6. AT+CWLAP                                           list the AP
  7. AT+ CWJAP =<ssid>,< pwd >          join the AP                                ssid = ssid, pwd = wifi password
  8. AT+CWQAP                                          quit the AP
  9. AT+CIFSR                                             Get IP address
  10. AT+ CIPSTATUS                                  get the connection status      <id>,<type>,<addr>,<port>,<tetype>= client or server mode
  11. AT+ CIPSERVER                                 set as server                               mode 0 to close server mode, mode 1 to open;                                                                              port = port; eg. turn on as a TCP server: AT+CIPSERVER=1,8888, check the self server IP address: AT+CIFSR=?



You May Also Like

Leave a Reply

Your email address will not be published. Required fields are marked *

Show Buttons
Hide Buttons