You are not logged in.

#1 2009-11-07 14:49:58

BeholdMyGlory
Member
Registered: 2008-08-30
Posts: 93

Mupen64Plus 2.0 hg in AUR; HOW TO install & configure controllers

With version 2.0 Mupen64Plus has undergone large changes "under the hood". Mupen64Plus is now modular, and as such the standard plugins has been split into several different packages/repositories. At the moment there exists the following modules:

* mupen64plus-core
      Core module of the Mupen64Plus project
* mupen64plus-ui-console
      Console (command-line) front-end user interface for Mupen64Plus v2.0 project
* mupen64plus-audio-sdl
      Audio plugin for the Mupen64Plus v2.0 project, using SDL. This plugin is based on the original jttl_audio plugin in Mupen64.
* mupen64plus-input-sdl
      Input plugin for Mupen64Plus v2.0 project using SDL. This is derived from the original Mupen64 blight_input plugin.
* mupen64plus-rsp-hle
      RSP processor plugin for the Mupen64Plus v2.0 project. This plugin is based on the Mupen64 HLE RSP plugin v0.2 with Azimers code by Hacktarux
* mupen64plus-video-rice
      Video plugin for the Mupen64Plus v2.0 project, using OpenGL. This plugin is based on the RiceVideoLinux plugin from earlier versions of Mupen64Plus.

Note however, that mupen64plus-core (or mupen64plus-core-hg on AUR) is just the core, and does not include a frontend. The Qt and GTK frontends have been scrapped, though, and the only existing frontend so far is mupen64plus-ui-console, which is a CLI frontend. You launch a game with mupen64plus-cli, see mupen64plus-cli --help for more information. As a sidenote, I believe that the Mupen64Plus team would appreciate if someone helped with creating a GTK frontend, since I believe the head developer(s) will probably be focusing on the Qt frontend if any.

The Rice Video plugin in Mupen64Plus 2.0 fixes a problem that at least I and another person had with xf86-video-ati and the old Rice, which made us unable to play in fullscreen.

Installing

To get Mupen64Plus 2.0 working, you will need to install all six modules. They are all part of the mupen64plus-hg group, but unfortunately neither yaourt nor the AUR web interface supports groups as far as I know, so you will have to install each module separately. With yaourt:

yaourt -S mupen64plus-core-hg mupen64plus-ui-console-hg mupen64plus-audio-sdl-hg mupen64plus-input-sdl-hg mupen64plus-rsp-hle-hg mupen64plus-video-rice-hg

The only way I can think of to make it easier to install, would be if I created an empty PKGBUILD that simply depended on all the modules, but I find this to not be a technically elegant solution.

Configuring controllers

With Mupen64Plus 2.0, a feature has been added to auto-detect and auto-configure USB controllers, but at the time of writing only a handful of controllers are supported:
* Logitech Dual Action gamepad
* Logitech Cordless Rumblepad 2
* Microsoft X-Box 360 pad
* N64 controller
* SAITEK P880
* Mega World USB Game Controllers

You know your controller isn't supported if you get the following messages when running mupen64plus-cli:

Input: N64 Controller #1: Disabled, no configuration data for 'YOUR CONTROLLER NAME HERE'
Input Warning: No SDL joysticks found
Input: Mupen64Plus SDL Input Plugin version 2.0.0 initialized.

If it is supported, you will get something like:

Input: N64 Controller #1: Enabled, using auto-configuration for joystick 'YOUR CONTROLLER NAME HERE'
Input: 1 SDL joysticks found, 1 plugged in and usable in the emulator
Input: Mupen64Plus SDL Input Plugin version 2.0.0 initialized.

Now, if your controller isn't supported, there are two things you can do, and I strongly recommend that you do the first, but you will probably want to do both unless you're patient (if your controller works, but you want to configure it, skip to step two):

Step 1:
Follow the intructions on http://www.emutalk.net/showthread.php?t=49731. If you have the old config file, but no longer have Mupen64Plus 1.5 installed and therefore cannot follow step 8 in the post, the controller name shown in

Input: N64 Controller #1: Disabled, no configuration data for 'YOUR CONTROLLER NAME HERE'

will work too. This will allow the Mupen64Plus team to include your controller for auto-detection.

Step 2:
Now you will probably want to configure the controller, especially if it wasn't supported already. You will need to edit the config file ~/.config/mupen64plus/mupen64plus.cfg, since no GUI frontend exists yet. Since revision 55 of mupen64plus-core, Mupen64Plus will create the config file if none exists when launching a game (previously you had to run mupen64plus-cli with the flag --saveoptions to create the config file). Mupen64Plus does not need a config file to run, but if you wish to tweak the settings you will need it.

Now, the section you will be interested in is [Input-SDL-Control1] (and possibly the other controller sections). If your controller is supported already, you will see some default settings and it will be quite easy to edit them. Otherwise the sections will be completely empty. Here follows my [Input-SDL-Control1], which you can copy and change to fit your needs. If you have your blight_input.conf you can use it as a reference to make it easier. For a list of options, see http://www.emuwiki.com/index.php?title= … #Input-SDL.

[Input-SDL-Control1]

# Specifies whether this controller is 'plugged in' to the simulated N64
plugged = True
# Specifies which type of expansion pak is in the controller: 1=None, 2=Mem pak, 5=Rumble pak
plugin = 1
# If True, then mouse buttons may be used with this controller
mouse = False
# Specifies which joystick is bound to this controller: -1=None, 0 or more= SDL Joystick number
device = 0
# The minimum absolute value of the SDL analog joystick axis to move the N64 controller axis value from 0.  For X, Y axes.
AnalogDeadzone = "4096,4096"
# An absolute value of the SDL joystick axis >= AnalogPeak will saturate the N64 controller axis value (at 80).  For X, Y axes. For each axis, this must be greater than the corresponding AnalogDeadzone value
AnalogPeak = "32768,32768"
# Digital button configuration mappings
DPad R = "hat(0 Right ) "
DPad L = "hat(0 Left ) "
DPad D = "hat(0 Down ) "
DPad U = "hat(0 Up ) "
Start = "button(9) "
Z Trig = "button(7) "
B Button = "button(0) "
A Button = "button(2) "
C Button R = "axis(3+) "
C Button L = "axis(3-) "
C Button D = "axis(2+) "
C Button U = "axis(2-) "
R Trig = "button(6) "
L Trig = "button(4) "
Mempak switch = ""
Rumblepak switch = ""
# Analog axis configuration mappings
X Axis = "axis(0-,0+) "
Y Axis = "axis(1-,1+) "

Note:
At the time of writing there is a bug in the parser which requires the extra space after the direction in the hat event, for example "hat(0 Up )". Otherwise it will read the direction as (in this case) "Up)" which is invalid and will be ignored. The trailing space after the ending parantheses is not required, and is merely a side effect of how the program that generates the config file works.

Note that you can combine options:

A Button = "button(2) key(38) mouse(1)"

This will map both button 2 on the controller, key 38 on the keyboard and the left mouse button to the A button in Mupen64Plus.

If anyone encounters any other problems, feel free to ask.

Offline

#2 2009-11-07 15:42:22

Dheart
Member
From: Sofia, Bulgaria
Registered: 2006-10-26
Posts: 956

Re: Mupen64Plus 2.0 hg in AUR; HOW TO install & configure controllers

...
Someone should add this to "READ BEFORE POSTING"
This is not Ubuntu forum. You shouldn't EVER post such howto on the forum, we have a wiki for that reason. That thing you've written should go the wiki and then post a topic at wiki discussions and ask for opinion.
Please, don't do that again, just contribute to the wiki.


My victim you are meant to be
No, you cannot hide nor flee
You know what I'm looking for
Pleasure your torture, I will endure...

Offline

#3 2009-11-07 16:48:16

BeholdMyGlory
Member
Registered: 2008-08-30
Posts: 93

Re: Mupen64Plus 2.0 hg in AUR; HOW TO install & configure controllers

Dheart wrote:

...
Someone should add this to "READ BEFORE POSTING"
This is not Ubuntu forum. You shouldn't EVER post such howto on the forum, we have a wiki for that reason. That thing you've written should go the wiki and then post a topic at wiki discussions and ask for opinion.
Please, don't do that again, just contribute to the wiki.

Yes, I'm quite aware that the wiki exists. The reason I'm writing it here is that the GUI frontends will probably come quite soon, and overall this is an early version. I don't see a reason to contribute this to the wiki when it will probably be unneeded and out-of-date relatively soon.

Offline

#4 2009-11-07 17:41:13

Themaister
Member
From: Trondheim, Norway
Registered: 2008-07-21
Posts: 652
Website

Re: Mupen64Plus 2.0 hg in AUR; HOW TO install & configure controllers

Still, it's better having something unfinished in the wiki, rather than nothing, am I right? smile

Offline

#5 2009-11-07 19:28:45

uncholowapo
Member
From: US
Registered: 2009-03-29
Posts: 238

Re: Mupen64Plus 2.0 hg in AUR; HOW TO install & configure controllers

To solve the "lets make it easier" problem, you could make a group for the mupen64plus packages.

EDIT: Oh and is there anyway to change the CFLAGS other than the default that come with the mupen Makefiles? Seeing -mtune=pentium-m running on my Dual Core Pentium (based on Core2Duo) makes me queasy.:P

Last edited by uncholowapo (2009-11-07 19:38:28)

Offline

#6 2011-05-06 17:16:46

inukaze
Banned
From: Venezuela
Registered: 2011-05-06
Posts: 16
Website

Re: Mupen64Plus 2.0 hg in AUR; HOW TO install & configure controllers

i Think its better , make a Full GUI , like the Mupen64Plus 1.5 ( GTK / QT ) Or Like Project64 GUI , for more Ease Config the emulator.

Offline

#7 2011-07-30 16:28:56

djipey
Member
Registered: 2011-07-30
Posts: 156

Re: Mupen64Plus 2.0 hg in AUR; HOW TO install & configure controllers

Hello. (I'm french so could you forgive my bad english?)

I'm tring to make mupen run, and i did. But now i would like to re-map the keys of my joystick.

So i tried to edit ~/.config/mupen64plus/mupen64plus.cfg, especially this line:

Z Trig = "button(3)"

I changed it to Z Trig = "button(5)", but when i launch the game, mupen re-write the file and put the line back to Z Trig = "button(3)".

How can i fix that? Do you have an idea? I'm here to explain again if you didn't understand what i said.

Thanks a lot.

Offline

Board footer

Powered by FluxBB