I’m trying to design my own battery pack. I want to use usb-c as one of the inputs. The goal is to draw as much power from the usb-c port as the source supports and to feed that into a boost converter to charge the cells.
I’m thinking about using the STUSB4500 (datasheet). The IC has 3 PDOs, PDO1 is fixed to 5v, PDO2 and 3 can be set to any voltage. A minimum required current can also be set for each PDO. Upon plugging into a charger, the IC will check whether any of the set voltages match the available voltages of the source, highest priority to PDO3, lowest to PDO1. If, for a common voltage, the source’s available current is greater or equal to the set current, it will agree on that voltage and allow power output.
There’s also a parameter you can set over i2c
REQ_SRC_CURRENT. When set to 1, the IC will automatically select the highest available current, instead of the one set in the PDO.
So I was thinking, maybe I could enable this parameter and set the PDOs like this:
- PDO3: 20v, 0.5A
- PDO2: 12v, 0.5A
- PDO1: 5v, 0.5A
Every charger will be able to output at least 0.5A, so by doing this, the IC will pick the highest voltage and then set the current to the highest available. I think I could then get this maximum current using i2c, and limit the cell charging current to not exceed this.
Do you think this is a viable solution? One problem I’m thinking of is that if the charger would output for example 15v, this wouldn’t be a match and they would settle on 5v. Because there’s a limited amount of PDOs, I can’t set one for every common voltage.