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.

MSP430FR6047: I2C Start Condition is not sent

Part Number: MSP430FR6047

Hello,

I am currently trying to control a display via I2C. This works quite well most of the time. But sometimes the I2C communication does not work properly because the start condition is not sent. During debugging the corresponding bit (UCTXSTT) is not cleared by the controller either, but remains set. I also observe this behavior when I unplug the display and thus no other device is connected to the I2C bus. However, this problem does not always occur and sometimes sending the start condition works both with and without the display connected. What can be the reason that the start condition is sometimes not sent?

Thanks a lot
Tobias Heindl

  • Hi Tobias,

    It looks like this bit will be held high during a few conditions:

    When you attempt a repeated start condition

    When the there is a NACK condition

    The complete address is not sent

    Is it possible that any of these conditions are occurring? 

    Are you using this device for USS applications? Is it possible that the USS algorithm is interrupting some of the I2C behavior? Please let me know if you are working from one of our example codes, and if you have made any major changes, so that I may better understand your use case.

  • What are you using for pullup resistors?

  • I am using 22k resistors as pullups for the SDA and SCLK

  • Hi,

    There is no repeated start condition or NACK because the initial start of the I2C-Kommunication with the start condition and the address is not sent, even when debugging. So on the oscilloscope there is no activity at SCLK and SDA. Only a constant high level after initialization of the I2C pins. And as I said sometimes it works just fine.

    I use only the display for testing purposes without any USS application. My project is based on the example project "I2C Master TX bytes to Multiple Slaves", but I have adjusted it so that it only sends to one slave. 

  • Hi Tobias,

    So you see no activity at all when you perform an I2C transmission and probe the lines? This sounds to me like this is a software issue. If there is some activity, it would be very helpful if you could take an o-scope capture of the lines. 

    With that being said, I also think that 22k pull up resistors are very weak for this. You should decrease this value. Depending on your desired I2C CLK frequency, you should be using something closer to 4.7k. Please try implementing this change, and let me know what your I2C CLK frequency is as well.

  • Hi Dylan, 

    I have solved the problem. As you suggested, I first changed the pullup resistors. Unfortunately, this did not help. Therefore, I continued to search for errors in the software.

    It worked reliably after I swapped the initialization of the I2C pins and the initialization of the USCI module. I used to initialize the USCI module first and then the pins and that seems to have caused the problems.

    Thanks for your help with the problem

  • The recommended order is: configure USCI, pins, enable USCI. (32.3.1)

**Attention** This is a public forum