From d2897bc6a0bf201415377e2b8c5f32dd5c42be99 Mon Sep 17 00:00:00 2001 From: nastys <@a.a> Date: Mon, 24 Jan 2022 11:18:08 +0100 Subject: [PATCH] macOS: Fix DS3 init on Monterey --- 3rdparty/hidapi/hidapi | 2 +- rpcs3/Input/ds3_pad_handler.cpp | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/3rdparty/hidapi/hidapi b/3rdparty/hidapi/hidapi index c47734cb07..8ff2deec75 160000 --- a/3rdparty/hidapi/hidapi +++ b/3rdparty/hidapi/hidapi @@ -1 +1 @@ -Subproject commit c47734cb076881097e241ed691691793075a93a3 +Subproject commit 8ff2deec755c4cdf9515930ecb4a94ec17bc98d1 diff --git a/rpcs3/Input/ds3_pad_handler.cpp b/rpcs3/Input/ds3_pad_handler.cpp index 0423d543d7..eea5edaf3c 100644 --- a/rpcs3/Input/ds3_pad_handler.cpp +++ b/rpcs3/Input/ds3_pad_handler.cpp @@ -292,6 +292,14 @@ void ds3_pad_handler::check_add_device(hid_device* hidDevice, std::string_view p return; } device->report_id = buf[0]; +#elif defined (__APPLE__) + int res = hid_init_sixaxis_usb(hidDevice); + if (res < 0) + { + ds3_log.error("check_add_device: hid_init_sixaxis_usb failed! (result=%d, error=%s)", res, hid_error(hidDevice)); + hid_close(hidDevice); + return; + } #endif for (wchar_t ch : wide_serial)