DS-Homebrew / nds-bootstrap

Boot an nds file
https://wiki.ds-homebrew.com/nds-bootstrap/
GNU General Public License v3.0
1.16k stars 75 forks source link

Real-Time Clock (RTC) doesn't work correctly on the DSi for some games #827

Closed SleepyLark closed 2 years ago

SleepyLark commented 4 years ago

Your console

Tell us which console you are using:

CFW and configuration

Tell us which CFW do you have:

DSi:

3DS/2DS:

nds-bootstrap version

Tell us which versions you are using:

Your device

Tell us which card you are using:

If this issue only affects a certain game, which game is it?

Love Plus [English Translation] Animal Crossing: Wild World (#700)

Expected behaviour

The RTC in the game should function the same as the system's clock.

Actual behaviour

The clock in the game keeps skipping or doesn't work correctly. For Love Plus, it keeps thinking it's been over 48 hours and keeps prompting the user to save. It get's worse once Real Time Mode is unlocked as the day keeps resetting despite the day and time still being the same as the system's.

Steps to reproduce

  1. Launch Love Plus on the DSi (it doesn't matter if it's the Fan-translation or not)
  2. Select a save file and press "Real Time Mode" (I can upload a completed save file later on if needed)
  3. Wait a little bit. The screen should flash and a prompt window will appear saying that the week has changed even though the day is the same.

Other notes

This issue has been known for a while, however I discovered that when playing it on the 3DS there was no problems with the clock, so it's only affecting the DSi. I've already tried setting the clock speed to NTR which didn't do anything.

RocketRobz commented 4 years ago

I'm starting to wonder if Animal Crossing: Wild World, also has the RTC issue on 3DS.

SleepyLark commented 4 years ago

I think you may be right. I have Wild World opened side-by-side at the moment. On the DSi the bell chimes about every 5 minutes and flickers to night before saying "Good morning", while on the 3DS the only time it chimed was when it was the top of the hour in-game. The clock still says the right time and the time of day doesn't appear to change. Now I'm curious to know what other games have this problem.

Ihamfp commented 4 years ago

I sometimes get an RTC bug on Pokemon Platinum as well, the clock/watch thing randomly displays the wrong time for about a second. It's very rare tho, only happened once or twice in 3 hours. It runs on a DSi with Unlaunch+twlmenu, hiya is installed but not launched. Might be related to the frequency of game time update, or maybe the RTC randomly fails to answer in time, and it gets more visible the more frequently the game needs it.

dasBroetschen commented 4 years ago

Same RTC problem here in "Animal Crossing Wild World" (European)

RTC seems to not work well in the current state, or am I missing a (ini-file) setting?

RocketRobz commented 4 years ago

A .ini file setting will not fix this.

dasBroetschen commented 4 years ago

A .ini file setting will not fix this.

So is there no actual fix for this problem? Or will it be fixed within future updates?

SugaryHull commented 4 years ago

Loading an NDS Bootstrap generated save file to the retail card for Animal Crossing: Wild World doesn't remedy the issues described above, indicating that the issue persists across saves. The card was loaded directly from Unlaunch, indicating that HiyaCFW is not related

Update: Wiping the save and creating a new one on the retail card did not resolve the issue. The card was launched from Unlaunch. Perhaps it's an issue with EmuNAND

oeramo commented 4 years ago

Loading an NDS Bootstrap generated save file to the retail card for Animal Crossing: Wild World doesn't remedy the issues described above, indicating that the issue persists across saves. The card was loaded directly from Unlaunch, ~indicating that HiyaCFW is not related~

Update: Wiping the save and creating a new one on the retail card did not resolve the issue. The card was launched from Unlaunch. Perhaps it's an issue with EmuNAND

I don't have the knowledge to understand exactly why the problem occurs, but this sounded very strange to me so I decided to try to load my nds-bootstrap generated save file to a R4i with the same backup rom, and that did in fact solve the real-time clock issue. So I don't think that the issue lies that low.

DSi, slot-1 launched from within TwilightMenu++, EUR rom.

RocketRobz commented 4 years ago

Why the bug happens, is because arm7 does the loading, instead of arm9. arm7 handles RTC, so reading from the SD card causes issues with RTC. One way to fix it, is to optimize the read code somehow, or just by moving the FAT code to arm9, and just have arm7 do the sector reading, so not much time is taken on the arm7 side.

RocketRobz commented 4 years ago

Tried ACWW in the fatOnArm9 branch, and the RTC bug is fixed, it seems! Can anyone else try this build, and see if the bug is fixed for you as well? nds-bootstrap-nightly.zip Note that loading takes a while. :P If the game doesn't boot, try turning off heap shrink.

EDIT: nvm. After moving around for a while, Day briefly changes to Night, and the bell still chimes.

SleepyLark commented 4 years ago

Tried ACWW in the fatOnArm9 branch, and the RTC bug is fixed, it seems! Can anyone else try this build, and see if the bug is fixed for you as well? nds-bootstrap-nightly.zip Note that loading takes a while. :P If the game doesn't boot, try turning off heap shrink.

EDIT: nvm. After moving around for a while, Day briefly changes to Night, and the bell still chimes.

Tried it on Love Plus with heap shrink off, it couldn't go past the logo screen, same thing with Wild World, unless I'm doing something wrong

RocketRobz commented 4 years ago

Set ROM read LED to Power, so that you'll know data is loading.

KmvaMaeru commented 4 years ago

I have ACWW in a 3ds and a dsi and so far the 3ds version runs normally, the dsi one is the only with that bug and I've already tried with different roms and regions but none of that seems to fix it on the dsi. Actually, Ds to Ds connections seems to fail using the dsi as host and work perfectly with the 3ds as host because of the bug. I'm able to experiment and give you info if you need it, but is there a way I can help out in this matter? I'd love if this was fixed.

RocketRobz commented 4 years ago

It seems commit 157eac13 has fixed this. I need someone else to test this (or the latest) nightly build, before this can be closed.

KmvaMaeru commented 4 years ago

Nope, the Dsi at least is not fixed to me :/ (I compiled the last git version and put it as the nightly)

oeramo commented 4 years ago

Looks like I am not able to build nds-bootstrap from Linux because of lzss being Windows-only, and the TWiLightMenu-update repo hasn't been updated in a while. Could someone please share the latest binaries to test?

KmvaMaeru commented 4 years ago

@omarelhajj97 I just copy pasted both lzss files on the directory and it worked on windows, it doesn't work on Linux that way?

oeramo commented 4 years ago

@omarelhajj97 I just copy pasted both lzss files on the directory and it worked on windows, it doesn't work on Linux that way?

No, the build fails mid-way because it doesn't find the program in the directory. The files are just a .c source file and a .exe Windows binary.

Bihlasagna69 commented 4 years ago

It seems commit 157eac1 has fixed this. I need someone else to test this (or the latest) nightly build, before this can be closed.

It worked for me...... ....For now, I guess I mean I literally just updated twilight menu to latest version on my dsi xl :/

Bihlasagna69 commented 4 years ago

It seems commit 157eac1 has fixed this. I need someone else to test this (or the latest) nightly build, before this can be closed.

Actually it didn't work Today's is ladiday on animal crossing and it keeps saying "ladiday has ended" and 1 second later says "today's ladiday!"

paranoid64 commented 3 years ago

I have installed the latest version, but the problem still exists. Does anyone have a solution for this ?

RocketRobz commented 3 years ago

It would already be in nds-bootstrap, if there is.

AbnormalPoof commented 2 years ago

Should we unpin this?

RocketRobz commented 2 years ago

Done.