2010-05-07, 07:13
Cowriter: TheDuffMan
Might as well be Cowriter: phearless-d
Some great work from various users on the board made this possible. I ran into a ton of issues when trying to set my Acer 1600 up with EMUs in a Live enviornment so I thought I would compile everything into a Acer specfic thread. This should work for most Live installs, but there were certain issues on the Revo that Duffman and I solved. I'm going to cover SNES, NES / GBA / GB, and Genesis / Sega CD. This should be enough to get any Linux emu running though. There are other emulators than the ones I used, but I found them all to be problematic with in the Live/Acer enviornment (Kega, FCEU, etc.). The writers are seeing NO slow down in boot times, or any problems within XBMC using this method.
BIG thanks to phearless-d, Zosky, Leo2, fuz1on, grassmunk and TheDuffman. Also to http://lifehacker.com/5523672/turn-your-...me-console that gave Duff and I the initial inspiration to being on the quest for an Acer Revo XBMC EMU enabled box.
The big starting point for me was this thread:
http://forum.xbmc.org/showthread.php?p=5...post533162
I'll be repeating some of the information there.
ZSNES:
All below is paraphrased from phearless:
Follow the first post in the thread above to the letter.
Terminal: sudo apt-get update then sudo apt-get install zsnes.
Install Launcher to XBMC if you haven't already:
Download Launcher from http://code.google.com/p/xbmc-launcher/downloads/list
---> Addendum: JustSomeUser has a patch for Launcher, DuffMan and I are using it - http://forum.xbmc.org/showpost.php?p=464...tcount=582 - highly recommended.
unzip and sftp it over to /home/xbmc/.xbmc/plugins/programs
Create a directory tree /.xbmc/userdate/plugin_data/Launcher if it does not exsists, and a create/edit a launchers.xml file to phearless's directions.
Edit the Launcher script according to phearless.
End paraphrase.
Now as an Acer user you'll have ZSNES running, but without sound.
Here's how to fix that (credit TheDuffMan):
.asoundrc has only the following line, nothing else:
XBMC Audio settings:
Audio Output Device: DEFAULT
Passthrough Output Device: CUSTOM
Custom Passthrough Device: plughw:0,3
--> A note on hardware devices for non revo users when setting up plughw. If you're trying this guide on something other than a Revo, your HDMI audio device may be different. Run "aplay -l" in the terminal and check the HDMI results for card X, device Y, and fill in plughw:X,Y accordingly.
With that we solved a whole world of issues, and we don't lose any sound options in XBMC (even menu nav sounds).
Suggested args for ZSNES:
Complete args here: http://zsnes-docs.sourceforge.net/html/advanced.htm
I personally use -v 22, which is the custom resolution. By editting /.zsnes/zsnesl.cfg:
This gave me the proper aspect ratio etc. You may have to play with that for your TV, but that should work fine for most 1080p TVs.
On a 720p TV try:
As suggested by grassmunk. This may or may not work for you - and may cut off some pixels. This is going to be a bit of trial and error if you want the perfect resolution.
When you need to exit a game on ZSNES and return to XBMC hit ESC.
Genesis / Sega CD:
Gens is fairly simple once you've setup ZSNES and followed the phearless instructions.
Open up terminal or Putty in:
You may need to add the -f argument to the above to get additonal packages that are needed for Gens to run/install properly.
sudo apt-get install -f gens
Terminal will tell you if this is needed.
Edit launchers.xml and add:
Launch it and see if it is working. It probably is but not in true fullscreen and possibly without audio. To fix that hit ALT+ENTER while a ROM is running, and click through the menus in Gens to change your backend to OpenGL+SDL. While you are here you can also set a custom fullscreen resolution through the menu that best fits your TV. This can all be done by editting the .cfg file in your /.gens folder as well. When done hit ALT+ENTER again to get back to full screen. When you need to exit a game and return to XBMC hit CTRL+Q. DuffMan added --quickexit so Gens would have the same functionality as other EMUs and exit upon hitting ESC. I required no args but I did make some personal changes to the cfg file based on preferences. Complete args available are here:
http://ubuntuforums.org/showthread.php?t=447293
*If someone has a better list of gens args please let me know.*
NES / GBA / GB:
Mednafen's setup follows the same route as the Genesis set up.
Terminal:
Add this to launchers.xml (for NES)
-nes.xres and -nes.yres are optional, they are what fits my TV. The other args are not optional.
Complete mednafen args here:
http://mednafen.sourceforge.net/documentation/
GAMEPAD SETUP!
This one gave me some headaches, but in the end, it's actually VERY simple. If you are using a HID USB gamepad, this is going to be a cinch, otherwise you are in for some trouble that I cannot cover here... It would be it's own thread most likely. MOST gamepads in from the past 5 years or so are HID. Xbox gamepad setup is a little different, but if you have it working in general it should be the same (NOTE: As grassmunk pointed out some of the buttons on X360 controllers are considered sliders, this is true of some Logitech controllers as well, in that case you're going to need to use sudo apt-get install joystick, then run jscal -c /dev/input/js0 to set them up again that is an incomplete tutorial but there are plenty on the web for that). After you read this you'll wonder why it took me so long to figure out, but honestly there is little to no documentation for this and a lot of conflicting data out there.
ZSNES: Remove -m from your arguments in launchers.xml, this way you can get to the gui (with esc). From the gui enter the control setup.
Gens: ALT+ENTER to get to the gui, set up through gui.
Mednafen: ALT+SHIFT+x (which x is the number controller you want to set up, ALT+SHIFT+1 sets up controller 1) and follow on screen instructions.
Other possibilities: You can use a program like joy2keys to mimic specific keystrokes, including ESC and CTRL+Q to have remote exit. This is a bit messy so I opted for a $15 wireless keyboard (logitech "Wii" keyboard).
Common Issues:
I cannot import ROMs when scanning for them through XBMC!
Solution: sudo nano on launchers.xml may have jacked up your permissions, depending on how you editted the file:
NOTE: Make sure you properly set the permissions for this file so XBMC can write to it - if you created with sudo nano it may be set to root/root. Here's how to fix it from Terminal:
I've still got sound issues!
You may be using a different sound driver package. This setup works for me with sudo apt-get install libsdl1.2-alsa. This seems to vary from user to user, some do better with -all some with -sdl some with -esd. I can tell you -alsa works perfectly for me on the Acer Revo 1600.
I need to see error logs!
My setup: Acer Revo 1600, 2GB ram, HDMI out to Sony Receiver, video passthrough to LG 1080p TV. Logitech Wireless Rumble 2. "Wii" Logitech Wireless keyboard (for remote exit of games and Terminal commands).
Again a BIG credit to everyone who worked hard on compiling this data, especially phearless and Duffman.
The final product in Alaska:
Screen caps provided by TheDuffMan.
For approval for How-Tos.
Might as well be Cowriter: phearless-d
Some great work from various users on the board made this possible. I ran into a ton of issues when trying to set my Acer 1600 up with EMUs in a Live enviornment so I thought I would compile everything into a Acer specfic thread. This should work for most Live installs, but there were certain issues on the Revo that Duffman and I solved. I'm going to cover SNES, NES / GBA / GB, and Genesis / Sega CD. This should be enough to get any Linux emu running though. There are other emulators than the ones I used, but I found them all to be problematic with in the Live/Acer enviornment (Kega, FCEU, etc.). The writers are seeing NO slow down in boot times, or any problems within XBMC using this method.
BIG thanks to phearless-d, Zosky, Leo2, fuz1on, grassmunk and TheDuffman. Also to http://lifehacker.com/5523672/turn-your-...me-console that gave Duff and I the initial inspiration to being on the quest for an Acer Revo XBMC EMU enabled box.
The big starting point for me was this thread:
http://forum.xbmc.org/showthread.php?p=5...post533162
I'll be repeating some of the information there.
ZSNES:
All below is paraphrased from phearless:
Follow the first post in the thread above to the letter.
Terminal: sudo apt-get update then sudo apt-get install zsnes.
Install Launcher to XBMC if you haven't already:
Download Launcher from http://code.google.com/p/xbmc-launcher/downloads/list
---> Addendum: JustSomeUser has a patch for Launcher, DuffMan and I are using it - http://forum.xbmc.org/showpost.php?p=464...tcount=582 - highly recommended.
unzip and sftp it over to /home/xbmc/.xbmc/plugins/programs
Create a directory tree /.xbmc/userdate/plugin_data/Launcher if it does not exsists, and a create/edit a launchers.xml file to phearless's directions.
Edit the Launcher script according to phearless.
End paraphrase.
Now as an Acer user you'll have ZSNES running, but without sound.
Here's how to fix that (credit TheDuffMan):
.asoundrc has only the following line, nothing else:
Code:
defaults.pcm.device 3
XBMC Audio settings:
Audio Output Device: DEFAULT
Passthrough Output Device: CUSTOM
Custom Passthrough Device: plughw:0,3
--> A note on hardware devices for non revo users when setting up plughw. If you're trying this guide on something other than a Revo, your HDMI audio device may be different. Run "aplay -l" in the terminal and check the HDMI results for card X, device Y, and fill in plughw:X,Y accordingly.
With that we solved a whole world of issues, and we don't lose any sound options in XBMC (even menu nav sounds).
Suggested args for ZSNES:
Code:
<args>-m -s -v 18 -ad sdl -r 6</args>
Complete args here: http://zsnes-docs.sourceforge.net/html/advanced.htm
I personally use -v 22, which is the custom resolution. By editting /.zsnes/zsnesl.cfg:
Code:
; Custom Resolution X and Y for Custom Video Modes [256x224..2048x1536]
CustomResX=1440
CustomResY=1080
On a 720p TV try:
Code:
; Custom Resolution X and Y for Custom Video Modes [256x224..2048x1536]
CustomResX=1360
CustomResY=768
When you need to exit a game on ZSNES and return to XBMC hit ESC.
Genesis / Sega CD:
Gens is fairly simple once you've setup ZSNES and followed the phearless instructions.
Open up terminal or Putty in:
Code:
sudo apt-get install gens
You may need to add the -f argument to the above to get additonal packages that are needed for Gens to run/install properly.
sudo apt-get install -f gens
Terminal will tell you if this is needed.
Edit launchers.xml and add:
Code:
<launcher>
<name>SEGA Genesis</name>
<application>/usr/bin/gens</application>
<args>--quickexit</args>
<rompath>/home/xbmc/ROMS/GENESIS/</rompath>
***YOUR PATH TO YOUR ROMS***
<romext>gen|zip|GEN|ZIP|Zip|Gen</romext>
<thumb></thumb>
<wait>true</wait>
</launcher>
Launch it and see if it is working. It probably is but not in true fullscreen and possibly without audio. To fix that hit ALT+ENTER while a ROM is running, and click through the menus in Gens to change your backend to OpenGL+SDL. While you are here you can also set a custom fullscreen resolution through the menu that best fits your TV. This can all be done by editting the .cfg file in your /.gens folder as well. When done hit ALT+ENTER again to get back to full screen. When you need to exit a game and return to XBMC hit CTRL+Q. DuffMan added --quickexit so Gens would have the same functionality as other EMUs and exit upon hitting ESC. I required no args but I did make some personal changes to the cfg file based on preferences. Complete args available are here:
http://ubuntuforums.org/showthread.php?t=447293
*If someone has a better list of gens args please let me know.*
NES / GBA / GB:
Mednafen's setup follows the same route as the Genesis set up.
Terminal:
Code:
sudo apt-get install mednafen
Add this to launchers.xml (for NES)
Code:
<launcher>
<name>NES</name>
<application>/usr/games/mednafen</application>
<args>-nes.xres 960 -nes.yres 700 -fs 1 -sounddriver sdl</args>
<rompath>/home/xbmc/ROMS/NES/</rompath>
<romext>nes|zip|ZIP|NES|Nes|Zip</romext>
<thumb></thumb>
<wait>true</wait>
</launcher>
-nes.xres and -nes.yres are optional, they are what fits my TV. The other args are not optional.
Complete mednafen args here:
http://mednafen.sourceforge.net/documentation/
GAMEPAD SETUP!
This one gave me some headaches, but in the end, it's actually VERY simple. If you are using a HID USB gamepad, this is going to be a cinch, otherwise you are in for some trouble that I cannot cover here... It would be it's own thread most likely. MOST gamepads in from the past 5 years or so are HID. Xbox gamepad setup is a little different, but if you have it working in general it should be the same (NOTE: As grassmunk pointed out some of the buttons on X360 controllers are considered sliders, this is true of some Logitech controllers as well, in that case you're going to need to use sudo apt-get install joystick, then run jscal -c /dev/input/js0 to set them up again that is an incomplete tutorial but there are plenty on the web for that). After you read this you'll wonder why it took me so long to figure out, but honestly there is little to no documentation for this and a lot of conflicting data out there.
ZSNES: Remove -m from your arguments in launchers.xml, this way you can get to the gui (with esc). From the gui enter the control setup.
Gens: ALT+ENTER to get to the gui, set up through gui.
Mednafen: ALT+SHIFT+x (which x is the number controller you want to set up, ALT+SHIFT+1 sets up controller 1) and follow on screen instructions.
Other possibilities: You can use a program like joy2keys to mimic specific keystrokes, including ESC and CTRL+Q to have remote exit. This is a bit messy so I opted for a $15 wireless keyboard (logitech "Wii" keyboard).
Common Issues:
I cannot import ROMs when scanning for them through XBMC!
Solution: sudo nano on launchers.xml may have jacked up your permissions, depending on how you editted the file:
NOTE: Make sure you properly set the permissions for this file so XBMC can write to it - if you created with sudo nano it may be set to root/root. Here's how to fix it from Terminal:
Code:
cd /home/xbmc/.xbmc/userdata/plugin_data/programs/Launcher/
write ls -l in the command line.
It should spit out something like this:
-rw-r--r-- 1 root root 570 2010-04-25 17:12 launchers.xml
See the "root root" there, well if that's the case XBMC cannot write to the file because it's owned by root and the group root.
sudo chown xbmc:xbmc luanchers.xml
sudo chmod 666 launchers.xml (optional)
Make sure it's correct:
ls -l
-rw-r--r-- 1 xbmc xbmc 570 2010-04-25 17:12 launchers.xml
I've still got sound issues!
You may be using a different sound driver package. This setup works for me with sudo apt-get install libsdl1.2-alsa. This seems to vary from user to user, some do better with -all some with -sdl some with -esd. I can tell you -alsa works perfectly for me on the Acer Revo 1600.
I need to see error logs!
grassmunk Wrote:To trouble shoot the other issues:
1) I created a script /home/xbmc/launcher.sh
Code:echo "Launching... " > log.txt
echo $@ >> log.txt
echo "Program Log" >> log.txt
$@ >> log.txt
and made it executable (chmod +x /home/xbmc/launcher.sh)
2) I changed the launcher line to /home/xbmc/launcher.sh and the args line to /usr/bin/zsnes -m -v 20 -s
3) When I ran the script it would exit but only because of spaces when running games with no spaces in the name it would load (this is because of the script, not because of launcher just be aware). Now I was finally able to see zsnes logs and errors
My setup: Acer Revo 1600, 2GB ram, HDMI out to Sony Receiver, video passthrough to LG 1080p TV. Logitech Wireless Rumble 2. "Wii" Logitech Wireless keyboard (for remote exit of games and Terminal commands).
Again a BIG credit to everyone who worked hard on compiling this data, especially phearless and Duffman.
The final product in Alaska:
Screen caps provided by TheDuffMan.
For approval for How-Tos.