I see a few posts on this forum about changing the dynamic range of my sensor, BHI260AP, however I do not understand how to actually implement this change.
This is a quote from one of the links below:
You could refer the following code to modify sensor range.
In bhi2.c file, bhy2_set_virt_sensor_range() function support to set sensor range.
int8_t bhy2_set_virt_sensor_range(uint8_t sensor_id, uint16_t range, struct bhy2_dev *dev)
To set sensor range, you could call bhy2_set_virt_sensor_range() in begin().
-- I cannot find a BHI2.c file, Does this mean the BHY2.c file?
-- I found the refered function but its within the BHY2.c file. I also am not sure what to modify or how to call the function. SEE SCREENSHOT
I also found the sensortec file and where the function is being called from. SEE SCREENSHOT
I feel quite dumb, but can someone explain this better to me?
https://www.bosch-sensortec.com/media/boschsensortec/downloads/datasheets/bst-bhi260ap-ds000.pdf (GO TO PAGE 149 for dynamic ranges)
The previous posts discussed how to modify the measurement range on Nicla Sense ME board, the software environment is Arduino. If you install the Arduino code of the Nicla Sense ME board, you will see bhi2. c in this directory "C:\Users\you name\Documents\Arduino\libraries\Arduino_BHY2\src\bosch" on you PC.
For information of Nicla Sense ME, you could find it from here: https://docs.arduino.cc/hardware/nicla-sense-me
Generally, the acceleration range is initialized once rather than set dynamically. Cou we know background information from you:
1. Could we know your current hardware and software environment?
2. What is your application and need to modify the acceleration dynamic range?