This commit is contained in:
Jan Racek
2026-03-27 21:29:01 +01:00
parent 85eb7e59d9
commit bfab154547
42 changed files with 118 additions and 1013 deletions

View File

@@ -12,12 +12,6 @@ namespace psxsplash {
* - Emulator mode: break instructions intercepted by PCSX-Redux
* - Real hardware mode: SIO1 serial protocol (break handler installed
* by pcdrv_sio1_init, then pcdrv_init detects which path to use)
*
* Both modes are preserved — we call pcdrv_sio1_init() first (installs
* the SIO1 break handler + redirects printf), then pcdrv_init() which
* checks for the PCSX-Redux emulator and falls back to SIO1 if absent.
*
* All tasks resolve synchronously since PCdrv I/O is blocking.
*/
class FileLoaderPCdrv final : public FileLoader {
public:
@@ -27,11 +21,9 @@ class FileLoaderPCdrv final : public FileLoader {
// ── scheduleInit ──────────────────────────────────────────────
psyqo::TaskQueue::Task scheduleInit() override {
return psyqo::TaskQueue::Task([this](psyqo::TaskQueue::Task* task) {
// Set up SIO1 break handler + printf redirect (real-hardware path).
// On emulator this is harmless — pcsx-redux ignores SIO1 setup.
pcdrv_sio1_init();
// Detect emulator vs SIO1 and initialise the active transport.
m_available = (pcdrv_init() == 0);
task->resolve();
});