cancel
Showing results for 
Search instead for 
Did you mean: 

LIS3MDL hard iron offset registers

onderdelen
Associate III

 

Hi,

 

the datasheet for the LIS3ML does not mention any dedicated offset registers that can be used to deduct an offset vector from the measurements:

Schermafbeelding 2023-10-16 om 14.59.54.png

 However, when I view the LIS3MDL app note, it says they are there:

Schermafbeelding 2023-10-16 om 15.01.33.png

 The app note points to 05h through to 0ah. According to the datasheet, these registers are reserved.

I tried them out and wrote zero values to 05h ... 0ah . After that, my X axis reading become really messed up!

 

Is the app note wrong? or the datasheet? Please indicate what can be done with the offset, apart from deducting the offset vector in the application in the microcontroller.

 

Thanks,

 

Ewout Boks

2 REPLIES 2
Federica Bossi
ST Employee

Hi @onderdelen ,

Sorry for this confusion, you can refer to the Application Note.

I don't know why those registers are reserved in the DS but thank you for notice me this error, we will release a new DS version soon.

If my reply answered your question, please click on Accept as Solution at the bottom of this post. This will help other users with the same issue to find the answer faster!

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
onderdelen
Associate III

Hello,

 

thank you for your explanation.

unfortunately, your answer does not corroborate my findings.

When I write values to the offset registers from the app note (address 0x5 and up, 2s-complement 16 bit data x,y,z) and then read back from the LIS3ML, I get very different values. See my screenshot : nieuweKorrektie = expected values, huidigeKorrektie = values read from the chip.  As you can see, these do not mach as expected.

Please tell me if these registers can be used at all.

with best regards,

 

Ewout Boks