# Remove gravity acceleration on the MPU6050

**URL:** <https://forum.arduino.cc/t/remove-gravity-acceleration-on-the-mpu6050/672780>\
**Category:** Programming\
**Created:** [September 1, 2020, 4:41pm UTC](https://forum.arduino.cc/t/remove-gravity-acceleration-on-the-mpu6050/672780 "2020-09-01T16:41:23Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![darlandc1998](https://avatars.discourse-cdn.com/v4/letter/d/2bfe46/32.png) [@darlandc1998](https://forum.arduino.cc/u/darlandc1998)\
**Post date:** [September 1, 2020, 4:41pm UTC](https://forum.arduino.cc/t/remove-gravity-acceleration-on-the-mpu6050/672780/1 "2020-09-01T16:41:23Z")

</div>

Hello, I'm creating a bracelet that contains an MPU6050 sensor and a Wemos D1 Mini card. I need to get the acceleration of the sensor in m / s2, and that I already did, but I would like to disregard the acceleration of gravity (9.8m / s2), and as it is a bracelet, the acceleration of gravity varies according to the movement of the pulse. Is there a library that can remove this acceleration to get the real value of the acceleration? Or is there a mathematical model for this?

Thanks in advance 🙂

---

<div class="post-metadata">

**Author:** ![pmagowan](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@pmagowan](https://forum.arduino.cc/u/pmagowan)\
**Post date:** [September 1, 2020, 5:18pm UTC](https://forum.arduino.cc/t/remove-gravity-acceleration-on-the-mpu6050/672780/2 "2020-09-01T17:18:49Z")

</div>

I don't follow. What has gravity got to do with the 'real' acceleration? Acceleration is the delta of velocity/time IIRC and this will be irrespective of the force causing the acceleration. what is it you are trying to achieve in a wider sense. try and avoid xy problems

---

<div class="post-metadata">

**Author:** ![johnwasser](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/johnwasser/32/214270_2.png) [@johnwasser](https://forum.arduino.cc/u/johnwasser)\
**Post date:** [September 2, 2020, 2:57pm UTC](https://forum.arduino.cc/t/remove-gravity-acceleration-on-the-mpu6050/672780/3 "2020-09-02T14:57:15Z")

</div>

To subtract the gravity vector you first have to measure the gravity vector. You can do that with the accelerometer if it isn't being accelerated by anything other than gravity. If a force is applied to move the accelerometer you can no longer determine what part of the acceleration is gravity and what part is caused by an outside force.

What are you trying to learn from the acceleration? Absolute position? That will drift very quickly. Gestures? For that, you can use the change in acceleration rather than absolute acceleration.

---

<div class="post-metadata">

**Author:** ![anon57585045](https://avatars.discourse-cdn.com/v4/letter/a/ed8c4c/32.png) [@anon57585045](https://forum.arduino.cc/u/anon57585045)\
**Post date:** [September 2, 2020, 5:43pm UTC](https://forum.arduino.cc/t/remove-gravity-acceleration-on-the-mpu6050/672780/4 "2020-09-02T17:43:57Z")

</div>

Sounds like you are trying to measure the pulse by physical vibration (hence acceleration). I think the physical pulse doesn't produce much acceleration. Have you run any tests, just to look at raw data? If it doesn't work at all, it's kind of pointless to charge ahead with solutions since there won't be a problem.

Once you actually see something that looks like a pulse in your data, you can worry about identifying and compensation for other factors like gravity (which BTW varies all the time on a bracelet as it is seldom in the same orientation).

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [May 6, 2021, 12:44am UTC](https://forum.arduino.cc/t/remove-gravity-acceleration-on-the-mpu6050/672780/5 "2021-05-06T00:44:02Z")

</div>

Closed on May 6, 2021, 12:44am UTC


