Skip to main contentProcess Overview
If you have a development board that is not officially supported by Edge Impulse, no problem. This guide contains information on connecting any device to Edge Impulse.
In general you will need to write code that works with your devices peripherals (UART, DSP, and NPUs), sensors (drivers) and then connect that functionality into Edge Impulse’s Firmware SDK (MCUs only) and Inferencing SDK (all devices). You will be responsible for development, build chains, testing, and support for the integration of the device into Edge Impulse services.
When going through these porting guides you should understand that Edge Impulse on-device features fall into two main categories. First is on-device data ingestion which is the ability to take sensor data from a device and send that data to an Edge Impulse project via one of the supported methods. Second, and most important, is on-device Inferencing which is the ability to take sensor data from a device and pass it to the Edge Impulse SDK running on that device.
Demonstrate that your device is “Edge Impulse Ready”
For the quickest and well document process for demonstrating that your device is “Edge Impulse Ready” please follow these guides:
- Linux Inferencing Process Overview to validate that your device can run inference with Edge Impulse models.
- Linux Data Ingestion Process Overview: Coming soon.
- Microcontroller Units (MCUs) Inferencing Process Overview: Coming soon.
- Microcontroller Units (MCUs) Data Ingestion Process Overview: Coming soon.
However, below is a broad outline of the things you can to get your device working with Edge Impulse. The goal of these steps is to demonstrate that your device is “Edge Impulse Ready” by successfully collecting data from the device and running an inference on the device. You may jump to the appropriate section below depending on your device type.
Collecting data
Edge Impulse can handle data from any device, whether it’s coming from a new development board or from a device that has been in production for years. Just post your data to the Ingestion API and it will automatically show up in the studio. You can either do this directly from your device (if it has an IP connection) or through an intermediate protocol like a phone application. To deal with data that is already collected we have the Uploader tools, which can label and import data.
A quick way of getting data from devices is using the Data forwarder. This lets you forward data collected over a serial interface to the studio. This method only works on sensors with lower sampling frequencies (f.e. no audio), does not allow sensor selection, and does not sign data on device. It’s however a really easy way to collect data from existing devices with just a few lines of code.
Running impulses
The Inferencing SDK enables you to run impulses locally and on-device. The SDK contains efficient native implementations of all processing and learning blocks. The SDK was written in portable C++11 with as little dependencies as possible, and the best way of testing out whether it works on your platform is through the Deployment page in the studio. From here you can export a library with all blocks, configuration and the SDK. See the Deployments tutorials.
If you need to make changes to the SDK to get it to run on your device we welcome contributions. We also welcome contributions which add optimized code paths for your specific hardware. The SDK documentation has more information on where to add these.
Controlling the device from the studio
Devices can be controlled from the studio through the Remote Management Service protocol. This is a service where devices connect to, either over a WebSocket or through a serial connection (with the help of the Serial daemon). The studio lists these devices, and can instruct them to start sampling straight from the UI.
To add full support for your development board you’ll need to implement the serial protocol and (if your device has an IP connection) the WebSocket protocol. Alternatively you can also implement the WebSocket protocol through an intermediate layer (like a mobile phone app). There are end-to-end integration tests available at edgeimpulse/integration-tests-firmware which validate both the serial and websocket protocols on a development board.
Devices that connect through the data forwarder can be controlled by the studio, but have a limited integration. They don’t support sensor or frequency selection.
Full integration in Edge Impulse, and help porting?
Do you want help porting? Or want to get the best integration in Edge Impulse, including full studio support, and want to let users build binaries directly from the UI? Contact us and we’ll let you know the possibilities.