Skip to main content
Visitor II
July 2, 2024
Question

LIS3MDL - Problem with readings after calibration.

  • July 2, 2024
  • 5 replies
  • 2197 views

We embed lis3mdl on our board that we produce, most of them are perfect, unfortunately there are single pieces where the magnetic north is wrong, the heading is wrong by up to 60-100 degrees. What could be the reason ?

 

Regards.

 

    This topic has been closed for replies.

    5 replies

    Technical Moderator
    July 3, 2024

    Presumably the MEMS had or have mechanical stress that leads to this deviation. Are you sure that you have taken sufficient account of the information in Technical Notes TN0018 and TN1507?

    Regards
    /Peter

    Graduate II
    July 3, 2024

    Did you run some self-tests ?

    We observed something similar a few months ago, and running the self-tests showed us that these components were damaged therefore needed to be replaced.

    TBart.1Author
    Visitor II
    July 3, 2024

    How to run such a self-test?

    Graduate II
    July 3, 2024

    You can find the driver and example there:

    https://github.com/STMicroelectronics/STMems_Standard_C_drivers/tree/master/lis3mdl_STdC

    You'll also need to check the the datasheet (link in the readme).

     

    Don't forget to check the units !

     

    Hope that will help.

     

    Sulian

    TBart.1Author
    Visitor II
    July 3, 2024

    Ok, I'll do a self-test, but is it even possible that every 10-20th this magnetometer would be factory-damaged and not my fault? While following all recommendations from the manuals?

    Graduate II
    July 4, 2024

    Factory-damaged, I don't know, but from transport or welding perhaps, not particularly your fault. Personally, we once had a batch of 10 with 9 defective, we change them and the new ones worked perfectly.

    So that's not impossible.

    I'd be interested in hearing your self-tests results.

    Technical Moderator
    July 4, 2024

    is it even possible that every 10-20th this magnetometer would be factory-damaged?

    Of course, a faulty device ex factory is also possible, but the error rates are in the ppm range.

    So, it is practically impossible to get that much faulty devices, as every single MEMS is thoroughly tested at the factory. If there are failures of this magnitude, it is always due to incorrect handling or insufficient care.

    Regards
    /Peter

     

    Graduate II
    July 12, 2024

    Hi @TBart.1 
    Did you had time to try the self-tests ?