Skip to main content
Associate
June 11, 2026
Question

Configuration of pedometer for Regression Tool

  • June 11, 2026
  • 5 replies
  • 60 views

Hello, 
 

I’m having some problems with regression tool configuration for pedometer.

I'm having some issues with the regression tool configuration for the pedometer. I’m using the STEVAL-MKI109D and STEVAL-MKI238A with MEMs Studio tool (FW: 2.10.2).

First, I set up the sensor using 'Easy Configuration' and changed the Full Scale to ±4g, the Output Data Rate (ODR) to 25 Hz, enabled High-Performance mode, and set the bandwidth to ODR/2.

Quick setup configuration

First, I recorded and saved different walking types (slow, normal, and fast, with 20 steps each) using the 'Save to file' tab. This only saves the Accelerometer data.

Next, I opened the Pedometer tab and ran the regression tool using these three files (fast_steps20.txt, normal_steps20.txt, and slow_steps20.txt). I selected the LIS2DUX12 sensor and tested it with the default settings for error type (Mean) and complexity level (50%). The generated results are in the attached zip file.

After that, I went to the debug page to test the results. I loaded the pedometer.json configuration and selected the normal_steps20.txt log file. However, the following warning appeared: 'Accelerometer power mode detected is power down!'.

I tried modifying the JSON configuration file to enable high-power mode. Although the warning disappeared, the debug results were still incorrect.

How can I fix this?


Thanks, 
GoncaloS

5 replies

Federica Bossi
ST Technical Moderator
June 12, 2026

Hi ​@GoncaloS ,

You are right tag 0x1B is intended for MLC filter FIFO output on LSM6DSV16X. Please consider that enabling only MLC_FILTER_FEATURE_FIFO_EN is not sufficient for filter outputs. In addition to the global FIFO enable bits, each individual filter must also be enabled at configuration-generation level by adding:

-MLC_enable_filters_in_FIFO

in the custom options under “Config generation” using the “...” button into MLC page.
Also note that MLC result entries are written to FIFO only when the class changes.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
GoncaloSAuthor
Associate
June 12, 2026

Hi @Federica Bossi,

Thanks for your reply. So, do I have to use the MLC feature instead of the Pedometer function to train my model to identify steps? I didn't understand very well what you meant.

Regards,
GoncaloS

GoncaloSAuthor
Associate
June 12, 2026

Hi ​@Federica Bossi

Following up on my previous response, since I can only identify states with the MLC and cannot count steps directly, my plan is to use the configuration from the regression tool for the 3 walking profiles (slow, normal, and fast) to dynamically adjust the pedometer parameters. This way, I can accurately count steps at different speeds.

Regards, 
GoncaloS

Federica Bossi
ST Technical Moderator
June 12, 2026

Hi ​@GoncaloS ,

I apologize for the confusion; due to an error, my previous response was intended for another post. We are currently working on your request, and I will get back to you shortly with an update.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Federica Bossi
ST Technical Moderator
June 12, 2026

Hi ​@GoncaloS ,

we reviewed your configuration.

Regression tool provides only set of parameters to optimize pedometer steps detection and the output configuration will not enable pedometer and power accelerometer on. This is why the debug tool is triggering the error you shared. Therefore you will need to add instructions to enable pedometer and power on sensor at the end of your configuration file (see last 4 instructions).

 

  While reviewing the output file shared, we identified an issue with this specific sensor related to  missing embedded function enable request and related mandatory delay of 5 ms and  following value written for register 0x02 should be "0x01" instead of "0x11". 

 

We are currently working on integrating these fixes into next version of MEMS Studio.

Performing the debug of this fixed configuration on "fast_steps20.txt" you will get 18 steps according to the regression_tool.config file.
 

 

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Federica Bossi
ST Technical Moderator
June 12, 2026

Here is the json

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
GoncaloSAuthor
Associate
June 12, 2026

Hi ​@Federica Bossi,
 

Thanks, now it’s working! I have one more question: Can I include different walking patterns in the same regression?

In my case, I want to use different patterns (slow, normal, and fast walk) to generate a single algorithm capable of counting steps across different scenarios. How can I achieve this? Is it possible? I have already tested combining multiple and different datasets, but the steps are only being counted well for some of the log files.

Regards,
GoncaloS