O ESP8266 permite ser configurado como access point, desta forma pode-se montar uma rede sem a necessidade de um roteador. A configuração é via comandos AT.
Veja como pode ser feito:
In addition to connecting to WiFi Access Points the module can also act as an Access Point--this means you can connect devices to the module without any other network infrastructure in place. Ideal for a local private shared "drop box" perhaps...
The module comes with an access point pre-defined (SSID of "ESP_...") but you can define your own with:
The first parameter is the SSID name; the second parameter is the password; the third the WiFi channel--pick one not used in your area; and, the final parameter is the encryption standard to use. An encryption value of
0 turns encryption off which means the password is ignored--but it still can't be an empty value. I couldn't get any encryption to work though (it would always create an unencrypted network) you might have more luck--possibly with a more recent firmware...
To actually enable the network to be created you need to set the "WiFi mode" of the module to "AP" (
2) or "Both" (
Now you will be able to connect to your module as an access point from another device (e.g. a laptop or a phone).
You can list the IP address etc of any device connected to the network with:
Which generates the response:
Now you can run the server example from above and connect--note that the module always has the IP
192.168.4.1 when acting as an AP.
As informações acima forma retiradas dos link: