OESF Portables Forum
Everything Else => Zaurus Distro Support and Discussion => Distros, Development, and Model Specific Forums => Archived Forums => Angstrom & OpenZaurus => Topic started by: x86Daddy on December 21, 2004, 03:01:21 pm
-
On the SL-5500, I consider zfceu my favorite NES emulator. However, the zfceu_gui program doesn't work, even with compat libs. After seeing MrSquishy's Post (https://www.oesf.org/forums/index.php?showtopic=9438) on how he made a front-end for snes9x, I modded his script to work with zfceu as follows:
#!/bin/sh
#Path to your Roms
LOCATION=/root/Documents/roms
#Load a game from your list
ROM=` cd $LOCATION; ls -1 *.nes \
| opie-sh -i -l -t "Roms" -F -g `
if [ "$ROM" = "" ]
then exit
fi
#Enable Sound Button
setsound () {
opie-sh -m -t "Sound" \
-M "Do you want sound?" \
-g -0 Yes -1 No
RETURNCODE=$?
#Hitting "OK" returns 255, so if you press "OK" you get sound.
case $RETURNCODE in
255) SOUND=11000;;
0) SOUND=11000;;
1) SOUND=0;;
esac
}
setsound
if [ "$SOUND" = "" ]; then
exit
fi
zfceu -frameskip 40 -sound $SOUND $LOCATION/$ROM
And a corresponding .desktop file to launch it:
[Desktop Entry]
Comment=ZFCEU Game Selector
Exec=ZFCEU.sh
Icon=package_games
Type=Application
Name=ZFCEU
I have this working quite nicely on my SL-5500 using OZ 3.5.2. I still don't like the zfceu keymapping... everytime I slip when pressing the up key and hit Home... game over man; game over. Other than that, though, I'm pleased with the results.
-
Thats pretty cool. Where do I put the script to make it work?
-
Somewhere in your path.
I dump mine in /mnt/card/opt/QtPalmtop/bin and symlink them for the sake of consistency.
Anywhere should be fine though.
-
Thanks for that script by the way. I had considered just making .desktop files for all of my roms with sound and frameskip options, but this should work better.
I put it in /mnt/card/opt/QtPalmtop/bin and symlinked it to /opt/QtPalmtop/bin put the .desktop file in /mnt/card/opt/QtPalmtop/apps/games and smylinked that to /opt/QtPalmtop/apps/games but when I tap on the icon I get a "could not locate application ZFCEU.sh error"
AFAICT I've done everything right, but it still does not work. Did I miss something obvious?
-
Got it to work, I had to change permissions from my windows user where I synced the file from to root on my z. It worked but pressing yes for sound resulted in no sound. Also 11000 for sound produced very slow sound. I made a few changes to the script and It works like a champ.
#!/bin/sh
#Path to your Roms
LOCATION=/mnt/card/games/nes/
#Load a game from your list
ROM=` cd $LOCATION; ls -1 *.nes \
| opie-sh -i -l -t "Roms" -F -g `
if [ "$ROM" = "" ]
then exit
fi
#Enable Sound Button
setsound () {
opie-sh -m -t "Sound" \
-M "Do you want sound?" \
-g -0 Yes -1 No
RETURNCODE=$?
#Hitting "OK" returns 255, so if you press "OK" you get sound.
case $RETURNCODE in
255) SOUND=22050;;
1) SOUND=22050;;
0) SOUND=0;;
esac
}
setsound
if [ "$SOUND" = "" ]; then
exit
fi
zfceu -frameskip 40 -sound $SOUND $LOCATION/$ROM
Changed sound from 11000 to 22050 and the returncode 0 to 1 and 1 to 0.
-
Sweet, NES on the Z
I had to change zfceu to run with the compat libs on OZ 3.5.2, just change the last line of the script to:
runcompat zfceu -frameskip 40 -sound $SOUND $LOCATION/$ROM
One question, though. My screen (SL-5500) seems to be just a few pixels too low. The last few lines get cut off the bottom. Is there a way to tell zfceu to push it up a line or 3? Other than that, though, the demo roms I tried seem to work great, and the little opie-sh script is just the example I've been looking for to do some other things! Thanks guys!!
-Matt
-
You can run
makecompat /opt/QtPalmtop/bin/zfceu
on the command line to tell it to always run zfceu with the compat libs.
This is my opie-sh-nes.sh script
#!/bin/sh
#Path to your Roms
LOCATION=/mnt/card/games/nes
#Load a game from your list
ROM=` cd $LOCATION; ls -1 *.zip \
| opie-sh -i -l -t "Roms" -F -g `
if [ "$ROM" = "" ]; then exit; fi
zfceu -subase 1 -frameskip 30 -sound 11025 $LOCATION/$ROM
the -subase 1 makes it so that your savegames get put into /root/.zfceu/sav which I have symlinked to /mnt/card/games/nes/saves.
I just like to keep my roms tidy.
I also dont have the sound button because I found that it runs about the same with or without sound, where as Snes9x (which this script it modified from) gets a noticable boost if you turn off the sound.
I've been trying to track down the zfceu source, as I'd like to try recompiling it for 3.5.2.
Ideally, I'd like to have River City Ransom work.
I was going to make a Landscape/Portrait option, but znester doesnt run on 3.5.2 even with compat libs.
-
Do you have the same problem with the screen being positioned too low? On mine, the last few pixels (5 or 10 maybe, hard to tell) are off the bottom of the screen.
-
Do you have the same problem with the screen being positioned too low?
No problem with that. It the screen always off or just with zfceu?
-
Would one of you please post a link to or attach the zfceu binary or ipk that your using for this... all the links I have found are dead today.
Thanks
Greg
-
I think this is the one Im using.
-
Thanks MrSquishy, I will give your opie-sh-nes script a try tomorrow.
Greg