-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failed to find MPU6050 but it's detected by i2cdetect #35
Comments
My first guess would be that when you use "i2cdetect" it is using the correct pins for SCL and SDA, but when you use then that code is using different pins. |
in my code, I connect the i2c variable to board.SCL_1 and board.SDA_1
why? because if I connected it to board.SCL and board.SDA the error would be |
wait do we have to follow hardware pin to connect the i2c cable? isn't it enough to connect it to the i2c pin on jetson nano? |
Do I get |
@Aldhanekaa. Hello :). It seems to me that this is more a question than a problem with the library. I have just checked the sensor, and it worked fine using the RP2040 feather. I would recommend following this guide |
I follow this tutorial https://automaticaddison.com/visualize-imu-data-using-the-mpu6050-ros-and-jetson-nano/ to run MPU6050 on jetson nano, I've followed all of the steps though even when after I changed the i2c to pin 5,3 (SCL,SDA) it still unable to find the MPU. But, is it possible this occur because my MPU broken? I think I do so because I once scratched the board with screwdriver because the soldier tin from different pin was joined (I want to split it) (I'm newbie in soldering :D ), however if it really broken why the LED still turned on and i2cdetect still able to detect the address?. |
@Aldhanekaa the library is looking for a sensor in the
Regarding, the |
Hm still returns an error cant find MPU. I've changed the library python script as you suggest, however it seems like the error occurred because it tries to check. def __init__(self, i2c_bus: I2C, address: int = _MPU6050_DEFAULT_ADDRESS) -> None:
self.i2c_device = i2c_device.I2CDevice(i2c_bus, address)
print(f"{self._device_id} {_MPU6050_DEVICE_ID}")
if self._device_id != _MPU6050_DEVICE_ID:
raise RuntimeError("Failed to find MPU6050 - check your wiring!")
and it prints |
The |
The response consistently |
So I'm using GY-521 MPU-6050 for my Jetson Nano, So I tried to run this code example https://github.com/adafruit/Adafruit_CircuitPython_MPU6050/blob/main/examples/mpu6050_simpletest.py then there is an error
Failed to find MPU6050 - check your wiring
.My wirings:
The
i2cdetect
still able to detect the i2c though.I also change line 10 from the example to be set the address to 105 (i2cdetect detects 0x69)
mpu = adafruit_mpu6050.MPU6050(i2c, 105)
.My MPU-6050 led is still on, but why it fails to find MPU6050?
The text was updated successfully, but these errors were encountered: