diff --git a/Source/Core/Core/Src/HW/WiimoteReal/IOdarwin.mm b/Source/Core/Core/Src/HW/WiimoteReal/IOdarwin.mm index 0c2f742987..7dbb45e6f1 100644 --- a/Source/Core/Core/Src/HW/WiimoteReal/IOdarwin.mm +++ b/Source/Core/Core/Src/HW/WiimoteReal/IOdarwin.mm @@ -244,7 +244,7 @@ int Wiimote::IOWrite(unsigned char *buf, int len) if (!IsConnected()) return 0; - ret = [cchan writeAsync: buf length: len refcon: nil]; + ret = [ichan writeAsync: buf length: len refcon: nil]; if (ret == kIOReturnSuccess) return len; diff --git a/Source/Core/Core/Src/HW/WiimoteReal/WiimoteReal.cpp b/Source/Core/Core/Src/HW/WiimoteReal/WiimoteReal.cpp index f5ded4125d..8c7b01a72c 100644 --- a/Source/Core/Core/Src/HW/WiimoteReal/WiimoteReal.cpp +++ b/Source/Core/Core/Src/HW/WiimoteReal/WiimoteReal.cpp @@ -147,10 +147,11 @@ void Wiimote::InterruptChannel(const u16 channel, const void* const data, const // party ones don't. if (rpt.first[0] == 0xa2) { - rpt.first[0] = 0x52; + rpt.first[0] = WM_SET_REPORT | WM_BT_OUTPUT; } - if (rpt.first[0] == 0x52 && rpt.first[1] == 0x18 && rpt.second == 23) + if (rpt.first[0] == (WM_SET_REPORT | WM_BT_OUTPUT) && + rpt.first[1] == 0x18 && rpt.second == 23) { m_audio_reports.Push(rpt); return; diff --git a/Source/Core/Core/Src/HW/WiimoteReal/WiimoteRealBase.h b/Source/Core/Core/Src/HW/WiimoteReal/WiimoteRealBase.h index 6765748e58..4b66eb4930 100644 --- a/Source/Core/Core/Src/HW/WiimoteReal/WiimoteRealBase.h +++ b/Source/Core/Core/Src/HW/WiimoteReal/WiimoteRealBase.h @@ -32,7 +32,14 @@ #define WM_OUTPUT_CHANNEL 0x11 #define WM_INPUT_CHANNEL 0x13 +// The 4 most significant bits of the first byte of an outgoing command must be +// 0x50 if sending on the command channel and 0xA0 if sending on the interrupt +// channel. On Mac we use interrupt channel; on Windows/Linux, command. +#ifndef __APPLE__ #define WM_SET_REPORT 0x50 +#else +#define WM_SET_REPORT 0xA0 +#endif // Commands #define WM_CMD_RUMBLE 0x10