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.

MSP430FR5994: I2C Communication failed when 1 slave is not having a POWER.

Part Number: MSP430FR5994


Hello All,

This is Anil. i am working on the MSP430FR5994 with the I2C Communication. On a single I2C communication i have connected BQ34Z100PW-G1 and LC709203F as a slave devices. both Slaves i am using for voltage reading.

If both devices are powered(+3/+4 V for LC709203F  or +12V for BQ34Z100PW-G1), then using MSP i can able to read the voltages form the IC's.  But now the scenario is that, i intentionally removed the Power of BQ34Z100PW-G1, and  LC709203F this is having a powered.  and by MSP i am trying to read the voltage, so as per my knowledge LC709203F  this one should give a voltage to MSP, but as soon as i removed the power of BQ34Z100PW-G1 then on-words MSP is not able to read the voltage from both Slaves .

In the above same situation i commented the code of BQ34Z100PW-G1, then i am getting correct results from LC709203F IC. 

So , now my question  is that if slave is not having Power and controller is trying to communicate with that slave plus other slaves also in I2C communication, then all slaves will fail or only NOT powered Slave device will fail?

thanks 

Anil D.

  • Hello Anil,

    first of all, please close your previous post related to this topic.
    Answer is within your words: i commented the code of BQ34Z100PW-G1, then i am getting correct results from LC709203F IC.
    Your program needs to recognize that a particular IC is not answering and handle that properly.
    It applies to both your ICs.
  • Thanks Tomasz for your quick Reply.

    But i wants to clarify one thing here is that, always i need to read the voltage from both IC's. because its like if +12V battery connected then i have to read the voltage again and need to do some operation accordingly . So i can't stop reading the communication.
    See, in the datasheet of BQ34Z100PW-G1 also there is no provision of letting that IC ON without giving +12V and read the Voltage from ONE IC PIN. then how can i make the IC to be in ON condition, it always be dependent on the +12V.

    My application is related to the Car battery(BQ34Z100PW-G1) and small Backup Battery (LC709203F). So if Car battery is removed then how can i make that particular IC be in the ON condition.
    So here NO programmatic issue, here i just wants the confirmation that, even i have connected 2 Slave I2C, and one is not POWERED, then another will get affected or NOT. If another IC is get affected then why its affected. if its not affected then how can i write a code for it?

    and one more point is that i didn't posted anything related to this topic before this thread. so i don't know, on which post you are talking about.

    thanks
    Anil D.
  • Hi,

    regarding last issue: e2e.ti.com/.../2683712
    probably your friend.

    <<< always i need to read the voltage from both IC's.
    O.K. What if one chip goes damaged?
    Your program cannot read value from another chip.

    <<< there is no provision of letting that IC ON without giving +12V ... then how can i make the IC to be in ON
    I have never discussed that. It is your issue when +12V is lost.

    <<< and one is not POWERED, then another will get affected or NOT.
    The another is not affected. When you commented out code for the first device your program was working.

    <<< So here NO programmatic issue
    Of course it is a programming issue.
    Somewhere in your code you do not check status of I2C commands and continue communication with a device which is not responding, or you check statuses and handle it in a wrong way.
  • Hello Tomasz,

    ---> "O.K. What if one chip goes damaged? Your program cannot read value from another chip."   -- yes my program is not able to read value from Another Slave. Let me describe more on it. See firstly I2C communication will try to send SLAVE ADDRESS with START bit, after that MSP will try to send the COMMAND REGISTER ADDRESS, so here while sending MSP will check whether Slave is responding with ACKNOWLEDGMENT or NOT. so here after sending a REG. Address if its not giving a ACK then because of timeout it will come out from that communication. This is what i observed in coding. But here i could not understand the thing is, reading of Voltage from 2 different IC's - program is different. So how 1'st will affect the 2'nd I2C communication.

    ----> " It is your issue when +12V is lost. "  --- Yes sir this is my issue only, and not able to read from the Another IC that is also my issue. But why i came to you to understand the I2C communication while this kind of issue occurs. Simple point to ask is "If IC is OFF and MSP is trying to communicate with that IC only with another 2 IC's as a Slave in I2C communication then is that UNPOWERED IC will affects the communication of OTHER devices or NOT?  After dumping code, after few years if your one of your Slave IC broken, so that time it will affect to my code, so how to resolve this? 

    ---> "Somewhere in your code you do not check status of I2C commands and continue communication with a device which is not responding, or you check statuses and handle it in a wrong way."  ---- Yes man I am checking that continuously, why i need to continuously checking? Because If that +12V connected again then that particular time only i need to update the same to MSP.

    So on my this situation i need solution. Please don't tell me i am not Handling the coding perfectly. 

    Thanks,

    Anil D.

  • You need to be careful since it is possible for the chips to be powered via the ESD diodes from the GPIO lines. Operation may be erratic, however.
  • Yes Keith,

    Here i am using Complicated Design, because see " " this is the link for Datasheet of (BQ34Z100PW-G1). Here there is no provision to make this IC ON without +12V, so if  removed the Reading voltage then IC also dies. in this situation MSP goes failed to read the another IC voltage which is connected to the same I2C Bus.

    ---> Can you elaborate this Point." chips to be powered via the ESD diodes from the GPIO lines. "

    Thanks,

    Anil D.

  • It depends on what rail the ESD diodes connect to. If they connect to the low voltage rail, current can flow from the I2C pins into the chip and power it. Generally, it is not recommended to power any pin without VCC/VDD on the chip for this reason. This chip might have special provisions, we need to have TI chime in.
  • Dear Anil,

    if you disconnect +12V do you receive ACK?
    I understand that in this case you have no ACK from BQ34Z100PW-G1.
    What your program does next?
    I assume that it goes to second chip, sends start, than sends COMMAND REGISTER ADDRESS and waits for ACK.
    Do you receive ACK from the second chip?
    If it does not receive ACK from the 2nd chip what is I2C lines voltage?

  • Hi Keith,

    Whatever you said that is correct, I am also thinking that Because of I2C pins 2nd I2C slave gets power and it may affect my communication.
    ESD diodes are connected to the the Circuitry, but not with the I2C Pins. For I2C pins I connected Pull UP registers of 10K ohm.
    what i am thinking is because of One chip is not working properly, why my others communication not working. I think because of on a single line i am trying to communicate with 2 slaves thats why it gives me an error.


    Thanks
    Anil D.
  • Hi Tomasz,

    whatever you said is correct, If from BQ34Z100PW-G1 this IC NO ACK i got it , for the next communication also (LC709203F) i am not getting any results. the situation is same for all devices .
    Talking on voltage levels
    1) if all communication is good then getting 3.3v on both lines SDA and SCL.
    2) If removed the Power of BQ34Z100PW-G1 device , then only on SDA will show some time as a 3.3v because of sending a slave and reg address that time only it will goes to 3.3v. and SCL always be a 0.0v.

    See one more scenario i observed that is, After removed POWER of BQ34Z100PW-G1 device i am not getting any results , BUT after connected POWER again, that communication starts again giving me results.

    Thanks,
    Anil D.
  • Hi Anil,

    re 2) what voltages do you have on SDA/SCL when +12V is disconnected and you do not send start bit and reg. address?
  • Hello Tomasz,

    Here How i resolved the Problem:
    1) MSP will try to communicate with not Powered device, no problem, But while trying its sent start and SLAVE address and REG address to the I2C line. But I2C slave is not responding MSP will try for the next I2C Device. But here communication is not completed because Stop bit is not send by MSP. So MSP will think like with the same IC MSP need to try Again. So because we are facing problem to communicate with 2nd Device also.
    2) i changed mechanism that is, if MSP is getting 0.0v from BQ34Z100PW-G1 IC then voltage is not there, then need to send STOP bit separatly , because MSP already sent a SATRT and REG address to I2C line to free that line MSP need to Send STOP.

    Its Resolved my issue.
    Thanks for everyone.

    Anil D.
  • Glad you did!

**Attention** This is a public forum