05-07-2021 11:39 AM
Hi,
The BMA456 datasheet notes that a temperature measure of 0x80 corresponds to an invalid data. I believe this happens in the case the temperature is read twice during the 1.28s update period. The library does not handle this case as an error but instead returns a temperature of -105 deg C (if degree celsius range was asked).
I suggest to return a specific error for this case so that the user of the lib can try reading the temperature a bit later.
Thanks,
Solved! Go to Solution.
05-07-2021 07:26 PM
Hi,
Thanks for your feedback. We will look into the BMA456 API code on the Github to try to reproduce the issue. If the issue is confirmed, then we will update the API code on the Github.
Thanks.
05-10-2021 03:40 PM
Hi,
Sorry that we could not reproduce the issue. We don't see wrong temperature values if we read the temperature data register very fast.
Could you please show us the link of the BMA4 lib that you are using? It would be great if you can provide a piece of your code where the error occurs.
Thanks.
06-08-2021 11:20 AM
Hi, sorry for the delay I didn't get notified of a reply.
I am using the latest version of the source and function bma4_get_temperature().
I'm surprised you can't reproduce the problem it is specifically described in the BMA456 datasheet, the behaviour and value I read matches the datasheet and there is no code to handle that specific value in bma4_get_temperature().