Merge pull request #7659 from jordan-woyak/dk-bongos-fix2

HW: DK Bongos actual fix
This commit is contained in:
Mat M 2018-12-28 20:01:09 -05:00 committed by GitHub
commit 187058a072
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 4 deletions

View File

@ -66,7 +66,7 @@ bool CSIDevice_GCAdapter::GetData(u32& hi, u32& low)
if (m_simulate_konga) if (m_simulate_konga)
{ {
hi &= CSIDevice_TaruKonga::BUTTON_MASK; hi &= CSIDevice_TaruKonga::HI_BUTTON_MASK;
} }
return true; return true;

View File

@ -355,7 +355,7 @@ bool CSIDevice_TaruKonga::GetData(u32& hi, u32& low)
// Unsets the first 16 bits (StickX/Y), PAD_USE_ORIGIN, // Unsets the first 16 bits (StickX/Y), PAD_USE_ORIGIN,
// and all buttons except: A, B, X, Y, Start, R // and all buttons except: A, B, X, Y, Start, R
hi &= BUTTON_MASK; hi &= HI_BUTTON_MASK;
return true; return true;
} }

View File

@ -123,7 +123,8 @@ public:
bool GetData(u32& hi, u32& low) override; bool GetData(u32& hi, u32& low) override;
static const u32 BUTTON_MASK = (PAD_BUTTON_A | PAD_BUTTON_B | PAD_BUTTON_X | PAD_BUTTON_Y | static const u32 HI_BUTTON_MASK =
PAD_BUTTON_START | PAD_TRIGGER_R); (PAD_BUTTON_A | PAD_BUTTON_B | PAD_BUTTON_X | PAD_BUTTON_Y | PAD_BUTTON_START | PAD_TRIGGER_R)
<< 16;
}; };
} // namespace SerialInterface } // namespace SerialInterface