How the MPU 6050 Works | High Level MEMS Overview

In this tutorial, I will explain how the MPU6050 accelerometer gives us acceleration values at a high level. I will overview MEMS concepts that are critical to accelerometers. The takeaway is that you will have a high level of knowledge of how the MPU gives us actual acceleration values. If you have not already, please subscribe to my Youtube Channel, especially if you learned something from this article. 

What is the MPU 6050?

    • The MPU6050 is a MEMS (microelectromechanical) accelerometer. That is, it utilizes properties of mechanics and electricity to output an acceleration value. The two main properties it utilizes are inertia and capacitance. 
    • Pros of the MEMS Accelerometers in general:
      • Small
      • Cheap
      • Low Power
      • Economy of scale, can be manufactured in large batches
    • Cons of MEMS Accelerometers in general:
      • Generally less accurate than Piezoresistive or Piezoelectric based accelerometers.
      • Designing MEMS can be challenging because components are put together on the micro-scale (microns). Here is the MPU6050 on the micron level taken with an electron microscope. 

    Created by TDK Invensense, a California-based company founded in 2003

    How does it give us Linear Acceleration?

    • The premise behind the whole device is the "Proof Mass on a Spring". A system by which a proof mass can move freely along a given axis due to an attachment on a spring of known properties.  As the MPU6050 accelerates the proof mass begins to move along its given axis. 
    • Additionally, within the system there is a fixed comb of electrodes. As the proof mass moves, the distance between the proof mass and the electrodes begins to change, producing a change in capacitance that can be measured and translated into acceleration via analog-to-digital techniques. A representation of this concept is shown here:

      We can see in the diagram above that the electrodes in yellow are fixed, and as the proof mass (light blue) begins to move it changes the values of C1 and C2. This is the basis of the acceleration values we are seeing in the MPU6050. We can see similar structures in the micron-level diagram of the MPU6050. Note that you need at least three of these mechanisms to measure all three degrees of linear acceleration. 

      How does it give us Angular Acceleration Values?

      • Getting the three values of angular acceleration works similarly, in that it also uses a proof mass on a spring to induce changes in capacitance, except it also incorporates the forces from the Coriolis Effect. 
      • What is the Coriolis Effect? At a high level, when a given object is moving along an axis with a given velocity and with an angular rate applied to the object, we see a perpendicular force produced on the object. This is the Coriolis Effect.

        In the diagram we see that the Coriolis force is in yellow because we have a velocity in the positive x-direction and a counterclockwise angular rate on the Z-axis. This type of force is utilized on the proof masses in the gyroscope of the MPU6050 to generate predictable displacements between the proof mass and the electrodes.

        • The proof masses on the MPU are set up similarly to this:

        Two adjacent masses are set to oscillate opposite one another, meaning they have velocities along the same axis but in the opposite direction. As the MPU rotates counterclockwise on the Z-axis (it can also rotate around other axes as well) we know from the nature of the Coriolis Effect that the masses will move in the opposite direction. This movement induces a change in capacitance with the electrodes (electrodes not shown in this diagram). Once again, it is the change in capacitance that is translated to the acceleration we get from the MPU6050. 

        • To be more specific there are actually four proof masses on the gyroscope for the MPU6050. Four proof masses are required to capture all three axes of angular rotation (roll, pitch, and yaw):

        As the MPU is powered on these masses begin to oscillate at a known frequency, and thus any rotation of the MPU alters the movement of these proof masses relative to one another, altering the capacitance between the electrodes! 

        Conclusion:

        Hope you had some takeaways after reading that high-level overview. The MPU6050 and MEMS accelerometers in general are marvelous pieces of engineering. Pretty amazing how all of this is captured on the micro-scale and how there is an incredible consistency when using such sensors. I would like to thank the sources I used to make this blog and youtube video:

        https://www.siliconsensing.com/technology/mems-accelerometers/

        https://lastminuteengineers.com/mpu6050-accel-gyro-arduino-tutorial/

        https://mjwhite8119.github.io/Robots/mpu6050

        https://circuitdigest.com/microcontroller-projects/interfacing-mpu6050-module-with-arduino#:~:text=How%20does%20MPU6050%20Module%20Work,of%20a%20system%20or%20object

        Create a free account to access full content.

        All access to code and resources on ShillehTek.

        Signup Now

        Already a member? Sign In

        Explore More on Our Blog

        Build a Real-Time Azure IoT Sensor Pipeline with Raspberry Pi Pico W + BME280

        Build a Real-Time Azure IoT Sensor Pipeline with Raspberry Pi Pico W + BME280

        How to send live environmental sensor data to Azure IoT Hub and visualize it in Azure Data Explorer.

        How to Connect an Arduino Sensor to ROS 2 on a Raspberry Pi

        How to Connect an Arduino Sensor to ROS 2 on a Raspberry Pi

        Learn how to connect a BME280 sensor to an Arduino and publish real-time sensor data into ROS...

        How to Install ROS 2 Humble on Raspberry Pi (Ubuntu 22.04.5 LTS)

        How to Install ROS 2 Humble on Raspberry Pi (Ubuntu 22.04.5 LTS)

        Learn how to install ROS 2 Humble on a Raspberry Pi 4B running Ubuntu 22.04.5 LTS. This step-by-step guide walks...

        Part 5: Building a Wi-Fi Control Interface for Remote Control Robot

        Part 5: Building a Wi-Fi Control Interface for Remote Control Robot

        Part 4: Adding Obstacle Detection - Raspberry Pi Pico W Robotics Course

        Part 4: Adding Obstacle Detection - Raspberry Pi Pico W Robotics Course

        Part 3: Motor Control Programming - Raspberry Pi Pico W Robotics Course

        Part 3: Motor Control Programming - Raspberry Pi Pico W Robotics Course

        Part 2: Robot Assembly - Raspberry Pi Pico W Robotics Course

        Part 2: Robot Assembly - Raspberry Pi Pico W Robotics Course

        Build a Wi-Fi-Controlled Obstacle-Avoidance Robot with Raspberry Pi Pico W

        Build a Wi-Fi-Controlled Obstacle-Avoidance Robot with Raspberry Pi Pico W

        Learn how to build a remote-control robot using the Raspberry Pi Pico W and a few simple hardware components. This...

        Simple Guide: Build a Reverse Geolocator with Raspberry Pi Pico W and GPS Module

        Simple Guide: Build a Reverse Geolocator with Raspberry Pi Pico W and GPS Module

        Reverse Geolocator Tutorial with Raspberry Pi Pico W and GPS Module

        Learn how to create a reverse...

        LoRa and Raspberry Pi Pico W: Building a Sender-Receiver Communication System

        LoRa and Raspberry Pi Pico W: Building a Sender-Receiver Communication System

        function toggleAuthorBio() { var bio = document.getElementById('authorBio'); var button = document.querySelector('.toggle-button'); if (bio.style.display === 'none') { bio.style.display = 'block'; button.textContent = '▼ About this Author'; // Using Unicode character directly button.classList.add('expanded'); } else { bio.style.display = 'none'; button.textContent = '▶ About this Author'; // Using Unicode character directly button.classList.remove('expanded'); } }