This is a copy of ESP8266HTTPUpdateServer/ESP32's HTTPUpdateServer library, modified to be compatible with ESPAsyncWebServer.
It will provide a simple webpage for updating the firmware or filesystem of ESP8266
or ESP32
microcontrollers.
- Supports:
- ESP8266
- ESP32
- Can Update:
- Firmware
- FileSystem
- Update route customization (default:
/update
) - Update credentials customization (default:
No credentials
)- Username
- Password
- FileSystem Options:
- SPIFFS
- LittleFS
This Library is available in Arduino Library Repository
and PIO
and you can install it from:
- Arduino IDE Library Manager
- PlatformIO Libraries
ipdotsetaf/ESPAsyncHTTPUpdateServer@^1.1.0
- Include the library after
ESPAsyncWebServer.h
#include <ESPAsyncWebServer.h>
#include <ESPAsyncHTTPUpdateServer.h>
- Create an object from
ESPAsyncHTTPUpdateServer
ESPAsyncHTTPUpdateServer _updateServer;
AsyncWebServer _server(80);
- Setup the update server before starting the webServer
_updateServer.setup(&_server);
_server.begin();
_updateServer.setup(&_server, "/customroute");
_updateServer.setup(&_server, "username", "password");
or
_updateServer.setup(&_server, "/customroute", "username", "password");
Important
The library's default fileSystem is SPIFFS
but if you are using LittleFS
for your FileSystem, make sure to add the -DESPASYNCHTTPUPDATESERVER_LITTLEFS
Build Flag to your environment.
Tip
In order to debug the library functionality, you can add the -DESPASYNCHTTPUPDATESERVER_DEBUG
Build Flag to your environment.
This will enable the library to print logs to the Serial.
Tip
If you are using another Serial
port, you can override the default serial by adding the -DESPASYNCHTTPUPDATESERVER_SerialOutput=Serial1
Build Flag to your environment.
- Optional Page Styling
- You can open Issues for any bug report or feature request.
- You are free to contribute to this project by following these steps:
- Fork this Repo.
- Create a new branch for your feature/bugfix in your forked Repo.
- Commit your changes to the new branch you just made.
- Create a pull request from your branch into the
master
branch of This Repo(https://github.com/IPdotSetAF/ESPAsyncHTTPUpdateServer).