Dynamically set PDO with G0 and ucpd - charge through dongle
The background is I am trying to build a pass through or charge through dongle like application. Using a G0 with 2 UCPD ports, port 0 as sink, and port 1 as DRP, using the respective TCPP chips
My goal is to have the input port 0, get the available PDO's, subtract the power consumed by the device, then pass these adjusted PDO's to the output, port 1, letting the up stream device chose. Once a PDO is selected on port 1, port 0 would also select the corresponding PDO
I have a couple questions about implementing this with UCPD on STM. I'm just fumbling around with a test project (no HW yet) but I can't seem to see how one would dynamical set PDO's. Specifically:
Can PDO's be set and removed dynamically during run time?
What part of the PD code would be the best area to edit / add this functionality ?
Cheers
