+ CurrentHIDInterface = DESCRIPTOR_PCAST(ConfigDescriptorData, USB_Descriptor_Interface_t);
+ } while (HIDInterfaceInfo->Config.HIDInterfaceProtocol &&
+ (CurrentHIDInterface->Protocol != HIDInterfaceInfo->Config.HIDInterfaceProtocol));
+
+ HIDInterfaceInfo->State.InterfaceNumber = CurrentHIDInterface->InterfaceNumber;
+ HIDInterfaceInfo->State.SupportsBootProtocol = (CurrentHIDInterface->SubClass != HID_BOOTP_NonBootProtocol);
+
+ if (USB_GetNextDescriptorComp(&ConfigDescriptorSize, &ConfigDescriptorData, DCOMP_HID_NextHID) != DESCRIPTOR_SEARCH_COMP_Found)
+ return HID_ENUMERROR_NoCompatibleInterfaceFound;
+
+ HIDInterfaceInfo->State.HIDReportSize = DESCRIPTOR_PCAST(ConfigDescriptorData,
+ USB_HID_Descriptor_HID_t)->HIDReportLength;
+
+ DataINEndpoint = NULL;
+ DataOUTEndpoint = NULL;
+
+ continue;