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.

INA219: I2C bus failure

Part Number: INA219
Other Parts Discussed in Thread: , INA209

Hello TI experts

I'm designing a custom current sense board using INA219, after soldering the chip and the I2C pull-up resistors and making sure that everything is connected and there are no shorts in the circuit, i face a weird behavior in in the I2C connection. When i connect the board first time to arduino, I can detect the chip using the I2C scanner which gives me the address of the INA219 chip but when i disconnect the board and  reconnect it to arduino, i cant detect anything and the arduino sketch hangs.  I soldered another 2 boards with new components and the same problem happens. Im unable to understand this weird behavior and now im stuck here and cant find a solution. all what i can say is that all the boards i soldered have the SCL and SDA pulled up to 5V and i checked that with a voltage meter and i was able to detect all of them with the I2C scanner when i connect them to arduino for the first time  (btw, every board is tested separately)  but after disconnecting and reconnecting a gain, i cant detect anything and the SCL and SDA  lines become pulled down to 0V. the schematic is attached.

Could some one please help me regarding this issue? what could be the cause of this issue?

Thanks alot in advance

Mansour

  • Hello Mansour,

    I hope to solve this problem. While I am working on this, may I get the following details?

    1. Before you disconnected the board, were you able to read back data over I2C?
    2. Are you reconnecting the boards while they are still powered on?
    3. Are you reseting power after the reconnection and attempting communication then?

    Sincerely,
    Peter Iliya
    Current Sense Amplifier Applications
  • Hello Peter

    Ja first time when i connect the board, I get data back over I2C but as i said when i reconnect again, i cant get anything and the I2C returns no data and as i said before, the SCL and SDA ( mostly SCL line) becomes pulled down on the INA219 side. And yes i tried all your suggestions but no hope. what I realized is when i heat the chip a little bit using hot air and connect again. it works but after that the same problem happens and its the same on all the boards i made. any suggestion would be great.

    Thanks in advance

    Mansour

  • Hello Mansour,

    I am asking around for more information about your scenario and will get back to you on this.

    I tried replicating this experiment with our INA219 evaluation module (EVM) and the complimentary USB DIG Platform board that has the host/master microcontroller on it to communicate with the INA219. I disconnected the board during I2C communication and the USB DIG board was still driving the SCL and writing commands on the SDA line. Nothing was happening on the INA219 EVM because it was powered off, but this should not matter because the INA219 in this situation, like most of our other parts is the I2C slave device and needs the master to drive the SCL.

    I reconnected the boards and communication resumed normally. I am not sure if this is the problem, but the INA219EVM board has 10kOhm pull-up resistors for SCL and SDA and the USB DIG Patform has 4.7kOhm pull-up resistors.

    When you disconnect the boards, are the Arduino's SDA/SCL pinouts still connected to any pull-up resistors?

    Peter Iliya

    Current Sense Amplifier Applications

  • Hi Peter

    Thanks for your help. Ja I did add pullup resistors on the arduino as well but still facing the same problem. Moreover, I would say that the top layer of my PCB has a ground plane, Would that probably affect? like a ground loop happening for an example? 

  • Funny old thing... my situation is slightly different I put an ina209 onto a Linux machine (Orange Pi running Ubuntu) and did a scan - sure enough the board turned up at address 0x40 every time. I've put the same board onto my ESP8266 software which generally scans I2c no problem - I even tried putting 2k2 pullups to 5v... and I'm getting nothing - absolutely zilch. I've even tried swapping SDA and SCL just to be sure - nothing. It is not seeing the board. I wonder if this is related.
  • Hello

    Thanks alot for the suggestions but I found the problem :). its because of the flux I used during soldering process which was supposed to be a non conductive flux but instead it turned out to be a conductive one specially when it hardens after the board cools down and and that affected the I2C lines and i have the same problem with all my other boards i did last time suing that bad flux. Anyway i did some new INA219 board without flux and they are working like charms :)

    Greetings

    Mansour

     

  • As it turns out it's a timing issue with my i2c library - I borrowed code from the WIRE Arduino library (I don't use Arduino) and it works - so it's just a case of comparing my timings with theirs and Bob's your uncle.

  • Mansour,

    This is great. Please post back to the forum if other issues arise.

    Peter Iliya