F*cking Linux !!!

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
OK - so I installed GXMAME and XMAME on my Acer Aspire One and plugged in my USB Saturn gamepad.

lsusb shows the device is there

Most Linux software still looks for gamepads as /dev/js0 so some googling led me to ln -sf /dev/input/whatever_it_was_called /dev/js0 which apparently redirects it somehow.

If I do sudo cat /dev/js0 then the terminal gets rubbish on it when I move the d-pad or press buttons so it's definately there. What the fuck is cat when it's at home ?

If I try jstest /dev/js0 I get permission denied. Same as when I launch GXMAME through the terminal.

If I try sudo jstest /dev/js0 I get Invalid Argument.

I'm lost. I haven't a clue what all these commands are. Help0r :(

If I had a way of installing XP I'd have done it by now I'm that fucked off :(
 

nath

Fledgling Freddie
Joined
Dec 22, 2003
Messages
8,009
Can't remember what it stands for but cat is just a command to display the contents of something. cat Ilikecheeseburgers.txt would result in the terminal outputting "hello, my name is nathan and I like cheeseburgers".

Beyond that I can't really help, don't have a tremendous amount of experience with *nix :\.
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
you've created a symbolic link from /dev/input/whatever_it_was_called to /dev/js0. what are the rights you have on /dev/input/whatever_it_was_called. type ls -l /dev/input/whatever_it_was_called

you'll see something like this:
Code:
server [/home/awesome] ls -l wijnoob
-rw-r-----   1 awesome sysadmin       0 Jun 17 17:21 wijnoob


the idea is that I think your application is running as some user, and doesn't have permissions to access the device.
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
bah, don't give in! try and fix it! :eek:
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
you've created a symbolic link from /dev/input/whatever_it_was_called to /dev/js0. what are the rights you have on /dev/input/whatever_it_was_called. type ls -l /dev/input/whatever_it_was_called

you'll see something like this:
Code:
server [/home/awesome] ls -l wijnoob
-rw-r-----   1 awesome sysadmin       0 Jun 17 17:21 wijnoob


the idea is that I think your application is running as some user, and doesn't have permissions to access the device.

Tried that. How do you cut and paste text from a terminal window ??
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
select it all with your mizouse, then go to your browser and press crtl-v I should think. or middle mouse button or some such...
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
select it all with your mizouse, then go to your browser and press crtl-v I should think. or middle mouse button or some such...

oh, and answer my excel question then ;)
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
[user@localhost ~]$ ls -l /dev/input/by-id/usb-CYPRESS_USB_Gamepad-event-joystick /dev/js0
lrwxrwxrwx 1 root root 10 2009-06-17 16:28 /dev/input/by-id/usb-CYPRESS_USB_Gamepad-event-joystick -> ../event14
lrwxrwxrwx 1 user user 55 2009-06-17 14:50 /dev/js0 -> /dev/input/by-id/usb-CYPRESS_USB_Gamepad-event-joystick

ok - that means something ?
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
it seems /dev/input/by-id/usb-CYPRESS_USB_Gamepad-event-joystick is a link to something called /dev/input/by-id/event14. can you do an ls -l of that?
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
[user@localhost ~]$ ls -l /dev/input/event18
crw-r----- 1 root root 13, 82 2009-06-17 18:18 /dev/input/event18

It moved to 18 :/
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
mmmkay if it keeps changing you're going to have to run your app as root (or sudo <myapp> or something like that)

your device is owned by root.root and has no global read rights.
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
i tried sudo gxmame but it didn't run. couldn't find its config files or something.
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
ideally you'd like your game user to have read rights on the joystick or summat. as it currently is configured, the only user who can read from the device is root, or anyone in the root group.

ofc, you don't want your game user in the root group eh :)
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
try this for a second (off the top of my head, might not work)

su - -c "/path/to/gxmame" [enter]
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
same as when i ran it using sudo.

i changed all the config paths to point to /home/user rather than /root and that didn't make any difference
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
can you paste exactly what you do to run it and the console messages? other than that I fear I am going to fail miserably to help you out mate :/
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
Just running gxmame on its own i get:

[user@localhost ~]$ gxmame
** Message: Loading gamelist
** Message: Loaded 6166 roms by 720 manufacturers covering 32 years.
** Message: with 231 games supporting samples.
** Message: catver not loaded, using default values
/dev/js0: Permission denied
** Message: No Joystick found

** (gxmame:14244): WARNING **: Couldn't find themed icon for "gxmame-sound-toolbar"

** (gxmame:14244): WARNING **: Couldn't find themed icon for "gxmame-rom

running sudo gxmame i get:

[user@localhost ~]$ sudo gxmame
** Message: Loading gamelist
** Message: gamelist not found, need to rebuild one
** Message: No Joystick found

** (gxmame:16084): WARNING **: Couldn't find themed icon for "gxmame-sound-toolbar"

** (gxmame:16084): WARNING **: Couldn't find themed icon for "gxmame-rom"
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
Why don't you try installing it :)
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
put your list and roms and things in the root homedir then. you did notice the permission denied not being there second time around :)

meh, I think it's needing some tweaking to fix. it's clearly not pleased with the joystick link anyway. I googled, it's sometimes picky.
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
put your list and roms and things in the root homedir then. you did notice the permission denied not being there second time around :)

meh, I think it's needing some tweaking to fix. it's clearly not pleased with the joystick link anyway. I googled, it's sometimes picky.

how can i copy files from my user (user) to root. i won't have permission.
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
you don't have root? sudo su -


otherwise it's:
(copy - use -R if you have directories and shizzle)
sudo /bin/cp (-R) /path/to/your/pr0n/stuff /path/to/root's/homedir/


(move -only if you're sure of space et al)
sudo /bin/mv /path/to/your/pr0n/stuff /path/to/root's/homedir/


edit: once you're root though...don't go typing rm or anything just cos you think you're 'ard ;)
 

TdC

Trem's hunky sex love muffin
Joined
Dec 20, 2003
Messages
30,925
damn man, how did you install the package in the first place? o0
 

Wij

I am a FH squatter
Joined
Dec 23, 2003
Messages
18,404
Ubuntu sorts it. Joypads just work on Ubuntu :)

SDLMAME on Ubuntu Live USB seems to work ok although some games don't work on SDLMAME that work on Windows MAME even though it's same version (0132).
 

phlash

Fledgling Freddie
Joined
Dec 24, 2003
Messages
195

...but didn't try asking the blogger if he'd had trouble with joystick/joypad input? :)

From my Ubuntu settings, I can see that the device manager (udev) configuration (in /etc/udev/rules.d) detects joystick devices and assigns them to the 'plugdev' group, which most users are in, so they can open/use joysticks on Ubuntu. Perhaps the linux configuration on an Aspire isn't so smart? Or perhaps the device isn't recognised as a joystick and is thus not treated correctly (but given that it 'just works' on Ubuntu that's unlikely).
 

Users who are viewing this thread

Top Bottom