Author Topic: MegaDrive Battery Saves compatibility  (Read 695 times)

0 Members and 1 Guest are viewing this topic.

Offline Artai

  • Newbie
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
MegaDrive Battery Saves compatibility
« on: May 13, 2017, 09:32 PM »
Hi everyone.
As some of you know, there's an issue in playing games with battery save on both EDMD and emulators.
I think a topic like this can be useful, since I recently tried to convert these files to play games on various platforms.
The games chosen as samples are the Phantasy Star series. The colored texts are avoidable notes.

So I begin my experience with Master System emulation.
It turns out SMS battery saves are 128KB, and with the tool provided by krikzz you can automatically shrink the file to half its size.
I had to do this because Phantasy Star would suddenly freeze on my console for unknown reasons, and I was nearly at the end! Seems my save got corrupt, but on emulators it would go smoothly.
I managed to use this save file on three different emulators: Fusion for Windows, Openemu for OS X, MD.emu for Android. Every save file is initially written by EDMD, not viceversa.
Tutorial
-Fusion: first browse for the saves folder in Set Config, the program doesn't do it automatically. Then place the SRM in the chosen folder and change its type to .ssm
-Openemu: start a new game and save. Go to AppSupport/Openemu/TwoMbit/Battery Saves and see how the .sav file is named. Delete it, place the SRM instead, and change both its name and filetype (.sav)
-MD.emu: set Save Path to Same as Game in System Option, then drag your SRM to the same folder as your rom.

As you can see in the notes, I've used the same source to every emulator.

Now the topic's issue: the MegaDrive saves for Phantasy Star II almost work on these emulators. The ROM successfully detects my save and its name (e.g. PSII saved in slot 1 by Rolf) on every platform, but I start over from level 1 and the first city.
When a save file is created on EDMD, it's made of 64KB of clean data. On the other hand when you create a save file with the mentioned emulators you get a mess of files incompatible to each other, because they pollute every hex string their own way.
In the attached screenshot you have a SRM from EDMD on the left, and a Openemu (core is the common GenesisPlus) battery save, which is almost identical to a Fusion's one.



The only difference seems to be this alternation of FF (ΓΏ) once every other address. Unfortunately I'm not a programmer and I can't figure out how to automatically change over 65,000 strings, and do the reverse.
I don't know if this could solve the problem, but isn't it worth a try? Please help :D
EDMD v2 OS v35 - MegaDrive 2 CD 2 32X

Offline chrisw80

  • Newbie
  • *
  • Posts: 30
  • Karma: +2/-0
    • View Profile
Re: MegaDrive Battery Saves compatibility
« Reply #1 on: August 18, 2017, 03:42 PM »
There is a tool for this 8to16 and 16to8, but I can't find it.  Here is what I am referring to, but the links are dead.

https://krikzz.com/forum/index.php?topic=832.0

Offline FeverDrive

  • Hero Member
  • *****
  • Posts: 713
  • Karma: +23/-0
  • GOTTA GO FAST
    • View Profile
Re: MegaDrive Battery Saves compatibility
« Reply #2 on: August 19, 2017, 12:45 AM »
There is a tool for this 8to16 and 16to8, but I can't find it.  Here is what I am referring to, but the links are dead.

https://krikzz.com/forum/index.php?topic=832.0
https://krikzz.com/pub/support/everdrive-md/v2/
Previously known as DC/AC

Offline chrisw80

  • Newbie
  • *
  • Posts: 30
  • Karma: +2/-0
    • View Profile
Re: MegaDrive Battery Saves compatibility
« Reply #3 on: August 19, 2017, 12:56 AM »
Thank You!