Hacking is there no sleep

HackNeyed

Active Member
Newcomer
Joined
Jul 8, 2006
Messages
26
Trophies
0
Age
41
Website
Visit site
XP
191
Country
Hey, don’t bark at Nintendo, the original GBA didn’t have a lid and the GBA SP never automatically went into sleep mode when you closed it. Not all GBA games support sleep mode at all anyway.

Some GBA games, more so in the later ones, have an option to put the game into sleep mode but, and you didn’t specify though I’ll assume you are using the EZ 3n1 which does not support GBA games’ sleep mode.

The eWin Expansion Pak however does support sleep mode in games. As far as power drain is concerned, running the game from NOR on the 3n1 is just like playing a retail cart (though without the option of ingame sleep mode). I’d figure the normal power drain while playing a game on the eWin vs the 3n1 running in PSRAM mode would be about equal so if you run the games in PSRAM and would like the sleep mode then I’d get the eWin. But honestly, I’m just nit picking.
 

Hooya

Well-Known Member
Member
Joined
Aug 25, 2006
Messages
1,878
Trophies
0
Age
42
Location
Central Illinois
Website
Visit site
XP
317
Country
United States
The DS games have to be programmed to go to sleep mode when the DS is closed?

Or is it already an in-built function for all DS games.

It has to be programmed in. I say this because many games utilize some sort of effect or something when you close the lid. The two Castlevanias for instance sound like a coffin lid shutting when you close it. In many Mario games like NSMB and March of the Minis Mario says "bye bye!" when you close the lid and "it'sa me, Mario" when you open it up. Bleach automatically hits "pause" when you close the lid so the action doesn't start up right away, and in Zelda you use the sleep function to solve a puzzle in the game at a certain point. All of these instances point to me that there is some sort of in game programming that activates sleep function. This is further supported by situations like Tag mode in Zelda and the analogous Trade mode in the Nintendogs series where the DS doesn't go to sleep but rather in an open connection mode when the machine is closed.
 

HackNeyed

Active Member
Newcomer
Joined
Jul 8, 2006
Messages
26
Trophies
0
Age
41
Website
Visit site
XP
191
Country
I knew someone could answer that better then me.

I will add that I believe that sleep mode in DS games (unlike GBA game) is mandatory by Nintendo. Much like when Microsoft said to developers on the 360 that EVERY game must support the ability to play people's custom soundtracks in game via the Guide Tap thingy.

My beef is that I would rather have EVERY game let me remap controls as I like, instead of playing a game where the button that throws a grenade was the reload button in that other game I just beat... and to play custom music all racing games. hehe
 

Movi

Well-Known Member
Newcomer
Joined
Aug 16, 2007
Messages
64
Trophies
0
XP
124
Country
Poland
Ok, what about GBA games that support pseudo-sleep (like Metroid Fusion and Zero-Mission)? When i activate the sleep mode, they dim and then almost instantly wake up. Do i need to patch them or something like that?
 

DanTheManMS

aka Ricochet Otter
Member
Joined
Jun 2, 2007
Messages
4,453
Trophies
1
Age
34
Location
Georgia
XP
751
Country
United States
Rather than using GBATA for adding sleep mode to GBA games, try Dwedit's program at http://www.pocketheaven.com/boards/viewtopic.php?t=5797

Dwedit said:
Apparently, GBATA does indeed do this already. However, GBATA's version does not appear to shut down the screen and sound hardware properly, or make any attempt to hide the sleep sequence joystick buttons from the game. (my tool suppresses START if you hold down L+R then hit start, doesn't do anything about L or R though.). With my tool, the wake up sequence is also filtered from the game since it waits for you to let go, then waits 3 frames afterwards.

The programs both work differently. His program changes the first instruction to jump to some code at the end, which installs the IRQ handler. Then any time the game would install its own IRQ handler, it redirects the address to another address designated as the "game's IRQ address". The IRQ handler sits in cartridge space, and the game jumps there first, then jumps to the real IRQ handler. His tool also appears to add a huge overhead of 17 instructions (arm instructions executed from cartridge space...ouch) to all interrupts, which is about a whopping 5% cpu usage if hblank interrupts are enabled.

My program modifies the code when a game tries to install an interrupt to instead jump (so it changes the write to a long jump... weeee) to a custom interrupt installing routine, which sets up the 'game's IRQ address', and installs 7 words of fast IRQ code at the top of the supervisor stack, then sets the interrupt handler to point there. My IRQ handler only has 4 instructions (in iwram) of overhead for non-vblank interrupts.
I guess his idea to hijack the first instruction, then alter the address of all the game's irq installers was probably a better idea.

Other differences between the program is that his tool fails on Final Fantasy 5, when mine doesn't.
 

HackNeyed

Active Member
Newcomer
Joined
Jul 8, 2006
Messages
26
Trophies
0
Age
41
Website
Visit site
XP
191
Country
Ok, what about GBA games that support pseudo-sleep (like Metroid Fusion and Zero-Mission)? When i activate the sleep mode, they dim and then almost instantly wake up. Do i need to patch them or something like that?

The 3n1 and Ez4 just does that, they dont work right when you try to use sleep mode, in game or Dwedit's app and if I recall correctly GBATA doesnt work as well. Well, thats not to fault the apps, it seems to be the Ez cards because the eWin Exspanion Pak does actually support sleep mode as I've tested in game and Dwedit apps.

Dwedit's program is nice, though it makes Advance Wars white screen... maybe others.
 

roflmywaffle

Well-Known Member
Newcomer
Joined
Apr 30, 2007
Messages
63
Trophies
0
XP
30
Country
United States
GBATAs method works, but other methods don't. It was a while before (we frost & myself, I was helping him with a bunch of "new EZV owner" stuff) found something that did. We tried dwedits tool w/o success...
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    SylverReZ @ SylverReZ: @realtimesave, Sup