You can perform remote firmware updates using ESP8266.
Hardware Setup
Add Includes to Skecth
#include <ESP8266WiFi.h> #include <ArduinoOTA.h> // Enable Remote Updates
The password is same API_KEY
#define ODEV_API_KEY "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
The first upload must be done by the Serial, the others can be done by the network.
Upload ( Using IDE )
On serial console you can see the IP:
Only if module is connected to network, after a couple of seconds, the esp8266-ota port will show up in Arduino IDE.
On linux, you can scan
avahi-browse -rt _arduino._tcp
If it does not appear in the list, restart the IDE.
If it still does not appear, you can use the option: Upload ( Manual PUSH )
Upload ( Command Line )
This option uses the command line (terminal) to upload.
Goto esp8266 tools folder (Ex.: /home/user/.arduino15/packages/esp8266/hardware/esp8266/2.X.X/tools)
Run command (change IP, APY_KET and FILE)
python espota.py -i IP.IP.IP.IP -a "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" -f /tmp/pathTo/Sketch.ino.bin
To find path to firmware you must enable verbose output in Arduino preferences:
Much information will appear, look for the file ending with ".ino.bin" on console
Upload ( Using Middleware )
PENDING
Add Comment