My end goal is to disable/remove js0, which is using the stock/default input driver, which causes problems with my usb ps3 controller. I run sixad-raw which set's up js1, which uses a better driver. Once setup I want to remove js0 and rename js1 to js0. This will need done everytime the controller is plugged in, which is where the udev rules come into play.
The rule and script run. But some of the code within the script is not being executed correctly by udev. If I run the script manually, it work's fine.
To summarize. I want to remove "/dev/input/js0". I then want to rename "/dev/input/js1" to "/dev/input/js0". Currently it seems the rm and mv lines are having problems. Can anyone see corrections I need to make?
85-myrules.rules
startjoy1 (has 0755 permissions)Code:ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="054c", ATTR{idProduct}=="0268", RUN+="/usr/bin/startjoy1"
Code:#!/bin/bash sudo sixad-raw /dev/hidraw2 & sudo rm /dev/input/js0 sudo mv /dev/input/js1 /dev/input/js0 exit



Adv Reply

Bookmarks