Dolphin, the GameCube and Wii emulator - Forums

Full Version: Any way to create 4GB+ non-HC "WiiSD.raw" images? (yes, 4GB non-HC SD cards do exist)
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I distinctly remember back in the day when I was doing stuff with DS homebrew before SDHC was ever a thing that people recommended 2GB capacity as maximum because 4GB had problematic compatibility, presumably because not everything supported FAT32 (FAT16 maxes out at 2GB partition size EDIT: though it seems GParted can actually create a 4GB FAT16 partition? I may need to experiment with that...).

But as far as I know, all Wii homebrew and official Wii software doesn't have any such issues with FAT32 but, as we all know, not all games are compatible with SDHC cards (Excite Truck is always an annoying one for me since it supports custom per-course music from the SD card).

However, software and emulation doesn't have the hardware limitations that real-world non-HC SD cards could have ran into which got me thinking: what about the ability to create non-HC "WiiSD.raw" images that are greater than 2GB? And we might not even have to stop at 4GB since I'm pretty sure that was only the maximum at the time because flash memory simply hadn't yet progressed far enough along to reach the point of making 8GB cards feasible.
Software that doesn't support SDHC cards also has the limitation that only FAT16 is supported. (The FAT driver is part of the game.) So the only way you're going to get around it is if you hack the game itself, which I know people have managed to do with at least Super Smash Bros. Brawl.
I'm pretty sure it's part of the pre-HC SD spec that they're formatted as FAT16, and the moment you reformat them as something else, they're no longer an SD card, despite having the same hardware. Therefore a 4GB non-HC card is off-spec and not an SD card at all.
(10-23-2023, 07:27 AM)JosJuice Wrote: [ -> ]Software that doesn't support SDHC cards also has the limitation that only FAT16 is supported. (The FAT driver is part of the game.) So the only way you're going to get around it is if you hack the game itself, which I know people have managed to do with at least Super Smash Bros. Brawl.

Testing both commercial retail discs of Excite Truck and Smash Bros. Brawl launched directly through the disc channel on the Wii menu on my launch-day Wii console, both games were able to without issue read my 2GB non-HC Toshiba SD card that came with my launch 3DS that I formatted to FAT32 with 16K cluster size (the largest for a 2GB partition, my logic being it'd be the closest to testing a larger-capacity non-HC SD card).

I also tried out some homebrew that has file browsers, specifically WiiXplorer and Savegame Manager GX (and I guess the Homebrew Channel itself to an extent?) and both also "just worked" without issue as did the official "SD card menu" on the Wii Menu itself.

For reference I also quickly tested Excite Truck as well as the SD card menu in Dolphin and they also worked (fun fact that maybe you already know: the "Create Partition Image" function in gnome-disks-utility creates a partition image that's perfectly compatible with Dolphin's SD card disk image functionality if you rename the resulting .img file and its extension accordingly).

As a sanity check of Dolphin's own SD card functionality, I set Dolphin to a 4GB image with the exact same contents as my Wii's 2GB SD card just to confirm that it is in fact making an SDHC-formatted SD card image and indeed the SD card menu works while Excite Truck does not see the 4GB SDHC card.

So the question in my opening post still stands: What about the feasibility for 4GB+ non-HC "WiiSD.raw" images?
I think Dolphin just assumes SD/SDHC based on the filesize of the image, the flipover point being defined as 2GiB: https://github.com/search?q=repo%3Adolph...&type=code

I'm not sure what the real hardware differences are but I assume it's something that's not actually stored in the disk image itself and something that is reported by the hardware via some query. So you'd probably have to implement an extra toggle or something.
I recently purchased a used 4GB non-HC SD card (there are still 6 available from this seller if you need one for testing):
And I can confirm that 4GB non-HC SD cards generally "just work" on a real Wii console, including in Excite Truck; I've opened a bug report about this not working in Dolphin: As I describe in the bug report, there is a quirk with going to and from the Wii Menu that can require ejecting and re-inserting the 4GB non-HC SD card, but this isn't something that should really apply to Dolphin in the context of directly booting a game or the like.