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.

TPS25750: Enabling USB-C PD negociation when loading patch from MCU and no battery connected

Part Number: TPS25750
Other Parts Discussed in Thread: BQ25792,

Hello,

We are currently working on a 60W (20V, 3A) battery powered product using the TPS25750D+BQ25792 and would like it to work when the battery is taken out of the product as well, but we cannot manage to make the TPS25750D negociate contracts with the power source while the battery is dead or not present.

So far here is what we have tried:

-Using the "always enable sink" mode:

  • The system does boot when we plug in the USB-C PD capable charger, 5V 3A power supply is correctly provided.
  • The PBM 4CC tasks are used to load the PATCH from the MCU.
  • Once the patch is loaded successfully we are still in 5V 3A power supply mode.
  • We can communicate with the BQ25792 using the 4CC commands but we are stuck in 5V 3A when we would like the contract to be 20V 3A.

From what we understood via the datasheets and other technical documentation, this is due to the dead battery flag being still up and the TPS25750D working as a legacy (non PD) USB device. However when we try to clear the dead battery flag, using the DBFg 4CC command, the power supply cuts off and the system shuts down. The only way we can start negociating PD contracts in this configuration is by plugging in the battery pack (which is exactly what we don't want to do), and clearing the dead battery flag.

-Using the "negociate high voltage" mode:

  • The system does boot when we plug USB-C PD capable charger, 20V 3A power supply is correctly provided.
  • We can communicate with the TPS25750D but not with the BQ25792 as the PATCH is not yet loaded.
  • As soon as we try to load the PATCH, the TPS25750D cuts the power supply off, shutting down our system.

As you can see we have tried multiple configurations and none seem to work as we would like.

From what we have read in other posts on this very forum the TPS25750D should allow this functionality but we cannot find what is preventing it...

Best regards,

Morgan.

  • Good Morning Morgan,

    Would you be able to provide the settings file (JSON) format from the TPS25750 Application Customization GUI that you are using?

    Kind regards,

    Conner Gillette

  • Hello Conner,

    I work with Morgan on this project. Please find below the json from the TPS25750 App GUI from which we generate the lowRegion.bin we load through I²C.

    {
       "questionnaire":{
          "version":"7.0.4.7",
          "answers":[
             4,
             null,
             3,
             null,
             1,
             1,
             1,
             null,
             1,
             null,
             0,
             12.6,
             3,
             0.12,
             0.32
          ],
          "options":{
             
          },
          "configID":"0000",
          "vendorID":"0000"
       },
       "configuration":{
          "data":{
             "selected_ace":[
                {
                   "register":6,
                   "data":[
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0
                   ]
                },
                {
                   "register":22,
                   "data":[
                      10,
                      0,
                      0,
                      77,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      3
                   ]
                },
                {
                   "register":50,
                   "data":[
                      0,
                      168,
                      42,
                      44,
                      145,
                      1,
                      38,
                      44,
                      209,
                      2,
                      0,
                      44,
                      177,
                      4,
                      0,
                      244,
                      65,
                      6,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0
                   ]
                },
                {
                   "register":51,
                   "data":[
                      4,
                      44,
                      145,
                      1,
                      16,
                      44,
                      209,
                      2,
                      0,
                      44,
                      177,
                      4,
                      0,
                      44,
                      65,
                      6,
                      0,
                      69,
                      65,
                      6,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0
                   ]
                },
                {
                   "register":92,
                   "data":[
                      48,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      16,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      48,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      4,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0,
                      0
                   ]
                },
                {
                   "register":117,
                   "data":[
                      0,
                      0,
                      0,
                      0
                   ]
                }
             ]
          }
       }
    }

  • Also, if this can help, here is the dump of most of the registers when we have no battery plugged on a 60W USB-C power supply :

    {
            "registers": {
                    "tps25750": {
                            "mode": "APP ",
                            "type": "I2C ",
                            "device_capabilities": {
                                    "power_role": 0,
                                    "usb_pd_capability": 0,
                                    "bc1p2_supported": 3,
                                    "i2cm_level": 1
                            },
                            "int_event1": {
                                    "cmd_complete": 1,
                                    "error_device_incompatible": 0,
                                    "error_cannot_provide_voltage_or_current": 0,
                                    "error_can_provide_voltage_or_current_later": 0,
                                    "error_power_event_occurred": 0,
                                    "error_missing_get_cap_message": 0,
                                    "error_protocol_error": 0,
                                    "error_message_data": 0,
                                    "snk_transition_complete": 0,
                                    "plug_early_notification": 0,
                                    "error_unable_to_source": 0,
                                    "tx_mem_buffer_empty": 0,
                                    "patch_loaded": 1,
                                    "ready_for_patch": 1,
                                    "i2c_master_nack_ed": 0
                            },
                            "status": {
                                    "plug_present": 1,
                                    "conn_state": 6,
                                    "plug_orientation": 0,
                                    "port_role": 0,
                                    "data_role": 0,
                                    "vbus_status": 1,
                                    "usb_host_present": 0,
                                    "acting_as_legacy": 3,
                                    "bist": 0
                            },
                            "power_path_status": {
                                    "pp_cable1_switch": 0,
                                    "pp1switch": 0,
                                    "pp3switch": 1,
                                    "pp1_overcurrent": 0,
                                    "pp_cable1_overcurrent": 0,
                                    "power_source": 2
                            },
                            "port_control": {
                                    "type_c_current": 2,
                                    "resistor15k_present": 0,
                                    "charger_advertise_enable": 0,
                                    "charger_detect_enable": 0
                            },
                            "boot_status": {
                                    "patch_header_err": 0,
                                    "dead_battery_flag": 1,
                                    "i2c_eeprom_present": 0,
                                    "patch_download_err": 0,
                                    "master_tsd": 0,
                                    "patch_config_source": 6,
                                    "rev_id": 161
                            },
                            "device_info": "TPS65992 HW00A1 FWF509.05.00_0008 ZAceS",
                            "sink_caps": {
                                    "num_pdo": 4,
                                    "PD1": {
                                            "operational_current_mA": 3000,
                                            "voltage_mV": 5000,
                                            "dual_role_data": 0,
                                            "higher_capability": 1,
                                            "dual_role_power": 0,
                                            "supply_type": 0
                                    },
                                    "PD2": {
                                            "operational_current_mA": 3000,
                                            "voltage_mV": 9000,
                                            "dual_role_data": 0,
                                            "higher_capability": 0,
                                            "dual_role_power": 0,
                                            "supply_type": 0
                                    },
                                    "PD3": {
                                            "operational_current_mA": 3000,
                                            "voltage_mV": 15000,
                                            "dual_role_data": 0,
                                            "higher_capability": 0,
                                            "dual_role_power": 0,
                                            "supply_type": 0
                                    },
                                    "PD4": {
                                            "operational_current_mA": 3000,
                                            "voltage_mV": 20000,
                                            "dual_role_data": 0,
                                            "higher_capability": 0,
                                            "dual_role_power": 0,
                                            "supply_type": 0
                                    },
                                    "active": {
                                            "operational_current_mA": 0,
                                            "voltage_mV": 0,
                                            "dual_role_data": 0,
                                            "higher_capability": 0,
                                            "dual_role_power": 0,
                                            "supply_type": 0
                                    }
                            },
                            "power_status": {
                                    "power_connection": 1,
                                    "source_sink": 1,
                                    "type_c_current": 2,
                                    "charger_detect_status": 0,
                                    "charger_advertise_status": 2
                            },
                            "pd_status": {
                                    "cc_pull_up": 3,
                                    "port_type": 1,
                                    "present_pd_role": 0,
                                    "soft_reset_details": 0,
                                    "hard_reset_details": 0,
                                    "error_recovery_details": 0,
                                    "data_reset_details": 0
                            }
                    },
                    "bq25792": {
                            "reg00_minimal_system_voltage": {
                                    "vsysmin_raw": 26,
                                    "vsysmin_mv": 9000
                            },
                            "reg01_charge_voltage_limit": {
                                    "charge_voltage_limit_raw": 1260,
                                    "charge_voltage_limit_mv": 12600
                            },
                            "reg03_charge_current_limit": {
                                    "charge_current_limit_raw": 300,
                                    "charge_current_limit_ma": 3000
                            },
                            "reg05_input_voltage_limit": {
                                    "input_voltage_limit_raw": 46,
                                    "input_voltage_limit_mv": 4600
                            },
                            "reg06_input_current_limit": {
                                    "charge_input_limit_raw": 300,
                                    "charge_input_limit_ma": 3000
                            },
                            "reg0f_charger_control_0": {
                                    "en_term": 1,
                                    "en_hiz": 0,
                                    "force_ico": 0,
                                    "en_ico": 0,
                                    "en_chg": 1,
                                    "force_ibatdis": 0,
                                    "en_auto_ibatdis": 1
                            },
                            "reg10_charger_control_1": {
                                    "watchdog_2": 0,
                                    "wd_rst": 0,
                                    "vac_ovp_1": 0
                            },
                            "reg13_charger_control_4": {
                                    "en_ibus_ocp": 1,
                                    "force_vindpm_det": 0,
                                    "dis_votg_uvp": 0,
                                    "dis_vsys_short": 0,
                                    "dis_stat": 0,
                                    "pwm_freq": 0,
                                    "en_acdrv1": 0,
                                    "en_acdrv2": 0
                            },
                            "reg16_temperature_control": {
                                    "vac2_pd_en": 0,
                                    "vac1_pd_en": 0,
                                    "vbus_pd_en": 0,
                                    "tshut_1": 0,
                                    "treg_1": 3
                            },
                            "reg1b_charger_status_0": {
                                    "vbus_present_stat": 1,
                                    "ac1_present_stat": 1,
                                    "ac2_present_stat": 1,
                                    "pg_stat": 1,
                                    "poorsrc_stat": 0,
                                    "wd_stat": 0,
                                    "vindpm_stat": 0,
                                    "iindpm_stat": 0
                            },
                            "reg1c_charger_status_1": {
                                    "bc1_2_done_stat": 0,
                                    "vbus_stat": 5,
                                    "chg_stat_2": 0
                            },
                            "reg1d_charger_status_2": {
                                    "vbat_present_stat": 0,
                                    "dpdm_stat": 0,
                                    "treg_stat": 0,
                                    "ico_stat_1_0": 0
                            },
                            "reg24_charger_flag_2": {
                                    "topoff_tmr_flag": 0,
                                    "prechg_tmr_flag": 0,
                                    "trichg_tmr_flag": 0,
                                    "chg_tmr_flag": 0,
                                    "vsys_flag": 1,
                                    "adc_done_flag": 0,
                                    "dpdm_done_flag": 1
                            },
                            "reg2e_adc_control": {
                                    "adc_avg_init": 0,
                                    "adc_avg": 0,
                                    "adc_sample_1": 3,
                                    "adc_rate": 0,
                                    "adc_en": 0
                            },
                            "reg2f_adc_function_disable0": {
                                    "tdie_adc_dis": 0,
                                    "ts_adc_dis": 0,
                                    "vsys_adc_dis": 0,
                                    "vbat_adc_dis": 0,
                                    "vbus_adc_dis": 0,
                                    "ibat_adc_dis": 0,
                                    "ibus_adc_dis": 0
                            },
                            "reg30_adc_function_disable1": {
                                    "vac1_adc_dis": 0,
                                    "vac2_adc_dis": 0,
                                    "dm_adc_dis": 0,
                                    "dp_adc_dis": 0
                            },
                            "reg35_vbus_adc": {
                                    "vbus_adc_mv": 5134
                            },
                            "reg3b_vbat_adc": {
                                    "vbat_adc_mv": 0
                            },
                            "reg3d_vsys_adc": {
                                    "vsys_adc_mv": 0
                            },
                            "reg47_dpdm_driver": {
                                    "dminus_dac_2": 0,
                                    "dplus_dac_2": 0
                            }
                    }
            }
    }

  • While using 'AlwaysEnableSink" mode, after the patch is loaded, can you attempt to send the 4CC command GSrc? This should cause the higher voltage PDO to be negotiated if the patch was successfully loaded and the source offers higher voltage PDOs. Please let me know if this resolves your issue, or if you run into further issues.

    Detail on the 4CC command below:

    Kind regards,

    Conner Gillette

  • Hello Conner,

    after more testing, the 'GSrC' command is always rejected (task result 0x3) while the negotiation is not done :

    • Battery unplugged w/ Dead Battery Flag-> 'GSrC' result 0x3
    • Plug Battery -> 'GSrC' result 0x3
    • Clear Dead-Battery flag -> Negotiation done -> 'GSrC' result 0x00

    When the negotiation is done, we can see that the 0x30 register is updated, but the 'GSrC' command doesn't seem to be able to update it by itself before that.

    You can see below the list of the Source Capabilities once the negotiation is done :

    {
    "rx_source_caps": {
            "num_pdo": 6,
            "PD1": {
                    "operational_current_mA": 2500,
                    "voltage_mV": 5000,
                    "peak_current": 0,
                    "unchunked_ext_support": 0,
                    "dual_role_data": 0,
                    "usb_suspend_support": 0,
                    "dual_role_power": 1,
                    "supply_type": 0
            },
            "PD2": {
                    "operational_current_mA": 2730,
                    "voltage_mV": 9000,
                    "peak_current": 0,
                    "unchunked_ext_support": 0,
                    "dual_role_data": 0,
                    "usb_suspend_support": 0,
                    "dual_role_power": 1,
                    "supply_type": 0
            },
            "PD3": {
                    "operational_current_mA": 2800,
                    "voltage_mV": 12000,
                    "peak_current": 0,
                    "unchunked_ext_support": 0,
                    "dual_role_data": 0,
                    "usb_suspend_support": 0,
                    "dual_role_power": 1,
                    "supply_type": 0
            },
            "PD4": {
                    "operational_current_mA": 2840,
                    "voltage_mV": 15000,
                    "peak_current": 0,
                    "unchunked_ext_support": 0,
                    "dual_role_data": 0,
                    "usb_suspend_support": 0,
                    "dual_role_power": 1,
                    "supply_type": 0
            },
            "PD5": {
                    "operational_current_mA": 3130,
                    "voltage_mV": 20000,
                    "peak_current": 0,
                    "unchunked_ext_support": 0,
                    "dual_role_data": 0,
                    "usb_suspend_support": 0,
                    "dual_role_power": 1,
                    "supply_type": 0
            },
            "PD6": {
                    "operational_current_mA": 3140,
                    "voltage_mV": 13200,
                    "peak_current": 2,
                    "unchunked_ext_support": 1,
                    "dual_role_data": 0,
                    "usb_suspend_support": 0,
                    "dual_role_power": 0,
                    "supply_type": 3
            }
        }
    }

    Given the datasheet, do you have a way to know why the command is rejected ?

    Best regards,

    Richard

  • Just to clarify, are you trying to send GSrC after you see the 0x31 register (your sink capabilities, since you are sinking power to charge the dead battery) updated with your high voltage PDOs?

  • We are trying to send the GSrC after loading the lowRegion.bin through I²C. As we are a sink-only device (only recharge the battery), at that moment, we can see the 0x33 TX_SINK_CAPS register (our sinks caps we promote to the source), but nothing in the 0x30 RX_SOURCE_CAPS register.

    We never read the 0x31 RX_SINK_CAPS register. Do we need to ?

    Richard

  • Could it be possible we maybe made a mistake in our electrical hw wiring ? Please see an extract of our schematics, if you see an evident mistake we could have made.

    Thank you,

    Richard

  • Thank you Richard, I will review the schematic and the dead battery functionality and provide an update by Friday EOB.

  • Thank you ! Additional information we discovered today : when disconnecting/reconnecting the CC lines, it seems to trigger the PD negotiation. This test was done while having the battery plugged but the dead-battery flag still on, just so our system doesn't shutdown when disconnecting the CC lines.

    Have you seen similar behavior before ?

    Richard

  • I haven't seen this behavior before, no. So, you're able to successfully load the patch, but the device won't renegotiate to a higher PDO until you disconnect and reconnect the CC lines?

    Also, after giving your schematic a cursory review, I don't see any issues. I will consult with one of our systems engineers and get back to you.

    Kind regards,

    Conner

  • Hi Conner,

    Good news, we believe we have found what the issue was:

    During initial plugging of the USB-C cable, the source (our 60W PD charger) send SOURCE_CAPABILITIES but our system is not yet responsive because our MCU hasn't booted yet and cannot load the patch. After sending multiple messages the PD charger is timing out leading to legacy charger behaviour. We tried making our MCU boot early and charge the patch as soon as we plug in the USB-C cable and the negotiation occured as expected.

    Thank you for your time, I hope this can solve other people issues as well.

    Best regards,

    Morgan.

  • Thank you for following up. I'm glad to hear it's working. Please reach out if you run into any further issues.

    Kind regards,

    Conner Gillette