Prevent the SPEEDLINK COMPETITION PRO joystick from switching into Android controller mode when enumerated over HID on Windows 10.

Sam Lantinga 2019-08-22 15:58:00 -07:00
parent dd29abb478
commit 5c15e81cfb
1 changed files with 13 additions and 2 deletions

View File

@ -298,8 +298,19 @@ int HID_API_EXPORT hid_exit(void)
int hid_blacklist(unsigned short vendor_id, unsigned short product_id) int hid_blacklist(unsigned short vendor_id, unsigned short product_id)
{ {
return vendor_id == 0x1B1C && // (Corsair) // Corsair Gaming keyboard - Causes deadlock when asking for device details
product_id == 0x1B3D; // Gaming keyboard? Causes deadlock when asking for device details if ( vendor_id == 0x1B1C && product_id == 0x1B3D )
{
return 1;
}
// SPEEDLINK COMPETITION PRO - turns into an Android controller when enumerated
if ( vendor_id == 0x0738 && product_id == 0x2217 )
{
return 1;
}
return 0;
} }
struct hid_device_info HID_API_EXPORT * HID_API_CALL hid_enumerate(unsigned short vendor_id, unsigned short product_id) struct hid_device_info HID_API_EXPORT * HID_API_CALL hid_enumerate(unsigned short vendor_id, unsigned short product_id)