Pocketsnes V4


Yeah I've just checked the code and I'm missing a few calls to Sync(), so with the current version there is a chance you can lose data. I'm creating a new version to resolve these issues, I'm also changing the SRAM is handled to be more DaveC friendly.

I also found a cause for the occasional slowdown (where the game appears to stick for a second or two every now and then ). Its caused by the auto saving of SRAM, the emulator will check the SRAM every now and then and if it has been changed it will save the data to disk. In the auto sram routine I did actually have a call to sync() which is what causes the delay.

So I've disabled this functionality at the moment, so SRAM will now only be saved as you return to the menu. You can currently have the menu automatically save it for you, or you can choose to manually save SRAM.

Is anyone going to cry like a bitch about me removing the automatic SRAM saving while running the emulator? I suppose I could add another menu option to allow you to enable but I don't want to add more options to the emulator just for the sake of it, so unless I get a decent response to save it I'm not going to bother.

Oh and I've tidied up where the SRAM files are stored, they were stored in the same directory at pocketsnes.gpe but they are now held in the options directory with everything else, I'll reming everyone again when version 5 is released as it means you will have to move any existing saves into the options directory in order for pocketsnes to see them.

Later
Reesy

Sounds like someone needs a donation :) . Keep up the good work sir!
 
Last edited by a moderator:
Those changes sound great, Reesy. Returning to the menu to auto-save SRAM is perfect, it will become second-nature. Thanks.
 
Hi, Reesy !

i'm a little surprised no one reacted to my previous post about the impossibility to use the savestates system when switching on/off the sound option.

am i the only one whose savestates made with sound desactivated just don't work with sound activated ?
or is it only this peculiar RPG related problem ?

for example: i started to play without sound.
i'm about to enter a dungeon with my first savetate.

without sound, everything works fine and i enter the dungeon (beware evil lurking creatures :D)
with sound activated (whatever settting), i enter the dungeon... only to get a black screen :/
 
Just tested this. My sound-on savestates work fine when I load them with sound off, but a savestate made with sound off locks the emulation when loaded with sound turned on and there should be a sound (like the sound of an attack in an RPG).

baalim posted on Feb 1 2007 at 09:49 AM said:
Hi, Reesy !

i'm a little surprised no one reacted to my previous post about the impossibility to use the savestates system when switching on/off the sound option.

am i the only one whose savestates made with sound desactivated just don't work with sound activated ?
or is it only a final fantasy V related problem ?

for example: i started to play without sound.
i'm about to enter a dungeon with my first savetate.

without sound, everything works fine and i enter the dungeon (beware evil lurking creatures :D)
with sound activated (whatever settting), i enter the dungeon... only to get a black screen :/
 
Last edited by a moderator:
I'm no coder, but I think I know the problem baalim and Stevie Max. That's not a pocketsnes problem but something that would happen in most any emulator.

If you start playing a game with sound disabled, the emulator is not emulating the sound chip, so when you create a sound-less save state, there is audio data in the file. Therefore when you load the state with audio enabled, the emulator has no audio data to load up (or to use as a reference point for starting music or sound effects), thus the crash when it attempts to play sounds.
 
Yep, more or less. The sound is active the second time, and so the game is expecting it to be in a certain state, but it isn't, gets confused and crashes, as it would never happen on a real console.
 
I don't think so, if possible, try saving to sram and load that with sound activated.
 
All I know is this emulator really rocks. I appreciate all involved and positive feedbbacks for Reesy.... I've been playing this every signle night since 1st release and love it. So user friendly. My only issue was with save states (not working) & occasional freezes or crashes (mostly when playing Sim world. Seems like bugs will be fixed with version 5, Awesome job & thanks.
 
That sounds fine to me. If it eliminates the pauses and constant card writing that works.

You could also have a directory called "sram" or something like that. This way it is separate and if you want to delete or move saves they aren't mixed in with other things. Just a suggestion though if you like it you can use it, if not it is no big deal.

After looking at the code for awhile do you think there is much room for speedup? Some games run perfectly smooth but others such as Axelay are a bit choppy. Some of us can only go to 240 MHz (like me) so further overclock is not possible. I don't know if there is anything that can be done as alot of stuff is already ASM so I was just wondering if it is basically at the limit of speed right now.

Thanks for all of the great work on this.
 
I was thinking about splitting out the savestate, sram and setting files. At the moment everything is shoved in the settings directory, I may do this if I get bored.

I'm currently going through the graphics code line by line and adding comments to explain what I think is going on. Hopefully by the time I'm finished I will have some an idea of what is going on. At this point I can start to create something tailored to the GP2X, there is alot of code in there which allows the rendering code to be very portable so I should be able to rip out a whole load of stuff but we shall see.

I'm only spending a few hours a week on it so I wouldn't expect anything soon ;)
 
Reesy posted on Feb 1 2007 at 06:36 PM said:
I was thinking about splitting out the savestate, sram and setting files. At the moment everything is shoved in the settings directory, I may do this if I get bored.

I'm currently going through the graphics code line by line and adding comments to explain what I think is going on. Hopefully by the time I'm finished I will have some an idea of what is going on. At this point I can start to create something tailored to the GP2X, there is alot of code in there which allows the rendering code to be very portable so I should be able to rip out a whole load of stuff but we shall see.

I'm only spending a few hours a week on it so I wouldn't expect anything soon ;)


Cool , sounds good.

Take your time no rush. Thanks for all of the time you have put into this.

Cheers
 
Last edited by a moderator:
Reesy posted on Feb 1 2007 at 06:59 PM said:
Well there have been no compliants about losing the in-game automatic SRAM saves, so I'll go ahead and release version 5 a little later.

Mhhh... I may sound dumb but... what are SRAM saves? I only know quicksave/load and in-game saving :ph34r:
 
Last edited by a moderator:
On alot of cartridges you could save information (scores, levels etc) directly on the cartridge in onboard memory called SRAM. PocketSnes emulates this SRAM but each time you restart the game the SRAM is cleared, so to get around this the SRAM is dumped out into a file. This file is then loaded each time you play the game, giving you the basic functionality you would have had using the original cartridge.

If you use save states, then the SRAM is included in the save state and you do not need to worry about SRAM saves. Some people prefer not to use save states as they like to enjoy the games as the originally released, its these wierd types of people that make use of the SRAM saves.
 
Hi, The emulator is great but how can i select PAL or NTSC? I am playing games that are running far too quick and i think is because is PAL and I am playing NTSC or the other way around. One of these games is Pinball Fantasies is quite hard to play like that ;)

Keep up the good work, dream team ;)

Thanks
 
Reesy posted on Feb 1 2007 at 08:21 PM said:
On alot of cartridges you could save information (scores, levels etc) directly on the cartridge in onboard memory called SRAM. PocketSnes emulates this SRAM but each time you restart the game the SRAM is cleared, so to get around this the SRAM is dumped out into a file. This file is then loaded each time you play the game, giving you the basic functionality you would have had using the original cartridge.

If you use save states, then the SRAM is included in the save state and you do not need to worry about SRAM saves. Some people prefer not to use save states as they like to enjoy the games as the originally released, its these wierd types of people that make use of the SRAM saves.

--> so it's those .srm files?
I personnaly don't make use of them, but they can prove usefull, for example in Sonic 3 (megadrive) where you had to use those saves in order to finish the game
They shall not be removed, as it's the more convenient way i found for transfering saves from one emulator to another ;) but I don't mind them not being automatically written on the card...
 
Last edited by a moderator:
I personally just save in the game and right after use the save state, which is essentially the same thing.
 
Back
Top