Jump to content

Bug in RTC Clock?


Rinkwraith

Recommended Posts

I'm just getting started doing some development work on the DS using Dualis. Unfortunately I don't have my PassMe yet so can't check this on a real DS... however...

 

If you read the time into the IPC->curtime array then the second value curtime[1] appears to hold the year value. When running on Dualis, 2005 comes out with the value 58. 2006 as 68. Initially I could just about bring myself to accept this on the grounds that 2000 would be 08 and maybe they didn't/couldn't have a zero value from the RTC so they used 8.

 

However, if I set my PC clock to 2058 then curtime[1] holds... 58. If this is true then how can you tell the difference between 2005 and 2058?

 

Could it be a Dualis or NDSLib bug?

Link to comment
Share on other sites

I didn't really have any info on the structure of the date when I added that to dualis. I just kept switching things around until joat's touchscreen demo seemed to display the correct time and date.

Link to comment
Share on other sites

I didn't really have any info on the structure of the date when I added that to dualis. I just kept switching things around until joat's touchscreen demo seemed to display the correct time and date.

I think you probably have it right.

 

It seems to be a small bug in Dualis rather than a mis-coding. I've noticed that if I start up, load & execute the file then it reports 58 for 2005. If I leave Dualis open, stop the emulation and then load & execute my demo, it reports 5.

 

Odd that the first execution causes a problem though. Must just be me, I'll have a look for Joat's demo and see what happens if I run that.

 

Hope this helps.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...