LSM9DS0 Magnetometer not working

Hello,
I have a LSM9DS0 sensor that I just recently purchased. Only the accelerometer at the 0x1E address is working. I can’t get the magnetormeter to work. I can write to certain registers on it but I can’t write to register 25 to set the guass and I can’t read anything from the 0x08 and 0x09 registers. I’m using a Raspberry Pi with the pi4j library and an i2c shield that I purchased as well. When I do a i2cdump on the 0x1E address I can see that register 25 isn’t being written to and there’s no output data in the 0x08 and 0x09 registers. I’m not sure if I’m doing something wrong or if the sensor is bad. I can write to other registers for the magnetometer. Any help or suggestions would be greatly appreciated.

Thanks,
Craig

Hi Craig,
The sensor has been upgraded with LSM9DS1.
I will recommend checking this datasheet.

When you scan the i2c bus does the board come up with two i2c addresses?
Thanks

That did it! Thank you very much!!! :grin:

Final question…I hope (lol)…what’s the difference between OUT_X_L_M and OUT_X_H_M?

Thanks,
Craig

here is the breakdown – OUT_X_L_M
OUT — output
X — x- axis
L — LSB
M — Magnetometer/Magnetic field
OUT_X_L_M
OUT — output
X — x- axis
H— MSB
M — Magnetometer/Magnetic field
Thanks

I need help on this issue too and I’m not as experienced as the original poster. I have the LSM9DS1 and by trial and error I’ve got some things working but it’s frustrating. One issue I have is the addresses… the code in the samples here use 6A and 1E. On my system the two showing up in i2cdetect are 6A and 1C but substituting 1C for 1E in the code does not work. Can you update the code sample for the upgraded LSM9DS1 please? Trying to figure it out from the datasheet has been difficult.

Thanks,
Paul