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.

LM75A I2C hangs

Other Parts Discussed in Thread: LM75A

Hi, We are using I2C to read temperature from LM75A. There is 10k ohm pull up resistor on both lines. These lines are going to one connector also after temperature sensor IC and we have not connected anything on that connector. We are reading temperature regularly 500 times in 1 second with 120 kHz clock on SCL. After about 2 hours the processor is not able to read on I2C2 lines and both SCL and SDA becomes low. On giving hardware reset twice through switch it starts reading again. But if we keep without any action for long like half an hour and then it does not starts read again even after hardware reset. Then it (I2C) starts working after power reset only. During this status we observed that SCL is high. On keeping the board in same condition for night and probing the SCL and SDA, we observed that SCL gone low again.

This issue is with I2C2 only. The processor is sending command regularly on UART1 port, but there is no activity on I2C lines. On pressing hardware reset, I2C get initialized in processor, but there is no communication between i.MX6S processor and LM75A.

 

With regards

Lalit Kumar

  • Moving to temperature sensors forum.
  • Hi Lalit,

    The LMT75A should not be read 500 times in 1 second. The datasheet on page 4 states the wait time between each conversion be at least 300ms:


    Let me know if that solves the problem.

    -Michael Wong

  • Thanks Michael, I will check and update you.
  • Michael I have doubt if this is affecting I2C. As we have also used NXP part LM75A, which was hanging even after reading rate of 1 second. in NXP datasheet, there is also mentioned that "This Temp register can be read at any time by a controller on the I2C-bus. Reading temperature data does not affect the conversion in progress during the read operation.”
  • Hi Lalit,

    This is strange. Can you provide a schematic of your system?

    -Michael Wong
  • On increasing reading rate like 500 times in 2 second with NXP IC, it gets stuck within 1 or 2 hours.

  • Hi Lalit,

    Your schematic seems fine to me. I made a mistake in my first post, it is possible to read the LM75 500 times a second but the temperature will not update to a new reading unless there is a 300ms wait time in between readings. The NXP LM75 is a copy to TI's LM75 and should behave the same way. Since two parts are not working correctly it seems like the problem may be with your system and not the parts. Have you tried communicating with any other I2C parts and found similar issues?

    -Michael Wong
  • Hi Michael,

    We are using other I2C parts on the same board but on other I2C port. There is no problem. For temp sensor IC, I observed that both I2C lines are getting stuck low. On giving hardware reset (reset to processor through switch), SCL line goes high, but SDA line remains low. I have also tried by adding 33pF capacitor on SDA line to Ground as mention in one of the TI application note (AN-2113), but this also not resolving the issue. On probing SCL, fall time is about 3ns to 5ns and rise time is about 750ns.

    When I am increasing reading repetition rate in one second in hundreds like 100, 500 etc, it get stuck within 12 hours. In some boards with less repetition rate also, this issue was observed. I have put 2 boards with TI IC and one board with NXP IC and this board has capacitor on SDA line, with repetition rate of 3 in one second. These 3 boards are running for one week without getting stuck.

    -Lalit

     

  • Hi Michael,

     

    The issue is being observed again even with lesser rate of access.

     

    With regards

    Lalit

  • Hi Lalit,

    Michael was out today so I'm replying in his place. There is no way the LM75A can drive the SCL line low. This is a logic input - no output drivers there.

    The LM75A state machine resets the SDA output if it communicates a low for too long. Are you sure you are using an LM75A? This function is called TIMEOUT as described in the EC Table:

    Are you 100% positive that the connector that doesn't go anywhere really doesn't go anywhere?

    How many devices are on this bus?

    I didn't see the pullups in your schematic so I assume they are in some device. Could the processor somehow be removing the pullups during reset thus the bus you go low? On multi-function MCU pins it's usually wise to have them go to high impedance until software runs.

    It's just curious the SCL also gets stuck low if it is the LM75A it means it is malfunctioning in a very big way.

    Have you tried more than one part?

    Have you tried a different board do all boards do this?

    By reading less and seeing that the failure rate lessens could point to a marginal timing issue:

    Could the processor by mistake be seeing a false start and misbehaving (Clock transition to low while data is high). You mentioned putting a 33pF on the SDA line did that make the failure rate worse? You may try a bigger cap and see if the failure rate gets worse.

    Putting a cap on SCL would slow down the falling edge of the clock that could cause the failure rate to lower or go away.

    Probe the signals at the input of the processor pins with buffered probes (not cap loading) and see how close the timing is.

    Can you send us scope photos of the failure as it occurs, probe SDA, SCL and VDD (I know it's a pain but it has to be done)...

    I'll be out for a while so Mike will pickup the discussion again on Monday. Hope you come to quick resolution!

    Take care, 

  • Thanks Emmy for detailed reply.

    Yes, I am using LM75A. Both SDA and SCL go low.

    These lines are connected to one connector in addition to LM75A. But on mating connector (i.e on another board), these pins are not connected. I2C lines provided there for future purpose.

    More than one parts is not tried. Pull-up resistor of 10k ohm are put on both lines, were on different page, so forgot to show in this schematic.

    This problem comes in almost all boards, but the failure rate is different.

    I had tried 33pF on SCL line on one board and after that it takes more time to fail, but the problem is not removed permanently.

    We don't have buffered probes, so will not be able to probe as you told. Bytheway we have probed SCL and SDA, and was able to capture these signals. Bleow are waveforms, when it stuck low and working

     

    With regards

    Lalit

  • I was able to capture I2C lines with VDD. I am attaching here.