maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Games (https://talk.maemo.org/forumdisplay.php?f=12)
-   -   How To: Nintendo 64 Emu for N900 <Now in Extras-Devel> (https://talk.maemo.org/showthread.php?t=57647)

IzzehO 2010-07-02 15:17

How To: Nintendo 64 Emu for N900 <Now in Extras-Devel>
 
New Update: July 11th Please Read:
The GTK GUI has been recompiled and re-adjusted to run on the N900 by javispedro, and he has kindly added it to the repos. There are several issues with it... however for basic tasks it is stable enough. If you have stability issues with this version, you can still run it from the command line as before... just add a --nogui to the line. It is running the same version I have had posted in this thread as they are both simply ports of the current version being worked on for the Pandora.

Note: This is a development application and neither myself, javis... or the homeless guy on the corner... is responsible if you break your phone. That aside we'll be happy to help if something does happen.

The original intention of this thread was a guide to getting a command line, older, version of the emulator running on the N900... but is now obsolete... so I have reworked it with optimized settings and configuration files to enable faster emulation and better default controls. This should add support for the PS3 controller, as well as rudimentary explanation for getting Accelerometer gameplay (very fun with F-Zero X or Mario Kart 64... and do-able with Super Mario 64 and other RPGs :P)
I did not design any part of this emulator, all development is being done for the Pandora, only thing that has been changed is slight modifications to the GUI along with a recompile to run under Maemo by javispedro. Once again... me nothing... Pandora everything... javispedro recompile with GUI. Do not bother to report bugs here unless you are certain they are Maemo specific... and if you don't bother to read these first 2 pages do not bother to post as I will no longer be answering stupid questions.

If you are updating to this version from my old command line versions, please issue the following in xterminal before installing:
Code:

# This will also remove saves and screenshots, please read below if you want to save them.
rm -R .mupen64plus

To keep save states:
Code:

cp -R .mupen64plus/save .
rm -R .mupen64plus
mv save .mupen64plus/

http://www.youtube.com/watch?v=eEDi0hHKxf8
http://i2.ytimg.com/vi/eEDi0hHKxf8/hqdefault.jpg

On to the optimized settings and configs.
Currently, I've added settings for exiting the emulator with Q, enabled frameskip, disabled framebuffer and increased the resolution (This removes jagged edges and fixes a lot of issues with 2D images). I've also got my own keyboard configuration with keys already mapped for both keyboard and PS3 controller.

To install my config files, you can either install mupen64plus from Extras-Devel before or after these steps... it really shouldn't matter.

Now download the following file from the phone and save to your main directory:
Custom Config

Open up a terminal and issue the following:
Code:

mkdir .mupen64plus                (If you haven't run mupen64plus GUI yet)
cd .mupen64plus
tar zxf /home/user/MyDocs/customconfig.tar.gz

Your done! Start the emulator.

Keyboard map is below:
z = R
x = A
c = B
v = L
Space = Z
Enter = Start
Arrow Keys = Dpad
IJKL = Joystick
TFGH = C buttons
q = Quit the emulator
p = Pause the emulator

Also of note:
Frameskip is set to 2.
Framebuffer is disabled and resolution is 800x480
Memory Pak is enabled
Audio is disabled as it sounds terrible.

__________________________________________________ ___

For PS3 Sixaxis Support
Simply open the Input Settings (After syncing the PS3 controller as per Smoku's instruction) and tap the bar at the top of the screen (It'll say Keyboard or None) until PS3 Controller shows up.

http://i26.tinypic.com/15x89u.jpg

The issue at the moment is this may make ugly things happen as Smoku's application also causes the buttons on the controller to emulator Key Presses, this can be resolved as follows (need rootsh installed):

Code:

root
cd /usr/share/hal/fdi/policy/20thirdparty/
mv 20-x11-sony-sixaxis.fdi 20-x11-sony-sixaxis.fdi.bak

Note that this will stop keyboard buttons working for the PS3 controller, to change it back just do the reverse:

Code:

# To change back to work with other programs
root
cd /usr/share/hal/fdi/policy/20thirdparty/
mv 20-x11-sony-sixaxis.fdi.bak 20-x11-sony-sixaxis.fdi

I'd generally recommend against changing individual buttons in this release as the input plugin detects the first button push when trying... and with the sensitivity of accelerometer, it will detect the "joystick" moving first every time... and you will end up with axis' assigned to buttons: This becomes even more difficult given the way to erase this is to press a button that is not available on the N900 keyboard (delete).

For multiple controller support a very nice guide has been written up here thanks to jschan:
http://talk.maemo.org/showpost.php?p...&postcount=811

Key Map:
Left Joystick = Joystick
Dpad = Dpad
Right Joystick = C Buttons
X = A
[] = B
O = C Down
/\ = C Left
Start = Start
L1 = Z
R1 = R
R2 = L

________________________________________________

To get accelerometer support
Install Accelemymote from extras-devel repository. Once installed, restart the phone. Open Accelemymote from the menu and then start mupen64plus. In the Input Settings configuration you'll need to tap the Keyboard button at the top (it may say None as well.. its at the top, dead-center of the screen) until Accelemymote shows up (See the image above for PS3 instruction..

This now means the joystick input will be accepted from the accelerometer.

I'd generally recommend against changing individual buttons in this release as the input plugin detects the first button push when trying... and with the sensitivity of accelerometer, it will detect the "joystick" moving first every time... and you will end up with axis' assigned to buttons: This becomes even more difficult given the way to erase this is to press a button that is not available on the N900 keyboard (delete).

http://www.youtube.com/watch?v=DKtUY-PPJEs
http://i1.ytimg.com/vi/DKtUY-PPJEs/hqdefault.jpg

TROUBLESHOOT
Quote:

Originally Posted by javispedro (Post 746755)
Small FAQ:
  • It says I have no graphics plugin selected!
    Go to Options -> Configure -> Plugins and select gles2n64 for graphics.
  • It says I have no input plugin selected / I don't know what the mappings are
    Go to Options -> Configure -> Plugins and select blight's SDL for "Input plugin". Then click on Configure.
  • There's no blight's SDL input plugin
    Update mupen64plus.
  • There are no plugins at all to choose from / It says I have no plugins!
    The plugin path has changed. You have to open X-Terminal and type:
    (if you don't have rootsh you can safely ignore this first step)
    Code:

    rootsh chown -R user:users .mupen64plus
    Code:

    cp /usr/share/mupen64plus/config/mupen64plus.conf  ~/.mupen64plus
  • How to quit?
    Ctrl+Backspace should always work (unless you enabled blight's input plugin mouse option). q will also work with custom config
  • libsdl1.2 / libsdl-ttf2.0 dependency missing!
    Refresh application manager and update mupen64plus.

Some additions of my own:
  • I receive XXXX error
    If you recieve unresolvable errors: Read what they tell you and think. If that still doesn't work, uninstall and reinstall with the following commands (rootsh is needed):
    Code:

    root
    dpkg --purge mupen64plus-arm-gui mupen64plus-arm mupen64plus-arm-gles2n64
    apt-get install mupen64plus-arm-gui mupen64plus-arm mupen64plus-arm-gles2n64

  • SIGSEV type error:
    Close the GUI and re-open. If this does not fix it either your ROM is corrupted (grab a new one from elsewhere) or the game simply does not run.

IzzehO 2010-07-02 15:18

Re: How To: Nintendo 64 Emu for N900
 
A few things of note:
  • By default I've disabled audio as it's not only very glitchy, but slows the emulator down immensely. I've also enabled a single frameskip to increase performance. This also increases graphical glitches and even stops some games from started (Dual Heroes for example)
  • The package I've uploaded is a compilation of javispedro's source and binary compiles, so I've simply left source code behind.
  • For any developers interested: Source here: Here Google Code page, with plugin: Here.
  • Javispedro's original source and binaries: http://depot.javispedro.com/nit/64/.
  • For a quick test, Mario Kart 64 and Lylat Wars run full speed.
  • Several games run far better with overclocking (I run mine at 950MHz).
  • See below for the default keymap - I'm open to a different map as I haven't put much testing in to it.
  • Discussion board for the Pandora version, the devs are very nice: http://www.gp32x.com/board/index.php.../page__st__240

Below are instructions editing config files. This is to optimize speed, customize controls and enable audio.

To change key mapping:
Open blight_input.conf in a text editor (I'd suggest leafpad... grab it from Application Manager). Eg.
Code:

leafpad .mupen64plus/blight_input.conf
Here you will see [controller 0] and below it a list of key maps for each N64 button. plugged = 1 enabled the controller. device = -2 is for keyboard. For each button there is a key( 0 ) change 0 to key number. It works with ascii code. Hint: http://www.theasciicode.com.ar/ Ensure to use lower case letters and their respective codes.

Some quickies: Right = 275, Left = 276, Down = 274, Up = 273, Space = 32.

For the joystick key( 1 , 2 ) is either left, right or down, up (Dependant on Y or X axis). If you have issues with doing all this, install Mupen64Plus version 1.5 on Linux and use the GUI there to map the keys.

To change frame skip and resolution.
Edit gles2n64.conf
Code:

leafpad .mupen64plus/gles2n64.conf
To disablele (or increase) frameskip change it as instructed. There are other things to play with in this config, just experiment.




Some games that run full speed, or close to:
Mario Kart 64
Star Fox 64
Super Mario 64
Banjo Kazooie (Once in game, cinematics can be slow)
Chameleon Twist
Duke Nukem 64
F-Zero X (Very fast)
1080 Snowboarding (Runs extremely well as of 6th July)
Harvest Moon 64
Dual Heroes

... Many however will crash on run... or be so far graphically glitchy that it's pointless to play.


CREDITS - These guys are the true legends
Ari64 and Adventus for the OpenGL ES plugin which has made this all possible at a decent speed.
JayFoxRox, Pickle, Exophase and Adventus for the Pandora emulator (Hopefully didn't miss anyone)
Also all those here: http://code.google.com/p/mupen64plus/people/list for their contribution to the original mupen64plus.
javispedro for the compile for N900

ryanl33x1511 2010-07-02 15:20

Re: How To: Nintendo 64 Emu for N900
 
wat is fps ?

weißelstone 2010-07-02 15:24

Re: How To: Nintendo 64 Emu for N900
 
Quote:

Originally Posted by ryanl33x1511 (Post 738677)
wat is fps ?

fps= Frames per second

Reffyyyy 2010-07-02 15:27

Re: How To: Nintendo 64 Emu for N900
 
Also, when editing the controller config, don't forget to put the code of the lower case letters instead of higher case.

IzzehO 2010-07-02 15:30

Re: How To: Nintendo 64 Emu for N900
 
I believe he was asking what sort of fps the games get... as I didn't use the term FPS anywhere in there.

It completely depends on the game and your overclock... but at 800MHz with Lylat Wars I get about 20fps.

Spyder 2010-07-02 15:31

Re: How To: Nintendo 64 Emu for N900
 
When you said it was glitchy, are you running your processor at stock speeds or did you overclock?

This looks awesome!! GoldenEye, anyone?!

IzzehO 2010-07-02 15:34

Re: How To: Nintendo 64 Emu for N900
 
Quote:

Originally Posted by Spyder (Post 738688)
When you said it was glitchy, are you running your processor at stock speeds or did you overclock?

This looks awesome!! GoldenEye, anyone?!

Yeah, afraid Golden Eye runs at about 1 frame a second... it's not one of the easy ones to emulate. I'm running with overclock (as said 4 times already :S), but thats not the issue. The issue is the OpenGL ES plugin is still in early stages (it's made leaps and bounds since this was compiled though) and you get artifacts (rectangular boxes, text not showing up) in some games. Games like Lylat Wars and Mario Kart don't seem to get any issues like this, however.

My most enjoyable moment so far was a 2 player game of Mario Kart output to a TV, I used the keyboard and a friend used the PS3 controller.

Also note there has been more discussion on this in this thread:
http://talk.maemo.org/showthread.php?t=56752&page=5

Reffyyyy 2010-07-02 15:34

Re: How To: Nintendo 64 Emu for N900
 
I run at 805mhz. Goldeneye doesn't run too well for me. It's completely playable in some areas but in others, it becomes completely unplayable.

So far, Mario Kart works the best. F-Zero also works pretty damn well. Super Mario 64 is also completely playable.

Reffyyyy 2010-07-02 15:43

Re: How To: Nintendo 64 Emu for N900
 
http://talk.maemo.org/showpost.php?p...2&postcount=71

This is my Blight_input.conf.

You have to move it using either Xterminal or (my personal preference) Midnight Commander to /home/user/.mupen64plus and overwrite the older one (which I suggest backing up)

I'll write how to do it in more depth if needed.

IzzehO 2010-07-02 16:04

Re: How To: Nintendo 64 Emu for N900
 
Found a way around installing Ren'Py. Updated now. Didn't actually occur to me to check which libsdl component was needed.. just went all in.

Clubberlang 2010-07-02 16:25

Re: How To: Nintendo 64 Emu for N900
 
Ohh can someone put this thing in extras dev and make a front end for noobs like myself?

awesome work and thanks..

Fötus 2010-07-02 16:35

Re: How To: Nintendo 64 Emu for N900
 
1 Attachment(s)
First of all thank you very much for the tutorial, but when I try to start a ROM I get this error. Does someone know what to do, to solve the problem?
Attachment 11698

Reffyyyy 2010-07-02 16:40

Re: How To: Nintendo 64 Emu for N900
 
@Fötus

Maybe the rom is broken? Are you sure that the rom has been extracted from the zip or rar file?

If it's broken, try a different rom.

IzzehO 2010-07-02 16:40

Re: How To: Nintendo 64 Emu for N900
 
You aren't selecting a rom. When running it should be mupen64plus <rom name>

Fötus 2010-07-02 16:52

Re: How To: Nintendo 64 Emu for N900
 
I have tried:
mupen64plus MK64
mupen64plus MK64.n64

but both with the same result.
Do you have any further suggestions?

Fötus 2010-07-02 16:56

Re: How To: Nintendo 64 Emu for N900
 
Sorry, for the last post it is now working :-) Thank you very much.
/home/user/.mupen64plus/mupen64plus /home/user/MyDocs/MK64.n64

Reffyyyy 2010-07-02 17:29

Re: How To: Nintendo 64 Emu for N900
 
The installation is a rather simple process.

First of all you are going to need to grab rootsh from Application Manager. You'll also need wget and libsdl.
Open up a terminal.
Code:
root
apt-get install wget libsdl2.0-0

salawat 2010-07-02 17:37

Re: How To: Nintendo 64 Emu for N900
 
i did everything you said, however when i type mupen64plus <romname> it says its not found, when i do the same as what Fotus did i get the same message, whats the problem?

Jay92 2010-07-02 17:37

Re: How To: Nintendo 64 Emu for N900
 
Once I've typed that into xterminal
I get back

Reading package lists... Done
Building dependency tree
Reading state information... Done
wget is already the newest version
wget set to manually installed
E: Couldn't find package libsdl2.0-0



So what should I do now?

salawat 2010-07-02 17:39

Re: How To: Nintendo 64 Emu for N900
 
i got the same message

Reffyyyy 2010-07-02 17:44

Re: How To: Nintendo 64 Emu for N900
 
@Jay92

The only other way I know of is to install Ren'Py. It can be found in Extras (I don't know if it's in testing or devel. Usual warnings apply)

@salawat
Have you typed cd /home/user/MyDocs first? (Or wherever the file is located)

Fötus 2010-07-02 18:14

Re: How To: Nintendo 64 Emu for N900
 
Mine is working now and also very quick, but my controlls from the PS3 Sixaxis seem to be a bit mixed up.

selct = trigger the extras
[] = jump
O = A / accelerate

But nothing else.

I've checked want characters my PS3 sixaxis sends:
Start = KP_Enter
select = space
L1 = w
R1 = e
L2 = q
R2 = r
X = z
[] = a
/\ = s
O = x

Has someone a suggestion what I could change or what I'm doing wrong?

Jay92 2010-07-02 18:23

Re: How To: Nintendo 64 Emu for N900
 
I have followed all instructions but it still says
Error: Couldn't load Rom!

Fötus 2010-07-02 18:28

Re: How To: Nintendo 64 Emu for N900
 
Now it all works :-) *happy*

@Jay92: try to type in the long path like:
/home/user/.mupen64plus/mupen64plus /home/user/MyDocs/"name of the ROM file"

Reffyyyy 2010-07-02 18:33

Re: How To: Nintendo 64 Emu for N900
 
@Jay92

Try naming the rom to something simple like mk.z64, put it into the root N900 directory.

Then go into Xterminal, type in cd /home/user/MyDocs (capitals included)

Then type mupen64plus mk.z64 (capitals apply)

Also, you can type out part of the filename, press tab and it'll finish off the rest of the filename for you.

salawat 2010-07-02 18:38

Re: How To: Nintendo 64 Emu for N900
 
thanks Reffyyyy now it works!!!

Jay92 2010-07-02 18:38

Re: How To: Nintendo 64 Emu for N900
 
thanks Fötus

javispedro 2010-07-02 18:44

Re: How To: Nintendo 64 Emu for N900
 
Installing DrNokSnes from extras will fetch SDL.

DonPIZI 2010-07-02 18:54

Re: How To: Nintendo 64 Emu for N900
 
does zelda ocarina of time work?
can anyone test it?

Reffyyyy 2010-07-02 18:56

Re: How To: Nintendo 64 Emu for N900
 
@DonPIZI

It works but it's slow and (in my opinion) not very playable.

DonPIZI 2010-07-02 18:59

Re: How To: Nintendo 64 Emu for N900
 
ohh thats bad :( but thanks for the info!

Reffyyyy 2010-07-02 18:59

Re: How To: Nintendo 64 Emu for N900
 
I'm going to try Majora's Mask when my internet decides to stop exploding.

drums4life687 2010-07-02 19:04

Re: How To: Nintendo 64 Emu for N900
 
So I just mailed my N900 out to Nokia yesterday to replaced my cracked LCD and have been eagerly awaiting instructions for this emu. Any chance anyone can upload a video of mario kart to youtube?

Also just curious, of the people successfully running the emulator, what speed is your processor clocked at?

Reffyyyy 2010-07-02 19:10

Re: How To: Nintendo 64 Emu for N900
 
I would upload a video but the only camera device I have is my laptop webcam (which is a massive piece of crap)

Mine is clocked at 805mhz with Titan's power settings. (ULV)

salawat 2010-07-02 19:11

Re: How To: Nintendo 64 Emu for N900
 
how do you change the buttons because in super mario 64 which is in excellent speed i is up, k is down, j is left and l is right

thanks!

Reffyyyy 2010-07-02 19:15

Re: How To: Nintendo 64 Emu for N900
 
Quote:

Originally Posted by salawat (Post 738911)
how do you change the buttons because in super mario 64 which is in excellent speed i is up, k is down, j is left and l is right

thanks!

If you tell me the exact layout you want, I'll do it for you.

Or

You have to navigate to /home/user/.mupen64plus

Find the blight_input.conf and edit each button with a code from here

http://www.asciitable.com/ (Ensure that you only use the lower case ones)

Example


"R Trig-key( 117 )" is u on the keyboard

If you want to change it to be p on the keyboard, change the "117" into "112" as it corresponds with the p on the table above

R Trig-key( 112 )

nax3000 2010-07-02 19:18

Re: How To: Nintendo 64 Emu for N900
 
So is someone willing to make a GUI for this and put the whole thing on extra-devel?
________
Bondage slave

Reffyyyy 2010-07-02 19:40

Re: How To: Nintendo 64 Emu for N900
 
Legend of Zelda: Majora's Mask runs ok. Playable. But when I went into one of the areas, the emulator crashed with "segmentation fault"

salawat 2010-07-02 20:04

Re: How To: Nintendo 64 Emu for N900
 
Quote:

Originally Posted by Reffyyyy (Post 738915)
If you tell me the exact layout you want, I'll do it for you.

Or

You have to navigate to /home/user/.mupen64plus

Find the blight_input.conf and edit each button with a code from here

http://www.asciitable.com/ (Ensure that you only use the lower case ones)

Example


"R Trig-key( 117 )" is u on the keyboard

If you want to change it to be p on the keyboard, change the "117" into "112" as it corresponds with the p on the table above

R Trig-key( 112 )


ermm thanks! btw im uploading a video as i type.

can you change the dpad buttons with the joystick ones plz
A- A button, B- S button, L- z button, R - x button, Z- Q button
and can the C buttons be FTBH and start the same =.

thanks


All times are GMT. The time now is 22:02.

vBulletin® Version 3.8.8