I am designing a device in which will have a phone with a USB-C port (host) connected to a USB 2.0 device (OTG mode). When the phone is connected to the device, it provides power to the device. I would like that when I connect a charger, the phone becomes a power sink rather than a source (and of course power to the USB 2.0 device is also maintained) so that it can be charged.
I have read this whitepaper and I know I need atleast a USB Type C port controller that supports Dual Role Power. For now, I do not care about USB PD. I have concluded that the TUSB320 will probably get the job done and I would like someone to confirm that the reference design below is in fact what I am looking for.
This is my planned design (and understanding). I would connect D+,D-,GND and 5V to my USB 2.0 device, connect the ID pin to a logic level FET (Source to 5V, Drain to VBUS). When no charger is present, the CC and ID pins will be set such that the phone provides 5V through the FET to the USB 2.0 device. When a charger is connected on VBUS, the CC pins will be set such that the phone sinks the power. My VBUS will be 5V.
Will this design work?