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.

TPS25751: Charging DRP device like laptop/MacBook

Part Number: TPS25751

Tool/software:

Dear TI support,

we have finally solved some problems with TPS25751 in use with external MCU and finally got SOURCE mode working properly. See the thread bellow if needed:

https://e2e.ti.com/support/power-management-group/power-management/f/power-management-forum/1414755/tps25751-development-with-external-mcu-and-bq25731

Now we would like to be able to charge from our DRP device another DRP device like laptop MacBook,power bank etc.

I Attach our json file here:

{
  "questionnaire": {
    "device": "TPS25751",
    "answers": [
      null,
      1,
      4,
      4,
      0,
      0,
      0,
      3,
      1,
      1,
      1,
      null,
      0,
      0,
      0,
      0,
      0,
      0,
      0
    ],
    "vendorId": "0000",
    "productId": "0000",
    "version": "1.0.0.2"
  },
  "configuration": {
    "data": {
      "selected_ace": [
        {
          "register": 6,
          "data": [
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0
          ]
        },
        {
          "register": 22,
          "data": [
            10,
            48,
            0,
            76,
            0,
            4,
            0,
            0,
            0,
            0,
            3
          ]
        },
        {
          "register": 40,
          "data": [
            2,
            0,
            63,
            7,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0
          ]
        },
        {
          "register": 41,
          "data": [
            82,
            80,
            152,
            90
          ]
        },
        {
          "register": 50,
          "data": [
            5,
            168,
            42,
            44,
            145,
            1,
            32,
            44,
            209,
            2,
            0,
            44,
            193,
            3,
            0,
            44,
            177,
            4,
            0,
            244,
            65,
            6,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0
          ]
        },
        {
          "register": 51,
          "data": [
            5,
            44,
            145,
            1,
            16,
            44,
            209,
            2,
            0,
            44,
            193,
            3,
            0,
            44,
            177,
            4,
            0,
            69,
            65,
            6,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0
          ]
        },
        {
          "register": 55,
          "data": [
            63,
            64,
            31,
            65,
            144,
            145,
            1,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0
          ]
        },
        {
          "register": 92,
          "data": [
            11,
            4,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            5,
            0,
            0,
            0,
            48,
            4,
            0,
            0,
            0,
            0,
            0,
            0,
            5,
            12,
            0,
            0,
            48,
            0,
            0,
            0,
            5,
            8,
            0,
            0,
            73,
            1,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0
          ]
        },
        {
          "register": 112,
          "data": [
            3
          ]
        },
        {
          "register": 152,
          "data": [
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0
          ]
        }
      ]
    }
  }
}

We have preferred power role set to Power source (provider), but when we connect our device to laptop Lenovo ThinkPad, our device is being charged from laptop and there is no DR_Swap to source mode as we would expect. See the log attached.

3644.log.zip

For example when I connect smart phone Xiaomi 14 which is DRP too, there is automatically issued DR_Swap in order to our device start to act as Source. I would expect the same with the laptop.

Could you point us please, what to do with TPS25751 in order to switch it to source mode and start charging the laptop?

Thank you

  • Hi Jan,

    In this case, you are looking for a PR(Power Role swap). Does your device always want to be source? There is a bit in the Port Control Registers for "Initiate Swap to Source" that can be used here. What this does, is any time the TPS25751 starts in the Sink power role, it will send a power role swap request to the far-end.

    I generated a .c file based off of the previous PP3 one that has the "initiate swap to source" bit set. I also attached the JSON. The FW change is not included in the json, and is still not supported by the GUI as mentioned before, but you can use the json for reference for the field changed.

    {
      "questionnaire": {
        "device": "TPS25751",
        "toolBuildVersion": "1.0.2",
        "answers": [
          null,
          1,
          4,
          4,
          0,
          0,
          0,
          3,
          1,
          1,
          1,
          null,
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ],
        "vendorId": "0000",
        "productId": "0000",
        "version": "1.0.0.2"
      },
      "configuration": {
        "data": {
          "selected_ace": [
            {
              "register": 6,
              "data": [
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 22,
              "data": [
                10,
                48,
                0,
                76,
                8,
                4,
                0,
                0,
                0,
                0,
                3
              ]
            },
            {
              "register": 40,
              "data": [
                2,
                0,
                63,
                7,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 41,
              "data": [
                210,
                80,
                152,
                90
              ]
            },
            {
              "register": 50,
              "data": [
                5,
                170,
                42,
                44,
                145,
                1,
                32,
                44,
                209,
                2,
                0,
                44,
                193,
                3,
                0,
                44,
                177,
                4,
                0,
                244,
                65,
                6,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 51,
              "data": [
                5,
                44,
                145,
                1,
                16,
                44,
                209,
                2,
                0,
                44,
                193,
                3,
                0,
                44,
                177,
                4,
                0,
                69,
                65,
                6,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 55,
              "data": [
                63,
                64,
                31,
                65,
                144,
                145,
                1,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 66,
              "data": [
                26,
                0,
                8,
                0
              ]
            },
            {
              "register": 92,
              "data": [
                11,
                4,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                5,
                0,
                0,
                0,
                48,
                4,
                0,
                0,
                0,
                0,
                0,
                0,
                5,
                12,
                0,
                0,
                48,
                0,
                0,
                0,
                5,
                8,
                0,
                0,
                73,
                1,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 112,
              "data": [
                3
              ]
            },
            {
              "register": 119,
              "data": [
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                15,
                0
              ]
            },
            {
              "register": 122,
              "data": [
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 123,
              "data": [
                0,
                2,
                255,
                255,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 125,
              "data": [
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 126,
              "data": [
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            },
            {
              "register": 152,
              "data": [
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0,
                0
              ]
            }
          ]
        }
      }
    }

    Jan_fixed-120424.c

    Thanks and Regards,

    Chris

  • Hi Chris,

    thank you for fast .c file generation, I have tried this Initiate Swap to Source bit before, but it doesn't work correctly.

    I attach logs with the behavior.

    7433.log.zip

    Would you have any idea how to make it work, please?

    Thank you

  • Hi Jan,

    Due to the nature of PD logs, it is a little unclear which side is which. I'm going to assume that as you said, the far end acts as source. In this case, the TPS25751 begins as UFP Sink

    The "initiate swap to source" setting appears to be working, as we see a PR_SWAP initiated by the sink multiple times (first instance is line 26). The issue is what happens after. Let me explain the expected behavior, and then break down where you might need to debug and address potential issues.

    PR_Swap initiated

    Far end accepts

    Original source removes VBUS

    Sends PSRDY when VUBS is removed

    Original Sink becomes New Source and starts to prepare VBUS by providing 5-V

    New Source sends PSRDY when complete.

    What are you doing with your 5-V and PPHV supplies during the this transition? Are they able to source 5-V at this time?

    The first time, we see that the system makes it past the PR_SWAP case and then attempts to negotiate a high voltage contract, where the voltage immediately drops out. Can you help me understand what you see from the MCU and Voltage programming at this time? Have we provided 5-V to PPHV at this point?

      

    We see multiple disconnects and reconnects in the remainder of the logs, where we see the system only make it to the finaly ps_rdy. Then the 5-V drops to 4-V? Do you know what could be causing this behavior and where that 4-V is coming from?

    Thanks and Regards,

    Chris

  • Hi Chris,

    sorry for long delay, I will evaluate your tips shortly and let you know if I find anything.

    Thank you

  • Hi Jan,

    Sounds good, will wait for your feedback.

    Thanks and Regards,

    Chris