🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Compass and calibration

    FAQS
    2
    5
    12.6k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Q
      quetzal
      last edited by

      Hello,

      I've recently received the m5stack "limited" with battery and mpu9250.
      I want to use mpu9250 to get heading (0 to 360 degres from earth north).

      I've run the sample code "MPU9250BasicAHRS.ino" without much problems, but values are very stranges.
      If my understanding is good, the yaw is the heading. Pitch and roll seem ok but only if I start the m5stack on a plate surface. So I think there is a calibration problem somewhere.
      This sample seem to be based on https://github.com/kriswiner/MPU9250/blob/master/MPU9250BasicAHRS.ino (and the lib too). I think base the lib on the t3 version will be better, but it have to work with the standard version.

      Do you think what is wrong ? Is it possible to calibrate better and to save the calibration ? (or have I a bad interpretation of Yaw ?).

      Thanks !

      1 Reply Last reply Reply Quote 0
      • Q
        quetzal
        last edited by

        Hello,

        Moreover, i'm not sure but I think magnets on the m5stack with mpu9250 is a bad idea (i've removed the ones in my board). So i still not resolved my problem :/

        JJJ 2 Replies Last reply Reply Quote 0
        • JJJ
          JJ @quetzal
          last edited by

          @quetzal
          Hi, there has been some discussion of this here: https://github.com/m5stack/M5Stack/issues/39

          1 Reply Last reply Reply Quote 0
          • JJJ
            JJ @quetzal
            last edited by

            @quetzal Hi Quetzal,

            Below is a link to a high quality article discussing exactly how to calibrate a magnetometer and how this can be applied to the M5Stack to get accurate readings from the mpu9250.

            https://appelsiini.net/2018/calibrate-magnetometer/

            1 Reply Last reply Reply Quote 0
            • Q
              quetzal
              last edited by

              Hello JimiT,

              I will see if it can solve my problem, thanks for your help ! I will follow the github issue.

              Thanks

              1 Reply Last reply Reply Quote 0
              • First post
                Last post