Skip to content

Commit

Permalink
HW: DK Bongos actual fix
Browse files Browse the repository at this point in the history
  • Loading branch information
jordan-woyak committed Dec 28, 2018
1 parent dd1fc70 commit 2765475
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Source/Core/Core/HW/SI/SI_DeviceGCAdapter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ bool CSIDevice_GCAdapter::GetData(u32& hi, u32& low)

if (m_simulate_konga)
{
hi &= CSIDevice_TaruKonga::BUTTON_MASK;
hi &= CSIDevice_TaruKonga::HI_BUTTON_MASK;
}

return true;
Expand Down
2 changes: 1 addition & 1 deletion Source/Core/Core/HW/SI/SI_DeviceGCController.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ bool CSIDevice_TaruKonga::GetData(u32& hi, u32& low)

// Unsets the first 16 bits (StickX/Y), PAD_USE_ORIGIN,
// and all buttons except: A, B, X, Y, Start, R
hi &= BUTTON_MASK;
hi &= HI_BUTTON_MASK;

return true;
}
Expand Down
5 changes: 3 additions & 2 deletions Source/Core/Core/HW/SI/SI_DeviceGCController.h
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,8 @@ class CSIDevice_TaruKonga : public CSIDevice_GCController

bool GetData(u32& hi, u32& low) override;

static const u32 BUTTON_MASK = (PAD_BUTTON_A | PAD_BUTTON_B | PAD_BUTTON_X | PAD_BUTTON_Y |
PAD_BUTTON_START | PAD_TRIGGER_R);
static const u32 HI_BUTTON_MASK =
(PAD_BUTTON_A | PAD_BUTTON_B | PAD_BUTTON_X | PAD_BUTTON_Y | PAD_BUTTON_START | PAD_TRIGGER_R)
<< 16;
};
} // namespace SerialInterface

0 comments on commit 2765475

Please sign in to comment.