Questions tagged [mpu6050]

The MPU6050 is a Motion and Position sensor device that operates on an I2C bus. Importantly it is a 3.3 Volt device that is popularly used to provide 6-axis information with other devices and not just the Raspberry Pi - so connection of modules incorporating it may need special attention/configuration to work on the RPi.

Filter by
Sorted by
Tagged with
0 votes
0 answers
27 views

MPU6050 on I2C is intermittently connected

I have several MPU6050 that will sometime show up in 'sudo i2cdetect -y 1' as 68. When it is there my python code that reads them works. Then randomly the code will fail to see the sensor, and when ...
user avatar
-1 votes
1 answer
77 views

Handling computer mouse pointer with MPU6050 sensor

I am a student and want to make a project where the computer mouse pointer can be controlled via the MPU6050 sensors. So far I have calculated the below things. pitch and roll with accelerometer data: ...
user avatar
  • 1
1 vote
1 answer
22 views

Seperate GPIO pin outputs influencing sensor readings

I'm controlling a Nema 17 stepper motor with an L298n driver via BCM pins 5, 6, 26, 25. Basically, all I'm doing is alternating them between HIGH and LOW. Alongside, I'm reading the acceleration ...
user avatar
  • 121
0 votes
0 answers
285 views

Python I2C error with SMBus and GY-521 (MPU6050), bytes omitted resulting in crash

I am using an GY521 (MPU6050) to test the I2C interface. I am able to read data from it, but sometimes, randomly, the python interpreter would crash: IOError: [Errno 121] Remote I/O error. I have used ...
user avatar
  • 1
0 votes
0 answers
189 views

How to read from MPU6050s FIFO buffer and light sensor simultaneously

I am facing the problem that I cannot read acceleration values of MPU6050s FIFO buffer and a signal from a light sensor at the same time properly. First of all my setup consists of a RasPi 2B where I ...
user avatar
  • 101
0 votes
2 answers
355 views

MPU6050 data logging start and stop on button press

I would really appreciate if anyone could give an advice or directions on how to start and stop data logging for accelerometer MPU6050 with a button press. So far I have a script that I start manually ...
user avatar
1 vote
3 answers
2k views

Self-balancing robot using Raspberry 3b+

I have built a self balancing robot using raspberry pi 3b+. I am not able to reduce the response time. Hence, the robot doesn't balance properly. I am using MPU 6050, 150rpm 12V DC motor. I checked ...
user avatar
1 vote
1 answer
375 views

Rasberry with MPU6050 detects strange peaks in acceleration and gyroscope measurements

I am setting up the MPU 6050 with Raspberry 3b + for measuring acceleration and gyroscope. I made some tests with the sensor MPU 6050 at rest (just on the table, without motion). The measurements ...
user avatar
-1 votes
1 answer
1k views

MPU 6050 Accelorometer Gyroscope code is giving me an angle of 75 degrees when it's suppose to be 90 degrees

I used a bubble level and Angle apps to verify that my MPU 6050 is actually rotated 90 degrees. Even so, my code tells me that the MPU 6050 is rotated ~75 degrees when it is in fact rotated around 90 ...
user avatar
0 votes
1 answer
3k views

OSError: [Errno 121] Remote I/O error or pigpio.error: 'I2C read failed' on MPU6050

So I use MPU6050 to get acceleration from stepper motor linear rail movement(steper motor working in thread, I use pigpio for the motor) by make the MPU6050 can work on threading and it can show data ...
user avatar
0 votes
1 answer
782 views

Raspberry Pi not detecting MPU6050 with i2cdetect

I am trying to connect my GY-521 MPU6050 to my Raspberry Pi Zero W using I2C detect but I'm unable to find the MPU6050 on the table. The results using i2cdetect: pi@raspberrypi:~ $ sudo i2cdetect -...
user avatar
0 votes
1 answer
1k views

Using the HMC5883L on the GY87

This was touched on in this question, but I was unable to get the solution to work: (Not all devices that are connection via I2C are showing) I have a GY-87 multi-sensor module and can get the IMU (...
user avatar
  • 1
0 votes
2 answers
598 views

Raspberry Pi Detects I2C Device Sometimes

I have my MPU-92/65 connected to my Raspberry Pi and it's sometimes detected but not always. $ i2cdetect -y 1 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -...
user avatar
  • 133
2 votes
1 answer
6k views

Change I2C Pins on Raspberry Pi

On a RPi 3, default SDA-I2C and SCL-I2C are assigned to pins 3 and 5 (same as GPIO02 and GPIO03). Is possible to change to another pins? How can I do this?
user avatar
0 votes
0 answers
772 views

Wireless Gyro/Accelerometer Sensors for Raspberry Pi

Is there a way to have a wireless gyro/accelerometer sensor connected to Raspberry Pi? Have worked with single MPU-6050 in the past. Was wondering if there was a way to have a wireless sensor instead....
user avatar
5 votes
1 answer
2k views

GY-521 module / MPU-6050 3x Accelerometer not detected by i2cdetect

I got this GY-521 module (https://www.aliexpress.com/item/MPU-6050-3-Axis-gyroscope-acce-lerometer-module-3V-5V-compatible-For-Arduino/2035920870.html?spm=2114.13010608.0.0.pRpLS4) and no matter what ...
user avatar
0 votes
1 answer
1k views

MPU6050: Two sensors receiving same data

I am using the Raspberry Pi 3 Model B to read in two MPU6050 sensors at the same time. I faced some initial problems in setting up everything but now I am able to read in data relatively fast. My ...
user avatar
0 votes
1 answer
732 views

How many i2c buses?

My project involves talking to 16 IMU's at once. I can do 2 MPU6050 on one bus because of addressing, but I pretty much need 400kbps for throughput. I was looking over the pigpio library to see if I ...
user avatar
0 votes
1 answer
1k views

Error when execute sudo vi /etc/modules

I am following this tutorial I want to enable I2C feature on Raspi2. I need to write some line on modules.conf (.conf ? I don't remember the extension). But executing sudo vi /etc/modules on ...
user avatar
4 votes
2 answers
4k views

MPU6050 Python Library

I would like to use my MPU6050 gyro/accelerometer in some projects but I can't find a good library. I would prefer it to be in python but can deal with C++. I want something where I can do a simple ...
user avatar
  • 2,090
2 votes
0 answers
615 views

I2C and camera issues

Is there any known issue by using I2C components and the RPi Camera at the same time? I am using: Raspberry Pi B+, running Raspbian (updated and upgraded to the latest versions) MPU6050 3 Axis ...
user avatar
2 votes
1 answer
676 views

Not all devices that are connection via I2C are showing

I have linked this chip to my raspberry pi. I used these instructions to do it then installed everything I was told to install using these instructions. For some reason only two of the devices are ...
user avatar
  • 21
1 vote
1 answer
1k views

How to set up MPU6050's registers properly?

I would like to use the MPU6050 as IMU in my quadcopter. I've been Googling for 2 days, but I can't find anything where this is explained well. I know that the settings are not general, but I hope ...
user avatar
  • 95
1 vote
2 answers
793 views

MPU6050 gyroscope not responding

I was testing my MPU6050 with Raspberry PI and got accelerometer(X,Y,Z) and gyroscope(X,Y,Z) data forming on registers at decentely high sample rate. Looks like I've accidently fed +5v from RPI to SDA ...
user avatar
1 vote
1 answer
3k views

MPU-6050 is not being detected by Raspberry Pi

I am trying to interface MPU-6050 with the Raspberry Pi, Since it require I2C connections so I have connected using the following pins: 3.3V connect to VCC SDA connect to SDA SCL connect to SCL ...
user avatar