Acquiring data from Lis2dh

Hello.

I'm using a lis2dh in the nrf52840 dev kit and Zephyr on VScode. Using the function sensor_channel_get and the struct sensor_value I need 8 bytes to read each accelerometer axis. Is it possible or there is any function to acquire data from this accelerometer using only 2 bytes?

Thanks.

  • Hello,

    I am not sure I understand what you mean by "function to acquire data from this accelerometer using only 2 bytes?"

    Are you saying that you are now able to read the accellerometer data, but that you receive 8 bytes per axis? And you only want two bytes? If so, can you please share some code on how you are currently reading the accelerometer? And I am not sure whether it is possible "to aquir data from this accelerometer using only 2 bytes". Did you find somewhere saying this is possible? And what does it mean? Perhaps you want to strip down the data (less accurate, but only 2 bytes?)

    Best regards,

    Edvin

Related