From c62945af58c9d205db69e5887731c3b5e6c438c0 Mon Sep 17 00:00:00 2001 From: Gericom Date: Sun, 11 Jan 2026 12:09:17 +0100 Subject: [PATCH] Lock scfg9 when switching to DS mode to avoid DSi mode being misdetected. Fixes #90. --- arm9/source/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arm9/source/main.cpp b/arm9/source/main.cpp index 422d4ed..0695fbe 100644 --- a/arm9/source/main.cpp +++ b/arm9/source/main.cpp @@ -100,8 +100,8 @@ static void bootArm9() if (((REG_SCFG_EXT >> 14) & 3) == 0) { - // When switched to DS mode, disable vram extensions - REG_SCFG_EXT &= ~(1 << 13); + // When switched to DS mode, disable vram extensions and lock scfg9 + REG_SCFG_EXT &= ~((1 << 13) | (1 << 31)); } while (gfx_getVCount() != 191);