Note: if the button is removed, the esp8266 will always be in AP mode “Wifi configuration” led = “Off” sending and / or connection with failed server. led = “On” sending and receiving data Ok.
Arduino 1.8.5 esp8266 12e configuration code#
The technically pressed stops the void loop execution, resets network parameters and enables AP mode, this functionality depends on the code or loop executed.GPIO 4 (Pin D2) – led green + Resistance 220 Ohm.GPIO 14 (Pin D5) – led red + Resistance 220 Ohm.GPIO 5 (Pin D1) – Wifi Config button + 10K resistor.We have used an ESP8266 12E, we have added a button to configure the Wifi and 2 led diodes as indicators. Function add css styles in html, modify HTML form styles via ccs, in this case invert colors.ġ Module ESP8266 12E Node MCU or ESP8266 12FĪn example has been downloaded from Github and has been cut to make a light and simple version, without the slightly complex functionalities that we will see later, this version will realize the basic configuration of NETWORK credentials. – Boolean checkbox function to select, enable or disable parameters, to capture parameters and store data requires handling SPIFFS and Json functions. Form form to enter string “parameters”, create input fields of parameters, to capture parameters and store data requires handling functions SPIFFS and Json. – Custom html text function, allows you to add titles in HTML form. Timeout of AP mode “180 s”, if it is not configured wifi the module restarts automatically after the defined time in seconds example: 180. Main Functionality Configuration of NETWORK credentials. I will mention some of the functionalities of the WifiManager libraries, in case of using them the complete and detailed information of each library is available in github, in this case I have used the Version 2: WifiManager library by Ken Taylor. Note: they work perfectly, obviously between the 2 libraries there are variations in code implementations and that generates incompatibilities or errors in some functions between version 1 and 2. Version 2: WifiManager by Ken Taylormodified and based on WifiManager created by tzapu. Version 1: WifiManager created by tzapu – creator This time we will make a brief introduction to the WifiManager library, I have tested 2 similar versions. In the case of the esp8266 programmed in Arduino IDE for some time I have seen a proposal called WIfiManager presented by Tzapu, which allows an agile and fast connection, the first tests are registered since 2015.
Arduino 1.8.5 esp8266 12e configuration password#
The main disadvantage is to configure the network credentials in a esp8266 without requiring to modify and download the firmware again, I have tested with several methods to dynamically store the SSID and PASSWORD of a network.