{\r
/* Check the HID descriptor class and protocol, break out if correct class/protocol interface found */\r
if ((DESCRIPTOR_CAST(CurrentDescriptor, USB_Descriptor_Interface_t).Class == KEYBOARD_CLASS) &&\r
- (DESCRIPTOR_CAST(CurrentDescriptor, USB_Descriptor_Interface_t).Protocol == KEYBOARD_PROTOCOL))\r
+ (DESCRIPTOR_CAST(CurrentDescriptor, USB_Descriptor_Interface_t).Subclass == KEYBOARD_SUBCLASS))\r
{\r
- return Descriptor_Search_Found;\r
+ return DESCRIPTOR_SEARCH_Found;\r
}\r
}\r
\r
if (DESCRIPTOR_TYPE(CurrentDescriptor) == DTYPE_Endpoint)\r
{\r
if (DESCRIPTOR_CAST(CurrentDescriptor, USB_Descriptor_Endpoint_t).EndpointAddress & ENDPOINT_DESCRIPTOR_DIR_IN)\r
- return Descriptor_Search_Found;\r
+ return DESCRIPTOR_SEARCH_Found;\r
}\r
else if (DESCRIPTOR_TYPE(CurrentDescriptor) == DTYPE_Interface)\r
{\r
- return Descriptor_Search_Fail;\r
+ return DESCRIPTOR_SEARCH_Fail;\r
}\r
\r
- return Descriptor_Search_NotFound;\r
+ return DESCRIPTOR_SEARCH_NotFound;\r
}\r