ESP12E WiFi Module is the most common WiFi module in most of the products in nowadays. The modules are smaller in size and have internal programming ability with onboard pins. It has an internal 32-bit microcontroller that can perform multiple communications and output signals. The module is programmable with multiple languages and in most modern IoT devices ESP12E is available for creating and network hub and device. ESP12E has all popular network protocols and security encryption in a single chip with fast speed and low power consumption. The module ESP12E is popular due to its cheapness and it has less ping as compare to any other module.
ESP-12E Pinout DiagramThe ESP12E WiFi Module is the best module for WiFi communication. It is because of its onboard microcontroller which generates multiple pins. The pins of ESP12E is a stand-alone device. It is just like a microcontroller with WiFi in a small size. There is a total of 22 pins which offer multiple kinds of communication and all of them are:
Pin Configuration DescriptionIn this section, we will describe details of pinout. We list functionality of each pin one by one.
GPIO PinsThere is a total of 11 I/O pins. Therefore, these pins can perform multiple kinds of input and output functions that are interfaceable with all the TTL/CMOS devices. All GPIO pins are:
The devices ESP 12E is programmable with UART communication in many IDE. Those UART pins are usable after even programming. Both pins are:
The module offers direct SPI communication with itself. This communication uses four pins for proper communication, which are:
In ESP12E some GPIO pins are useable for I2C communication. In this communication, only two pins help to communicate. One for clock and other for data. Therefore, in ESP, both are:
It isn’t common in every device. The I2S helps to collect, process and transmit the audio signal. The I2S uses 6 pins and in ESP 12E all I2S pins are:
In every controller, the ESP 12E can convert it every pin into PWM pins through programming. There are three specifics for the PWM signal. All these pins are:
The IR interface uses modulation and demodulation which requires NEC coding. The ESP12E is interfaceable using the IR interface pins and it is specific to these pins:
The device has a 10-bit ADC pin, which uses 0-1V range to convert the analog data to digital data.
Power : ESP12E uses the VCC pin to power up the whole module and the ground pin to make the common ground with power supply and other devices
Enable: The devices have an internal digital switch. The enable pin will receive the digital HIGH signal to activate the chip.
Reset: To reset the device the digital will help to reset it through the LOW state. The reset pin is the first pin of the module is:
The block diagram of ESP12E has multiple registers and features which is viewable by a block diagram:
ESP12E ApplicationsTo control the device there are two methods, Arduino and FTDI. The Arduino uses UART communication to communicate with ESP12E.
ESP12E is a family of ESP8266. So, Arduino IDE uses “Generic ESP8266” for ESP12E. To upload the device Arduino requires the UART communication pins RX and TX only. During the use of ESP12E, there won’t be any library. The module can operate with the same language Arduino board uses; the PINs will help to communicate through Arduino programming. For Example, to use the built-in LED the following code will help to blink the led.
void setup() { pinMode(LED_BUILTIN, OUTPUT); } void loop() { digitalWrite(LED_BUILTIN, LOW); delay(1000); digitalWrite(LED_BUILTIN, HIGH); delay1000); }
In Arduino IDE, if the built-in LED is unknown the LED_BUILTIN will help to initialize the LED pin. There are other protocols in the ESP 12E but to control them Arduino uses external libraries. ESP 12E will require the external libraries to control the other protocols like SPI, WIFI, I2C, HTTP, etc. The module is useable as a master and slave. To use the master/slave the different programming will require. These are the most common libraries in ESP8266.
#include <ESP8266WiFi.h> #include <ESP8266mDNS.h> #include <WiFiClient.h> #include "ESP8266WiFi.h" #include <ESP8266WiFiMesh.h> #include <ESP8266WiFiMulti.h> #include <LittleFS.h>ESP12E WiFi Module Command Mode
The module also comes with command mode. It comes with command mode by default. The command mode uses the baud rate of 115200. The Arduino COM monitor is useable for command mode. The following commands will help to send the data to the module to affect the default setting.
In this example, we will use the module as a WiFi access point. The module will have its WiFi name and WiFi password. All the WiFi stations will able to connect with it with the use of passwords directly.
The following code will help to make the ESP12E as a WiFi access point.
#include <ESP8266WiFi.h> void setup() { Serial.begin(115200); WiFi.softAP("SSID-NAME-HERE", "WIFI-PASS(8 MAX)"); void loop() { Serial.printf("Stations connected = %d\n", WiFi.softAPgetStationNum()); delay(3000); }
The library will require to make the WiFi mode an access point. The WiFi.softAP will helpful in describing the WiFi name and password. Once it’s done, the loop will have a WiFi.softAPgetStationNum() to get the detail of the number of connected devices. Once the device is connected there will be an increment in the value unless it gets disconnected. The module can act as a hybrid by using another method which is by AT command:
AT+CWMODE=2
The command will help to make the module an access point without programming. The other thing like device name and password will be able to change/make using the following commands:
AT+CWJAP=" SSID"," PASSWORD"
The SSID should be replaced with WiFi name and Password with WiFi password and it should be a maximum 8 in numbers.
2D Physical DiagramOther Wireless Modules:
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4