cancel
Showing results for 
Search instead for 
Did you mean: 

Firmware crashing after adding sensor FP-SNS-DATALOG2 Steval-STWINBX1

George_Kryshco
Associate II

Hello everyone,

I’m working on a custom version of the FP-SNS-DATALOG2 firmware and attempting to integrate a new sensor, LSM6DSV320X, which is available on the STEVAL-SensorTile.Box Pro but not on the STEVAL-STWINBX1.

To add support for this sensor, I performed the following changes:

  • Added Drivers/BSP/Components/lsm6dsv320x/lsm6dsv320x_reg.c/.h
  • Integrated corresponding PnPL + App Model .c/.h files
  • Added that sensor task
  • Modified:
    • DatalogAppTask.c/.h
    • App.c/.h
    • sysdebug_conf.h
    • SensorManager_conf.h
    • HardwareDetect.c/.h
  • Updated existing DTM(Device Template Model) from stdatalog-pysdk pnpl module(FP-SNS-DATALOG2-9.json) to include the new sensor
  • Removed ism6hg256x from the build

With these changes, I’m able to start logging using a custom device template, and the sensor appears to work initially. However, the system becomes unreliable after a reset.

Main Issue

The board operates correctly until it is reset. After reset, I encounter multiple faults, including:

  • HardFaults
  • Bus faults
  • Memory management faults
  • Usage faults (forced)
  • Precise data access violations
  • Occasional unaligned access faults

(See attached screenshots for details.)

What I Tried

I suspected a memory issue, so I increased the ThreadX byte pool (TX_BYTE_POOL) from 565 KB to 570 KB, but this did not resolve the problem.

Questions

  • Could this be due to incorrect memory configuration or alignment issues?
  • Is there some required initialization or configuration step I might be missing?
  • Is the system tightly configured for the original onboard sensors in a way that affects adding external ones?

I’ve also attached the project archive with my modifications for reference.

Any insights or suggestions would be greatly appreciated.

Thank you in advance,
George Kryshco

 

George_Kryshco_0-1776248930173.png

George_Kryshco_1-1776249010364.png

George_Kryshco_2-1776249023475.png

George_Kryshco_3-1776249390424.png

George_Kryshco_4-1776249445477.png

George_Kryshco_5-1776249491006.png

George_Kryshco_6-1776251185062.png

 

 

1 REPLY 1
mƎALLEm
ST Employee

Hello,


@George_Kryshco wrote:

Main Issue

The board operates correctly until it is reset. After reset, I encounter multiple faults, including:

  • HardFaults
  • Bus faults
  • Memory management faults
  • Usage faults (forced)
  • Precise data access violations
  • Occasional unaligned access faults

How to debug a HardFault on an Arm® Cortex®-M STM32

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.