|
|
|
#241 (permalink) |
|
Emu author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Sep 2006
Location: VisualC
Posts: 656
|
It's, afaik, a timing problem, related to the IRQs. Check the Zelda Video Demo (it isn't running), and you'll see it's the same problem. I've worked on it a few hours, with mid to good results, but it's far for finished.
__________________
Emulator development blog |
|
|
|
|
|
#242 (permalink) |
|
Plugin author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jul 2007
Location: Nulle part
Posts: 370
|
Thanks. I can tell you RaymanDS is not working because of a strange problem in the ARM9. The ARM9 freezes on this opcode :
MCR CP15, 0, R0, CR7, CR0, 4 which means "Wait for IRQ". IE=0x00040019 and IF=0x000C0019, so IRQ should be triggered, but it is not. |
|
|
|
|
|
#243 (permalink) |
|
Emu author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Sep 2006
Location: VisualC
Posts: 656
|
Same problem as Mario Kart, Pokemon, Zelda Video Demo and probably others :P
__________________
Emulator development blog |
|
|
|
|
|
#244 (permalink) |
|
Plugin author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jul 2007
Location: Nulle part
Posts: 370
|
This is VERY strange. IE&IF=0x00040019, so IRQs should be triggered. DeSmuME does'nt trigger these IRQs, I don't know why. Very strange.
PS : Why do you don't commit your changes to CVS ? Last edited by NHervé; April 21st, 2008 at 21:24. Reason: Automerged Doublepost |
|
|
|
|
|
#245 (permalink) |
|
Emu author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Sep 2006
Location: VisualC
Posts: 656
|
Why should I? That's the interesting question. Anyway, to make a long story short, I'm not very interested on seeing games running on desmume, but making it a good development tool. As of now, the included debugger tools are far from good, so if it's not going to be useful for homebrew development, there isn't much point for me.
Of course I make an incompatible game run once and then, just because the challenge is fun.
__________________
Emulator development blog |
|
|
|
|
|
#247 (permalink) |
|
Emu author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Sep 2006
Location: VisualC
Posts: 656
|
Oh, and I forgot that I won't be committing minor fixes on official Desmume for a long while (as I did before, basically supporting homebrewers requests), you can find the reason somewhere in the forums.
__________________
Emulator development blog |
|
|
|
|
|
#249 (permalink) |
|
Emu author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Sep 2006
Location: VisualC
Posts: 656
|
Hacking it to one makes the game run ? :P
__________________
Emulator development blog |
|
|
|
|
|
#250 (permalink) |
|
Plugin author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jul 2007
Location: Nulle part
Posts: 370
|
PS : I hacked this by forcing the I flag to be 0, I got over 2 intros further but the game still doesn't work. After reading the ARM datasheet, I found that this MCR opcode switches the proc in low-power mode, and any IRQ can wake it up even if IRQs are disabled (I flag set to 1), which DeSmuME doesn't support. I'll try to implement this feature and I'll tell you.
|
|
|
|
|
|
#251 (permalink) | |
|
Emu author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Sep 2006
Location: VisualC
Posts: 656
|
Quote:
__________________
Emulator development blog |
|
|
|
|
|
|
#252 (permalink) |
|
Plugin author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jul 2007
Location: Nulle part
Posts: 370
|
I'm gathering more and more infos : before calling the MCR opcode, the game stores the 8 first bits of R2 into the control bits of the CPSR. Maybe R2 is having wrong value. I think any NDS program shouldn't set I flag to 1 before calling a "wait for IRQ" opcode.
|
|
|
|
|
|
#253 (permalink) | |
|
PCSX2 Coder
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jan 2004
Location: Plymouth, UK
Posts: 9,591
|
Just thought id put my 2 cents in with my lack of knowledge.
from reading this Quote:
Im probably completely wrong, but if it gets the cogs ticking, thats all that matters
__________________
http://www.generalemu.net/ Intel Core 2 Quad Q6600 @ 3.4Ghz (425x8), eVGA 8800GTX 768mb, 996Gb HDs, 2Gb Corsair DDR2-800 @ DDR2-1020 5-5-5-18 Dual Channel, 14605 3dMark 06 Points CPU-Z Link 3dMark06 Score Link Dont PM me for help, use the forums, thats what its for! |
|
|
|
|
|
|
#254 (permalink) |
|
Plugin author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jul 2007
Location: Nulle part
Posts: 370
|
Maybe it's that, or maybe the game is disabling IRQs for a special purpose and it uses that MCR opcode that ignores the I flag.
I tried by adding a "lowPower" variable in the armcpu_t struct, setting it to 1 when the MCR opcode is called and to 0 when a IRQ occurs, but it is still not correct. It makes the game freezes in a strange location (0x0FFF0000). Last edited by NHervé; April 22nd, 2008 at 19:51. Reason: Automerged Doublepost |
|
|
|
|
|
#255 (permalink) |
|
PCSX2 Coder
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jan 2004
Location: Plymouth, UK
Posts: 9,591
|
do you know when the IRQ disable flag is being set? or is it being done manually and not being reset? i dunno cos ive not looked at the source
__________________
http://www.generalemu.net/ Intel Core 2 Quad Q6600 @ 3.4Ghz (425x8), eVGA 8800GTX 768mb, 996Gb HDs, 2Gb Corsair DDR2-800 @ DDR2-1020 5-5-5-18 Dual Channel, 14605 3dMark 06 Points CPU-Z Link 3dMark06 Score Link Dont PM me for help, use the forums, thats what its for! |
|
|
|
|
|
#256 (permalink) |
|
Plugin author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jul 2007
Location: Nulle part
Posts: 370
|
Yes. The game calls a subroutine in order to set the CPSR to 0x1F (I=0), then calls the MCR that succeds, calls then another subroutine that sets the CPSR to 0x9F (I=1), then calls the same MCR. This time the MCR lamentably freezes the ARM9 due to I=1.
|
|
|
|
|
|
#257 (permalink) |
|
PCSX2 Coder
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jan 2004
Location: Plymouth, UK
Posts: 9,591
|
okay, any idea what causes the interrupt?, maybe it expects a response by then.
Meh, ill leave you guys to it, i really dont know the DS system
__________________
http://www.generalemu.net/ Intel Core 2 Quad Q6600 @ 3.4Ghz (425x8), eVGA 8800GTX 768mb, 996Gb HDs, 2Gb Corsair DDR2-800 @ DDR2-1020 5-5-5-18 Dual Channel, 14605 3dMark 06 Points CPU-Z Link 3dMark06 Score Link Dont PM me for help, use the forums, thats what its for! |
|
|
|
|
|
#258 (permalink) |
|
Plugin author
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jul 2007
Location: Nulle part
Posts: 370
|
I don't know. When I hack it I get 3 intros instead of 1, but it's still not correct. It seems that what I described in my previous post is done by the game in order to "test" something. Maybe it's the init sequence of the SDK that's been used to develop this game.
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|