Arduino Nicla Vision
The Nicla Vision is a ready-to-use, standalone camera for analyzing and processing images on the Edge. Thanks to its 2MP color camera, smart 6-axis motion sensor, integrated microphone, and distance sensor, it is suitable for asset tracking, object recognition, and predictive maintenance. Some of its key features include:
  • Powerful microcontroller equipped with a 2MP color camera
  • Tiny form factor of 22.86 x 22.86 mm
  • Integrated microphone, distance sensor, and intelligent 6-axis motion sensor
  • Onboard Wi-Fi and Bluetooth® Low Energy connectivity
  • Standalone when battery-powered
  • Expand existing projects with sensing capabilities
  • Enable fast Machine Vision prototyping
  • Compatible with Nicla, Portenta, and MKR products
Its exceptional capabilities are supported by a powerful STMicroelectronics STM32H747AII6 Dual ARM® Cortex® processor, combining an M7 core up to 480 Mhz and an M4 core up to 240 Mhz. Despite its industrial strength, it keeps energy consumption low for battery-powered standalone applications.
The Arduino Nicla Vision is available for around 95 EUR from the Arduino Store.
Arduino Nicla Vision

Installing dependencies

To set this device up in Edge Impulse, you will need to install the following software:
  1. 2.
  2. 3.
    On Linux:
    • GNU Screen: install for example via sudo apt install screen.
Problems installing the CLI?

Connecting to Edge Impulse

With all the software in place it's time to connect the development board to Edge Impulse.

1. Connect the development board to your computer

Use a micro-USB cable to connect the development board to your computer.

2. Update the firmware

The development board does not come with the right firmware yet. To update the firmware:
  1. 2.
    Open the nicla_vision_ingestion.ino (for IMU/proximity sensor) or nicla_vision_ingestion_mic.ino(for microphone) sketch in a text editor or the Arduino IDE.
  2. 3.
    For IMU/proximity sensor data ingestion into your Edge Impulse project, at the top of the file, select 1 or multiple sensors by un-commenting the defines and select a desired sample frequency (in Hz). For example, for the accelerometer sensor:
1
/**
2
* @brief Sample & upload data to Edge Impulse Studio.
3
* @details Select 1 or multiple sensors by un-commenting the defines and select
4
* a desired sample frequency. When this sketch runs, you can see raw sample
5
* values outputted over the serial line. Now connect to the studio using the
6
* `edge-impulse-data-forwarder` and start capturing data
7
*/
8
#define SAMPLE_ACCELEROMETER
9
//#define SAMPLE_GYROSCOPE
10
//#define SAMPLE_PROXIMITY
11
12
/**
13
* Configure the sample frequency. This is the frequency used to send the data
14
* to the studio regardless of the frequency used to sample the data from the
15
* sensor. This differs per sensors, and can be modified in the API of the sensor
16
*/
17
#define FREQUENCY_HZ 10
Copied!
For microphone data ingestion, you do not need to change the default parameters in nicla_vision_ingestion_mic.ino sketch.
  1. 1.
    Then, from your sketch's directory, run the Arduino CLI to compile:
    1
    arduino-cli compile --fqbn arduino:mbed_nicla:nicla_vision --output-dir .
    Copied!
  2. 2.
    Then flash to your Nicla Vision using the Arduino CLI:
    1
    arduino-cli upload --fqbn arduino:mbed_nicla:nicla_vision
    Copied!
Alternatively, if you opened the sketch in Arduino IDE, you can compile and upload the sketch from there.
  1. 1.
    Wait until flashing is complete, and press the RESET button once to launch the new firmware.

3a. Data forwarder (Fusion sensors)

From a command prompt or terminal, run:
1
edge-impulse-data-forwarder
Copied!
This will start a wizard which will ask you to log in, and choose an Edge Impulse project. You will also name your sensor's axes (depending on which sensor you selected in your compiled nicla_vision_ingestion.ino sketch). If you want to switch projects/sensors run the command with --clean. Please refer to the follow table for the names used for each axis corresponding to the type of sensor:
Sensor
Axis names
#define SAMPLE_ACCELEROMETER
accX, accY, accZ
#define SAMPLE_GYROSCOPE
gyrX, gyrY, gyrZ
#define SAMPLE_PROXIMITY
cm
Note: These exact axis names are required for the Edge Impulse Arduino library deployment example applications for the Nicla Vision.

3b. Data forwarder (Microphone)

From a command prompt or terminal, run:
1
edge-impulse-data-forwarder --baud 1000000 --frequency 8000
Copied!
This will start a wizard which will ask you to log in, and choose an Edge Impulse project. You will also name your sensor axes - in case of microphone, you need to enter audio. If you want to switch projects/sensors run the command with --clean. Please refer to the follow table for the names used for each axis corresponding to the type of sensor:
Note: These exact axis name is required for the Edge Impulse Arduino library deployment example application for the Nicla Vision Microphone ingestion.

4. Verifying that the device is connected

That's all! Your device is now connected to Edge Impulse. To verify this, go to your Edge Impulse project, and click Devices. The device will be listed here.
Configuring the data forwarder for the Nicla Vision.
The Nicla Vision Data forwarder in the Devices tab.
With everything set up you can now build your first machine learning model with these tutorials:
Looking to connect different sensors? Use the nicla_vision_ingestion sketch and the Edge Impulse Data forwarder to easily send data from any sensor on the Nicla Vision into your Edge Impulse project.

Deploying back to device

With the impulse designed, trained and verified you can deploy this model back to your Arduino Nicla Vision. This makes the model run without an internet connection, minimizes latency, and runs with minimum power consumption. Edge Impulse can package the complete impulse - including the signal processing code, neural network weights, and classification code - up into a single library that you can run on your development board.
Use the Running your impulse locally: On your Arduino tutorial and select one of the Nicla Vision examples.