cancel
Showing results for 
Search instead for 
Did you mean: 

Questions about how IKS01A3 DataLogTerminal example works

JTomp.1
Associate II

Hi,

I'm using the IKS01A3 board on a P-NUCLEO-WB55 board with the example application IKS01A3 DataLogTerminal.

Some questions:

  • where is the mapping from GPIO numbers (0 through 15) to pin names on the micro (STM32WB55 in QFN68 package)? I have the board schematic which shows port names e.g. PA0, etc. but the example code refers to GPIO numbers. I can't find the mapping from GPIO numbers to pin/port names.
  • I'm trying to see all of the LIS2DW12 sensor data, not just a 1s sample as done in the MX_IKS01A3_DataLogTerminal_Process function in the app_mems.ca file. I can't see where the interrupt service routine reads the sensor and writes it into the IKS01A3_MOTION_SENSOR_Axes_t data structure.

Thanks for helping a newbie!

Jim Tompkins

Halifax, Canada

1 ACCEPTED SOLUTION

Accepted Solutions

Hi Jim @JTomp.1​ ,

sorry, it is the FP-SNS-MOTENVWB1 function pack (not the FP-SENS-MOTENV1), which is dedicated to the P-NUCLEO-WB55 + X-NUCLEO-IKS01A3.

-Eleon

View solution in original post

6 REPLIES 6
Eleon BORLINI
ST Employee

Hi Jim @JTomp.1​ ,

  • to match the GPIO name with the STM32WB55 pin, you can use the STM32CubeMX tool for the uC configuration, where the STM32WB55 default configuration is implemented.0693W000006FIXbQAO.png0693W000006FIXvQAO.png
  • Are you using Unicleo-GUI for the data acquisition? Did you try to use the \Projects\P-NUCLEO-WB55.Nucleo\Applications\MOTENV1 example in the FP-SNS-MOTENV1 firmware function pack, which combines the P-NUCLEO-WB55 board with the IKS01A3 expansion?

Let me know if these suggestion can help your application building.

-Eleon

Hi Eleon,

Thanks for the answer!

I will look in MX for the pin configurations. In the image above, for example, PB0 has signal name = GPIO-Output. The code refers to GPIO0: GPIO15. I was hoping to find a reference somewhere in the code from PB0 to one of the GPIOx names, but could not find this.

I downloaded the FP-SENS-MOTENV1 function pack to try. Under projects, I can't see a reference to STM32WB55. Also, if I start a new project in MX using the P-NUCLEO-WB55 board and try to add embedded software packs using the FP-SENS-MOTENV1 .zip file, it doesn't like the format of the .zip file. Does FP-SENS-MOTENV1 support P-NUCLEO-WB55?

The DataLogTerminal example works, but I would like to modify in as follows for my own application:

  • use only the LIS2DW12 sensor on the IKS01A3. I couldn't see easily which interrupt was used for which sensor. When I disabled all the interrupts listed in MX_GPIO_INIT in main.c, the application still worked! So I'm not clear how the data gets from the sensor into the micro. Is it polled?
  • log all of the LIS2DW12 X, Y and Z data into a circular buffer and then do some processing on it. But I can't see in the code where the LIS2DW ISR grabs the data from the sensor.

Thanks for your help,

Jim

Eleon BORLINI
ST Employee

Hi @JTomp.1​ ,

my suggestion to start from the project in: \Projects\P-NUCLEO-WB55.Nucleo\Applications\MOTENV1\STM32CubeIDE\MOTENV1_IKS01A3_WB55RG, opening it with the STM32CubeIDE or the the IDE you use, instead of from the CubeMX trying to import the firmware package in .zip file format.

On this project, the LIS2DW12 is implemented and you can disable all the other sensors if you need.

As regard the DataLogTerminal example, yes, the data acquisition from the sensor is in polling mode: if you want to trigger it you should insert the function below in a loop as defined in lis2dw12_read_data_single.c:

int32_t LIS2DW12_ACC_GetAxes(LIS2DW12_Object_t *pObj, LIS2DW12_Axes_t *Acceleration)

-Eleon

0693W000006FTnBQAW.pngHi Eleon,

My STM32Cube_FW_WB_V1.9.0 installation doesn't include the MOTENV1 application folder. See the image above.

My installation of the MOTENV1 function pack doesn't have a subfolder for the P-NUCLEO-WB55.

Do I need to install something else?

I will take a look at the read_data_single C file.

Thanks,

Jim

Hi Jim @JTomp.1​ ,

sorry, it is the FP-SNS-MOTENVWB1 function pack (not the FP-SENS-MOTENV1), which is dedicated to the P-NUCLEO-WB55 + X-NUCLEO-IKS01A3.

-Eleon

Thanks Eleon!
Best regards,
Jim