LSM6DS33 to work with LSM6DSO driver

Hello Nordic team and fellow developers,

I am working on an adafruit nrf52840 feather sense board, for which i have created a custom DTS file.

I am trying to interface with all the onboard sensors, which one of them is the LSM6DS33. I have noticed there is already a driver in the SDK for the LSM6DSO, which i very similar.

One thing that is not compatible with the existing driver, is the chip id. 

When i set CONFIG_LSMDSO=y for enabling the driver located in \v1.9.1\zephyr\drivers\sensor\lsm6dso, the function: lsm6dso_init_chip() gets called.

This function checks the chip id, which needs to be changed. I am talking about changing:

#define LSM6DSO_ID 0x69 line 173 in \v1.9.1\modules\hal\st\sensor\stmemsc\lsm6dso_STdC\driver\lsd6dso_reg.h
So my question is:

How can i modify the config or use the driver, without altering the SDK and still use the driver with the sensor api?

Thanks in advance

/Mads


 

Parents Reply Children
Related