I am using the BMM150 Magnetometer. The datasheet does not contain any information regarding the addresses of the calibration values that need to be read from the device to compensate the magnetometer output. These address reads can be deducted from the GitHub project, but it is still lacking a description of what each parameter is. Is there any application note or further documentation explaining this?
Also would like to know why the datasheet states that the max range in the z-axis is +-2500uT but it gets saturated to +-2048uT when using the int16_t format compensation? I assume this will be clearer once I have more information regarding the calibration/compensation parameters.
Solved! Go to Solution.
Thank you for the clarification regarding the remnant magnetic field.
Regarding the output, I think there was a miscommunication. So let me try to explain better.
The maximum magnetic field output in the z-axis is specified as +-2500uT in the datasheet.
I am using the provided API to scale the raw output to uT values. When looking at the output provided by the API, a magnetic field value of 2500uT would be represented by a integer output of 2500uT * 16 LSB/uT = 40000. So when using the int16_t formatting, this output would not be possible as int16_t can only go up to +32768. I assume this is why the API saturates the output to 32768 in software when using the int16_t formatting.
However, when using the suggested int32 formatting (from previous PDF), the output can go a lot higher, and it seems the magnetic field output on the z-axis is not capped at 2500uT by the hardware, as a magnetic field output (output of API) of way more than 2500uT is read from device if such a field is induced onto the device.
So does the ouput become invalid once it provides a magnetic field output of more than 2500uT in the z-axis? Or just non-linear? Why is the datasheet maximum specified as +-2500uT when the HW can give much higher magnetic field readings? I assume there must be a reason for this?
Thank you in advance
I just used my eval. board and BMI270 shuttle board that has BMM150 installed. From the Windows GUI SW plot below, it can be seen that BMM150 z axis data (in red color) doesn't go beyond +/-2500uT when I place a strong magnet nearby. After I remove the strong magnet, BMM150 goes back to normal immediately. By the way, the GUI SW uses BMM150 API/driver on the Github.
Therefore, in theory when external magnet field is beyond BMM150 z axis +/-2500uT range, BMM150 z axis raw data should be fixed or clamped for saturation. However, if BMM150 z axis still outputs raw data when the external magnetic field is beyond +/-2500uT range and the API/driver still outputs values that are outside of +/-2500uT range, then BMM150 is still working but the performance is not guaranteed because each BMM150 is calibrated, trimmed and tested under +/-2500uT range in Bosch factory.