How to make STUSB4500 negotiate PDO2 automatically?
My schematic is exactly as shown on page 26 of https://www.st.com/resource/en/datasheet/stusb4500.pdf with an ESP32 connected to the I2C pins and a BQ2057WSN downstream on Vsnk. However, on connection to USB-C the chip negotiates an explicit 5V power contract (verified with a PD sniffer) instead of the 9V specified in PDO2/PDO3. If I run a trivial sketch on the microcontroller that does nothing at all other than connecting to the chip over I2C and issuing a soft reset then the STUSB4500 again starts out at 5V, but then correctly renegotiates to 9V.
I need the STUSB4500 to function autonomously so that my device can charge without power to the microcontroller. What am I missing?
If it helps, when I run the ReadParameters example from the SparkFun libraries at https://github.com/sparkfun/SparkFun_STUSB4500_Arduino_Library the output I get is:
Connected to STUSB4500!
PDO Number: 2
Voltage1 (V): 5.00
Current1 (A): 1.00
Lower Voltage Tolerance1 (%): 0
Upper Voltage Tolerance1 (%): 20
Voltage2 (V): 9.00
Current2 (A): 1.50
Lower Voltage Tolerance2 (%): 10
Upper Voltage Tolerance2 (%): 10
Voltage3 (V): 9.00
Current3 (A): 1.50
Lower Voltage Tolerance3 (%): 10
Upper Voltage Tolerance3 (%): 10
Flex Current: 5.32
External Power: 0
USB Communication Capable: 0
Configuration OK GPIO: 0
GPIO Control: 1
Enable Power Only Above 5V: 1
Request Source Current: 0