This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

fail i2c connection between smp430fr5739 and mpu 9150

Other Parts Discussed in Thread: MSP430FR5739

Dear experts

I have a problem to interface between two devices : msp430fr5739 (master) and mpu9150 (slave).

I always got NACKs when I try to write into the registers slave.

I connected two pull up resistors (10k or 4.7k) onto lines (SDA SCL), also I configured the slave address as 0x68 (AD0 connect to the ground).

the program I used is based on ccs in c language.

hope someone can help me with a basic i2c code between those two devices.  

  • You must check if the slave is actually configured/addressed.

    Since it is sending a NACK , it mostly is.

    Maybe the format of data u have sent must be incorrect.

    I am no expert but thought i would share certain problem solving techniques i had used in my basic I2c transmission.

    Best of Luck ! 

  • oded meiri said:
    I always got NACKs when I try to write into the registers slave.

    Do you get the NACK after addressing the slave or after sending the data?

    Perhaps you're using the wrong slave address. The slave address is the upper 7 bits of the start byte, right-adjusted (0x00 to 0x7f), while the eUSCI will automatically add the R/W bit when sending the start byte - based on the UCTR bit.

**Attention** This is a public forum