Android: Route DolphinBar Balance Board to the Balance Board slot

WiimoteScannerAndroid::FindAttachedWiimotes() added every device
connected through the DolphinBar to the Wii Remote results, with a
TODO noting that balance boards were not differentiated. As a result,
a Wii Balance Board connected through the DolphinBar was always
assigned to a Wii Remote slot (Player 1), and games that request a
Balance Board never detected it.

Use Wiimote::IsBalanceBoard() to route balance boards into the
balance_boards results, matching the Linux and Windows scanner
backends. Tested on an AYN Thor (Android 13) with a Mayflash
DolphinBar in Mode 4 running Wii Fit Plus: the board is now detected
in the Balance Board slot.
This commit is contained in:
tommywaaf
2026-07-06 19:58:42 -04:00
parent aabea5b1e3
commit 342115806b
@@ -46,10 +46,12 @@ auto WiimoteScannerAndroid::FindAttachedWiimotes() -> FindResults
if (!wiimote->ConnectInternal())
continue;
// TODO: We make no attempt to differentiate balance boards here.
// wiimote->IsBalanceBoard() would probably be enough to do that.
results.wii_remotes.emplace_back(std::move(wiimote));
// Differentiate balance boards so they are routed to the balance
// board results rather than being treated as a regular Wii Remote.
if (wiimote->IsBalanceBoard())
results.balance_boards.emplace_back(std::move(wiimote));
else
results.wii_remotes.emplace_back(std::move(wiimote));
}
}