You are using staging server - a separate instance of the ESP Component Registry that allows you to try distribution tools and processes without affecting the real registry.

uploaded 1 year ago
ESP Delta OTA Library

readme

# ESP Delta OTA

Compressed Delta OTA Updates aims at enabling Over-the-Air firmware update with compressed delta binaries. 

## Getting Started

### Hardware Required

To run the OTA demo, you need an ESP32 dev board (e.g. ESP32-WROVER Kit) or ESP32 core board (e.g. ESP32-DevKitC).
You can also try running on ESP32-S2, ESP32-C3 or ESP32-S3 dev boards.

### Prerequisites

* **ESP-IDF v4.3 and above**

  You can visit the [ESP-IDF Programmming Guide](https://docs.espressif.com/projects/esp-idf/en/latest/get-started/index.html#installation-step-by-step) for the installation steps.

* **detools v0.49.0 and above**

  Binary delta encoding in Python 3.6+. You can install detools using the following command: 
  ```
  pip install detools
  ```
  More information about the package [here](https://pypi.org/project/detools/).

## Usage

### Configure the project
Open the project configuration menu(`idf.py menuconfig`)

In the `Example Connection Configuration` menu:
 * Choose the network interface in the `Connect using`  option based on your board. Currently  both Wi-Fi and Ethernet are supported
* If the Wi-Fi interface is used, provide the Wi-Fi SSID and password of the AP you wish to connect to
* If using the Ethernet interface, set the PHY model under `Ethernet PHY Device` option, e.g. `IP101`

In the `Example Configuration` menu:
* Set the URL of the firmware to download in the `Firmware Upgrade URL` option. The format should be `https://<host-ip-address>:<host-port>/<firmware-image-filename>`, e.g. `https://192.168.2.106:8070/hello_world.bin`
  * **Note:** The server part of this URL (e.g. `192.168.2.106`) must match the **CN** field used when [generating the certificate and key](#run-https-server)
* Select the `EXAMPLE_SET_UPDATE_FIRMWARE` option if you want to create the patch file during the build process. If this option is selected then set `EXAMPLE_UPDATE_FIRMWARE_PATH` with the absolute path of the binary to create the patch with.

### Build and Flash

Run `idf.py -p PORT flash monitor` to build and flash the project.

(To exit the serial monitor, type ``Ctrl-]``.)

See the [Getting Started Guide](https://docs.espressif.com/projects/esp-idf/en/latest/get-started/index.html) for all steps required to configure and use the ESP-IDF to build projects.

### Run HTTPS Server
Start an HTTPS server to host the patch file
   ```
   openssl s_server -WWW -key ca_key.pem -cert ca_cert.pem -port 8070
   ```

## Creating Patch
To generate the patch, we need `base_binary` and `updated_binary`.
Run the python tool to create the patch:
   ```
   python tools/esp_delta_ota_patch.py <target> <path to base binary> <path to updated binary> <patch file name>
   ```

## API Reference
To learn more about how to use this component, please check API Documentation from header file [esp_encrypted_img.h](./include/esp_delta_ota.h)

Links

Supports all targets

License: Apache-2.0

To add this component to your project, run:

idf.py add-dependency "espressif/esp_delta_ota^0.0.1"

or download archive

Stats

  • Downloaded in total
    Downloaded in total 50 times
  • Downloaded this version
    This version: 6 times

Badge

espressif/esp_delta_ota version: 0.0.1
|