Hacking TempGBA: NDSGBA revival

Do GBA games make your nono parts happy?


  • Total voters
    429
I wouldn't mind at all.

Relatedly, how well does gbaemu4ds emulate the GBA right now? And do you think you're close to hitting the DS's hardware limit?
Here is the compatibility list http://wiki.gbatemp.net/wiki/Gbaemu4ds_Compatibility_List. The Problem with the gbaemu4ds is I run the games on the cpu directly and only hook reads and writes/reads to the I/O ,writes/reads to the Card, swi and so on. So everything is executed 4-8 times as fast exception those opc they are slowed down (they take about 100 times more cpu time). So the problem is how can I patch the gba code so it won't crush my hypervisor (by overwriting the code and so on) and dose not run out of sync (Like on H-Blank irqs(they have to be patched manual) or sometimes they speed up and run to fast and then crush).
 
  • Like
Reactions: WiiUBricker
Signed up just to say I support the project. To be honest the emulation for GBA\SNES is really poor on the DSTWO when compared PSP (which is also free to begin with.)
 
toke entry: add wireless multiplayer support

lol

j/k hooking up the normal GBA's is fun enough.

Good to see such projects.

I gotta say:
Back then when the M3CF and that Supercard were out:
M3 won hands down.

The Supercard DS Two however has been worth the purchase for the hombrew alone !
 
toke entry: add wireless multiplayer support

lol

j/k hooking up the normal GBA's is fun enough.

Good to see such projects.

I gotta say:
Back then when the M3CF and that Supercard were out:
M3 won hands down.

The Supercard DS Two however has been worth the purchase for the hombrew alone !

Well that's because the slot 2 Supercard used slower RAM so most GBA games didn't run at full speed.
 
A little status update, as of today (2013-03-11).

I believe I got the battery-backed save to work, but it doesn't work in Pokémon Emerald; it creates a 128 KiB file but it's devoid of data and/or it's read incorrectly.

In Donkey Kong Country, on one emulator run, the save is created correctly, then I exit the emulator. On a second emulator run, I see my saved game, start it and exit the emulator, and the save becomes 0 bytes.

Maybe that's down to the game_config.txt file? If so, should I include a game_config.txt in the initial download, with a link to filetrip's page for game_config.txt so that a user can download new files when wolfman51 does his additions?

---

About cheats, I think it would be relatively easy to add support for them to the code skeleton, but I can't find any reasonably large pack of cheats in a certain format that would be easy to edit by users, such as PAR code collections. cheats.gbatemp.net does not currently resolve, so I can't see the format of the GBA cheats pack that's supposed to be on there.

If any user has a copy of this pack, I would like to obtain it, as well as information about the pack's creators so I can put the correct author on a new filetrip page about it.
 
  • Like
Reactions: codezer0
About cheats, I think it would be relatively easy to add support for them to the code skeleton, but I can't find any reasonably large pack of cheats in a certain format that would be easy to edit by users, such as PAR code collections. cheats.gbatemp.net does not currently resolve, so I can't see the format of the GBA cheats pack that's supposed to be on there.

If any user has a copy of this pack, I would like to obtain it, as well as information about the pack's creators so I can put the correct author on a new filetrip page about it.
Databases: http://forum.supercard.sc/thread-6705-1-1.html

I outline the .cht file format here. The post is malformatted due to the forum move, Pluupy has a converted/fixed BBcode spoilered in his post a few posts in.
http://gbatemp.net/threads/guide-make-snes-cht-files-for-the-dstwo.263113/
 
a) Databases: http://forum.supercard.sc/thread-6705-1-1.html

b) I outline the .cht file format here. The post is malformatted due to the forum move, Pluupy has a converted/fixed BBcode spoilered in his post a few posts in.
http://gbatemp.net/threads/guide-make-snes-cht-files-for-the-dstwo.263113/
a) Downloaded, thanks. The cheat pack appears to use a word,byte hex format and the names for the cheats are written in a broken encoding:
cheats-encoding.png

b) That link is to the SNES .cht format. Should I assume that the "bank" is dropped in favor of some kind of RAM offset? SRAM? I dunno.
 
a) Downloaded, thanks. The cheat pack appears to use a word,byte hex format and the names for the cheats are written in a broken encoding:

b) That link is to the SNES .cht format. Should I assume that the "bank" is dropped in favor of some kind of RAM offset? SRAM? I dunno.
It's Shift-JIS IIRC, easy enough to change in something like Notepad++, then I copy-paste to google translate to see WTF I'm supposed to be reading.

The bank being dropped was for the SNES emulator, I mentioned it because it's the reason only PAR codes worked, since GG codes needed to modify banks over than RAM.

Dunno' about the various GBA banks.
 
Update (2013-03-13): Battery-backed saves are working reasonably well with game_config.txt, at least in Pokémon Emerald with Exophase's version of the file. I've decided to move it so it gets included in the first release at the right place, $(microSD root)/TEMPGBA/game_config.txt.
 
Equal or slightly slower. The sound crackles in a few games; that's up to the frame skipping.
wow, really? You've made one to be equal or about as equal as the other that has been out for years now? That is very impressive!!:blink:
 
Well it uses almost the exact same source, minus some features and menu stuff.
This. It's pretty much just gpSP Kai, which NDSGBA also used. But when we first got the source, it didn't display anything on the screens of the DSTWO, just pure white. When we got it working, it was the same performance (ish, see details below) as NDSGBA.

Screen drawing was pretty much already optimised, so it didn't need any improvement; CPU emulation is done via on-the-fly translation of GBA code to MIPS code, so it didn't need any improvement; inputs worked properly without the odd delay from CATSFC; but sound crackles a whole lot. That's something we have yet to fix fully. For now we just ramp up the CPU speed and hope for the best! BAG also tried to fix frame skipping, but it's implemented oddly as 2 variables in gpSP (and Kai) instead of 1.
 
Second update for today: Saved states, which were a major crasher, now work reasonably well when loaded. Their screenshots also appear on the saved states menu when a "Load saved state #X" cell is selected.

Cheats are still not in, because I can't support something that I can't understand (despite Rydian's post about it - sorry!). The project is open-source, so one who understands the cheat format more than me could put that support in and lift the menu code from CATSFC.

Who here would actually use the rewinding and rapid-fire features from NDSGBA?
 
Second update for today: Saved states, which were a major crasher, now work reasonably well when loaded. Their screenshots also appear on the saved states menu when a "Load saved state #X" cell is selected.

Cheats are still not in, because I can't support something that I can't understand (despite Rydian's post about it - sorry!). The project is open-source, so one who understands the cheat format more than me could put that support in and lift the menu code from CATSFC.

Who here would actually use the rewinding and rapid-fire features from NDSGBA?

I use the rapid fire for turn based games, shooters, and MMBN games but it's honestly a low priority for me below almost anything but cheats lol.
 
Well, there's two formats, and this is what I know of them.

  1. The first is the encrypted codes (Action Replay and Gameshark) from the physical, commercial devices. This is the type the gpSP ports/branches on the PSP support.

    PAR_V3 (M)
    205D5356 3DCE2E76
    ABEE9D7E 5832AAE6


    PAR_V3 HP In Battle
    A178F169 41239FBF
    A05A144C 078B0074


    PAR_V3 HP Out Battle
    8C57D694 CB339B75
    D0E34D66 5796A7D3


    PAR_V3 Freeze Timer
    6E0075F4 2DF8A892


    PAR_V3 No Encounters
    1C41D5DE BE72B526


    PAR_V3 Yes Encounters
    D90D5DC7 941C62C5
    This format needs no header info (emulators load it by matching filename or users do it manually), and is as follows.

    PAR_V3 HP Out Battle
    8C57D694 CB339B75
    D0E34D66 5796A7D3


    CHEAT_TYPE CHEAT NAME
    LINES OF
    THE CODE

    • The cheat_type is most often PAR_V3, though it looks like gameshark_v3 and RAW might work, but I've never had any luck with anything other than PAR_V3 (likely it's only what gpSP on the PSP supports), but thankfully PAR_V3 is the most common. "Pro Action Replay" is the older name given to the device branch, which is likely why it's used here instead of the more modern "AR" device name. Also AR and GS merged somehow with a version of the codes or some shit like that. Not sure on that story.

    • The cheat name is... the cheat name. Spaces and basic punctuation work, I don't know any length limit as I keep mine short so they show up on the screen without getting cut.

    • PAR/AR codes are given in two segments of 8 characters each per address/instruction modified (one line can modify up to 4 bytes of RAM IIRC, try decrypting some PAR codes with the tools below and you'll see the basics I guess). PAR/AR also has control codes for modifying assembly and making codes that are triggered via button presses. I don't know much of anything how these work though, but they're generally the codes that are like 8 lines long instead of one or two.

    Cracker's got cheat conversion/encryption/decryption tools and info here, it's what helped me figure out what I know so far.
    http://crackerscrap.com/projects.php
    Of note is that the Mother 3 codes don't work on gpSP Kai for the PSP, probably because Mother 3 is a full 32MB game, and most things tend to fail on it as it is (Cracker's tools and other such things) since 32MB is the max addressable ROM space from what I've read. I can toss other cheat files I've made at you, I just googled for AR codes to make the text files anyways.



  2. The second format seems built specifically for emulators, often called RAW codes as they're lists of addresses and values to write to those addresses (opposed to being encrypted and with extra control codes like modern AR/GS codes). This doesn't appear to be the type that gpSP on the PSP supports, but a lot of other things support it and it needs no encryption/decryption so I suppose it's worth knowing.

    [Role]
    MARIO = 41C20, 0
    PEACH = 41C20, 1
    KINOPIO = 41C20, 2
    LUIGI = 41C20, 3

    [Life]
    ON = 41111,63

    [Become airborne (hold down the jump button)]
    ON = 41C2E, 5F

    [Transparent]
    OFF = 41C2D, 0
    ON = 41C2D, 5F

    [GameInfo]
    Name = 0002 - Super Mario Advance (J) (Super Mario A) (J) ACT 32
    System = GBA
    Text = big fat finishing

    [Life]
    ON = 41111,63

    [Cheat title in square brackets.]
    NAME_OF_OPTION = address,value

    • Cheat name/title is obvious, this is the name of the cheat entry/group.

    • The name of the option. If there's multiple valid values for the address that players may want, there can be multiple lines (like the first code in the example), each with a different value. Generally this shows up as a multiple-choice selector when users pick that code. In cases where there's just one option for the code, most people just call it "ON" (and the interface tends to not give an option since it's just a toggle). In cases where the value of the address needs to be specifically reset (opposed to just unlocking it), people will add an "OFF" line as well (which makes it a multi-choice thing), but as far as I can tell the ON and OFF naming is just customary.

    • An equals sign to divide the name from the technical info.

    • The address appears to be the RAM address to modify, with leading 0's trimmed.

    • The value is the value in hex to write to that address. If more than one byte is being modified, they're separated by commas as well. For example writing zero to two bytes would be...
      ON=445E8,0,0

    • I'm assuming the game info is optional.
 

Site & Scene News

Popular threads in this forum