This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

How to use I2C for nRF9160 DK with getting sensor Data of MPU9250 or MPU6050?

Hello There,

I want use I2C in nRF9160 for getting MPU6050 or MPU9250 data in it,

I try this Example with change overlay file in it

SDK 1.5.1 and also try with 1.40 nrf\zephyr\samples\sensor\mpu6050\

new overlay file is 

nrf9160dk_nrf9160ns.overlay
/*
 * Copyright (c) 2019 Nordic Semiconductor ASA
 *
 * SPDX-License-Identifier: Apache-2.0
 */

&i2c2 {
	mpu6050@68 {
		compatible = "invensense,mpu6050";
		reg = <0x68>;
		status = "okay";
		label = "MPU6050";
		int-gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
	};
};

nRF9160 DK --------------MPU6050

pin SDA    30                 SDA

pin SCL    31                 SCA

VDD                              VDD

GND                              GND

Error Failed to find sensor MPU6050

BTW also I2C scanner old example with PIN 10 and 11 but not working

Is There any thing I miss?

This are the info write behind the board nRF9160 DK

PCA10090

1.0.0

2021.6

Parents Reply
  • Hi Simon,

    Thanks for your Response,

    Actually I get the Value of MPU6050 sample but I didn't connect with MPU9250 can you pls help me out
    where I need to Change
    like prj.conf,nrf9160 overlay file, main file

    And I tried I2C example its work fine and I am able to find my I2C device but how can i get the data from it.

    I just want MPU9250 data to nRF9160.

    Thanks
    Jaydip  

Children
Related