cancel
Showing results for 
Search instead for 
Did you mean: 

Motion Active Time Library application and functions in X-CUBE-MEMS1

LauraCx
ST Employee

Motion Active Time Library application and functions in X-CUBE-MEMS1

1. Motion Active Time Library

In some real cases, it is important to know in real-time how long an activity lasts, and if the activity is running in a particular moment.

MotionAT  matches the target, being a middleware library that combines results from activity recognition for wrist, motion intensity detection and pedometer for wrist algorithms. It directly provides real-time information about the number of active seconds (that is how long the user was active with the wearable device as a smart watch).

The library acquires data from the accelerometer and provides information about the number of active seconds (how long the user was active) with the wearable device. Recognition is based on accelerometer data only, and requires accelerometer data sampling frequency of 50 Hz.
1603.png
 

2. Calibration Algorithm

The library acquires data from the accelerometer and provides information about the number of active seconds (how long the user was active) with the wearable device.
 

The central functionthat executes the AT algorithm is the following one:

void MotionAT_Update(MAT_input_t *data_in, MAT_output_t *data_out)

where *data_in parameter is a pointer to a structure with input data of type MAT_input_t (including AccX which is the accelerometer sensor value in X axis in g; AccY which is the accelerometer sensor value in Y axis in g and AccZ which is the accelerometer sensor value in Z axis in g); *data_out parameter is a pointer to a structure with output data (that is active equal to 1 if the user was active during the last algorithm run, otherwise it is equal to 0)

See below an example of the output of MotionAT library in Unicleo-GUI framework :fast_down_button:
1605.png
 

3. Resources

User Manual 2349  Getting started with MotionAT active time library in X-CUBE-MEMS1 expansion for STM32Cube
 
Version history
Last update:
‎2021-10-22 02:44 AM
Updated by: