Use the CYUSB3014 firmware programming registration callback function to parse the two, what is the meaning of the parameters?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
WiLi_4402436
Level 1
Level 1
First like given

Just contact USB, there is a question I would like to ask

There is a registration callback function in the CYUSB3014 firmware programming:

CyU3PUsbRegisterSetupCallback(CyFxSlFIFoApplnUSBSetuPCB, CyTrue);

There are two parameters in CyFxSlFifoApplnUSBSetupCB:

Uint32_t setupdat0,

Uint32_t setupdat1

The two parameters are parsed in the function. I want to ask what these two parameters mean. What do you mean by that? ? ?

     bReqType = (setupdat0 & CY_U3P_USB_REQUEST_TYPE_MASK);

     bType = (bReqType & CY_U3P_USB_TYPE_MASK);

     bTarget = (bReqType & CY_U3P_USB_TARGET_MASK);

Thank you!

William

0 Likes
1 Solution
YangyangC_06
Employee
Employee
750 replies posted 500 replies posted 250 replies posted

Setupdat0 is the variable that holds the values of  bmRequestType, bRequest and wValue.

Setupdat1 is the variable that holds the values of  wIndex and wLength.

View solution in original post

2 Replies
YangyangC_06
Employee
Employee
750 replies posted 500 replies posted 250 replies posted

Setupdat0 is the variable that holds the values of  bmRequestType, bRequest and wValue.

Setupdat1 is the variable that holds the values of  wIndex and wLength.