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.

BQ25180: Waking up from ship mode by pushbutton sometimes does not work

Part Number: BQ25180

Tool/software:

Our battery powered device (charging with USB) contains a BQ25180. The device can shut itself down by sending the command for ship mode to the BQ25180 which then shuts down everything else. Wake-up is done by pushbutton or USB power. 

Generally it works fine on several devices (about 400). Just in very rare cases the device only wakes up from USB power. Even if it is shut down and started again several times (sending the command for ship mode to the BQ25180, waking up with USB) the problem remains. After removing and inserting the battery, everything works normally again.

For some reason the BQ25180 does not wake up from ship mode anymore in these rare cases until the battery is removed/inserted.

Command for software reset did not change anything. 

Command for hardware reset worked fine on two devices. On another device the ship mode does not work anymore at all after hardware reset. We did not remove the battery yet on that device. Probably everything would work after removing/inserting the battery.

We did not notice any difference in the status registers between normal working devices and devices that don't wake up from ship mode. 

Is there any reason why the BQ25180 acts like this? How to get it working normally again?

  • Hello Matthias,

    Could you please help to answer the following?

    After removing and inserting the battery, everything works normally again.

    Just to clarify, you are saying that after removing and reinserting the battery, you are then able to exit ship mode with the push button instead of only a VIN insertion?

    What is the VBAT voltage when trying to wake the device from ship mode using the push button?

    Could you please provide your schematic and MR, BAT, and SYS waveforms?

    Best regards,

    Alec Lehman

  • Hello Alec

    Thank you for your reply. Yes, after removing and reinserting the battery, we are able to exit ship mode both ways. The same after applying the command for hardware reset on two devices. On one device the ship mode does not work at all anymore after the hardware reset (power stays on). We did not remove the battery from that device yet. It happens very rarely, so we don't have more devices with the error at the moment.

    This is the relevant part of the schematic:

    The waveforms are from a working device. I don't have a waveform for VBAT.

    Waveform VSYS when starting:

    Waveform TS/MR:

    Best regards,

    Matthias

  • Hello Matthias,

    Thank you for providing the schematic and waveforms.

    I do not see any apparent issues with the schematic. I see that the push button pulls the TS/MR pin low through the P-channel FET and N-channel FET. I don't expect any issues with this solution, but it would be helpful to verify the waveform on the TS/MR pin when the button is being pressed to exit ship mode.

    The provided waveforms do not show any particularly unusual behavior. It would be helpful to see TS/MR and VSYS when attempting to exit ship mode with the push button in one of the rare cases. However, I understand that this issue is rare and may be difficult to recreate.

    It would also be helpful if you could provide a VBAT waveform when exiting ship mode or the VBAT voltage. Depending on the VBAT voltage, it is possible that when using the push button to exit ship mode, there is an inrush of current to VSYS which causes VBAT to drop below the BUVLO threshold. This would disengage the path from VBAT to VSYS. If in BUVLO, the device will be unable to exit ship mode or turn SYS on.

    On one device the ship mode does not work at all anymore after the hardware reset (power stays on).

    When is the hardware reset being performed? During a hardware reset, SYS should shut down and automatically turn back on. Is the hardware reset being performed after waking the device from ship mode by inserting VIN?

    It would be helpful if you could provide register dumps during normal behavior and the rare behavior. I know that you mentioned the status registers were the same, but it would also be helpful to see the flag registers.

    Best regards,

    Alec Lehman

  • Hello Alec

    Thank you for your reply. 

    Regarding hardware reset:

    Our device normally lets the BQ25180 powered on and goes into a power saving mode of the MCU when it has no tasks to do. But the user can select to shut down the device (to reduce battery drain). In that case the BQ25180 is put into ship mode and the MCU has no supply anymore.

    I made a test firmware that applies the hardware reset when the device starts (button pressed or USB powered). The user won't even notify that. Of course the firmware handles the situation to prevent a start-loop (reset once and then start normally). In cases where the device does not start from the button, it should work the next time because of the hardware reset. 

    Regarding register values:

    On working devices and on devices with the rare problem I saw this (no difference):

    STAT0: 0x31 (VIN Power good, constant current charging)
    STAT1: 0x00
    FLAG0: 0x20

    STAT0: 0x31
    STAT1: 0x00
    FLAG0: 0x00

    STAT0: 0x31
    STAT1: 0x00
    FLAG0: 0x40

    STAT0: 0x31
    STAT1: 0x00
    FLAG0: 0x60

    So in some cases VDPPM Fault and ILIM Fault are set. But working devices work as expected so far, so I would not assume that this is the cause of the problem.

    Regarding waveforms:

    I cannot measure waveforms of a device with the rare case - I cannot reproduce it on purpose. And even if it happens, I cannot open the device without removing the battery. Here are some waveforms of a working device. The pulse of the TS/MR pin stops as long as the button is pressed - as expected. The button is pressed long enough to start the device.

    VBat and TS/MR with cursor on TS/MR (power on device with button):

    VBat and TS/MR with cursor on VBat (power on device with button):

    VBat and TS/MR with zoomed VBat (power on device with button):

    Kind regards

    Matthias

  • Hello Matthias,

    Thank you for providing the registers and waveforms.

    We are conducting further research into this and will get back to you sometime this week at the latest.

    Thank you in advance for your patience.

    Best regards,

    Alec Lehman

  • Hello Matthias,

    Thank you for all of the information you have provided thus far; I really appreciate it. I want to ensure that I correctly understand the issue so that I can better narrow it down.

    Here is my understanding of the situation:

    • In your application, the intent is that ship mode can be entered by a push button press from the user or through I2C when the MCU wants to save power.
    • You have tested about 400 devices.
      • Most of these devices are able to enter and exit ship mode with no problem.
      • In three rare cases, the device is only able to wake up with an adapter insertion (a push button exit will not wake the device).
        • For two of these rare cases, there are two possible fixes to allow exiting ship mode using either VIN or the push button:
          1. Remove and reinsert the battery (always works)
          2. Perform a hardware reset (always works but sometimes causes the device to be unable to enter ship mode afterward)
        • For one of these rare cases, there is only one possible fix to allow exiting ship mode using either VIN or the push button:
          1. Remove and reinsert the battery
    • You have a workaround in your firmware to handle these rare cases, in case they occur.
    • There are no differences in the registers after exiting ship mode between working devices and devices with the rare problem.
    • You are unable to capture waveforms of the device behavior in the rare cases because you would have to remove the battery to access the device, which would kick the device out of the failed state.

    Could you please provide the following:

    1. The full register readings before entering ship mode and after exiting ship mode.
    2. A waveform showing VSYS, VBAT, IBAT or ISYS, and TS/MR at the moment the failure to exit ship mode happens.
      1. I understand that you will need to recreate the problem to provide this, but it would be very useful.
    3. What is the expected load on SYS? If you are unable to capture IBAT or ISYS, could you provide some details about the expected load?

    Best regards,

    Alec Lehman

  • Hello Alec

    Thank you very much for your reply. I copy your text here, so I can directly answer (in blue).

    • In your application, the intent is that ship mode can be entered by a push button press from the user or through I2C when the MCU wants to save power. It is just through I2C: The user can select to shutdown the device in a menu or the MCU shuts down the device after several days when unused. Anyway, the ship mode is always started by a I2C command.
    • You have tested about 400 devices.
      • Most of these devices are able to enter and exit ship mode with no problem. Correct
      • In three rare cases, the device is only able to wake up with an adapter insertion (a push button exit will not wake the device).
        • For two of these rare cases, there are two possible fixes to allow exiting ship mode using either VIN or the push button:
          1. Remove and reinsert the battery (always works) Correct
          2. Perform a hardware reset (always works but sometimes causes the device to be unable to enter ship mode afterward) So far worked on two devices. We don't have more devices with the problem at the moment.
        • For one of these rare cases, there is only one possible fix to allow exiting ship mode using either VIN or the push button:
          1. Remove and reinsert the battery I assume that. I did not remove/reinsert battery on that device to maybe be able to do some tests.
    • You have a workaround in your firmware to handle these rare cases, in case they occur. The workaround is to send hw reset command to BQ25180.
    • There are no differences in the registers after exiting ship mode between working devices and devices with the rare problem. Correct
    • You are unable to capture waveforms of the device behavior in the rare cases because you would have to remove the battery to access the device, which would kick the device out of the failed state. Correct

    I can not take waveforms when the error happens. At the moment I have no device with error that I can measure. 

    Here are some waveforms from a working device. The average load is about 50mA when the device is idle. When it is working with full power, the current is much higher (about 500mA). But when starting from ship mode it will not directly switch to full power. 

    VBAT (green), IBAT (yellow) and TS/MR (blue) when starting from ship mode: 

    The same zoomed: 


    Regarding full register readings: I have to implement this first and then provide you the values. 

    Kind regards

    Matthias

  • I made the full register reading on a working device:

    Before ship mode: 

    reg[00]: 0x00
    reg[01]: 0x00
    reg[02]: 0x00
    reg[03]: 0x46
    reg[04]: 0x47
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x01
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

    After ship mode (seems to be the same):

    reg[00]: 0x00
    reg[01]: 0x00
    reg[02]: 0x00
    reg[03]: 0x46
    reg[04]: 0x47
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x01
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

    After battere removal and re-inserting (default values as expected):

    reg[00]: 0x00
    reg[01]: 0x00
    reg[02]: 0x00
    reg[03]: 0x46
    reg[04]: 0x05
    reg[05]: 0x2C
    reg[06]: 0x56
    reg[07]: 0x84
    reg[08]: 0x4D
    reg[09]: 0x11
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

  • Hello Matthias,

    Thank you for providing the waveforms and register values; that's very helpful.

    I understand that you have to remove the battery to capture waveforms of the device which is unable to exit ship mode using either VIN or the push button. However, are you able to capture a waveform of IIN when inserting the adapter on this device? Just to clarify, I am referring to the device whose battery you have not yet removed and reinserted. It would also be helpful to see the registers after inserting VIN on this device.

    Best regards,

    Alec Lehman

  • Hello Alec

    So far I have some more register values. All of them are read when the device starts from ship mode by plugging in USB. One interesting thing I observed: On the device, where the ship mode did not work at all after hardware reset, the ship mode works now again. But the device still just starts from USB. 

    Device that does not start with button (battery not removed/reinserted yet):

    reg[00]: 0x81
    reg[01]: 0x00
    reg[02]: 0x40
    reg[03]: 0x46
    reg[04]: 0x47
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x01
    reg[0A]: 0x40
    reg[0B]: 0x0C
    reg[0C]: 0xC0

    Device that starts normally with button:

    reg[00]: 0x31
    reg[01]: 0x00
    reg[02]: 0x60
    reg[03]: 0x46
    reg[04]: 0x47
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x01
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

    Device with NTC pin of battery covered with tape to interrupt it. Starts normally with button: 

    reg[00]: 0x81
    reg[01]: 0x00
    reg[02]: 0x40
    reg[03]: 0x46
    reg[04]: 0x47
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x01
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

    Kind regards,

    Matthias

  • Hello Matthias,

    Thank you for providing these register values.

    I notice that for the device that does not wake from the push button (battery not yet removed and reinserted), and for the device where you covered the NTC pin with tape, there is TS_OPEN_STAT being reported.

    It seems that the one device which was unable to exit ship mode with either a VIN insertion or a push button press is now able to exit ship mode with a VIN insertion, meaning it is now like the other two devices which could only exit ship mode with a VIN insertion.

    Are you able to provide the register values of the other two devices which were only able to exit ship mode with a VIN insertion and not a button press? I would be interested to see if those devices were also reporting TS_OPEN_STAT.

    BQ25180 has an active voltage clamp which will prevent the voltage on the TS/MR pin from rising above the VTS_CLAMP threshold (typically 2.8V when VIN = 5V is present). When the TS/MR pin is floating, this clamp will be on and TS_OPEN_STAT will be set.

    It is not expected that TS_OPEN_STAT is being reported if the NTC is properly connected to the TS/MR pin.

    Just to clarify, the device where you covered the NTC with tape is able to exit ship mode with the push button?

    Best regards,

    Alec Lehman

  • Hello Alex

    I copy your text to reply. 

    I notice that for the device that does not wake from the push button (battery not yet removed and reinserted), and for the device where you covered the NTC pin with tape, there is TS_OPEN_STAT being reported. --> correct

    It seems that the one device which was unable to exit ship mode with either a VIN insertion or a push button press is now able to exit ship mode with a VIN insertion, meaning it is now like the other two devices which could only exit ship mode with a VIN insertion. --> correct

    Are you able to provide the register values of the other two devices which were only able to exit ship mode with a VIN insertion and not a button press? I would be interested to see if those devices were also reporting TS_OPEN_STAT. Not of these two devices (because they are working correctly after hardware reset command), but meanwhile we have another one. Below the registers from that one.

    BQ25180 has an active voltage clamp which will prevent the voltage on the TS/MR pin from rising above the VTS_CLAMP threshold (typically 2.8V when VIN = 5V is present). When the TS/MR pin is floating, this clamp will be on and TS_OPEN_STAT will be set.

    It is not expected that TS_OPEN_STAT is being reported if the NTC is properly connected to the TS/MR pin.

    Just to clarify, the device where you covered the NTC with tape is able to exit ship mode with the push button? Yes, that device exits ship mode without problem.

     

    Registers of another device that does not exit ship mode with button:

    reg[00]: 0x41
    reg[01]: 0x04
    reg[02]: 0x60
    reg[03]: 0x46
    reg[04]: 0x2A
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x00
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

    Kind regards,

    Matthias

  • Now I just had another device that did not exit from ship mode with the button. After hardware reset command it works normally and it exits the ship mode on button press. 

    registers before hw reset
    reg[00]: 0x41
    reg[01]: 0x00
    reg[02]: 0x60
    reg[03]: 0x46
    reg[04]: 0x2A
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x00
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

    registers after hw reset
    reg[00]: 0x41
    reg[01]: 0x00
    reg[02]: 0x60
    reg[03]: 0x46
    reg[04]: 0x2A
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x01
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

  • Hello Matthias,

    When the push button is disabled in the registers, the internal current source on the TS/MR pin is also disabled. As a result, the device cannot exit ship mode using the push button. A hardware reset resolves this issue because it re-enables the push button.

    For this new device that cannot exit ship mode using the push button, I see that the push button is disabled before the hardware reset. In this situation, it is expected that the push button will not wake the device from ship mode. After the hardware reset, I notice that the push button is re-enabled.

    Could you please confirm whether the push button was intentionally disabled in your firmware?

    Currently, it appears that the devices can consistently exit ship mode using VIN, but not always with the push button. The NTC pin connection does not seem to affect whether the device can wake using the push button. However, potential connection issues with the NTC are still possible, whether relevant to this issue or not.

    I would like to see the waveforms for IBAT, VSYS, TS/MR, and VIN when attempting to exit ship mode using the push button on a device where the push button does not wake the device. This waveform should help us determine whether the device is entering lockout due to a BATOCP event, in which case inserting an adapter would be the only way to exit lockout.

    It's possible that some devices are unable to exit ship mode using the push button because the push button becomes disabled, while in other cases, the issue may be due to a BATOCP lockout.

    Best regards,

    Alec Lehman

  • Hello Alec

    Thanks a lot for the hint about that bit. That bit (EN_PUSH) is not intentionally disabled by the firmware. I do read, modify, write and something seams to go wrong in very rare cases. I changed to write only to set all bits to the wanted values. This worked now on two devices that did not start anymore. I have noticed that this bit was different in some cases, but I didn't think that this has an influence on the behavior for our case.  The description in the datasheet is "Enable Push Button and Reset Function on Battery Only". I interpreted that the push button will only work in battery mode if this bit is set and work in any case if the bit is cleared. 

    So I think, this generally solves the problem. We still have this one device that reports open NTC. That device does not start on pushbutton pressed, even if the bit is set. I assume that is a problem of that single device. At the moment we cannot take waveforms of that device, because we can not open it without removing the battery. 

    Kind regards,

    Matthias

  • Hello Matthias,

    Thank you for confirming that the firmware was not supposed to be changing the EN_PUSH bit. I'm glad to hear that the issue is fixed by ensuring that the push button is enabled.

    I noticed that for one of the devices where the push button was not waking from ship mode, the TS_WARM and TS_COOL bits were being set. Notice that reg[0B]=0x0C in the provided registers below, whereas in all of the other provided register dumps, reg[0B]=0x00. I think this could also indicate an issue with how the registers are being set. Were these bits being set intentionally?

    Device that does not start with button (battery not removed/reinserted yet):

    reg[00]: 0x81
    reg[01]: 0x00
    reg[02]: 0x40
    reg[03]: 0x46
    reg[04]: 0x47
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x01
    reg[0A]: 0x40
    reg[0B]: 0x0C
    reg[0C]: 0xC0

    As for the one device that is reporting TS_OPEN_STAT, is VIN = 5V present when this bit (TS_OPEN_STAT) is being read as 1? It's possible that there is an issue with how the registers are being set for this device too.

    Best regards,

    Alec Lehman

  • Hello Alec

    The register reg[0B] is not accessed by the firmware. It is not written or read at all (except for the dump). Somehow strange, that the value is not the default value on that device (with TS_OPEN_STAT). I set the register back to default, but the device does still not wake up from ship mode. 

    Anyway that device (with TS_OPEN_STAT) maybe has other problems. Another time I made a dump, the registers were like this: 

    reg[00]: 0x00
    reg[01]: 0x82
    reg[02]: 0x04
    reg[03]: 0x46
    reg[04]: 0x47
    reg[05]: 0x2C
    reg[06]: 0x96
    reg[07]: 0x87
    reg[08]: 0x4D
    reg[09]: 0x01
    reg[0A]: 0x40
    reg[0B]: 0x00
    reg[0C]: 0xC0

    The dumps are with VIN = 5V. In this case the VIN_OVP Fault is set and VIN Power Good is not set. 

    Kind regards,

    Matthias

  • Hello Matthias,

    It appears that the primary cause of the issues you're experiencing is related to unintended firmware behavior. I recommend prioritizing the resolution of these firmware issues before proceeding with any other troubleshooting. Once that's addressed, if any issues persist, I'd be happy to investigate them. Fixing the root cause will help us avoid addressing problems that may stem from the firmware. Please feel free to reach out after if needed.

    Best regards,

    Alec Lehman

  • Hello Alec

    Thank you. Ok, so far this is good. We will internally investigate the issue on this one device. All other devices work as expected when the bit is set.

    Kind regards,

    Matthias