EEPROM saves are out to kill me, apparently

Discussion in 'GBA - Hardware, Devices and Utilities' started by carterman, Oct 17, 2008.

Oct 17, 2008
  1. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
    Apparently getting them to work with my backups is a fool's errand. Take, for example, Astro Boy - Omega Factor. I back up the rom using GBA Backup Tool (only version 0.1 because I'm a M3DS Real user), backup the save using chishm's cart_save.gba with my M3 Perfect CF (maybe this is the source of my problems? The DLDI file is supposedly non-working, but I've not had any problems with it ever), and then, well, I can't get it to read, at least with my M3 GBA expansion. Now, is there something else I need to do to get them working? Some kind of patching program? Anything at all? [​IMG]

    Here's the save file I'm trying to use for Astro Boy (US version), at least: http://rapidshare.com/files/154829354/ASTROBOY.SAV.html
     


  2. Destructobot

    Member Destructobot Crave the Hammer

    Joined:
    Oct 15, 2006
    Messages:
    5,005
    Location:
    Portland, OR
    Country:
    United States
    Try this: http://rapidshare.com/files/154861928/ASTROBOY.SAV.html

    Depending on the hardware you're using, EEPROM saves sometimes need to be byte flipped (i.e. take the first 8 bytes and reverse their order, then the next 8 bytes, and so on). The M3 Perfect was like this, so the M3 GBA expansion probably is too.
     
  3. Tanas

    Member Tanas GBAtemp Addict

    Joined:
    Aug 19, 2006
    Messages:
    2,258
    Country:
    United Kingdom
  4. Destructobot

    Member Destructobot Crave the Hammer

    Joined:
    Oct 15, 2006
    Messages:
    5,005
    Location:
    Portland, OR
    Country:
    United States
    The M3 Real handles save patching automatically, so that shouldn't be necessary.
     
  5. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
    while I haven't been able to test the save out myself yet, in case it does work, how exactly would you go about doing that myself? I have A LOT of GBA games, LOL.
     
  6. DanTheManMS

    Member DanTheManMS aka Ricochet Otter

    Joined:
    Jun 2, 2007
    Messages:
    4,325
    Location:
    Georgia
    Country:
    United States
    If this is the case, one way of flipping every 8 bits is with the Perl script found at http://wiki.pocketheaven.com/FlashManager

    Most people won't have Perl installed though, but I don't know of a way to do it with a more accessible language.
     
  7. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
    Well, I tried out the save, and it didn't work...that save you gave me was byte flipped already, right? Right now, I'm starting to think that cart_save just isn't writing saves properly to my M3 Perfect CF because of DLDI problems, but I'm quite honestly stuck.

    ...or at least until my (hopefully working) Acekard 2 gets here from DX and I can finally use GBA Backup Tool 0.2 and see if my problem is possibly just cart_save. Any alternatives to cart_save at all? *shrugs*
     
  8. Destructobot

    Member Destructobot Crave the Hammer

    Joined:
    Oct 15, 2006
    Messages:
    5,005
    Location:
    Portland, OR
    Country:
    United States
    The way I do it is to open the save in Hex Workshop, then use the byte flip function (Tools -> Operations -> Byte Flip -> 64 bit unsigned quad -> OK). There are probably other hex editors that will do this, but I don't know specifically what they are.

    Note that DanTheManMS meant to say "8 bytes", not "8 bits", and the wiki he linked to makes the same mistake.


    Edit: The save probably needs to be in a different format. If you post an Astroboy save from the M3 Real GBA expansion I'll take a look at it and see if I can make it work. Unfortunately, converting saves for use with the M3 range can be much more complicated than it is for any other GBA flashcart.
     
  9. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
    http://rapidshare.com/files/155009881/Copy...Factor.sav.html

    Note the 128 kilobyte size versus the original 8 kilobyte size. It also only seems to do this to EEPROM saves - I can directly use my saves backed up from SRAM games fine and it doesn't seem to mess with the size of them. (EDIT: This is false. It converts saves to 128 KB - I'll upload sample Metroid Zero Mission files to compare, the 32 KB original and 128 KB M3 Real GBA save - well I just accidentally erased my cartridge's save data, lol - any way to convert a 128 KB save back down to 32 KB, lol?)

    Thanks so much for all of your help. Does the EZ V 3-in-1 have this much trouble with EEPROM saves? Because I'm now seriously tempted to get one given all of the trouble with the M3 Expansion.
     
  10. Destructobot

    Member Destructobot Crave the Hammer

    Joined:
    Oct 15, 2006
    Messages:
    5,005
    Location:
    Portland, OR
    Country:
    United States
    Okay, new idea. Take the 8KB file you uploaded initially and pad it to 128KB (add blank data to the end of the file to get the needed file size). This will do it for you if you're using Windows: http://gbatemp.net/index.php?download=1354. A hex editor will work if you aren't.

    It looks like the save does not need to be byte flipped like it would for the M3 Perfect, so hopefully it just needs to be padded to the standard size.
     
  11. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
    Doesn't look like it worked. I'm still not convinced that the save backup is a good one at all, either due to the M3 Perfect CF DLDI supposedly being "non-working"...although it seems to work fine for other things. Go figure.
     
  12. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
  13. Destructobot

    Member Destructobot Crave the Hammer

    Joined:
    Oct 15, 2006
    Messages:
    5,005
    Location:
    Portland, OR
    Country:
    United States
    Those look like saves from different games, judging from the fact that the data structures look completely different, and the Final Fantasy Tactics Advance.sav file says "MarioTennis" at the start of the file.

    As for the Astroboy save, I'm having trouble getting any astroboy save working in VBA, and I don't have a flashcart in my posession at the moment that is good for this sort of testing, so I'm no help there.
     
  14. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
  15. Destructobot

    Member Destructobot Crave the Hammer

    Joined:
    Oct 15, 2006
    Messages:
    5,005
    Location:
    Portland, OR
    Country:
    United States
    Yes, those two saves are identical.
     
  16. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
    Well, at least what we've learned here is:
    - The M3 merely adds padding to non-EEPROM files to make them 128 KB
    - It does not work with my current method of obtaining EEPROM GBA Saves
    - Adding padding to EEPROM saves does not work immediately.

    This implies that either:
    - My method of obtaining EEPROM saves is messed up
    - Backed up EEPROM saves do not work at all

    I have to wait until I get my Acekard in and am able to try out Rudolph's GBA Backup Tool 0.2, but in the meantime, I might fire off an email to chishm to see if cart_save just does not work on the M3 Perfect CF...
     
  17. DanTheManMS

    Member DanTheManMS aka Ricochet Otter

    Joined:
    Jun 2, 2007
    Messages:
    4,325
    Location:
    Georgia
    Country:
    United States
    That would be because I wrote the wiki article, hehe. Thanks for the catch.
     
  18. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
    OK, here's 2 saves that should be theoretically identical in content, taken from the NES Classics Legend of Zelda, US version: http://rapidshare.com/files/155745182/zelda.rar.html

    ZELDA 1.sav: Created using cart_save
    The Other File: Save file created using IPS patched backup copy

    Both should have a freshly created first save file with the initials CD. Soon as my acekard2 gets here, maybe then I can get EEPROM saves working. Plus, there's an EEPROM converter included with the new GBA Backup Tool, but it does nothing for me.
     
  19. Destructobot

    Member Destructobot Crave the Hammer

    Joined:
    Oct 15, 2006
    Messages:
    5,005
    Location:
    Portland, OR
    Country:
    United States
    The saves are not identical, but they definitely look like they come from the same game. ZELDA 1.sav looks like a standard EEPROM save, while the other file is byte flipped. Theoretically, if you take the output from cart_save, byte flip it and pad it to 128KB it should work on the M3 GBA expansion. Here is that file: http://rapidshare.com/files/155760089/ZELD...lipped.rar.html

    Load a different GBA game (preferably one that uses the same save type, but that's not vital) to flush the old Zelda data from the GBA expansion's SRAM, then replace the Zelda save file with the one I uploaded. Be sure to rename it with the correct filename. It should work, but we've been there before.
     
  20. carterman
    OP

    Member carterman GBAtemp Regular

    Joined:
    Mar 22, 2007
    Messages:
    226
    Location:
    Lubbock, TX
    Country:
    United States
    Yeah, the saves weren't identical, as it turns out. Zelda only rewrites the save when there's an actual difference, or something. AND IT WORKED!!!! I LOVE YOU!!! [​IMG]

    Gonna see if anything else will work with this. Weird that it wouldn't do it before with Astro Boy...
     

Share This Page