EZ-USB FX3 Technical Reference Manual, Document Number: 001-76074 Rev. *F 103
Universal Serial Bus (USB)
if ((wValue != CY_U3P_USB2_OTG_B_HNP_ENABLE) && (wValue != CY_U3P_USB2_OT-
G_A_HNP_SUPPORT))
{
CyU3PUsbHandleSetFeature ((uint8_t)wValue);
return;
}
else
{
/* Send the request to the application. */
if ((glUibDeviceInfo.enumMethod == CY_U3P_USBENUM_WB) && (glUsbSetupCb
!= NULL))
{
isHandled = glUsbSetupCb (setupdat0, setupdat1);
if (isHandled)
{
glUibDeviceInfo.sendStatusEvent = CyTrue;
return;
}
}
}
break;
}
isHandled = CyFalse;
/* Set feature requests are forwarded to the application regardless of the
enumeration mode.
If the application returns false, then the request is handled here. */
if ((glUibDeviceInfo.enumMethod == CY_U3P_USBENUM_WB) && (glUsbSetupCb !=
NULL))
{
isHandled = glUsbSetupCb (setupdat0, setupdat1);
if (isHandled)
glUibDeviceInfo.sendStatusEvent = CyTrue;
}
/* If the application has not handled this request and this is a set feature
(EP HALT),
handle it here. */
if ((!isHandled) && (bTarget == CY_U3P_USB_TARGET_ENDPT) && (wValue ==
CY_U3P_USBX_FS_EP_HALT))
{
if ((CyU3PUsbStall (wIndex, CyTrue, CyFalse)) == CY_U3P_SUCCESS)
{
CyU3PUsbAckSetup ();
isHandled = CyTrue;
}
}
}
break;
case CY_U3P_USB_SC_GET_DESCRIPTOR:
{
isHandled = CyU3PUibSendDescr (setupdat0, setupdat1);
}
break;
case CY_U3P_USB_SC_GET_CONFIGURATION: