Kodewerx

Our culture has advanced beyond all that you could possibly comprehend with one hundred percent of your brain.
It is currently Sat Apr 27, 2024 9:27 pm

All times are UTC - 8 hours [ DST ]


Forum rules


Discussion of illegal hacking/cracking is prohibited. (No virus/trojans/cracks/warez/etc allowed.)



Post new topic Reply to topic  [ 9 posts ] 
Author Message
PostPosted: Fri Jan 19, 2007 8:34 pm 
Offline
Kommunist
Kommunist

Joined: Sun Nov 19, 2006 11:23 am
Posts: 37
Location: At my computer... -_-
Which one is this (AR DS) I'm trying to "press" the debug button with it...

_________________
<Insomniak`> Stupid fucking Google
<Insomniak`> "The" is a common word, and was not included in your search
<Insomniak`> "Who" is a common word, and was not included in your search


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sat Jan 20, 2007 1:04 am 
Offline
Kommunist
Kommunist

Joined: Tue Oct 10, 2006 9:32 am
Posts: 445
edit : see below post


Last edited by kenobi on Sun Jun 08, 2008 12:52 am, edited 1 time in total.

Top
 Profile  
Reply with quote  
PostPosted: Sat Jun 07, 2008 10:27 am 
Offline
Kommunist
Kommunist

Joined: Sun Jun 01, 2008 1:32 pm
Posts: 6
How do you use this code?


Top
 Profile  
Reply with quote  
PostPosted: Sat Jun 07, 2008 10:30 am 
Offline
Komrade
Komrade
User avatar

Joined: Tue Mar 27, 2007 6:23 pm
Posts: 1354
Location: Mario Raceway, 1509.831, 217.198, -564.429
Title: Mario Kart 64 Hacker
I doubt you'll get very far with that method, as the value is likely to be overwritten before it's read again. Worth a shot, but don't be too disappointed.

_________________
Image 143
HyperNova Software is now live (but may take a few tries to load) currently down; check out my PSP/DS/Game Boy/Windows/Linux homebrew, ROM hacks, and Gameshark codes!


Top
 Profile  
Reply with quote  
PostPosted: Sun Jun 08, 2008 12:23 am 
Offline
Kommunist
Kommunist

Joined: Tue Oct 10, 2006 9:32 am
Posts: 445
Indeed, this method I posted will get you nowhere because I don't set the debug button "On" but "Off"... (1=off, 0=on).

The "good" way to do it should be :

This will 'enable' the AND code type, use this code :
023FE424 E0033004 // Changes the D4 code type to AND
then use the D4 code type :
DA000000 027FFFA8 // Loads the 16 bits value at 0x027FFFA8
D4000000 0000DFFF // AND it with 0xDFFF
D7000000 027FFFA8 // Writes back the value at 0x027FFFA8

or

927FFFA8 DFFF2000 // If (the 16bits value at 0x027FFFA8 AND 0x2000) == 0x2000
DA000000 027FFFA8 // Loads the 16 bits value at 0x027FFFA8
D4000000 0000E000// ADD 0xE000 to it (= substracts 0x2000 from it)
D7000000 027FFFA8 // Writes back the value at 0x027FFFA8
D0000000 00000000 // Endif


And yes, the value gets overwritten by the ARM9, but what is important is that the code is executed before the value is readen by the ARM7 (which could be always the case with the AR's hook?)... And btw this method (writing directly to 027FFFA8) is what I used for the 'enable debug vcr' code for DQIV.


Top
 Profile  
Reply with quote  
PostPosted: Sun Jun 08, 2008 11:57 pm 
Offline
Komrade
Komrade
User avatar

Joined: Tue Mar 27, 2007 6:23 pm
Posts: 1354
Location: Mario Raceway, 1509.831, 217.198, -564.429
Title: Mario Kart 64 Hacker
Hm, so some games do respond to that even when swiIsDebugger() returns false? Could be an interesting hack. Can AR patch ARM7 binaries? Those flags are only accessible by ARM7 and have to be copied somewhere for ARM9 to see, so there's probably only one read of the hardware register you could patch, and not have to worry about anything overwriting it.

_________________
Image 143
HyperNova Software is now live (but may take a few tries to load) currently down; check out my PSP/DS/Game Boy/Windows/Linux homebrew, ROM hacks, and Gameshark codes!


Top
 Profile  
Reply with quote  
PostPosted: Mon Jun 09, 2008 11:14 am 
Offline
Kommunist
Kommunist

Joined: Tue Oct 10, 2006 9:32 am
Posts: 445
Erm I've mixed up ARM9/ARM7. I meant the data is written by the AR just after ARM7 wrote it, and before ARM9 reads it.

And yes, you can patch ARM7/ARM9 with the AR. Usually the NDS button data is copied at 0x027FFFA8, so setting a bpw on it (or a bpr on 0x04000136?) will be enough to find the ARM7 routine that writes it (and then being able to patch it).

I wanted, some time ago, to test the Debug button code for each and every game, but it sounded like too much work... For DQ I just got lucky : I looked at the ARM9 pad read routine for some reasons while hacking it, and I saw there was a "test" for the debug button value in it.


Top
 Profile  
Reply with quote  
PostPosted: Mon Jun 09, 2008 4:24 pm 
Offline
Kommunist
Kommunist

Joined: Sun Jun 01, 2008 1:32 pm
Posts: 6
I still dont get it... Nothing happens...

What do you have to do to press the debug button?

I really want to do it...


Top
 Profile  
Reply with quote  
PostPosted: Tue Jun 10, 2008 12:31 am 
Offline
Komrade
Komrade
User avatar

Joined: Tue Mar 27, 2007 6:23 pm
Posts: 1354
Location: Mario Raceway, 1509.831, 217.198, -564.429
Title: Mario Kart 64 Hacker
Well, like I said, that method might not work in all games, and most games probably just won't respond to it.

_________________
Image 143
HyperNova Software is now live (but may take a few tries to load) currently down; check out my PSP/DS/Game Boy/Windows/Linux homebrew, ROM hacks, and Gameshark codes!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 89 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group