This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

nrf9160 i2c2 can't be used.

Hi:

I use ncs 1.9.1, borad nRF9160-DK

sda-pin = <30>;
scl-pin = <31>;

Config:

I added i2c2 in blinky, here is the source code.

I see i2c2 enabled in zephyr.dts

But its output is like this:

Parents
  • Hi,

     

    I tried your example, and it seems to run as expected. I see this waveform in the beginning:

    And since I do not have this sensor myself, it does not go further (ie. no ACK).

     

    But its output is like this:

    this output looks very strange.

    Did you connect GND?

     

    Kind regards,

    Håkon

Reply
  • Hi,

     

    I tried your example, and it seems to run as expected. I see this waveform in the beginning:

    And since I do not have this sensor myself, it does not go further (ie. no ACK).

     

    But its output is like this:

    this output looks very strange.

    Did you connect GND?

     

    Kind regards,

    Håkon

Children
  • Hi Håkon:

      I'm connected to GND.

  • Hi,

     

    I took your build/zephyr/merged.hex file (ie. the one you compiled) and it also worked on the DK. I can see the same trace as posted below.

     

    Could you take a multimeter and check the voltage on the P0.30/P0.31 pins and see if it's at VDD level? Note that this will follow your VDD_IO settings (ie. the switch in the lower left corner, where you can set either 1.8V or 3V).

     

    Is your logic analyzer with a logic level of 3V? If so, try to adjust this to 1.8V in the PC application.

     

    Kind regards,

    Håkon

Related