diff --git a/src/devices/corsair_void.c b/src/devices/corsair_void.c index 13bfda72..32bf8244 100644 --- a/src/devices/corsair_void.c +++ b/src/devices/corsair_void.c @@ -63,9 +63,9 @@ void void_init(struct device** device) device_void.capabilities = B(CAP_SIDETONE) | B(CAP_BATTERY_STATUS) | B(CAP_NOTIFICATION_SOUND) | B(CAP_LIGHTS); device_void.capability_details[CAP_SIDETONE] = (struct capability_detail) { .usagepage = 0xff00, .usageid = 0x1, .interface = 0 }; - device_void.capability_details[CAP_BATTERY_STATUS] = (struct capability_detail) { .usagepage = 0xffc5, .usageid = 0x1, .interface = 0 }; - device_void.capability_details[CAP_NOTIFICATION_SOUND] = (struct capability_detail) { .usagepage = 0xffc5, .usageid = 0x1, .interface = 0 }; - device_void.capability_details[CAP_LIGHTS] = (struct capability_detail) { .usagepage = 0xffc5, .usageid = 0x1, .interface = 0 }; + device_void.capability_details[CAP_BATTERY_STATUS] = (struct capability_detail) { .usagepage = 0xffc5, .usageid = 0x1, .interface = 3 }; + device_void.capability_details[CAP_NOTIFICATION_SOUND] = (struct capability_detail) { .usagepage = 0xffc5, .usageid = 0x1, .interface = 3 }; + device_void.capability_details[CAP_LIGHTS] = (struct capability_detail) { .usagepage = 0xffc5, .usageid = 0x1, .interface = 3 }; device_void.send_sidetone = &void_send_sidetone; device_void.request_battery = &void_request_battery; diff --git a/src/hid_utility.c b/src/hid_utility.c index 3331827d..275dcfae 100644 --- a/src/hid_utility.c +++ b/src/hid_utility.c @@ -13,7 +13,7 @@ * @param vid The device vendor ID. * @param pid The device product ID. * @param iid The device interface ID. A value of zero means to take the - * first enumerated (sub-) device. + * first enumerated (sub-) device. (Ignored on macOS) * @param usagepageid The device usage page id, see usageid * @param usageid The device usage id in context to usagepageid. * Only used on Windows currently, and when not 0; @@ -32,6 +32,12 @@ char* get_hid_path(uint16_t vid, uint16_t pid, int iid, uint16_t usagepageid, ui return ret; } + // Because of a MacOS Bug beginning with Ventura 13.3, we ignore the interfaceid + // See https://github.com/Sapd/HeadsetControl/issues/281 +#ifdef __APPLE__ + iid = 0; +#endif + // usageid is more specific to interface id, so we try it first // It is a good idea, to do it on all platforms, however googling shows // that older versions of hidapi have a bug where the value is not correctly