New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shut down Wii software gracefully #4244
Conversation
Virtual Console titles indefinitely hang on "attempting shutdown" for right now. |
@JMC47 does that only happen with VC titles? |
This should now be fixed. |
7a80037
to
591eebe
Compare
Fixes saving in NES VC/SNES VC games. |
There was as far as I know no reason to put everything in the header. Separating the declaration from the implementation reduces build times in case the implementation is updated without changing any declaration.
Switches to the new naming conventions.
This adds support for triggering the power event (in the STM), so that stopping emulation first triggers a shutdown event, which notably gives emulated software time to save game data (issue 8979) and clean up SYSCONF (to disconnect Wiimotes and update their state in the SYSCONF). On the first press, the stop button/hotkey/whatever will trigger a STM power event. On a second try, we will forcefully stop emulation, just like how it was working before.
When standby mode is enabled, this causes games to ES_Launch the system menu instead of directly asking IOS (the STM more precisely) to shut down, which prevents graceful shutdown from working (it'll appear to hang). Dolphin never supported WC24 standby mode anyway, so this shouldn't cause any issues. (This should be reverted if and when WC24 standby is implemented…)
591eebe
to
453c4a4
Compare
lgtm |
// Disable WiiConnect24's standby mode. If it is enabled, it prevents us from receiving | ||
// shutdown commands in the State Transition Manager (STM). | ||
// TODO: remove this if and once Dolphin supports WC24 standby mode. | ||
SConfig::GetInstance().m_SYSCONF->SetData("IPL.IDL", 0x00); |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This PR is likely the cause of Issue #9819 (Dolphin crashes when exiting emulation of Gecko OS) |
This adds support for triggering the power event (in the STM), so that stopping emulation first triggers a shutdown event, which notably gives emulated software time to save game data (issue 8979) and clean up SYSCONF (to disconnect Wiimotes and update their state in the SYSCONF).
On the first press, the stop button/hotkey/whatever will trigger a STM power event, and we immediately show an OSD message, so it doesn't look like Dolphin is ignoring the stop command. On a second try, we will forcefully stop emulation, just like how it was working before.
Note: this still doesn't allow Wiimotes to trigger a poweroff when the last Wiimote is powered off. Not sure why; this will likely be something to look into in the future.
This change is