2023-02-07 10:00 AM
Sorry for the I'm too stupid to figure this out myself question, but couldn't figure out how to do this myself. In CubeMX Pinout & Configuration under software packs, I can install MEMS support, add a LSM6DSO (and required support elements) using i2c. In the Software Packages I can configure the mems and the LSM6DSO (including the SD0/AD0 pin for LSB of the address).
But, how does one add a second LSM6DSO to the project? Configuring the second slave address looks easy enough, but I need a second sensor instance first. Do I have to manually replicate the generated code used to create the first instance or is there some built-in way to "give me another i2c device with this configuration" option?
Solved! Go to Solution.
2023-02-10 02:31 AM
Hello @JD.1avies ,
Unfortunately, this feature is not supported today.
At the moment only one instance per sensor can be used.
Foued
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.
2023-02-10 02:31 AM
Hello @JD.1avies ,
Unfortunately, this feature is not supported today.
At the moment only one instance per sensor can be used.
Foued
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.
2023-02-10 08:34 AM
Thanks for the reply, so since there's not GUI way to do it, how would one do it in manually? Is there any refence material for doing so?
Would be nice if there was internal support for just "add" another instance which then gets its own handlers. I didn't look too deep, instead I just copied off a "my_lsm6dso.c" from the generated file and made the changes to support a second. Seems incredibly inefficient, but it was a hack to get something working.