I2C and nRF9160DK

Hello

I use nRF9160DK.

Can somebody tell me why it doesn't give an error ( ) if I don't have anything on the I2C line, or how can I be sure if it finds the right address?

And if I add a sensor with the address <0X43> to the line, it's still the same in the NRF terminal

nRF9160DK I use pins:

main.c

prj.conf

Thanks

Parents
  • I'm not that common, but I guess there are some assumptions, which doesn't match.

    1. The I2C bus is controlled by the nRF9160 and that doesn't depend on sensors connected to that bus. Therefore the OK is more, that the nRf9160 has such an I2C controller.

    2. your app crashs and reboots, I guess, "%p" requires "&dev_i2c" not "dev_i2c". Does the compiler warns about that?

    3. The Thingy:91 uses I2C for sensors. Maybe you check there in that board definition how to use an I2C sensor.

Reply
  • I'm not that common, but I guess there are some assumptions, which doesn't match.

    1. The I2C bus is controlled by the nRF9160 and that doesn't depend on sensors connected to that bus. Therefore the OK is more, that the nRf9160 has such an I2C controller.

    2. your app crashs and reboots, I guess, "%p" requires "&dev_i2c" not "dev_i2c". Does the compiler warns about that?

    3. The Thingy:91 uses I2C for sensors. Maybe you check there in that board definition how to use an I2C sensor.

Children
No Data
Related