always wondered why most of the flash carts wont write the save file in real time. when the hardware sees a write it should dump it as the game is saving. Or alteast dump the sram written data to the sd card after the save is completed.
The simplest guess explanation comes in three parts: it was probably easier, cheaper, and safer. It was easier because it meant simply patching games to have consistent save types or having the hardware support different save types natively then writing the load/save routine entirely in the boot loader in software. Having to do it in real time means either stealing CPU cycles from the CPU to do the writes or having the necessary hardware on the cart to do it behind the CPU's back. The former risks incompatibilities and the latter requires more expensive, complex hardware*. Both also might require a second save buffer (when RAM wasn't cheap) so you wouldn't get a mixed save--not really sure since if it's stealing CPU time it can just delay further progress in the game until the save is written. The last part is writing to SD, especially on a slow CPU, can take a while so the risk of corruption goes up a lot. It's really hard to do any sort of sanity checks*. To be really safe you'd want something like a capacitor in the cart to hold enough charge to fully do the write to SD even if power was suddenly lost*.
The ds flash carts have real time saves....
The DS, unlikely most systems, doesn't directly map a ROM into the memory area. Hence the whole interface is predicated upon streaming content in from the cartridge and writing out content. Hence, it's conducive to having wait checks in allowing a flash cart to write out a save and say "everything saved fine". It also discourages constant writes to save memory. Basically, DS games behave more like CD-ROM games or cassette games so can get around most the hassle of direct rom/ram mapping. I presume these properties hold true for most modern systems, even those which have built-in storage.
* The EZ Omega actually uses an FPGA to writes saves behind the CPUs back, but it still has issues because some games want to save near constantly. Hence some games are patched. It's also why it's such a headache for saves on the EZ Omega. You basically need something like multiple scratch files with hashes, you always have to worry about partial/mixed saves, and a power loss can cause massive filesystem corruption. And that's presuming you're not having issues like bad/questoinable contacts--which has seem to plague the EZ-Flash cards forever.