Added ability to set acceleration filter bandwidth independently from gyro
Renamed acceleration bandwidth frequencies to reflect actual values
Fix: reset temporary settings for calibrations
Added get functions for all scaling parameters and counts
There are no breaking changes. The function setDlpfBandwidth still modifies both gyro and accel bandwidth in the exact same as before. If someone wants a different accel filter bandwidth, the function setDlpfAccBandwidth must be called AFTER setDlpfBandwidth
For the calibrateX() methods, the comments in MPU9250.cpp suggest that the sensor ranges, dlpf bandwidth, and srd are restored to previous values after calibration. However, the functions setGyroRange, setSrd etc. modify the internal private member so the original setting is lost. This fixes the issue by saving the parameters before setting them for calibration.
I added getX() functions so that it's easy to externally serialize and transmit 16-bit counts then transform to physical units on host given all necessary scaling information.
There are no breaking changes. The function
setDlpfBandwidth
still modifies both gyro and accel bandwidth in the exact same as before. If someone wants a different accel filter bandwidth, the functionsetDlpfAccBandwidth
must be called AFTERsetDlpfBandwidth
For the
calibrateX()
methods, the comments in MPU9250.cpp suggest that the sensor ranges, dlpf bandwidth, and srd are restored to previous values after calibration. However, the functionssetGyroRange
,setSrd
etc. modify the internal private member so the original setting is lost. This fixes the issue by saving the parameters before setting them for calibration.I added
getX()
functions so that it's easy to externally serialize and transmit 16-bit counts then transform to physical units on host given all necessary scaling information.