Homepage › Forums › RetroPie Project › Controller Configuration in RetroPie › Configure Ultimarc UTrak and SpinTrak advMame
- This topic has 19 replies, 4 voices, and was last updated 8 years, 8 months ago by brettwgreen.
-
AuthorPosts
-
02/19/2016 at 03:22 #117509bobtParticipant
This is my first go at trying to create a retro-gaming system and I’m running into a few problems. I created a control panel with button, joystick, trackball and spinner all connected through the miniPAC. The joystick and buttons work as expected. The issue that I’m having is trying to configure the trackball and spinner in either the AdvanceMame or Mame4all. I’ve read that the spinner and trackball don’t work with Mame4all so I placed ROMS that require these controls in advancemame.
What I’ve done so far:
1. I connected the miniPAC to the laptop to verify the trackball and spinner are working – This worked as expected.
2. ls /dev/inputs revealed mice, mouse0, and mouse1
a) mouse0 is connected to the bluetooth keyboard
b) mouse1 is connected to both the trackball and spinner
3. I updated the advmame-0.94.0.rc and advmame-1.2.rc in the /opt/retropie/configs/mame-advmame folder to include the following lines
a) device_mouse raw
b) device_raw-mousedev[0] /dev/input/mouse1
4. Started a game and pressed tab to configure for this game
a) selected dial analog (initially set to <None>. Pressed enter and moved the spinner. Nothing happens.
b) started a game (tempest). It looks like the spinner is detected but only moves in one direction.
c) other games it appears that the spinner or trackball are not working.Am I missing something in the configuration files
02/19/2016 at 17:05 #117534nosedeathParticipantWelcome to hell. I have the exact same set up and I’m having the exact same problem. Only I’ve been looking for WEEKS for an answer!!
02/22/2016 at 03:39 #117755bobtParticipantI finally got the trackball and spinner to work.
I finally got the trackball and spinner to work with advmame
the first thing you need to do is figure out which mouse is providing the inputs
type ls /dev/input – I had mouse0 and mouse1determine which mouse is providing input for the trackball and spinner – it will be the same.
type cat /dev/input/mouse0
move the trackball or spinner. If text is showing on the screen then you will use mouse0 in your configuration. If no text then substitute mouse0 with mouse1.The roms that I had loaded were for advmame-0.94.0. edit the advmame-0.94.0.rc configuration file
cd .advanceI used the advmame-0.94.0 roms
edit advmam-0.94.0.rc in the retropie/.advance folderedit the following lines
device_keyboard raw
device_mouse rawdevice_raw_mousedev[0] /dev/input/mouse0
device_raw_mousetype[0] ps2input_map[p1_dialx] mouse[0,x]
input_map[p1_dialy] mouse[0,y]input_map[p1_trackballx] mouse[0,x]
input_map[p1_trackbally] mouse[0,y]02/22/2016 at 15:27 #117795nosedeathParticipantMy Trackball works with AdvMame but then a bunch of games don’t work. Missile Command, Centipede, Millipede…all the ones that NEED a trackball don’t work for me. BUT. I’ve been using the .37b5 roms. I’ll give what you did a try. Thanks for following up on this.
02/22/2016 at 20:54 #117827bobtParticipantI think the key was changing the mousetype to ps2. Originally when I had the issue my trackball/spinner were assigned to mouse1. I started over with a clean install. My trackball was then assigned to mouse0. After the new install, the trackball and Spinner were also recognized in mame4all.
02/23/2016 at 00:33 #117853nosedeathParticipantClean install of RetroPi & Emulationstation?
I might as well just try that.02/23/2016 at 00:49 #117854bobtParticipantyes. I did the clean install then updated the settings as listed above.
02/23/2016 at 14:48 #117902nosedeathParticipantOK…I started completely from scratch. Retro Pi 3.5. Fresh new flash drive.
Still nothing. I tried centipede on ALL the emulators. Nothing. I haven’t tried the .94 roms yet and I haven’t tried adding the…….device_keyboard raw
device_mouse rawdevice_raw_mousedev[0] /dev/input/mouse0
device_raw_mousetype[0] ps2input_map[p1_dialx] mouse[0,x]
input_map[p1_dialy] mouse[0,y]input_map[p1_trackballx] mouse[0,x]
input_map[p1_trackbally] mouse[0,y]….yet….so tonight I’ll see.
02/24/2016 at 14:36 #117983nosedeathParticipantOK!!! SO!!!
I switched roms.
I entered in all that code.
Nothing.I switched BACK to the .37b11…
I tried every MAME emulator and still…
Nothing.I give up.
02/24/2016 at 14:43 #117984bobtParticipantdid you verify that your trackball/spinner are on mouse0?
If not you need to verify by
ls /dev/input to see the inputs
cat /dev/input/mouse0 move the trackball/spinner. If you don’t see text then try mouse1.
cat /dev/input/mouse1
The input map would have to be updated to point to the correct mouse input
02/24/2016 at 17:56 #118007nosedeathParticipantYup, Mouse0.
One thing though. It doesn’t come up as TEXT it’s weird characters. Maybe I should try mouse1…Mmmmmm.
BACK TO THE DRAWING BOARD!!
02/24/2016 at 17:57 #118008nosedeathParticipantOh and for the file “advmame-0.94.0.rc” I put all that code at the beginning of everything. Is that correct or should I append it at the bottom?
02/24/2016 at 18:15 #118009bobtParticipantMouse0 is correct otherwise you would not have seen any characters.
I updated the existing lines within the .RC file. I’m attaching my .RC for your review. the file was showing up as invalid so I renamed the file.
02/24/2016 at 19:14 #118015nosedeathParticipantAwesome awesome awesome…thank you!
02/24/2016 at 19:17 #118016nosedeathParticipantis this going to enable the trackball to work on an y emulator then?
02/24/2016 at 19:47 #118023bobtParticipantthis will only work on the advmame.
02/24/2016 at 20:00 #118028nosedeathParticipantMaaaannnn ok…
02/25/2016 at 04:44 #118061nosedeathParticipantNothing. Still nothing. I did EVERYTHING.
so defeated.
03/25/2016 at 22:42 #121503robbomanParticipantTo all.. THANKS! I found all my remaining answers in this thread.
I’ve been struggling for a while to get trackball and spinner to both work. They now both work perfectly, just the way I want. And btw.. they work in Mame4All too, as well as AdvMame.
For starters, Mame4All is coded to prevent mouse from working at all when there is a js (gamepad, joypad, etc) connected to the system. I don’t use any gamepads (this is an arcade cab). I expected my Ipac2 to appear as a keyboard and mouse ONLY, but for some reason it was causing a js0 device to appear in /dev/input, along with mouse0 and mouse1. When js* is present, there is NO way to get a Mame4All mouse device working.
AdvMame doesn’t care if there’s a js0 present, so that’s one workaround.
But Andy Warne from Ultimarc was quick to respond to my emails, and today he emailed me a different firmware for my IPac2 that completely removes the js0. I flashed it with Winipac utility. Now my Ipac appears as just a keyboard and 2 mouse like I want, no js0. Mame4All FINALLY works with my trackball and spinner without changing anything else!
I found right away that Mame4All just sums together both mouse0 (trackball) and mouse1 (spinner).. I loaded up Arkanoid and both controls work at the same time, which might be OK but is is not exactly what I want.
I noticed that in AdvMame 0.94, Arkanoid worked with my trackball.. the spinner did nothing. I wanted the spinner for Arkanoid, and the tball to do nothing. I was able to make this happen by editing the advmame .rc file:
device_mouse raw
device_raw_mousedev[0] /dev/input/mouse0 device_raw_mousedev[1] /dev/input/mouse1
device_raw_mousetype[0] ps2 device_raw_mousetype[1] ps2
… then down in the input_map section…
input_map[p1_dialx] mouse[1,x] input_map[p1_dialy] mouse[1,y]
… dial = spinner of course. Arkanoid, Tempest, etc use the ‘dial’ control. This specifies p1 dial to be mouse1 (because mouse0 is my trackball)
… I also changed these to specify mouse0 (trackball) where needed:
input_map[p1_mousex] mouse[0,x] input_map[p1_mousey] mouse[0,y]
input_map[p1_trackballx] mouse[0,x] input_map[p1_trackbally] mouse[0,y]
Now, if I load up Centipede or Missile Command the trackball works and the spinner does nothing. Vice\Versa when I load Ark or Tempest.
Perfection!!!
Summary:
1). Mame4All: If you are using gamepads, no trackball/spinner for you. Keyboard and multiple mice works fine. If you have no gamepad and still don’t have any mouse, check to see if you have a mystery js0 or js1 entry in /dev/input. If you do,
sudo rm js*
But if the js0 comes right back when you reboot, and you happen to have an Ultimarc interface.. check with Ultimarc, this can be fixed in firmware.
2). Confirm all your mouses, tballs, spinners actually work on your PI, and figure out which is mouse0, which is mouse1, etc.
cat /dev/input/mouse0
…then move the control you think is mouse0 to confirm, it should generate characters onscreen until you ctl-c to quit. Repeat for mouse1, etc.
You can also try this command:
ls -l /dev/input/by-id
This will show you the device IDs and which mouse each one relates to.
3). AdvMame: edit your /opt/retropie/configs/mame-advmame/(filename).rc to specify which controls are default for each function (as per above).
A note about editing the .rc file for newbies:
Make a backup file first (save with a new name). If you have even one character out of place it will prevent AdvMame from running at all.04/03/2016 at 17:15 #122297brettwgreenParticipantBrilliant! Thanks so much for figuring this out. Just got my spintrak working with tempest and it’s 1981 all over again.
Curious why I set the input type to ps2 when it’s plugged into usb, but it does work.
-
AuthorPosts
- The forum ‘Controller Configuration in RetroPie’ is closed to new topics and replies.