eCore Quick Start Guide

Installation Step by Step

This is a detailed roadmap to walk you through the installation process.

Step 1. Install prerequisites

Some tools need to be installed on the computer before proceeding to the next steps.

To compile with ESP-IDF you need to get the following packages (in Ubuntu and Debian):

sudo apt-get install git wget flex bison gperf python3 python3-pip python3-setuptools ninja-build ccache libffi-dev libssl-dev dfu-util libusb-1.0-0

Note

  • CMake version 3.18.6 or newer is required.

To install CMake version 3.18.6, you have to type the following commands:

wget https://github.com/Kitware/CMake/releases/download/v3.18.6/cmake-3.18.6.tar.gz tar -zxvf cmake-3.18.6.tar.gz cd cmake-3.18.6 ./bootstrap make sudo make install

Important

  • CMake installation may take several minutes.

Python compatibility

ESP-IDF supports Python 3.6 or newer. It is recommended to upgrade your operating system to a recent version satisfying this requirement.


Step 2. Get ESP-IDF

To build applications for the ESP32, you need the software libraries provided by Espressif in ESP-IDF repository.

To get ESP-IDF, navigate to your installation directory and clone the repository with git clone, following instructions below:

mkdir -p ~/esp cd ~/esp git clone -b release/v4.3 --recursive https://github.com/espressif/esp-idf.git

ESP-IDF will be downloaded into ~/esp/esp-idf.


Step 3. Set up the tools

Aside from the ESP-IDF, you also need to install the tools used by ESP-IDF, such as the compiler, debugger, Python packages, etc.

cd ~/esp/esp-idf ./install.sh


Step 4. Set up the environment variables

The installed tools are not yet added to the PATH environment variable. To make the tools usable from the command line, some environment variables must be set. ESP-IDF provides another script which does that.

source ~/esp/esp-idf/export.sh


Step 5. Start a Project

Now you are ready to prepare your application for eCore.

Clone eCore repository. You can clone and build projects in your working directory. We are going to clone inside ~/esp directory:

cd ~/esp git clone https://pickdata_fw@bitbucket.org/pickdata-fw/ecore.git

You can start with minimal or any example project. We start with ecore_minimal_project:

cd ecore/ecore_minimal_project


Important

The ESP-IDF build system does not support spaces in the paths to either ESP-IDF or to projects.


Step 6. Build the Project

Build the project by running:

idf.py build

This command will compile the application and all ESP-IDF components, then it will generate the bootloader, partition table, and application binaries.

If there are no errors, the build will finish by generating the firmware binary .bin files into the ./build directory.


Step 7. OTA Firmware Update

Flash the binary that you just built onto your eCore through Pickdata eCore SWUpdate. You can do this in two ways:

Ethernet

Steps:

  1. Connect eCore to local network with DHCP server (by default, eCore Ethernet is configured to get dynamic IP)

  2. Put the following URL in your web browser:

    ecore.local:8080

    Pickdata eCore SWUpdate must be shown.

  3. Press the Browse button and select generated firmware binary .bin file from the ./build directory
  4. And finally, press the Update Firmware button. After a few seconds your eCore will be updated!

Wifi

Steps:

  1. Connect your PC to eCore Wifi with following parameters (by default, eCore Wifi is configured as access point):

    SSID: "eCore" Key: "12345678"

  2. Put following IP with port 8080 in your web browser:

    ecore.local:8080

    Pickdata eCore SWUpdate must be shown.

  3. Press the Browse button and select generated firmware binary .bin file from the ./build directory
  4. And finally, press the Update Firmware button. After a few seconds your eCore will be updated!


Important

It's assumed that Multicast DNS service is enabled.



Info

Further information on ESP-IDF Programming Guide