Moved JVS IO emulation from SI_DeviceAMBaseboard into new JVSIOBoard class.
Sega/Namco board-specific functionality is handled by derived JVSIOBoard classes.
Game input is now sourced from IOPorts rather than being hard coded into JVS IO handlers.
SI_DeviceAMBaseboard: Use IOPorts for status switch input.
Created IOAdapter classes for FZeroAX games.
Created SerialDevice classes for MarioKartGP and FZeroAX FFB steering wheels.
Added game-specific input handling to the various IOAdapter classes.
Some users seem to be under the impression that the panic alert is
saying that enabling MMU will fix the issue, but that's not what it
actually says. Let's try to make this a bit clearer.
I think we've gotten all the useful reports we can get from this now.
Nowadays we're just getting repeated reports of issues we already know
about, like https://bugs.dolphin-emu.org/issues/12321.
Set the default value of `Config::MAIN_WASAPI_DEVICE` to `default`
instead of `Default`. This fixes an issue where `AudioPane`'s `Output
Device` combo would be blank if `WASAPI` was selected and the user had
never changed the value of `Output Device`.
We don't have to worry about backward compatibility with users who have
`Default` in their config because config values aren't written unless
they've been changed at some point from the default, and the combo has
always saved `default` instead of `Default`.
Audio still worked during emulation in this situation because the
fallback for an unrecognized device name is the default device.
To help prevent similar situations in the future references to
`MAIN_WASAPI_DEVICE`'s default value now call `GetDefaultValue` instead
of hardcoding the expected default, or use the new helper function
`Config::IsDefaultValue`.
Significantly rewrote ICCardReader and DeckReader functionality.
Dual IC card slots of VirtuaStriker4 + Gekitou now work.
IC cards are automatically inserted/ejected in VirtuaStriker4 + Gekitou + Avalon.
IC card data is saved to a file.
Avalon deck contents are loaded from a JSON file.
Added IOPorts class to handle bespoke GPIO functionality.
This should stop AchievementManager::LoadGame from being called for the
default ISO when CBoot::BootUp is booting something other than a disc or
IPL (most notably, the Wii Menu), while still detecting all disc changes
that happen while a disc game is running.
Don't copy null terminators from the log's `header.gameid` into
`FifoDataFile`'s `m_game_id`.
Doing so would cause an infinite loop in `Core::GenerateScreenshotName`
as the various concatenations and `fmt::format` calls would then
effectively drop all the timestamps and disambiguating arbitrary numbers
since they followed the null terminator in the gameid, and so the
`File::Exists` calls would always return true.
Fixes https://bugs.dolphin-emu.org/issues/14002.
In some Triforce games (e.g. _F-Zero AX_), the bytes that follow the
region flag in the `boot.id` file (at `0x38`) happen to be `0x00`.
However, in other games (e.g _Mario Kart Arcade GP 2_), it seems the
region flag is padded with `0xFF`.
_Mario Kart Arcade GP 2_ (`boot.id` in the USA version):
```
00000 0000: 42 54 49 44 00 00 01 E0 00 00 00 01 00 00 00 01 BTID.... ........
00000 0010: FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF ........ ........
00000 0020: 47 43 41 4D 00 00 01 C0 07 D3 05 0F 00 00 00 07 GCAM.... ........
00000 0030: 53 42 4E 4C 00 00 00 00 0E FF FF FF FF FF FF FF SBNL.... ........
-----------
^
|
region flag
```
When the region flag was tested in `switch` statements (where a single
byte was expected in the `case`s), the test would fail, depending
on the game.
This issue would lead to the wrong calculation of the country in
`VolumeDisc::GetCountry()`, which was then used to build the game ID in
`VolumeDisc::GetGameID()`.
The solution is to test using only the least meaningful byte in the
region flag.
Unexpected game IDs were first noticed with USA version of _Mario Kart
Arcade GP 2_, which was wrongly assigned the same game ID that is given
to the Japan version (i.e. `GNLJ82`). The correct game ID for the USA
version is `GNLE82`.