Skip to content

Install using PlatformIO

Andres Meira edited this page May 12, 2021 · 3 revisions

We recommend you flash your board following the method described in the Quick Start. However you can also flash directly from source code using PlatformIO.

Install PlatformIO

Follow this guide to install PlatformIO on your machine. PlaformIO offers several benefits to the Arduino IDE, particularly the ability to contain dependencies within a simple folder structure.

Build the project

Build the project using the check mark on the bottom toolbar, then upload using the arrow button adjacent to it. The IDE should automatically detect the board of your connected OpenEEW sensor and start to write the new firmware.

To add the certificates (you can request these in Slack) and other contents of the data folder to the SPIFFS memory, you need to open tasks in the PlaformIO menubar on the left, and select Upload FileSystem Image:

Config.h

In the config.h file two levels of debugging can be set, first "debug" variable needs to be set true to allow serial communication and only basic status lines are part of the output. Second level is set by making LOG_L2 true, this would give specific output on the WiFi events.

The Sample rate needs to be defined by making true either of the 125Hz or 31.25Hz options. Device Id can be edited also, along with the udp port and destination IP.