Hi,
I've been trying to negotiate entering alternate modes between two CYPD2122 CCG2 controllers. I've successfully been able to handle the USD PD "Discover Identity" and "Discover SVIDs" commands. However when I try to use the "Discover Modes" command to get a list of available modes from the UFP, all the modes are populated with the VDM header for the transaction.
For example, if I used the EZ-PD config utility to set the SVID=0x6666 and defined 3 modes 0x11111111, 0x22222222, and 0x33333333 then when I request the modes for SVID 0x6666, the UFP acknowledges the request by sending a list of 3 modes all set to 0x66668043 (the VDM Header for the transaction). If I request modes for a different invalid SVID, it correctly NACKs the request. If I define a different number of modes for the SVID configuration, the response has the correct number of modes, but they are all incorrectly set to the VDM for the transaction.
Also, none of the callbacks in "pd_vdm.c" are ever being called even though they are correctly initialized at the start of main(). The documentation for the CCG2 API indicates that this is where user code is called when the API responses to VDM messages. However, my code is clearly responding to VDM messages, yet none of these callbacks are ever reached according to the debugger.
Some notes about my setup. I based my code off the CYPD-2122-24LQXI-notebook example. My application does not need a bootloader or the HPI interface so I have disabled/removed the corresponding code from my application.
Any help in resolving these issues would be greatly appreciated. Thanks