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.

TPS65982: I_PP_HV and I_PP_EXT source current not accurate. Other current questions.

Expert 1015 points
Part Number: TPS65982
Other Parts Discussed in Thread: , HD3SS460

Status of current readings using tools as of 9/15/2017.

SINK mode (current flowing from VBUS to PP_HV or PP_EXT):
I_PP_HV can't be read in SINK mode. This is by design according to the TPS65982 datasheet so it doesn't look like there is current limit on I_PP_HV in sink mode. Am I reading the datasheet correctly?
I_PP_EXT can't be read in SINK mode (current from VBUS to PP_EXT) and connections around the sense resistor for sink. This is a problem with the TPS65982 configuration firmware through revision 3.08. Is the fix coming any time soon? I am using 5mOhms as the sense resistor.

SOURCE mode (current flowing from PP_HV or PP_EXT to VBUS):
I_PP_HV is read incorrectly by the TPS6598x utilities GUI (as of version 2.4). It shows about half the value. 
I_PP_EXT is read incorrectly by the TPS6598x utilities GUI (as of version 2.4). It shows about half the value.
There is another discussion question about this problem, "I_PP_HV Readings using HI-Utility not accurate with TI-EVM board", and it hasn't been fixed yet.

Real world problem with this...
I set up a contract with a laptop for 20V/1A of current (the laptop has a variable sink capabilities of 19-20V, 1A). When I establish the contract using a TPS65982 on my board I find that the laptop draws ~1.7A at 20V. According to the USB PD spec, version 3.0, a source advertising 20V should be able to deliver 45W (2.25A), so maybe the laptop isn't doing anything 'illegal' by drawing the 1.7A. I set my power supply connected to the PP_HV or PP_EXT connections to a 3A current limit, so it won't current limit and break the connection.
With the laptop drawing about 1.7A I found...
If I make a 2A source contract with either the PP_HV path or the PP_EXT path everything works fine.
If I change the source contract to 1A, then the PP_HV path will cycle on and off with an overcurrent interrupt. This is expected, since the laptop tries to draw 1.7A and the TPS65982 is sensing the current > the 1A source contract.
However, if I change to the PP_EXT path and source the current through it, the TPS65982 doesn't break the connection. I have the sense resistor physical connection set up to measure current in source mode. But even with a 1A contract and the path supplying 1.7A, it doesn't shut the path off. Does the current sensing on the PP_EXT path work correctly? It doesn't seem so. Again, I have a 5mOhm resistor and the SystemConfig is set up to use that 5mOhm.
Could it be related to the bad readings of the I_PP_EXT by the Hi-Utility tool? It is reading ~0.84mA when drawing the 1.7A. However, the bad readings of the I_PP_HV don't preclude it from shutting off, but the I_PP_EXT doesn't work the same way.

  • Hi WST,

    What is the Rsense value in your setup - 5 mΩ or 10 mΩ?

    Regards,
    Atiq
  • I mentioned above that it is 5mohms and the System config register is set up to use 5mohms. However, as an experiment, I changed the system config register to 10mohms and it still had the same ADC reading using the Hi-Utility tool and it didn't affect the shutdown. This makes some sense, because if I say that I have 10mohms and only have 5 on the board, then the current reading would be less that the real value. For that reason, I'm wondering if the 10mohms is accidentally hard-coded into the firmware and the system configuration register value is being ignored, so that the TPS65982 thinks that the current is only 1/2 of what it really is.
  • Hi WST,

    We have submitted the latest FW to be put on TI.com. It usually takes 2-3 days for it to show up on the web after this so you can expect it any day now.
    Regarding the current reading values, are you attempting this with our latest configuration tool? with your board connected over I2C, you can click Debug --> Debug Mode. Within Debug mode, you can send the same 4CC commands to read back the ADC value. When I was doing my testing on the ADC reading as a SINK, I measured the same value on a multi-meter that I did with the configuration tool in debug mode. Please let me know if the issue persists in this test.

    Thank you,
    Eric
  • I am using the 3.08 App config tool, and earlier was using the 2.4 utilities tool to read the ADCs.
    So, today instead, I used the 3.08 configuration tool in debug mode. I had to figure out how to get the aardvark.dll in the correct place for the tool to be able to connect over I2C. I had it working in the Utilities GUI, but had to get it working with the APP config by putting the .dll and .py files in another directory.

    When you did your reading, was this in the dead battery mode, or with a sink through the path to an external device and your TPS65982 sourcing the current?

    For my testing, I first set my PP_EXT resistors in SOURCE mode, and sourced 2A of current to the DUT from my board with the TPS65982. I can set it up to use either the PP_HV path or the PP_EXT path. The power supply and other measurements said I was sourcing around 1.8A - 2A to the board.
    1) The I_PP_EXT ADC readings were 0xAE and 0xAF, or 174d and 175d. According to the formula, this is 1.2/1023 * ADC * Isense. The configuration tool read 1.019A and 1.025A, even though I was sourcing 2A. It appears the config tool was reading about 1/2 of the true value. (174 into the formula with Isense = 5 gives 1.021A).
    2) I switched to the HV path and read 1.125A. The ADC reading was 0x140, 320d. Using the formula with 320, I get 1.877A, the actual value. However, the Config tool is using a multiplier of 3!!! (1.2/1023*320*3 = 1.126). (Actually, both the Config ADC reading and the Utilities tool ADC reading use 1024 in the formulas). So, the latest configuration tool is using the 5V path current Isense factor of 3, NOT the HV path factor of 5. I think I am reading the datasheet correctly and getting the multipliers of 3 and 5.
    With the I_PP_HV path, I get the correct reading, but only if I do the calculations myself with a factor of 5.

    I then reconfigured my board manually to read the 5mOhm sense resistor in SINK mode. I set up my power supply to sink 2A in normal mode, and it said it was sinking exactly 2A through the TPS65982 paths from the DUT. I used the Application Configuration debug mode again, and this time
    3) Using the PP_HV path I read an ADC value from I_PP_HV of 02d
    4) Using the PP_EXT path I read an ADC value from I_PP_EXT of 00d
    So, it still doesn't work using the latest 3.08 tool in SINK mode, with the current switched through either path.

    Are the ADC readings tied to the over limit controls?? Does this mean that it won't open the path using the SINK configuration, either in EXT or HV?
    The source readings are off for both paths. Does this mean the firmware that the AppConfig creates for the TPS65982 can't handle 5mohms for Rsense? Does it use an erroneous factor of '3' for the multiplier with the I_PP_HV reading when running the over-current circuitry or only for the ADC readings?

    Bottom line, I'm using the PP_EXT path, only in SINK mode (I don't have a way to dynamically reconnect the sense resistors). It doesn't look like I have any capability to read the ADC value, and also it doesn't look like the TPS65982 can detect over current in this mode.

    This was all with the 3.08 version of the configuration tool. The 2.4 version of the Utility tool doesn't work any better.
  • Hi WST,

    Just to clarify, the TPS65982 does not implement any OCP when it is configured as a SINK. OCP is only implemented when sourcing current as this is a requirement from the PD spec. This explains why OCP does not work when you are configured as a SINK.
    When I am testing the current reading on the PP_EXT Path I complete all measurement using the TPS65982-EVM. When I am configured as a SINK, I swap the resistors on the RSENSE so that they are configured properly. I then apply a resistive load on the J6 header. In line with this load, I have a multimeter to measure the current through the PP_EXT path. In this configuration with the latest FW that includes the ADCs reading for PP_EXT as a SINK in non-dead battery cases, I am able to read the same current on the multimeter and through the ADCs command.
    I want you to try to copy this configuration on your end since I know you also have a TPS65982-EVM available to work with. Just load one of the default templates, such as TPS65982_HD3SS460_DRP_Host_Advanced and confirm that the PP_EXT is configured as a SINK and the resistors around RSense are configured properly. I recommend doing this test in dead battery mode since the latest FW is not posted on the web yet. The EVM has a 10mohm RSense and you should be able to read the correct current with this setup. Please let me know if you have the same issue with the EVM in this configuration.

    Thank you,
    Eric
  • Eric,
    I went through this involved setup with my EVM board in the discussion "TPS65982: I_PP_EXT not readable if in SINK mode". See the post near the end in that thread. I was able to read the current successfully, but it wasn't in the operating mode with current supplied to the TPS65982, but in dead battery mode. So, yes, I was able to read the current using the EVM, but not in a normal mode. I couldn't tell from register 1A if the PP_EXT switch was closed and there was a question about the RCP that never was answered. I guess I'll have to wait for the new FW and see if this allows me to measure the sink current when the TPS65982 isn't in dead battery mode.
    Warren