Views: 6,702,920 | Homepage | Main | Rules/FAQ | Memberlist | Active users | Last posts | Calendar | Stats | Online users | Search | 03-29-24 10:23 AM |
Guest: |
0 users reading Firmware factory reset | 1 bot |
Main - General - Firmware factory reset | Hide post layouts | New reply |
Nicknine |
| ||
Newcomer Normal user Level: 4 Posts: 1/4 EXP: 269 Next: 10 Since: 02-19-21 Last post: 1133 days ago Last view: 912 days ago |
On a real DS, it is possible to reset firmware to factory default and bring up the initial setup screen ("Before you begin...") again by removing the battery for a minute and putting it back in. Is there a way to simulate this on an emulator with a firmware ROM?
I've tried zeroing out the last 0x600 bytes in firmware ROM (that's where user settings are stored) but that's not quite it, it brings up "System settings have been lost" screen. |
Arisotura |
| ||
Big fire melon magical melon girl Level: 55 Posts: 663/876 EXP: 1311396 Next: 2793 Since: 03-28-17 From: France Last post: 15 hours ago Last view: 1 hour ago |
dunno how that works. I doubt the user settings actually get lost (they're stored in the same memory as the firmware code, so that'd suck big time)
I think it's a flag in the RTC or something in the like. (as far as removing the battery to reset settings is concerned. dunno about the factory-reset part) ____________________ Kuribo64 |
Nicknine |
| ||
Newcomer Normal user Level: 4 Posts: 2/4 EXP: 269 Next: 10 Since: 02-19-21 Last post: 1133 days ago Last view: 912 days ago |
Posted by Arisotura Hmm, RTC, that's what Desmume dev suggested as well. How does DS store clock? Unix timestamp or something else? Where does melonDS handle it? I can try playing with the code to make it return 0 or other possible sentinel values to see if it triggers initial setup. EDIT: Here it is: https://github.com/Arisotura/melonDS/blob/master/src/RTC.cpp. From the looks of it, DS returns time in the same structure as GC, counting from Jan 1 2000. |
Arisotura |
| ||
Big fire melon magical melon girl Level: 55 Posts: 664/876 EXP: 1311396 Next: 2793 Since: 03-28-17 From: France Last post: 15 hours ago Last view: 1 hour ago |
yup, that's it -- there might be some 'time lost' bit in the status regs.
edit- yeah that's bit7 in status register 1, probably ____________________ Kuribo64 |
Nicknine |
| ||
Newcomer Normal user Level: 4 Posts: 3/4 EXP: 269 Next: 10 Since: 02-19-21 Last post: 1133 days ago Last view: 912 days ago |
That was it! I've set bit 7 on status register 1 in the code and it brought up that screen.
Now I wonder if there's a nice way to implement this on user side in some way... |
Nicknine |
| ||
Newcomer Normal user Level: 4 Posts: 4/4 EXP: 269 Next: 10 Since: 02-19-21 Last post: 1133 days ago Last view: 912 days ago |
Do we know what clean, fresh from the store firmware ROM looks like? I'm guessing the last 0x600 bytes are filled with 0x00 or 0xFF.
EDIT: Doesn't seem like it, filling user area with 0xFF brings up "System settings have been lost" screen even with RTC power lost flag. It probably contains default settings for the region then? |
Main - General - Firmware factory reset | Hide post layouts | New reply |
Page rendered in 0.032 seconds. (2048KB of memory used) MySQL - queries: 27, rows: 86/86, time: 0.018 seconds. Acmlmboard 2.064 (2018-07-20) © 2005-2008 Acmlm, Xkeeper, blackhole89 et al. |