Showing posts with label emulator. Show all posts
Showing posts with label emulator. Show all posts

Saturday, June 23, 2007

gpsp & VisualBoyAdvanced

I found a list of emulators in a post on OESF. I started with gpsp the same way as I did with snes9x, put the bios in the rom's directory, started gpsp - I got the menu, I could use the arrow keys, but couldn't use return (or ok or whatever starts a rom). Cancel did not exit the program, the only way to stop it is killall gpsp via ssh. I also tried to start a rom from command line, but then I got a nonreponsive black screen. Now I had to kill opie inorder to stop gpsp.

Then I tried VisualBoyAdvanced (VBA). Installed it (with -force-depends), I used a similar script to the one I used with snes9x...
and voilla, vba runs, a bit slow, no sound (If I enabled sound it came out statering) - but playable.
I needed to tweak a little bit with ~/VisualBoyAdvance.conf. I switched the arrow keys directions, return did not work so I changed select to Q. I tried playing with the various switches to improve performance but I had no luck there.

Friday, June 22, 2007

snes9x

I found this old ipk on my zaurus, snes9x-sdl-qpe_1.39-r1_arm tried to install it, and it complained for missing libsdl, which was already installed by libsdl-1.2, so I forced demands, and installed:

# ipkg install -d loop0 snes9x-sdl-qpe_1.39-r1_arm.ipk -force-depends
# ipkg-link add snes9x-sdl-qpe
when I tried to run it, I got a black window with sound (which was encouraging). I found this website and used the following switches, no snes9x started but it was rather slow (because of the resize):
# snes9x -hi -x2 -xs 640 -ys 480
The -x2 switch causes snes9x to double the picture so it fits the screen nicely, removing it greatly improves performance (but results in a small window). Another possibility is to use qcop commands to change resolution to 320x200 (like I did for mplayer). Now horizontal lines appeard and the picture was upside down. To solve this I added "SDL_QT_INVERT_ROTATION=0" before running snes9x. Now picture is nice, performance seems reasonable, but, the arrow keys are messed up. I couldn't fix the arrow-keys, but I found a way to redefine the controls, so I used g, l, i & m instead. To set the keys a S9XKEYS variable need to be defined (before starting snes9x):
# export S9XKEYS=27,100,99,115,120,97,122,113,32,103,108,105,109,121,98,112,13
Which translate to:
  • Quit = Cancel
  • D = Button A
  • X = Button B
  • S = Button X
  • X = Button Y
  • A = Button L
  • Z = Button R
  • Q = Start
  • Space = Select
  • The directions are:
Y
IP
G
L
B
MCR

The definition of S9XKEYS is explained here:
S9XKEYS=Quit, A, B, X, Y, L, R, START, SELECT, LEFT, RIGHT, UP, DOWN, LEFTUP, LEFTDOWN, RIGHTUP, RIGHTDOWN
The key codes maybe found in this post or here. Maybe I'll manage to fool SDL with redefining the arrow-keys with opie-keyz.

I use this script to run snes9x and set everything to my taste (almost). I also found these additional switches:
-nso = no sound
-dfr = show frame rate.