Device bmi270@68 is not ready when using nrf5340 and the BMI270 sample

I am trying to get the BMI270 working with a nrf5340 DK. I have read Unable to Connect nRF5340DK with BMI270 Over I2C - Nordic Q&A - Nordic DevZone - Nordic DevZone (nordicsemi.com) and Falied to Connect nRF5340DK with BMI270 Over I2C - Nordic Q&A - Nordic DevZone - Nordic DevZone (nordicsemi.com), but neither had an answer. I understand the comment that the BMI270 driver "does a lot of stuff", but that did not seem like a reasonable answer to me considering it seems to work with the nrf52833. I added the:

zephyr,concat-buf-size = <128>;

Which did not solve my issue which was that I ran the sample and got this error message:

Device bmi270@68 is not ready

Parents
  • Hi,

     

    Do you have external pull resistors?

    If not, try to enable internal pull-ups in DT:

    &pinctrl {
    	i2c1_my_default: i2c1_my_default {
    		group1 {
    			psels = <NRF_PSEL(TWIM_SDA, 1, 2)>,
    				<NRF_PSEL(TWIM_SCL, 1, 3)>;
                bias-pull-up;
    		};
    	};
    
    	i2c1_my_sleep: i2c1_my_sleep {
    		group1 {
    			psels = <NRF_PSEL(TWIM_SDA, 1, 2)>,
    				<NRF_PSEL(TWIM_SCL, 1, 3)>;
    			low-power-enable;
    		};
    	};
    };
    
    &i2c1 {
    	compatible = "nordic,nrf-twim";
    	status = "okay";
    	pinctrl-0 = <&i2c1_my_default>;
    	pinctrl-1 = <&i2c1_my_sleep>;
    	pinctrl-names = "default", "sleep";
    	zephyr,concat-buf-size = <128>;
        bmi270@68 {
                compatible = "bosch,bmi270";
                reg = <0x68>;
        };	
    };

     

    Kind regards,

    Håkon

  • I have a board to connect w/the nRF5340 DK with a separate I2C SCL/SDA (currently P0.24 and P0.23 respectively). For the BMI270 INT1 is P0.06 and INT2 is P0.09.

    I replaced the overlay with what you provided but got the same response.

    I did have to add one additional item because there is a SAO address bit for the BMI and I need to make this MCU GPIO Output LOW and it will be BMI270 default i2c address 0b1101000 (0x68).

    &gpio0 {
        status = "okay";
        p0_19_hog: p0_19_hog {
            gpio-hog;
            gpios = <19 GPIO_ACTIVE_HIGH>;
            output-low;
        };
    };

Reply
  • I have a board to connect w/the nRF5340 DK with a separate I2C SCL/SDA (currently P0.24 and P0.23 respectively). For the BMI270 INT1 is P0.06 and INT2 is P0.09.

    I replaced the overlay with what you provided but got the same response.

    I did have to add one additional item because there is a SAO address bit for the BMI and I need to make this MCU GPIO Output LOW and it will be BMI270 default i2c address 0b1101000 (0x68).

    &gpio0 {
        status = "okay";
        p0_19_hog: p0_19_hog {
            gpio-hog;
            gpios = <19 GPIO_ACTIVE_HIGH>;
            output-low;
        };
    };

Children
Related