Deployed gesture recognizer |
This repository is a companion to the dsPIC33CK DSC Gesture Recognition with MPLAB ML Model Builder tutorial on the MPLAB Machine Learning Development Suite User's Guide. It contains the firmware to classify a few different motion gestures on a dsPIC33CK CURIOSITY DEVELOPMENT BOARD with the Mikroe IMU2 click board.
The supported gestures (shown in the video above) are:
- Wave
- Up-down
- Wheel
- Idle
- dsPIC33CK CURIOSITY DEVELOPMENT BOARD (DM330030)
- IMU 2 click board (https://www.mikroe.com/6dof-imu-2-click)
- dSPIC33CK Product Family Page
The data used for the development of this application can be found in dataset folder of this repo. It consists of 3-axis IMU recordings taken with the dsPIC33CK CURIOSITY DEVELOPMENT BOARD + IMU 2 click board. For further description of the application setup, see the dsPIC33CK DSC Gesture Recognition with MPLAB ML Model Builder tutorial.
A binary build of the data logging firmware used in the data collection for this project can be found in the binaries folder of this repo. To build data logging firmware for different sensor configurations, visit the (https://github.com/MicrochipTech/ml-dsPIC33CK-Curiosity-IMU-Data-Logger) Repository.
The sensor configuration used in this demo is summarized in the table below. These settings can be changed by modifying app_config.h.
IMU Sensor | Axes | Sampling Rate | Accelerometer Range | |
---|---|---|---|---|
Bosch BMI160 | Ax, Ay, Az, | 100Hz | 2G |
The firmware can be thought of as running in one of four as reflected by the onboard LEDs and described in the table below:
State | LED Behavior | Description |
---|---|---|
Error | LED3 (RED) LED lit | Fatal error. (Do you have the correct sensor plugged in?). |
Buffer Overflow | LED1 and LED3 (RED) LED lit for 5 seconds | Processing is not able to keep up with real-time; data buffer has been reset. |
Recognized Gesture | LED3 (GREEN) LED flashing according to gesture class except Idle gesture class LED3(Green) LED lit only | One of the known gestures has been detected. |
In addition, the firmware also prints the classification output for each inference over the UART port. To read the UART port output, use the terminal in MPLAB Data Visualizer, like shown in video above, with the following settings:
- Baudrate 38400
- Data bits 8
- Stop bits 1
- Parity None