PDA

View Full Version : btnx: Send keyboard and mouse combination events with mouse buttons


Pages : 1 2 [3] 4 5 6

daou
November 1st, 2007, 02:17 PM
btnx-config v.0.2.2 has been released. It fixes the revoco value bug (starting btnx-config cleared revoco values back to defaults).

heatpumpcontrol
November 1st, 2007, 07:52 PM
I've installed btnx 3.2 with 2.2 (although the config indicates version 2.1 in the about section of the config).

I want to thank you for your time.

My btnx will not function until I open up btnx and restart it using the command line or the GUI. I have read many pages and I can't find an answer..any help?

Thank you again.

daou
November 2nd, 2007, 05:08 AM
I've installed btnx 3.2 with 2.2 (although the config indicates version 2.1 in the about section of the config).

I want to thank you for your time.

My btnx will not function until I open up btnx and restart it using the command line or the GUI. I have read many pages and I can't find an answer..any help?

Thank you again.

Some other people have been having this problem as well. I'll try looking in to it.

daou
November 2nd, 2007, 05:11 AM
Looks like btnx made it into the archlinux repositories (http://aur.archlinux.org/packages.php?do_Details=1&ID=13477&O=600&L=0&C=0&K=&SB=n&SO=a&PP=25&do_MyPackages=&do_Orphans=&SeB=nd)! :grin:

rainman110
November 2nd, 2007, 05:41 AM
Terve Olli!
I just wanna say thank you for this nice program. It works like a charm :). The only issue was, that the btnx start script was only in /etc/init.d/ and there was no symbolic link in /etc/rc5.d/ . So it wasn't loaded on startup. But this is easy to fix.
Have you plans, to write a comparable program for lirc devices (or extend btnx for lirc devices)?
Cheers, Martin

daou
November 2nd, 2007, 05:59 AM
Terve Olli!
I just wanna say thank you for this nice program. It works like a charm :). The only issue was, that the btnx start script was only in /etc/init.d/ and there was no symbolic link in /etc/rc5.d/ . So it wasn't loaded on startup. But this is easy to fix.
Have you plans, to write a comparable program for lirc devices (or extend btnx for lirc devices)?
Cheers, Martin

Morjens :wink:!

If you are using btnx >= 0.3.0, the start up is done by udev. This allows hotplugging as well. Apparently some people have a problem with it. It starts fine for me, though. The old btnx used script files in the rcX.d folders.

I was actually thinking of building my own lirc device a while back. But as long as a lirc device registers a /dev/input/eventX (or /dev/eventX) event handler for itself, its possible to make it work with btnx. I was thinking of extending btnx to work with any input device, including keyboards with extra buttons that don't work. My Logitech keyboard is a good example. Some extra buttons actually send mouse button events.

It needs some work in btnx and a lot more work in btnx-config. When I have time, I'll implement it.

rainman110
November 2nd, 2007, 07:33 AM
That sounds really good! On my system (ubuntu 7.10), the newest releasy of btnx is not started with udev, but i have seen the udev-rule. There might be a problem with the rule, I'll have a look for it.
Lirc events are generated in e.g. /dev/lirc0, but if you have started the lirc daemon lircd, lircd sends the name of the pressed button over a socket. That makes implementation much easier i think. But correct me if I am wrong ;)
Heippä!

Got it: The problem was, that my mouse was connected via ps2 connector. After pluggin it to usb and reconfigure btnx, the udev rule worked, and btnx was loaded. Again, thank you for this great piece of software
BTW: my lirc device is self made. it is very easy to build ( i think 1 resistor, 1 diode, 1 voltage-gain, 1 ir-diode and 1 capicitor). Unfortunately, it is serial device, Would be cool to build a usb version, but i think this would be more complicated.

daou
November 2nd, 2007, 08:23 AM
I did some testing and it seems there is a problem with the initialization of btnx.

udev apparently fires up before the local filesystem is mounted. This creates a problem for btnx. It exits with an error when started by udev at this stage of the boot process. Ubuntu apparently gives it a few more tries. In some cases, it tries enough for btnx to launch. Sometimes it might not. On Mandriva, it seems that it might even lock the boot process because the init script gives returns an error.

I have to do more testing to figure out a solution.

daou
November 2nd, 2007, 08:30 AM
That sounds really good! On my system (ubuntu 7.10), the newest releasy of btnx is not started with udev, but i have seen the udev-rule. There might be a problem with the rule, I'll have a look for it.
Lirc events are generated in e.g. /dev/lirc0, but if you have started the lirc daemon lircd, lircd sends the name of the pressed button over a socket. That makes implementation much easier i think. But correct me if I am wrong ;)
Heippä!

Got it: The problem was, that my mouse was connected via ps2 connector. After pluggin it to usb and reconfigure btnx, the udev rule worked, and btnx was loaded. Again, thank you for this great piece of software
BTW: my lirc device is self made. it is very easy to build ( i think 1 resistor, 1 diode, 1 voltage-gain, 1 ir-diode and 1 capicitor). Unfortunately, it is serial device, Would be cool to build a usb version, but i think this would be more complicated.

I started a little hobby-project this summer. Kind of a like a Minority Report glove which I thought of combining with btnx. It has 3-axis accelerometers on three fingers, connected to a main board on top of the hand with Flex-PCB. The main board consists of a microcontroller, a USB-controller, and a little bit of other misc electronics. It shouldn't be too difficult to make the lirc a USB device with one of these USB-controller chips (National Semiconductor USBN9604).
My project has kind of stalled, however. The schematics and PCB-layout is pretty much ready, and I have all the necessary components. I just need to manufacture the PCBs somewhere (thinking Olimex, they have good prices) and find a way to solder the accelerometers (LGA-16). I had to take LGA case accelerometers because of size constraints on the finger boards and availability of other cases. And then there's the microcontroller coding... I expect the algorithms to be quite challenging.

Sensenseppl
November 2nd, 2007, 09:14 AM
The key drop-down-auto-completion-entry-box :-k is a little buggy. I'm not too happy with it myself. It's a bit of a hack. However, it is better than the old plain drop-down box because there are hundreds of values.

What does everyone think: would it be better that the key value entry was a simple button that opens a new dialog? This dialog would have a list of the keys and an auto-completion-entry at the top, and an OK button to confirm the selection. Would it make the interface better?

Optimum would be an automatic detection window/field, of course.

heatpumpcontrol
November 2nd, 2007, 10:51 AM
Some other people have been having this problem as well. I'll try looking in to it.

Hi Daou, Thanks for the your response. Actually I think that what my problem might be is that my mouse/keyboard set up is the Cordless Desktop MX3000 which comes with a serial MX600 mouse. If I had a USB mouse then I'm sure it would work...maybe. Anyhow, what I did was switch back to the old version 2.14 because it works great. It navigates Nautilus as I like it with the thumb buttons.

I am having an issue now though where upon log-in btnx-config starts up and I have to enter my user password to continue the boot and then the btnx-config GUI loads up. I must have entered something incorrectly. I had this before I switched to 2.14. I had placed the btnx-config command in "Sessions" but I later removed it because it would load like that on login however, it is still doing it.

I still have the btnx-config GUI that I can use with version 2.14 though so that is ok.

Thanks again.

UPDATE:

Found problem to be that I clicked on "Remember currently running application" button in Sessions. I cleared all my open windows and closed all open apps and clicked on "Remember currently running applications" again and restarted X (sudo /etc/init.d/gdm restart) and issue went away.

I installed new version 0.3.3 but btnx would not load automatically on log-in. I had to restart btnx manually (sudo /etc/init.d/btnx restart) and everything would work. I have switched back to version 0.2.14 and it loads normally. Again, this issue must be because I have a PS/2 mouse.

Thanks Daou

dr.koljan
November 2nd, 2007, 11:56 AM
I'm having a problem with creating a binary package with checkinstall.

btnx-config was OK and now I have a "btnx-config" entry in my Synaptic Package Manager, but I get the following error while checkinstall-ing btnx:

Installing with make install...

========================= Installation results ===========================
chmod a+rx ./scripts/install.sh
./scripts/install.sh
Installing............
btnx has been successfully installed.
./scripts/install.sh: /etc/init.d/btnx: /bin/sh: bad interpreter: No such file or directory
make: *** [install] Error 126

**** Installation failed. Aborting package creation.

Cleaning up...OK

Bye.

Any ideas why this happens?

olmari
November 4th, 2007, 12:50 PM
Terve Olli...

First I like to thank you for this marvelous program! Then to the problem...

ADD: Running Ubuntu 7.10 amd64...

I have problems with my MX Revolution thumb buttons, and I also have checked and doublechecked manual troubleshooting section... I also have DiNovo Edge keyboard which has small touchpad in it, and I am thinking _if_ that is contributing some part here... They use separate receivers, as Edge is bluetooth keyboard and Revolution is not bluetooth mouse. btnx does tell that I have 2 mouses if I move them both in the initial mousedetection state, so they're supposedly not "mixing" to eachothers.

The thing is that they both behave besically like left mouse button and nothing I do changes their behaviour. They

Just let me know if you want to see my xorg.conf and/or another settings here.

P.S. If you like we can talk finnish privately and then post solution here in english if that would make this easier for both?

EDIT: I just tested that in revoco settings if I assign button 4 or 5 to toggle the wheel spinning-mode, it does assign that part as should to either one of the thumb-button.

EDIT2: hmm it seems they DO work... but somehow I can't set them to act as back and forward as I'd want them to... if I choose say BTN_THUMB, XEV doesn't show me doing anything even when clicking the heck out of the button, while as unassigned it shows button 8 or 9 being pressed...

kdx
November 6th, 2007, 04:27 AM
If this question has already been answered in here, I apologize. This is one long thread to read!

Anyway, I have a Logitech VX Revolution. I've done everything that I could find in this thread in order to get it working, including uninstalling evdev and editing my xorg.conf to limit its control as much as possible.

The first time I fired up btnx, it detected all of my buttons, but once I tried to configure them, it stopped working. Now, the only button that it will detect is the search button (not even the left or right click buttons).

Any ideas??

Thanks!

rushrtb2112
November 6th, 2007, 10:27 AM
I have a logitech mx revolution and btnx is working great. The only problem I'm running into is with revoco. If i start btnx and change the revoco setting to automatic mode and restart btnx it works great. However when I reboot, revoco starts back in the free scroll mode. Is there any way to permenantly make the revoco set to automatic mode?

olmari
November 6th, 2007, 11:05 AM
I have a logitech mx revolution and btnx is working great. The only problem I'm running into is with revoco. If i start btnx and change the revoco setting to automatic mode and restart btnx it works great. However when I reboot, revoco starts back in the free scroll mode. Is there any way to permenantly make the revoco set to automatic mode?

This I can confirm also happening now when I actually tried to boot just to test it =)

yesjoshyes
November 6th, 2007, 08:56 PM
TERRIFIC PROGRAM!

thanks so much for taking the time with all of us, I appreciate it.

The only issue I havn't been able to work out from searching this thread over is what is the key to make MIDDLE CLICK activate the scrolling feature, as seen in windows. anybody know? i've tried several, none seem to work.

rand0m
November 7th, 2007, 05:30 AM
I'm having the same issue. Pressing the left ALT on the keyboard seems to stop it. I've also had problems with the scroll wheel adjusting the opacity of a window (running compiz). It seems the ALT key is "sticking" after using the thumb button occasionally. ALT+Scroll is supposed to adjust opacity. Again, pressing the ALT key releases it, and the mouse functions as expected. I'm guessing something is causing ALT to act like it is being held down. I get a few other odd mouse actions once in a while, and they all appear to be related to this.

Other than that, BTNX is great, and has been an excellent solution to a multi-button mouse!

I had this exact problem. It happens probably 1 out of 10 times I used the thumb buttons. While browsing in file manager or browser it'll make everything go nuts. So I tried uninstalling and reinstalling after seeing there was a new version on this howto. Now btnx-config doesn't detect my mouse at all (logitech mx510) during mouse detection. Suggestions?

daou
November 7th, 2007, 05:48 AM
Hi Daou, Thanks for the your response. Actually I think that what my problem might be is that my mouse/keyboard set up is the Cordless Desktop MX3000 which comes with a serial MX600 mouse. If I had a USB mouse then I'm sure it would work...maybe. Anyhow, what I did was switch back to the old version 2.14 because it works great. It navigates Nautilus as I like it with the thumb buttons.

I am having an issue now though where upon log-in btnx-config starts up and I have to enter my user password to continue the boot and then the btnx-config GUI loads up. I must have entered something incorrectly. I had this before I switched to 2.14. I had placed the btnx-config command in "Sessions" but I later removed it because it would load like that on login however, it is still doing it.

I still have the btnx-config GUI that I can use with version 2.14 though so that is ok.

Thanks again.

There are some problems getting btnx to work with PS/2 mice, especially with the udev hotplugging.

You can try to search for any instance of the word "btnx-config" in init scripts by executing the command:
sudo find /etc -name "*" | xargs grep btnx-config

It will give you a list of files. Try removing lines with btnx-config in any file that might be an init script. Or comment them with the '#' character, or make a backup first. That might stop btnx-config from loading.

daou
November 7th, 2007, 06:01 AM
This I can confirm also happening now when I actually tried to boot just to test it =)

This might be related to some of the init problems that btnx has been having lately. Perhaps fixing the init routine will help with this.

daou
November 7th, 2007, 06:03 AM
TERRIFIC PROGRAM!

thanks so much for taking the time with all of us, I appreciate it.

The only issue I havn't been able to work out from searching this thread over is what is the key to make MIDDLE CLICK activate the scrolling feature, as seen in windows. anybody know? i've tried several, none seem to work.

This is a Firefox specific feature. You can activate it in Edit->Preferences->Advanced->General->Use autoscrolling.

daou
November 7th, 2007, 06:06 AM
I had this exact problem. It happens probably 1 out of 10 times I used the thumb buttons. While browsing in file manager or browser it'll make everything go nuts. So I tried uninstalling and reinstalling after seeing there was a new version on this howto. Now btnx-config doesn't detect my mouse at all (logitech mx510) during mouse detection. Suggestions?

Are you also running compiz? And did you try reinstalling the older version of btnx and btnx-config?

EDIT: perhaps a new field is required in btnx to help with this problem since so many people (including myself) have this problem. Something that forces btnx to send a key release signal immediately after pressing for any keys sent by a button that behaves like this. This means that the button will not be able to be held down even if the user wants to. However, most of the functionality doesn't require this anyway. I've seen nothing in the code that could be the source of this problem, so I can't think of any better solution.

yesjoshyes
November 7th, 2007, 04:25 PM
This is a Firefox specific feature. You can activate it in Edit->Preferences->Advanced->General->Use autoscrolling.

thanks! that works! :guitar:

rand0m
November 7th, 2007, 06:35 PM
Are you also running compiz? And did you try reinstalling the older version of btnx and btnx-config?

EDIT: perhaps a new field is required in btnx to help with this problem since so many people (including myself) have this problem. Something that forces btnx to send a key release signal immediately after pressing for any keys sent by a button that behaves like this. This means that the button will not be able to be held down even if the user wants to. However, most of the functionality doesn't require this anyway. I've seen nothing in the code that could be the source of this problem, so I can't think of any better solution.

Yes, I am running compiz fusion. Tried installing the version I had before but I get the same problem.

As for the fix, that sounds like it would work. I can't think of a time where I'd need to hold down the thumb buttons anyway.

metoor30
November 8th, 2007, 02:24 PM
I don't know if anyone else is having this problem, but I found a solution so I thought I would post it...

I have an MX Revolution mouse and am running Gutsy (Gnome). After configuring the MX Rev in btnx, it would bring up a search window when I would press the search button. This happened even if I would change it in btnx-config.

Solution:

Go to System > Preferences > Keyboard Shortcuts, find the "Search" shortcut and disable it.

Also, make sure to press all the buttons when you detect the mouse. If you do not press the search button, it will not be detected when you detect buttons.

BTW, great program!!! It works better than the windows ap from Logitech.

Metoor30

daffyd
November 8th, 2007, 11:35 PM
I've tried using btnx, and the installation and configuring has worked flawlessly. However, I cannot actually get it to do anything, and I'm running out of ideas here.

I'm running it on Kubuntu Gutsy with a Logitech G5 2007 ed. (which has one thumb button more than the older G5). The RCs are correct according to hexdump of the mouse, and my xorg.conf looks like this:

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
# Option "Device" "/dev/input/mice"
Option "Device" "/dev/psaux"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "false"
EndSection


and here's a snippet from cat /proc/bus/input/devices:

I: Bus=0003 Vendor=046d Product=c705 Version=0110
N: Name="Logitech USB Receiver"
P: Phys=usb-0000:00:0b.1-3.1.2.1/input0
S: Sysfs=/class/input/input70
U: Uniq=09361E
H: Handlers=mouse1 event2
B: EV=7
B: KEY=ff0000 0 0 0 0 0 0 0 0
B: REL=103

I: Bus=0003 Vendor=046d Product=c049 Version=0111
N: Name="Logitech USB Gaming Mouse"
P: Phys=usb-0000:00:0b.1-3.1.3/input0
S: Sysfs=/class/input/input71
U: Uniq=
H: Handlers=mouse2 event3
B: EV=7
B: KEY=ffff0000 0 0 0 0 0 0 0 0
B: REL=143


I've not been messing around with xmodmap (so far), and never tried btnx before, so there's no leftovers from old config files or anything like that that causes the problem. I've also made sure that the buttons which I want fire an event on have the "Enabled" box checked, and been looking for keysym values with xev (which are sadly lacking).

btnx reports of no problems when started directly (ie. not through /etc/init.d), so everything seems to be hunkydory. Well, except from the fact that it doesn't work, which some may regard as slightly discouraging when it comes to using it.

So, anyone have an idea?

Any help is appreciated, and thanks in advance :-)

Curlydave
November 9th, 2007, 06:53 PM
Does anyone have an alternate working xorg config for Revolution users?

I used the old version of BTNX, the one without the UI for a while and it worked, minus dynamic wheel mode support. The new version is very broken for me, and I can't configure the buttons. Mouse 1 and 2 work, and mouse4 does what mouse3 should. The old version actually had all the buttons working automatically. The config in the troubleshooting section of the manual breaks my X. Any ideas?

heatpumpcontrol
November 9th, 2007, 07:42 PM
Ok I tried to find something but all I have is this:

grep: /etc/cups/classes.conf: Permission denied
grep: /etc/cups/printers.conf: Permission denied
grep: /etc/cups/ssl: Permission denied
grep: /etc/cups/ssl/server.crt: Permission denied
grep: /etc/cups/ssl/server.key: Permission denied
grep: /etc/cups/printers.conf.O: Permission denied
grep: /etc/cups/classes.conf.O: Permission denied
grep: /etc/X11/Xwrapper.config: Permission denied
grep: /etc/at.deny: Permission denied
grep: /etc/apt/secring.gpg: Permission denied
grep: /etc/apt/trustdb.gpg: Permission denied
grep: /etc/group-: Permission denied
grep: /etc/sudoers: Permission denied
grep: /etc/shadow: Permission denied
grep: /etc/gshadow: Permission denied
grep: /etc/ssl/private: Permission denied
grep: /etc/ssl/private/ssl-cert-snakeoil.key: Permission denied
/etc/btnx/btnx_config:# This is a btnx configuration file generated by btnx-config
grep: /etc/passwd-: Permission denied
grep: /etc/fuse.conf: Permission denied
grep: /etc/shadow-: Permission denied
grep: /etc/security/opasswd: Permission denied
grep: /etc/.pwd.lock: Permission denied
grep: /etc/ppp/pap-secrets: Permission denied
grep: /etc/ppp/chap-secrets: Permission denied
grep: /etc/gshadow-: Permission denied


None have btnx so I'm stuck. I don't see anything I can comment out.

hmm.

olmari
November 10th, 2007, 08:09 AM
Did you try "sudo grep ...."?

coredix
November 10th, 2007, 06:50 PM
hi,
sorry if this seems to be a little off-topic" but this thread (http://ubuntuforums.org/showthread.php?t=277388) is closed.

there was a tip for horizontal scrolling in firefox:
Mouse wheel tilt for horizontal scrolling
This tip is used to switch the mouse wheel tilt function to horizontal scroll in Firefox. Thanks to knn for suggesting this tip.

1. Go to about:config by typing "about:config" in the URL field of Firefox.

2. Set mousewheel.horizscroll.withnokey.action "Value" field to 0. NOTE: If you've swapped the wheel tilt buttons as described in the "Switch mouse wheel tilt functions" tip above, the direction will be reversed. In this case, change mousewheel.horizscroll.withnokey.numlines "Value" to 1.


after an upgrade from feisty to gutsy, this does´nt work anymore :(

any hints?

cheers coredix

ps: i´m still using the "old" method described in the above mentioned thread to configure the mouse buttons of my MX revolution

daou
November 11th, 2007, 06:24 AM
btnx-0.3.3 released:
Rehauled init process. It should now work on Mandriva as well. I've tested it on Mandriva. It should work on other distros as well that use chkconfig to install init scripts.btnx-config-0.2.3 released:
The udev rule generated by saving the config file has been updated, which has caused minor problems during boot.This combo should fix bugs related to btnx starting during boot (including for some people on Ubuntu).

RVDowning: if you are still following this thread, try the new combo on Mandriva and tell me if it works. I've tested it. I had some trouble with Mandriva's xorg.conf. It kept autodetecting the mouse and replacing my edits, which lead to btnx not working because the autodetected inputsections use evdev. I think I got around it by commenting a few lines (not too many, otherwise it autogenerates the sections again), and switching "evdev" to "mouse".

If anyone is using a different distro, let me know if these work on them. I'm especially interested about the functionality of the btnx init script in /etc/init.d/btnx in other distros. It seems the LSB System V init standard isn't as much of a standard as it's supposed to be. Implementations vary.

Raedwulf
November 11th, 2007, 11:05 AM
It almost works on opensuse.

I did a small change (not sure what it did) basically it couldn't stat btnx.
Apparently this line was causing problems

cat /lib/lsb/init-functions | grep start-stop-daemon > /dev/null
[ $? -eq 1 ] && DAEMON=$NAME

I Commented out && DAEMON=$NAME and it works...

However, I have some very strange problem with my MX518 mouse. For some bizarre reason, the '+' Button fires the same event as the Side Backward Button
i.e. they both fire button 8. And the Task Switcher Button (two squares) fires button 2 a.k.a. the middle button.

Btnx distinguishes these events but then there are multiple-events occuring.

I've read the btnx man page about this and tried the suggestions ... but to no avail :S.

But btnx works great, just doesn't quite fix my problem yet :(.

I'm using OpenSuse 10.3 x64, Xorg 7.3

Cheers!

jamesford
November 11th, 2007, 07:51 PM
unfortunately the new version doesent work well for me and i had to revert to the old version.

ive done and re-done the config several times and the result is always the same:
thumbwheel back/forward/press does nothing, no matter what i assign to them

also the back and forward buttons seems to behave as right and left scroll in addition to back and forward in webpages
it also failed to scrollwheel left tilt as a button while righttilt works

mx revo

MeanderingCode
November 14th, 2007, 01:17 AM
Hello.

Gutsy x86, repo kernel (2.6.22).

Any ideas?

root@kioskfreedom:/usr/local/src# tar -xvvf /freight/lindown/btnx-0.3.3.tar.gz
-rw-r--r-- daou/daou 6726 2007-07-01 05:47 btnx-0.3.3/data/events
drwxr-xr-x Creating directory: btnx-0.3.3
drwxr-xr-x Creating directory: btnx-0.3.3/data
-rwxr-xr-x daou/daou 5147 2007-11-10 06:01 btnx-0.3.3/scripts/install.sh
drwxr-xr-x Creating directory: btnx-0.3.3/scripts
-rw-r--r-- daou/daou 1942 2007-11-10 06:01 btnx-0.3.3/scripts/uninstall.sh
-rw-r--r-- daou/daou 3737 2007-11-11 01:53 btnx-0.3.3/scripts/btnx_init.sh
drwxr-xr-x daou/daou 0 2007-11-11 02:02 btnx-0.3.3/data/
drwxr-xr-x daou/daou 0 2007-11-11 02:02 btnx-0.3.3/scripts/
-rw-r--r-- daou/daou 835 2007-10-18 02:35 btnx-0.3.3/Makefile
-rw-r--r-- daou/daou 8819 2007-10-15 07:05 btnx-0.3.3/config_parser.c
-rw-r--r-- daou/daou 533 2007-07-01 08:47 btnx-0.3.3/device.h
-rw-r--r-- daou/daou 965 2007-07-01 08:47 btnx-0.3.3/config_parser.h
-rw-r--r-- daou/daou 11892 2007-11-10 03:44 btnx-0.3.3/btnx.c
-rw-r--r-- daou/daou 1718 2007-07-14 06:18 btnx-0.3.3/SUPPORTED_MICE
-rw-r--r-- daou/daou 7784 2007-10-15 07:05 btnx-0.3.3/revoco.c
-rw-r--r-- daou/daou 3520 2007-07-14 06:18 btnx-0.3.3/devices_parser.c
-rw-r--r-- daou/daou 399 2007-05-27 08:35 btnx-0.3.3/uinput.h
-rw-r--r-- daou/daou 3867 2007-07-06 01:25 btnx-0.3.3/uinput.c
-rw-r--r-- daou/daou 1914 2007-07-06 01:25 btnx-0.3.3/device.c
-rw-r--r-- daou/daou 584 2007-05-27 08:35 btnx-0.3.3/devices_parser.h
-rw-r--r-- daou/daou 559 2007-10-15 07:05 btnx-0.3.3/revoco.h
-rw-r--r-- daou/daou 1068 2007-07-14 06:18 btnx-0.3.3/README
-rw-r--r-- daou/daou 710 2007-07-06 06:38 btnx-0.3.3/btnx.h
-rw-r--r-- daou/daou 17987 2007-06-12 11:35 btnx-0.3.3/COPYING
-rw-r--r-- daou/daou 464 2007-07-14 06:18 btnx-0.3.3/INSTALL
root@kioskfreedom:/usr/local/src# cd btnx-0.3.3/
root@kioskfreedom:/usr/local/src/btnx-0.3.3# make
gcc btnx.c -Wall -c -o btnx.o
gcc uinput.c -Wall -c -o uinput.o
gcc config_parser.c -Wall -c -o config_parser.o
gcc devices_parser.c -Wall -c -o devices_parser.o
gcc device.c -Wall -c -o device.o
gcc revoco.c -Wall -c -o revoco.o
gcc -o btnx btnx.o uinput.o config_parser.o devices_parser.o device.o revoco.o -Wall
root@kioskfreedom:/usr/local/src/btnx-0.3.3# checkinstall

checkinstall 1.6.1, Copyright 2002 Felipe Eduardo Sanchez Diaz Duran
This software is released under the GNU GPL.


The package documentation directory ./doc-pak does not exist.
Should I create a default set of package docs? [y]: y

Preparing package documentation...OK

Please write a description for the package.
End your description with an empty line or EOF.
>> button extension (OlliSallonen.com)
>>

*****************************************
**** Debian package creation selected ***
*****************************************

This package will be built according to these values:

0 - Maintainer: [ root@kioskfreedom ]
1 - Summary: [ button extension (OlliSallonen.com) ]
2 - Name: [ btnx ]
3 - Version: [ 0.3.3 ]
4 - Release: [ 1 ]
5 - License: [ GPL ]
6 - Group: [ checkinstall ]
7 - Architecture: [ i386 ]
8 - Source location: [ btnx-0.3.3 ]
9 - Alternate source location: [ ]
10 - Requires: [ ]

Enter a number to change any of them or press ENTER to continue:

Installing with make install...

========================= Installation results ===========================
Installing btnx...
.........
Adding system startup for /etc/init.d/btnx ...
/etc/rc0.d/K49btnx -> ../init.d/btnx
/etc/rc1.d/K49btnx -> ../init.d/btnx
/etc/rc6.d/K49btnx -> ../init.d/btnx
/etc/rc2.d/S49btnx -> ../init.d/btnx
/etc/rc3.d/S49btnx -> ../init.d/btnx
/etc/rc4.d/S49btnx -> ../init.d/btnx
/etc/rc5.d/S49btnx -> ../init.d/btnx
btnx has been successfully installed!

You can type 'sudo /etc/init.d/btnx start' to start btnx if you have made a configuration file with btnx-config.

======================== Installation successful ==========================

Copying documentation directory...
./
./COPYING
./README
./INSTALL
grep: /var/tmp/ClKAdphZpfAZiXfjZPkNr/newfile: No such file or directory

Copying files to the temporary directory...OK

Striping ELF binaries and libraries...OK

Compressing man pages...OK

Building file list...OK

Building Debian package...OK

Installing Debian package... FAILED!

*** Failed to install the package

Do you want to see the log file? [y]: y


*** SIGINT received ***

Cleaning up...OK

Bye.

And here's that log file:

(Reading database ... 45133 files and directories currently installed.)
Unpacking btnx (from .../btnx_0.3.3-1_i386.deb) ...
dpkg: btnx: warning - conffile `etc/rc5.d' is not a plain file or symlink (= `/etc/rc5.d')
dpkg: error processing /usr/local/src/btnx-0.3.3/btnx_0.3.3-1_i386.deb (--install):
unable to create `./etc/btnx/events': No such file or directory
Errors were encountered while processing:
/usr/local/src/btnx-0.3.3/btnx_0.3.3-1_i386.deb

I'd love to configure w/o documentation if that would work (not that i think it's a good idea), but there's no configure file...?

I'm not sure what to do from here.

================================================== ==========
| EDIT |
=======

Well, "make install" worked. Don't like the checkinstall failing, though (and that other fellow also had no luck w/ it). Any thoughts?

btnx-config checkinstalled just fine, btw.

More problems, though....post to come

MeanderingCode
November 14th, 2007, 03:11 AM
Just too odd.

But, for any help it may provide, here's some info:
------------------------------------------------------------
Gutsy x86 repo kernel.
XFCE (Xubuntu alternate install cd), Compiz-fusion (in case that might matter)
Microsoft Wireless Notebook Laser Mouse 6000 (identifies in /proc/bus/input/devices as Microsoft Microsoft Wireless Optical Mouse# 1.00 (insert odd question mark character in place of #))

Simply under xorg.conf (xserver-xorg repository version 1:7.2-5ubuntu13, btw) i had this functionality with this entry:
left and right click; scroll wheel click as middle, scroll, tilt; thumb button register in xev as button 9 (many progs acted as if it were either left or right click, though)
Here's relevent section:
Section "InputDevice"
Identifier "Wireless Mouse"
Driver "evdev"
Option "CorePointer"
Option "Name" "*Microsoft Wireless Optical Mouse*"
Option "Buttons" "9"
Option "ZAxisMapping" "4 5"
Option "DialRelativeAxisButtons" "7 6"
EndSection

...

Section "ServerLayout"
...
InputDevice "Wireless Mouse" "SendCoreEvents"
...
EndSection

I was very happy to see this work (just as a note, the name matching with the asterisks was neccessary because i couldn't match the strange character in the name given by "cat /proc/bus/input/devices" after the word mouse, the event was changing every boot (so i couldn't use the device option))

I wanted to try this app out so i could map that thumb button to Control+Alt+Left Click (rotate cube in compiz). I couldn't just re-shortcut to "button 9" because i also have a touchpad and trackpoint on this here laptop. So.... but here's what happens:

Same xorg.conf, multiple different xorg.confs, whatever...simplest to say i tried having no entry for the device and i tried having "basic" entry daou has recommended, and in many flavours and iterations. Here's the best behaviour i got:

w/ said simplest xorg.conf, button 9 produces: button 9, button 2, button 1 (what i actually had set it for), Alt_L (also set)....it would only hold one meta key setting between x restarts, btw.

i can never, with any xorg.conf, get it to stop producing button 2 events for everything set and enabled in btnx.

w/ my above xorg.conf, thumb button produces: button 2 event or button 3 event or any damn button event i set it to EXCEPT button 1...won't do it, not even when i ask nicely. I tried setting buttons option to 7 instead of 9...to 3...no luck.

I also think it's messing with my trackpoint middle click scroll functionality (diff part of xorg.conf)...this is very bad.

Anyway, it's a great looking app, amazing and inspirational to my fledgling hacking, but i think i don't have the time to try and get this one working at this stage of dev.

Good luck, I'll be checking up on releases!!!

EDIT:daou, feel free to PM me if you want more details of my experience.

pistos
November 14th, 2007, 08:58 PM
First, I want to say thank you for a great little application. Btnx is a badly needed feature for Ubuntu!

Unfortunately, I think I may have discovered a bug in btnx. I had it install in my system (Gutsy, btnx 0.3.3, btnx config 0.2.3) and everything was working great. But, then when I tried to use gnome-pilot to sync my palm Treo 680 with Evolution I was not able to. Btnx had bonked palm pilot syncing. I uninstalled btnx and palm pilot syncing returned.

Here are a few more details that might help in tracking down where the conflict/bug is: I am using a USB mouse. And, gnome-pilot uses USB to sync with my Palm Treo 680. My guess is that btnx and gnome-pilot conflict over the USB.

Thanks again for your work on btnx. I hope you are able to track down the conflict and fix it without much trouble. I would love to have the functionality of btnx again.

daou
November 15th, 2007, 05:18 AM
Sorry for the delay in my responses. I'm allocating some time to develop btnx a bit further. The new versions will include support for multiple configurations. This will allow you to change button configurations on the fly. For example, you will be able to bind a button to restart btnx with a different configuration. One could be for gaming, one for internet surfing, another for image/3D editing, code development, etc. etc.

The interface will be cleaned up a bit as well. A screenshot of the new window is attached.

rand0m
November 15th, 2007, 06:54 AM
Something that forces btnx to send a key release signal immediately after pressing for any keys sent by a button

Will you be implementing this in the next version?

daou
November 15th, 2007, 07:48 AM
Will you be implementing this in the next version?

Now that you reminded me, I probably will ;).

SuperAndy
November 15th, 2007, 01:22 PM
I am having a crazy issue, only with the latest version, where if the computer turns the display off, due to idle time or whatever, btnx is killed, and doesn't start up again. i am thinking a possible work around would be to stick it in a script that runs on wake, but it doesn't happen for any other daemon.

I am running Ubuntu Gutsy x86, and just to clarify, the previous versions where the config was optional ran fine.

dspearing
November 15th, 2007, 04:01 PM
Hey, 1st thanks for taking the time to work on this. It looks like it has potential. I'm a recent convert from the Micro$oft world (well not completely just with Ubuntu). I've worked with Redhat before but could never get it to function as well as I would like. So far I'm LOVING Ubuntu 7.1x64. Anyway to the point:

I have a MX Revolution which I use to play WoW (which runs swimmingly on Wine except for some sound issues). Anyway, not all of my mouse buttons were working so I Googled and found btnx. I installed 0.3.3 and 0.2.3 config. The problem I'm having is trying to find a good configuration. Is there perhaps a config file someone has done that I could see so I have a reference point? I looked for this default config file for the MX that I saw referenced several times but I'm thinking maybe it was a previous version that had this because I have no default in my /etc/btnx folder. I'm used to using the uberOptions in the Windows world to set it up, but the configuration here seems foreign to me for some reason. If someone could lend me a hand I'd be most appreciative. Looking forward to being able to utilize all my buttons again.

Side note: I Screwed it up so bad that after rebooting I had to use the keyboard to open btnx to blow away my config. The buttons were all bass ackwards and I couldn't click anything.
:lolflag:

daou
November 15th, 2007, 04:14 PM
Hey, 1st thanks for taking the time to work on this. It looks like it has potential. I'm a recent convert from the Micro$oft world (well not completely just with Ubuntu). I've worked with Redhat before but could never get it to function as well as I would like. So far I'm LOVING Ubuntu 7.1x64. Anyway to the point:

I have a MX Revolution which I use to play WoW (which runs swimmingly on Wine except for some sound issues). Anyway, not all of my mouse buttons were working so I Googled and found btnx. I installed 0.3.3 and 0.2.3 config. The problem I'm having is trying to find a good configuration. Is there perhaps a config file someone has done that I could see so I have a reference point? I looked for this default config file for the MX that I saw referenced several times but I'm thinking maybe it was a previous version that had this because I have no default in my /etc/btnx folder. I'm used to using the uberOptions in the Windows world to set it up, but the configuration here seems foreign to me for some reason. If someone could lend me a hand I'd be most appreciative. Looking forward to being able to utilize all my buttons again.

Side note: I Screwed it up so bad that after rebooting I had to use the keyboard to open btnx to blow away my config. The buttons were all bass ackwards and I couldn't click anything.
:lolflag:

You can download the old btnx (http://www.ollisalonen.com/btnx-0.2.14.tar.gz). Inside the source archive, there is a data/defaults directory. It contains the default settings for the mice as used in the old version. Note: you can't use the default configuration files directly. Just look at the keycode and modifier values as a reference. They are also commented with the functionality that the combos provide.

Akegata
November 17th, 2007, 06:14 AM
I'm having problems with the latest version of btnx.
When I try to start the service after installing it, I get the error
Error opening button event file descriptor: No such file or directory

I have /dev/input/event[0-9], so I'm not sure what's going on. Could it be a permission problem?
They permission on the files is 660.

catsgomoo
November 17th, 2007, 08:23 PM
I'm having a bit of a problem. I have read the manual on fixing problems with extra keypresses or commands that go along with buttons, but I'm still unclear on how to fix it.

I have an MX1000 mouse, and I would like to map all my buttons to different keypresses from the keyboard, to help facilitate hotkeying in games. My problem is that although I get all my buttons configured the way I want, and they send the correct keypresses, they still send the other keypresses that Linux was using as well, in the first place.

So instead of my thumb forward button giving "Key_9", as it says in the config, in practice it actually sends "Key_9 and whatever the hell functions as right click."

How do I disable the original shortcuts and functions?

Much thanks in advance for help on this.

Edit: Fixed. It took every single fix that you had on the troubleshooting page. Yikes. I blame Logitech. Lomoco plus lots of monkeying aroudn in Xev (with a drawing made on pen and paper to help map the things out) fixed the issue.

Thanks so much for such a great piece of software!

-Phi-
November 18th, 2007, 11:30 PM
Just wanted to post and say thanks because the buttons on my VX Nano are now working great. \\:D/
I needed to do the xorg.conf edit to "auto" and other than that it was all straightforward.

- Phi

francois12
November 19th, 2007, 02:37 PM
having a "btnx failed to start" error during boot, but as you mentioned, it's just annoying because everything works fine!

amazing program!!

Daou, you're doing a great job, thanks a lot!

tehpopa
November 19th, 2007, 03:00 PM
Okay... forgive me for not seeing this in here, but searching didn't find me very much. I'm looking to use btnx as part of my solution to get vent working for me. Admittedly I don't even have Ubuntu installed anymore, but I am looking(desperately) to change that. So here's what I'm wondering. Can btnx send these keystrokes directly to a program? IE: Bind my mouses 4th button to ] or something, and have that be echo'd straight to a non-focused window? If not I think I've got another solution using btnx, x2vnc, and ventriloctrl. But it would be nice if I could slim it down a bit.

francois12
November 19th, 2007, 04:23 PM
hi
http://images2.hiboox.com/vignettes/4707/qr3lxzlq.png (http://www.hiboox.com/lang-fr/image.php?img=qr3lxzlq.png)
this picture explains the bug I have ;) when I click on the buttons shown it acts like a left click or a right click
Is there a fix for this? thanks
edit : it's not a "left click", it's a "middle click" (picture)

SuperAndy
November 21st, 2007, 05:49 AM
It does seem that turning the mouse off results in all settings going back to some default. If the mouse is left on, however, its fine. Is this a known bug?

blazoner
November 21st, 2007, 11:22 AM
I got tired of having to look up all of the button configurations from btnx 0.2.x every time I had to start from scratch, so here they are in abbreviated form.
################################################## #########
# !!!!!!!!!!!!!!!READ ME FIRST!!!!!!!!!!!!!!!!!!!
################################################## #########
# This file was used to configure btnx's behavior.
# Lines are commented with # characters.
#
# Basic structure of a button configuration for sending
# keyboard and button events
# -------------------------------------------------------
# Button
# keycode = KEY
# mod1 = KEY
# mod2 = KEY
# mod3 = KEY
# EndButton
#
#
# -------------------------------------------------------
# The configuration field for a button was started by
# a "Button" line and closed by an "EndButton" line.
# The mod[1..3] fields are optional. The fields have the
# following meanings:
#
# mod[1..3]: these are modifier key values. Examples are
# shift (KEY_LEFTSHIFT, KEY_RIGHTSHIFT), ctrl (KEY_LEFTCTRL, ...),
# alt, etc. You can combine up to three modifier keys together with
# a keycode. You can even combine them with mouse button events.
# You do not have to specify any mod keys if you don't need to.
#-----------------------------------------------------------
#-----------------------------------------------------------
# Left mouse button
# NOTE: This is commented out because you probably don't want
# to send extra events when pressing this button!
#Button
#name = Left button
#keycode = KEY_UNKNOWN
#EndButton


# Right mouse button
# NOTE: This is commented out because you probably don't want
# to send extra events when pressing this button!
#Button
#name = Right button
#keycode = KEY_UNKNOWN
#EndButton

# Top wheel scroll down
# NOTE: This is commented out because you probably don't want
# to send extra events when pressing this button!
#Button
#name = Top wheel scroll down
#keycode = KEY_UNKNOWN
#EndButton


# Top wheel scroll up
# NOTE: This is commented out because you probably don't want
# to send extra events when pressing this button!
#Button
#name = Top wheel scroll up
#keycode = KEY_UNKNOWN
#EndButton


#-----------------------------------------------------------
# These buttons were configured for the MX Revolution mouse.
#-----------------------------------------------------------
# Thumb wheel forward.
# Does a Ctrl+Alt+Left, useful for switching workspaces.
Button
name = Thumb wheel forward
keycode = KEY_LEFT
mod1 = KEY_LEFTCTRL
mod2 = KEY_LEFTALT
EndButton


# Thumb wheel back.
# Does a Ctrl+Alt+Right, useful for switching workspaces.
Button
name = Thumb wheel back
keycode = KEY_RIGHT
mod1 = KEY_LEFTCTRL
mod2 = KEY_LEFTALT
EndButton


# Thumb wheel press.
# Does an Alt+LeftMouseButton. Useful for dragging windows.
Button
name = Thumb wheel press
keycode = BTN_LEFT
mod1 = KEY_LEFTALT
EndButton


# Thumb button back.
# Does a Ctrl+PageDown. Useful for moving through tabs
# (Firefox, gnome-terminal, etc.)
Button
name = Thumb button back
keycode = KEY_PAGEDOWN
mod1 = KEY_LEFTCTRL
EndButton


# Thumb button forward.
# Does a Ctrl+PageUp. Useful for moving through tabs
# (Firefox, gnome-terminal, etc.)
Button
name = Thumb button forward
keycode = KEY_PAGEUP
mod1 = KEY_LEFTCTRL
EndButton


# Search key.
# Simulates a mouse-wheel click.
Button
name = Search key
keycode = BTN_MIDDLE
EndButton


# Top wheel right.
# Does an Alt+Right. Ex. Firefox forward
Button
name = Top wheel right
keycode = KEY_RIGHT
mod1 = KEY_LEFTALT
EndButton


# Top wheel left.
# Does an Alt+Left. Ex. Firefox back
Button
name = Top wheel left
keycode = KEY_LEFT
mod1 = KEY_LEFTALT
EndButton


=============================================
Buttons from other default configurations
=============================================
# Play/pause button
# Sends a play/pause key event.
Button
name = Play/pause
keycode = KEY_PLAYPAUSE
EndButton


# Volume up button
# Sends a volume up key event
Button
name = Volume up
keycode = KEY_VOLUMEUP
EndButton


# Volume down button
# Sends a volume down key event
Button
name = Volume down
keycode = KEY_VOLUMEDOWN
EndButton


# Search key.
Button
name = Search key
keycode = KEY_F5
EndButton


=================================================
Default keys from the MX610 with additional notes
=================================================
# Volume up button
# Sends a volume up key event
# NOTE: This is commented out. I didn't need to send this event as kmilo grabs it
#Button
#name = VolumeUp
#keycode = KEY_VOLUMEUP
#EndButton


# Volume down button
# Sends a volume down key event
# NOTE: This is commented out. I didn't need to send this event as kmilo grabs it
#Button
#name = VolumeDown
#keycode = KEY_VOLUMEDOWN
#EndButton


# Volume mute button
# Sends a volume mute key event
# NOTE: This is commented out. I didn't need to send this event as kmilo grabs it
#Button
#name = VolumeMute
#keycode = KEY_MUTE
#EndButton

# Media forward button
# Does a PLAYPause, useful for Amarok
Button
name = Messenger
keycode = KEY_PLAYPAUSE
EndButton


# Media back button
# Does a XF86Mail, opens KMail compose
Button
name = Email
keycode = KEY_MAIL
EndButton


# Browser forward button
# Does an XF86Forward. Ex. Konqueror forward
Button
name = Browser forward
keycode = KEY_FORWARD
EndButton


# Browser back button
# Does an XF86Back. Ex. Konqueror back
Button
name = Browser back
keycode = KEY_BACK
EndButton


# Wheel tilt right
# Useful for Amarok
Button
name = Wheel right
keycode = KEY_NEXTSONG
EndButton


# Wheel tilt left.
# Useful for Amarok
Button
name = Wheel left
keycode = KEY_PREVIOUSSONG
EndButton

I hope this helps, and I suggest that daou should probably link this post in post #1 of this thread.

blazoner
November 21st, 2007, 12:44 PM
Here's an ambitious project someone could dive into:
Make a graphical key-picker.

Make a bit-mapped picture something like the KvKbd (https://wiki.ubuntu.com/GutsyGibbon/Tribe5/Kubuntu?action=AttachFile&do=get&target=kvkbd2.png).
Instead of entering keystrokes, it would be set up to input keycodes to btnx-config.

It's out of my league, but would make the process simpler for the novice to grasp.

tarwatirno
November 24th, 2007, 12:09 AM
Hello, I recently bought a MX revolution mouse. I am trying to get btnx working. Everytime I try to start btnx I get the following error. I have been unable to find anything about this error.

Error: no supported mice detected.
You can make a support request for your mouse at
http://ubuntuforums.org/showthread.php?t=455656


Btnx-config detects the mouse and writes the config file for the mouse without complaint as

Mouse
vendor_id = 0x046d
product_id = 0xc525
revoco_mode = 1
revoco_btn = 3
revoco_up_scroll = 5
revoco_down_scroll = 5
EndMouse

The relevant section in /proc/bus/input/devices is

I: Bus=0003 Vendor=046d Product=c525 Version=0111
N: Name="Logitech USB Receiver"
P: Phys=usb-0000:00:13.0-3/input0
S: Sysfs=/class/input/input1
U: Uniq=
H: Handlers=mouse0 event1 ts0
B: EV=7
B: KEY=ffff0000 0 0 0 0 0 0 0 0
B: REL=143

And the mouse is configured in my xorg.conf as

Section "InputDevice"
Identifier "Logitech USB Reciever"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "auto"
Option "Emulate3Buttons" "no"
EndSection


I am using Debian rather than Ubuntu though I doubt that would matter. And I have an xserver configured to use xgl and compiz-fusion with the fglrx driver. There again I doubt that that would matter.

carmi
November 24th, 2007, 04:21 AM
I have a Logitech MX518 mouse that is somewhat configured. I want to get btnx working also though. I installed btnx fine and ran it. I started the mouse detection and continued to the second stage where I am supposed to move my mouse and press each button on it. Btnx doesn't recognize that I am clicking buttons at all. Xev shows that each button has a different button number and works.
Here is additional information about my configuration.

I am running Ubuntu 7.04 AMD64 using kde.

Xorg is:
Section "InputDevice"
Identifier "Configured Mouse"
Driver "evdev"
Option "Protocol" "auto"
Option "SendCoreEvents" "true"
Option "Name" "Logitech USB-PS/2 Optical Mouse"
Option "Emulate3Buttons" "false"
Option "ZAxisMapping" "4 5 6 7"
Option "Buttons" "12"
Option "Resolution" "800"
Option "AllowMouseOpenFail" "true"
EndSection


cat /proc/bus/input/devices shows:

I: Bus=0003 Vendor=046d Product=c01e Version=0110
N: Name="Logitech USB-PS/2 Optical Mouse"
P: Phys=usb-0000:00:0b.0-4/input0
S: Sysfs=/class/input/input2
H: Handlers=mouse1 event2 ts1
B: EV=7
B: KEY=ff0000 0 0 0 0
B: REL=103


I also have xbindkeys working for front and back buttons.

Thanks

blazoner
November 24th, 2007, 02:39 PM
Hello, I recently bought a MX revolution mouse. I am trying to get btnx working. Everytime I try to start btnx I get the following error. I have been unable to find anything about this error.

Error: no supported mice detected.
You can make a support request for your mouse at
http://ubuntuforums.org/showthread.php?t=455656


It looks as if you are trying to use the old btnx (http://www.ollisalonen.com/btnx/old.html).

Try using btnx-0.3.3 and btnx-config-0.2.3
Installation:

Note: If you are upgrading your btnx from pre v.0.3.0 or btnx-config from pre v.0.2.0, you must uninstall them first.

Note: If you have used another howto to configure your mouse, try to revert as much of the changes you have done.

1. Get all the necessary dependencies. btnx-config needs libgtk2.0 and libgtk2.0-dev (version 2.10.11 or newer), libglade and libglade-dev (version 2.6.0 or newer), pkg-config (0.21 or newer), and build-essential. btnx needs build-essential.
sudo apt-get install build-essential libgtk2.0-0 libgtk2.0-dev libglade2-0 libglade2-dev pkg-config

2. Install btnx
$ wget http://www.ollisalonen.com/btnx/btnx-0.3.3.tar.gz
$ tar -xvvf btnx-0.3.3.tar.gz
$ cd btnx-0.3.3
$ make
$ sudo make install

3. Install btnx-config.
$ wget http://www.ollisalonen.com/btnx/btnx-config-0.2.3.tar.gz
$ tar -xvvf btnx-config-0.2.3.tar.gz
$ cd btnx-config-0.2.3
$ ./configure
$ make
$ sudo make install

If you encountered an error, there is probably a dependency problem. You can also call "./configure builddocs=no" if there was a documentation build problem, or if you don't want to install the manual.

4. You should have gotten a menu item. In GNOME, Applications->System tools->btnx. In KDE, System->btnx. Press it to launch btnx-config.

You can find all the necessary information for configuring your mouse with btnx-config in the btnx manual. Either press the "Help" button in btnx-config or refer to the online manual at http://www.ollisalonen.com/btnx/man

blazoner
November 24th, 2007, 02:44 PM
I have a Logitech MX518 mouse that is somewhat configured. I want to get btnx working also though. I installed btnx fine and ran it. I started the mouse detection and continued to the second stage where I am supposed to move my mouse and press each button on it. Btnx doesn't recognize that I am clicking buttons at all. Xev shows that each button has a different button number and works.
Here is additional information about my configuration.

I am running Ubuntu 7.04 AMD64 using kde.

Xorg is:
Section "InputDevice"
Identifier "Configured Mouse"
Driver "evdev"
Option "Protocol" "auto"
Option "SendCoreEvents" "true"
Option "Name" "Logitech USB-PS/2 Optical Mouse"
Option "Emulate3Buttons" "false"
Option "ZAxisMapping" "4 5 6 7"
Option "Buttons" "12"
Option "Resolution" "800"
Option "AllowMouseOpenFail" "true"
EndSection


cat /proc/bus/input/devices shows:

I: Bus=0003 Vendor=046d Product=c01e Version=0110
N: Name="Logitech USB-PS/2 Optical Mouse"
P: Phys=usb-0000:00:0b.0-4/input0
S: Sysfs=/class/input/input2
H: Handlers=mouse1 event2 ts1
B: EV=7
B: KEY=ff0000 0 0 0 0
B: REL=103


I also have xbindkeys working for front and back buttons.

Thanks

From the first post:Note: If you have used another howto to configure your mouse, try to revert as much of the changes you have done.
Not doing so is guaranteed to cause you problems.

blazoner
November 24th, 2007, 04:07 PM
Here is my current WORKING xorg.conf mouse section.Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/psaux"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "true"
EndSectionI have set Option "Emulate3Buttons" "true"
This allows me to use my MX-Revolution without a true wheel-click, but instead to use Left+Right Click = Middle Click, and frees up my search button for more functionality. If I set revoco to "auto", it returns the functionality of the wheel-click, but that is now redundant, since whatever you actually map it to is automatically mapped to L+R Click.

I would love to have an option in revoco to turn off middle-click (as in "manual" mode) while still allowing "auto" functionality. Maybe even a "hybrid" mode, with switching between "auto" (speed sensitive) and "free" modes. (I have already emailed the author this request.)

[S]Duke
November 25th, 2007, 04:41 AM
Hello, I have a MX Revolution, and my Thumb Up and Down buttons don't seem to work at all, the others respond fine, but these two aren't working.

I'm on Gutsy, btw.

daou
November 25th, 2007, 06:17 AM
Here is my current WORKING xorg.conf mouse section.I have set Option "Emulate3Buttons" "true"
This allows me to use my MX-Revolution without a true wheel-click, but instead to use Left+Right Click = Middle Click, and frees up my search button for more functionality. If I set revoco to "auto", it returns the functionality of the wheel-click, but that is now redundant, since whatever you actually map it to is automatically mapped to L+R Click.

I would love to have an option in revoco to turn off middle-click (as in "manual" mode) while still allowing "auto" functionality. Maybe even a "hybrid" mode, with switching between "auto" (speed sensitive) and "free" modes. (I have already emailed the author this request.)

Thanks for responding to people's questions. For the revoco, what you propose could technically be done with btnx. There would still be an extra middle click, but it would be possible to program btnx to change revoco settings on the fly with it. Let me know what the author has to say about your request.

daou
November 25th, 2007, 06:18 AM
Duke;3834638']Hello, I have a MX Revolution, and my Thumb Up and Down buttons don't seem to work at all, the others respond fine, but these two aren't working.

I'm on Gutsy, btw.

Make sure your xorg.conf InputSection looks like the recommended one.

daou
November 25th, 2007, 06:19 AM
Here's an ambitious project someone could dive into:
Make a graphical key-picker.

Make a bit-mapped picture something like the KvKbd (https://wiki.ubuntu.com/GutsyGibbon/Tribe5/Kubuntu?action=AttachFile&do=get&target=kvkbd2.png).
Instead of entering keystrokes, it would be set up to input keycodes to btnx-config.

It's out of my league, but would make the process simpler for the novice to grasp.

I actually thought about this before. It would take a considerable amount of time to implement, however. If anyone feels comfortable coding and wants to do this (or any other new functionality for btnx), let me know first. I will be able to give some pointers.

daou
November 25th, 2007, 06:23 AM
I got tired of having to look up all of the button configurations from btnx 0.2.x every time I had to start from scratch, so here they are in abbreviated form.

I hope this helps, and I suggest that daou should probably link this post in post #1 of this thread.

I will.

daou
November 25th, 2007, 06:28 AM
It does seem that turning the mouse off results in all settings going back to some default. If the mouse is left on, however, its fine. Is this a known bug?

It's likely that btnx quits when your mouse disappears from the system. Maybe there is a problem with the hotplugging functionality if it doesn't start up again. You can check you System Monitor to see if btnx closes after turning off the mouse. Then check if it reappears when you turn it on.

daou
November 25th, 2007, 06:29 AM
hi
http://images2.hiboox.com/vignettes/4707/qr3lxzlq.png (http://www.hiboox.com/lang-fr/image.php?img=qr3lxzlq.png)
this picture explains the bug I have ;) when I click on the buttons shown it acts like a left click or a right click
Is there a fix for this? thanks
edit : it's not a "left click", it's a "middle click" (picture)

Have you tried editing your xorg.conf file like recommended in the manual?

[S]Duke
November 25th, 2007, 06:30 AM
I did it through just installing btnx and btnx-config, what exactly should I look for?

(Yes, I configured the buttons, all work except the two side button ones)

daou
November 25th, 2007, 06:31 AM
Okay... forgive me for not seeing this in here, but searching didn't find me very much. I'm looking to use btnx as part of my solution to get vent working for me. Admittedly I don't even have Ubuntu installed anymore, but I am looking(desperately) to change that. So here's what I'm wondering. Can btnx send these keystrokes directly to a program? IE: Bind my mouses 4th button to ] or something, and have that be echo'd straight to a non-focused window? If not I think I've got another solution using btnx, x2vnc, and ventriloctrl. But it would be nice if I could slim it down a bit.

btnx cannot send the events to specific windows only. If you know how to program, you could do it by including some X11 library functions to btnx.

daou
November 25th, 2007, 06:33 AM
Duke;3834910']I did it through just installing btnx and btnx-config, what exactly should I look for?

(Yes, I configured the buttons, all work except the two side button ones)

I'm referring to the reference InputSection given in the troubleshooting section of the btnx manual. Look for section 9.2.1 here (http://www.ollisalonen.com/btnx/man/btnx-manual.html#AEN790). Edit your xorg.conf file like described in that section, then restart your X session. It might help.

[S]Duke
November 25th, 2007, 06:51 AM
I tried to match it as much as possible, and got it looking like this:

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "no"
EndSection

However, now none of the buttons on the "thumb" part of the mouse. Before, it was everything except the two thumb buttons, but now the wheel has gone down as well.

daou
November 25th, 2007, 07:00 AM
Duke;3834976']I tried to match it as much as possible, and got it looking like this:

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "no"
EndSection

However, now none of the buttons on the "thumb" part of the mouse. Before, it was everything except the two thumb buttons, but now the wheel has gone down as well.

Try changing the Device to "/dev/psaux"

[S]Duke
November 25th, 2007, 07:13 AM
That seems to make it work.

I have another question though, it seems commands are a little limited for me. For example, KEY_VOLUME(UP or DOWN) doesn't seem to work, no matter what key I put it on. Any idea what may be causing this?

daou
November 25th, 2007, 07:33 AM
Duke;3835043']That seems to make it work.

I have another question though, it seems commands are a little limited for me. For example, KEY_VOLUME(UP or DOWN) doesn't seem to work, no matter what key I put it on. Any idea what may be causing this?

This is dependent on the window manager. It might not handle those keys correctly. But you can get around it. In GNOME (Ubuntu), for example, you can define a keyboard shortcut (System->Prefs->Kbd Shortcuts) for changing volume. Then make btnx send the same keyboard shortcut.

[S]Duke
November 25th, 2007, 07:43 AM
Would there be any wya to edit those in Thunar (XFCE)??

daou
November 25th, 2007, 07:52 AM
Duke;3835116']Would there be any wya to edit those in Thunar (XFCE)??
I haven't used XFCE much. Check their manuals.

francois12
November 25th, 2007, 03:17 PM
Have you tried editing your xorg.conf file like recommended in the manual?

thanks a lot
that's working great

eamann
November 25th, 2007, 03:45 PM
Hello!

I need to buy a cordless mouse for my Dell Inspiron 1520 laptop, with a dual boot XP / Ubuntu.

From what I have read, the Logitech VX Revolution gets the highest ratings among laptop mice. Can anyone tell me if all its seven button functions work "out of the box" in Ubuntu 7.10? If not, is it easy to configure the buttons in btnx (I am not yet very competent at programming).

Thanks in advance for your suggestions!

MustNotSleep
November 25th, 2007, 08:36 PM
Hello!

I need to buy a cordless mouse for my Dell Inspiron 1520 laptop, with a dual boot XP / Ubuntu.

From what I have read, the Logitech VX Revolution gets the highest ratings among laptop mice. Can anyone tell me if all its seven button functions work "out of the box" in Ubuntu 7.10? If not, is it easy to configure the buttons in btnx (I am not yet very competent at programming).

Thanks in advance for your suggestions!
I'm not that impressed with the VX Revolution, TBH, despite it being my first wireless and laser mouse. I bought it because it seemed like the best choice at the moment, but it's far from perfect, and it's quite expensive.

Most importantly the middle click is a bitch to press. You really have to use your arm muscles to press down on it, and it gets a challenge to middle click most of the times (especially links in a browser and such) because the scroll wheel will undoubtedly scroll up or down from the sheer pressure, making you miss the link. After a few times, this gets frustrating, and you'll probably end up plain CTRL clicking on the URL instead. Of course, with btnx, you could always map the middle click to whatever other button you want.

Those issues aside, the mouse was a breeze to setup with btnx. Make sure to install btnx-config as well. Out of the box (without btnx) you'll only have use of left, middle, right, wheel and thumb buttons (that dual as left and right buttons). For everything else, you'll need to configure it in btnx. So in the end, all buttons are functional and you can map them to whatever command you want.

I'm quite happy with the current setup, except for one thing: despite mapping the thumb buttons to back and forward, the normal left and right clicks are still associated with them. So when I click forward in Firefox, the right-click menu is displayed on the page. This is pretty annoying, and must be some weird Xorg.conf thing. Someone figure it out yet?

On a sidenote, what's the deal with Logitech making mice without a middle-click (I'm looking at you VX Nano!) or with a crippled middle-click (like the VX Rev)? Don't these people know how essential the middle-click has become in people's lives, and that they can't just remove it to force some weird fast scroll mode instead. The fast scroll is great, once you get used to it, but I must rather prefer having the original middle click. Leave my mouse wheel alone, damnit!

The VX Nano is a fine, fine mouse. Had it had a middle-click it would be my choice over the VX Rev. That damn nano USB receiver is just mind-blowingly small... And I don't need all these buttons, like zoom, search, side scroll, etc... What's the deal with side scroll anyways? It's so damn inconvenient...

OK, I'm done... :)

daou
November 26th, 2007, 05:24 AM
I'm quite happy with the current setup, except for one thing: despite mapping the thumb buttons to back and forward, the normal left and right clicks are still associated with them. So when I click forward in Firefox, the right-click menu is displayed on the page. This is pretty annoying, and must be some weird Xorg.conf thing. Someone figure it out yet?


Sounds like the same problem MX Revolution Gutsy users have had. Editing the xorg.conf InputSection seems to have fixed it for them.
Check the btnx manual section 9.2.1

most important parts are the Device = "/dev/psaux" and Protocol = "auto"

blazoner
November 26th, 2007, 09:49 AM
Hello!

I need to buy a cordless mouse for my Dell Inspiron 1520 laptop, with a dual boot XP / Ubuntu.

From what I have read, the Logitech VX Revolution gets the highest ratings among laptop mice. Can anyone tell me if all its seven button functions work "out of the box" in Ubuntu 7.10? If not, is it easy to configure the buttons in btnx (I am not yet very competent at programming).

Thanks in advance for your suggestions!
"Out of the box" functionality in Ubuntu is a bare minimum, fortunately, btnx and btnx-config are fairly simple to use. Unfortunately, this does mean you have to edit your xorg.conf file manually in order to make sure everything works as it should. (Check out the troubleshooting section in the btnx manual: http://www.ollisalonen.com/btnx/man )


The VX Revolution and the VX Nano both share the hyperscroll wheel with the MX Revolution. To get this working in Ubuntu, we use revoco (now included in btnx-config). This has a side effect of causing potential difficulties with the wheel button press.
To avoid this, I set my xorg.conf up to emulate a 3 button mouse, allowing me to get a middle click by clicking with L+R buttons. For me this works great.

Here is a copy of my working xorg.conf mouse section.Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/psaux"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "true"
EndSection In my case, I only changed 3 settings:

Option "Device" "/dev/psaux"
Option "Protocol" "auto"
Option "Emulate3Buttons" "true"


If you have problems getting Windoze to function with your Logitech mouse the same way that you have it set up in btnx, check out uberOptions (http://www.mstarmetro.net/~rlowens/uberOptions/).

*Currently "Emulate3Buttons" is not available under Windoze, but if you are virtualizing Windoze (At least using VirtualBox), it's all run by the Xserver anyways.

eamann
November 26th, 2007, 02:06 PM
Thank you all for your comments!

In the light of what you say I think I will opt for a less complex and cheaper mouse (I'm not sure that I would actually use all those seven buttons anyway).

Any suggestions as to what I should buy?

daou
November 26th, 2007, 02:35 PM
Thank you all for your comments!

In the light of what you say I think I will opt for a less complex and cheaper mouse (I'm not sure that I would actually use all those seven buttons anyway).

Any suggestions as to what I should buy?

If you aren't planning on buying a "complex" mouse, then the best tip I can give is to try out the different mice in your hand. Laptop (small) mice are often too small to hold comfortably, so make sure your hand is happy with what you buy.

atlas95
November 28th, 2007, 04:12 PM
Hello!
I have add the udev rules, those:

BUS=="usb", SYSFS{idVendor}=="046d", SYSFS{idProduct}=="c521", ACTION=="add", RUN+="/etc/init.d/btnx start", WAIT_FOR_SYSFS="bus"
BUS=="usb", SYSFS{idVendor}=="046d", SYSFS{idProduct}=="c521", ACTION=="remove", RUN+="/etc/init.d/btnx stop"

This work after start, but i suspend my laptop often and this rules doesn't restart, after resume i must restart the btnx daemon.

Could you help me please?
Thanks

Perrako
November 28th, 2007, 10:03 PM
I've gotten btnx working fine and I'm glad for the functionality. However, I have two issues with it.

1: I have an MX Rev and I have the side thumb buttons set to ctrl-tab and ctrl-shift-tab for firefox. However, on occasion when using these (relatively frequently), it just freaks out and cycles through all the tabs really fast as if I'm still holding them down. I've set the repeat delay to 100, tried changing the shortcut to ctrl-pgup and ctrl-pgdwn, but to no avail. It's easily stopped by pressing a side-button again, but it sucks playing russian roulette whenever I want to change tabs.

2: Is there a way to control revoco with btnx commands? Seems silly just to have it as a little control panel inside btnx.

Thanks for making my MX Rev work!

daou
November 29th, 2007, 03:55 AM
I've gotten btnx working fine and I'm glad for the functionality. However, I have two issues with it.

1: I have an MX Rev and I have the side thumb buttons set to ctrl-tab and ctrl-shift-tab for firefox. However, on occasion when using these (relatively frequently), it just freaks out and cycles through all the tabs really fast as if I'm still holding them down. I've set the repeat delay to 100, tried changing the shortcut to ctrl-pgup and ctrl-pgdwn, but to no avail. It's easily stopped by pressing a side-button again, but it sucks playing russian roulette whenever I want to change tabs.

2: Is there a way to control revoco with btnx commands? Seems silly just to have it as a little control panel inside btnx.

Thanks for making my MX Rev work!

The new btnx and btnx-config v.0.4.0 include an additional option "Force immediate release" which should help with the button getting stuck down. It also supports multiple configurations, so you could have, say 2 configurations, with different revoco settings. Then you can bind a mouse button to switch those configurations on the fly, which also changes the revoco settings.

I've finished coding the new version. I need to do a little more testing and update the documentation. I can provide a download for the newest version before release, if you want to test and try the new functionality. Otherwise, it should be ready in a few days.

daou
November 29th, 2007, 10:22 AM
btnx & btnx-config 0.4.0 released. It took a little less than a "few days".

Changes:

Support for multiple configurations. You can make many configs and switch between them with the press of a mouse button.
Configuration backup/restore functionality.
A force immediate button release property that releases a button right after it is pressed. Hopefully it will fix the stuck button problem.All this required a lot of changes to the programs. Don't hesitate to report any bugs, because I'm sure I missed some.

daou
November 29th, 2007, 11:29 AM
Hello!
I have add the udev rules, those:

BUS=="usb", SYSFS{idVendor}=="046d", SYSFS{idProduct}=="c521", ACTION=="add", RUN+="/etc/init.d/btnx start", WAIT_FOR_SYSFS="bus"
BUS=="usb", SYSFS{idVendor}=="046d", SYSFS{idProduct}=="c521", ACTION=="remove", RUN+="/etc/init.d/btnx stop"

This work after start, but i suspend my laptop often and this rules doesn't restart, after resume i must restart the btnx daemon.

Could you help me please?
Thanks

Try removing the WAIT_FOR_SYSFS="bus" part (and the ',' character before it. Tell me if it works.
I'm not sure why it wouldn't start after suspend. It's something that needs to be looked at.

schierly
November 29th, 2007, 05:12 PM
I can confirm, its working on Gutsy 32bit with my
Logitech LX3 Mouse Optical (USB)

Good advise, don't forget to unable the buttons. :)

This is the perfect program and should became standard in Ubuntu.

imwheel & Co didn't work in my case.

francois12
November 29th, 2007, 06:05 PM
btnx & btnx-config 0.4.0 released. It took a little less than a "few days".

Changes:

Support for multiple configurations. You can make many configs and switch between them with the press of a mouse button.
Configuration backup/restore functionality.
A force immediate button release property that releases a button right after it is pressed. Hopefully it will fix the stuck button problem.All this required a lot of changes to the programs. Don't hesitate to report any bugs, because I'm sure I missed some.
I updated and it works like a charm
very good work
=D>

atlas95
November 30th, 2007, 06:41 AM
Try removing the WAIT_FOR_SYSFS="bus" part (and the ',' character before it. Tell me if it works.
I'm not sure why it wouldn't start after suspend. It's something that needs to be looked at.
Yes ! It is working like a charme with this modif and last btnx version !
Thanks a lot

daou
November 30th, 2007, 06:46 AM
Yes ! It is working like a charme with this modif and last btnx version !
Thanks a lot

I added the change in btnx-config 0.2.3. It fixed a problem during boot, but apparently, it creates a problem during suspend.

Note that the udev rule will always default to the original one when you save the configuration.

I might remove it in the next release. Or add some options to btnx-config to control it.

jamesford
November 30th, 2007, 06:16 PM
yay new version works great!

but any suggestion what to use the thumbpress for on the mx revo? i cant think of anything useful to assign

XVII
November 30th, 2007, 09:11 PM
Cool, so it's kind of like moust gestures for the desktop?

daou
December 1st, 2007, 03:52 AM
yay new version works great!

but any suggestion what to use the thumbpress for on the mx revo? i cant think of anything useful to assign

If you are talking about the thumb wheel press, I use it for Alt+Left mouse button. This allows you to drag windows. Another useful one is Alt+Middle mouse button which can be used for resizing windows.
The thumb buttons I usually use as Ctrl+Page up or Ctrl+Page down for moving through tabs (not just Firefox), or volume control, or anything that can be adjusted in two directions.

jamesford
December 1st, 2007, 10:04 AM
those are good suggestions!
ive been assigning KEY_RIGHT(or KEY_LEFT)+KEY_LEFTCTRL+KEYLEFTALT to the thumb back/forward buttons for rotating the compiz-fusion cube

i just noticed a little bug in the btnx-config, if u accidently type a keycode that doesent exist into the keycode field an error popup is displayed thart keeps respawning itself forever and is impossible to get rid of without killal btnx-config

kdkirsch
December 3rd, 2007, 10:02 PM
Greetings. I have two problems relating to my mouse. First, btnx will not detect my Logitech MX Revolution. Second, I am experiencing input lag. Both of these problems arose immediately after upgrading to gutsy at release time.

1) btnx: My MX revolution worked perfectly under feisty. Since upgrading to gutsy it doesn't. When I try to detect my mouse the following is detected: Vendor ID: 0x001f, Product ID: 0x001e.
$ cat /proc/bus/input/devices

I: Bus=0017 Vendor=0001 Product=0001 Version=0100
N: Name="Macintosh mouse button emulation"
P: Phys=
S: Sysfs=/class/input/input0
U: Uniq=
H: Handlers=mouse0 event0
B: EV=7
B: KEY=70000 0 0 0 0
B: REL=3

I: Bus=0011 Vendor=0001 Product=0001 Version=ab41
N: Name="AT Translated Set 2 keyboard"
P: Phys=isa0060/serio0/input0
S: Sysfs=/class/input/input1
U: Uniq=
H: Handlers=kbd event1
B: EV=120013
B: KEY=402000000 3802078f840d001 feffffdfffefffff fffffffffffffffe
B: MSC=10
B: LED=7

I: Bus=0019 Vendor=0000 Product=0002 Version=0000
N: Name="Power Button (FF)"
P: Phys=button_power/button/input0
S: Sysfs=/class/input/input3
U: Uniq=
H: Handlers=kbd event3
B: EV=3
B: KEY=10000000000000 0

I: Bus=0019 Vendor=0000 Product=0001 Version=0000
N: Name="Power Button (CM)"
P: Phys=PNP0C0C/button/input0
S: Sysfs=/class/input/input4
U: Uniq=
H: Handlers=kbd event4
B: EV=3
B: KEY=10000000000000 0

I: Bus=0006 Vendor=001f Product=001f Version=0000
N: Name="Mouseemu virtual keyboard"
P: Phys=
S: Sysfs=/class/input/input5
U: Uniq=
H: Handlers=kbd event5
B: EV=100003
B: KEY=1ffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffff

I: Bus=0006 Vendor=001f Product=001e Version=0000
N: Name="Mouseemu virtual mouse"
P: Phys=
S: Sysfs=/class/input/input6
U: Uniq=
H: Handlers=mouse2 event6
B: EV=7
B: KEY=70000 0 0 0 0
B: REL=103

I: Bus=0003 Vendor=046d Product=c51a Version=0111
N: Name="Logitech USB Receiver"
P: Phys=usb-0000:00:02.0-8/input0
S: Sysfs=/class/input/input7
U: Uniq=
H: Handlers=mouse3 event7
B: EV=7
B: KEY=ffff0000 0 0 0 0
B: REL=143

I: Bus=0003 Vendor=046d Product=c51a Version=0111
N: Name="Logitech USB Receiver"
P: Phys=usb-0000:00:02.0-8/input1
S: Sysfs=/class/input/input8
U: Uniq=
H: Handlers=kbd event8
B: EV=f
B: KEY=7fff002c3027 bf00444000000000 1 f808837c000 667bfad9415fed 8e000000000000 0
B: REL=40
B: ABS=100000000


After hours of looking I still don't know what "Mouseemu virtual mouse" is. Since this is the device being detected by btnx and because it did not exist on my feisty system this must be the cause of my problem. I would greatly appreciate anyone's help with this.

2) Input lag: If I type something (any characters, it doesn't matter), there is a delay before the mouse will respond. It can best be described as "lag" because the cursor moves where you move it after a 0.5 second delay. I hope that this will be resolved with #1 but if it in fact unrelated I would of course appreciate anyone's help resolving this problem.

Thanks in advance. Cheers!

-kdkirsch

rand0m
December 4th, 2007, 03:30 AM
Hi, I liked to thank you for implementing the "Force immediate button release" option. Works great and now I can finally use my thumb buttons in dolphin :)

daou
December 4th, 2007, 05:55 AM
Greetings. I have two problems relating to my mouse. First, btnx will not detect my Logitech MX Revolution. Second, I am experiencing input lag. Both of these problems arose immediately after upgrading to gutsy at release time.

1) btnx: My MX revolution worked perfectly under feisty. Since upgrading to gutsy it doesn't. When I try to detect my mouse the following is detected: Vendor ID: 0x001f, Product ID: 0x001e.

2) Input lag: If I type something (any characters, it doesn't matter), there is a delay before the mouse will respond. It can best be described as "lag" because the cursor moves where you move it after a 0.5 second delay. I hope that this will be resolved with #1 but if it in fact unrelated I would of course appreciate anyone's help resolving this problem.

Thanks in advance. Cheers!

-kdkirsch

Make sure your xorg.conf InputSection looks like the recommended one as described in the btnx manual's troubleshooting section 11.2.1 (links at first post). If that doesn't help, make sure mouseemu is not installed. Remove it if necessary.

daou
December 4th, 2007, 07:25 AM
those are good suggestions!
ive been assigning KEY_RIGHT(or KEY_LEFT)+KEY_LEFTCTRL+KEYLEFTALT to the thumb back/forward buttons for rotating the compiz-fusion cube

i just noticed a little bug in the btnx-config, if u accidently type a keycode that doesent exist into the keycode field an error popup is displayed thart keeps respawning itself forever and is impossible to get rid of without killal btnx-config

This bug has been in the program for a while. Thanks for reminding me about it. I'll try to get it fixed for 0.4.1.

daou
December 4th, 2007, 07:29 AM
Hi, I liked to thank you for implementing the "Force immediate button release" option. Works great and now I can finally use my thumb buttons in dolphin :)

No problem, I'm glad it fixed the problem. Although, I suspect the heart of the problem lies elsewhere. I noticed that it usually happened when the system had a high load. Perhaps some input events were lost somewhere, or it's a buffering issue.

rand0m
December 4th, 2007, 06:37 PM
For me it was pretty consistent. The buttons would get stuck probably 30-40% of the time. Sometimes I would only be browsing files, barely any load on the system at all.

kdkirsch
December 5th, 2007, 01:24 AM
Make sure your xorg.conf InputSection looks like the recommended one as described in the btnx manual's troubleshooting section 11.2.1 (links at first post). If that doesn't help, make sure mouseemu is not installed. Remove it if necessary.
Removing mouseemu solved both of my problems.

To remove mouseemu:

$ sudo apt-get remove mouseemu

btnx will then detect your MX revolution correctly.

daou
December 5th, 2007, 12:34 PM
btnx 0.4.1 released

Minor init script fixes. Upgrade if you are experiencing delays during boot after installing btnx.btnx-config 0.4.1 released

New advanced options to enable/disable btnx hot-plugging and to control the WAIT_FOR_SYSFS option.
Some new stuff for maintainers.You can now also help translate btnx-config to your language(s): btnx-config @ Launchpad (http://launchpad.net/btnx-config).

Fangs404
December 6th, 2007, 03:46 AM
I just checked to see if a new version was released, and I'm glad I did. I was running on a really old version.

I'm trying to update, though, and I'm having some problems uninstalling the old version. The version of btnx-config I have is 0.2.1. So, since your site no longer has the package up, I checked it out from the subversion repo. However, running ./configure generates "configure: error: cannot find install-sh or install.sh in config "."/config" This happens because config/install.sh links to /usr/share/automake-1.10/install-sh which I obviously don't have. So how can I uninstall my current btnx-config?

Also, how do I find out what version of btnx I have? Finding out the version of btnx-config is easy because there's the About box, but how can I find out what version of the actual extension I have?

Thanks!

daou
December 6th, 2007, 05:54 AM
I just checked to see if a new version was released, and I'm glad I did. I was running on a really old version.

I'm trying to update, though, and I'm having some problems uninstalling the old version. The version of btnx-config I have is 0.2.1. So, since your site no longer has the package up, I checked it out from the subversion repo. However, running ./configure generates "configure: error: cannot find install-sh or install.sh in config "."/config" This happens because config/install.sh links to /usr/share/automake-1.10/install-sh which I obviously don't have. So how can I uninstall my current btnx-config?

Also, how do I find out what version of btnx I have? Finding out the version of btnx-config is easy because there's the About box, but how can I find out what version of the actual extension I have?

Thanks!

If you have 0.2.1, you can install the new version on top of it without uninstalling. Some files might get left on your system if the version was <0.2.0. The scripts were links on my system and in the SVN repo until about 0.2.2 or 0.2.3, and I had to manually replace them for the releases. It is now fixed, however.

You can get the version of btnx installed by running "btnx -v". This was introduced around btnx v. 0.3.2 I think. If that doesn't work, your btnx is probably version 0.3.0 or 0.3.1, and you can install btnx v. 0.4.1 without uninstalling btnx.

In fact, you might not even want to uninstall btnx and btnx-config because v. >= 0.4.0 imports your previous configuration into the new system.

jamesford
December 6th, 2007, 10:42 AM
for upgrading should i uninstall the old versions first and is it enough to run sudo make uninstall, or are there other leftovers i should remove manually? id like to make as clean new installs as possible

Fangs404
December 6th, 2007, 11:09 AM
If you have 0.2.1, you can install the new version on top of it without uninstalling. Some files might get left on your system if the version was <0.2.0. The scripts were links on my system and in the SVN repo until about 0.2.2 or 0.2.3, and I had to manually replace them for the releases. It is now fixed, however.

You can get the version of btnx installed by running "btnx -v". This was introduced around btnx v. 0.3.2 I think. If that doesn't work, your btnx is probably version 0.3.0 or 0.3.1, and you can install btnx v. 0.4.1 without uninstalling btnx.

In fact, you might not even want to uninstall btnx and btnx-config because v. >= 0.4.0 imports your previous configuration into the new system.

Thanks much for the quick reply. :)

daou
December 6th, 2007, 11:57 AM
for upgrading should i uninstall the old versions first and is it enough to run sudo make uninstall, or are there other leftovers i should remove manually? id like to make as clean new installs as possible

uninstalling btnx-config uninstalls files in /usr/share/btnx-config, some icons files elsewhere, and the executable. uninstalling btnx removes the /etc/btnx folder (all your btnx configurations), the udev rule, the btnx executable, and the init script. Doing both of these removes every trace of btnx from your system. No manual removal necessary.

Uninstalling before upgrading is not necessary. And I've coded it so that old configuration files can usually be imported to the new system. This means you won't lose any configuration you have done for the mouse. If it is necessary to make an uninstall before upgrade, I will update the notes before the installation instructions in the first post of the thread.

jamesford
December 6th, 2007, 01:03 PM
thanks for that

how about adding an rss feed to your website, easier to keep track of new releases that way :)

daou
December 6th, 2007, 01:14 PM
thanks for that

how about adding an rss feed to your website, easier to keep track of new releases that way :)

A good idea. I was thinking about that before. I've never created an RSS feed. Is there a lot involved in doing it, or does it just involve adding a couple of ready lines the the HTML documents?

jamesford
December 6th, 2007, 02:22 PM
i wish i could tell u but ive never made any either. theres plently of guides on google though such as http://www.petefreitag.com/item/465.cfm

daou
December 6th, 2007, 03:04 PM
i wish i could tell u but ive never made any either. theres plently of guides on google though such as http://www.petefreitag.com/item/465.cfm

Ok, there is now an RSS feed at the btnx webpage.

I tried finding some tools that could automate the job. There was an apache module that automatically indexes folders and makes RSS feeds, but no documentation anywhere. Another program apparently could make HTML/RSS from ChangeLogs which would have been nice, but wasn't quite what I was looking for (also documentation in Japanese).

I found a python library that makes generating them a bit easier. But seems to be a lack of a tool that automates the job... for example, parsing an SVN ChangeLog and updating RSS feeds automatically.

jamesford
December 6th, 2007, 03:13 PM
hey that looks nice *adds it to liferea* :)

edit: just did a clean uninstall as described above and installed 0.4.1, seems to work just fine however i now have 2 instances of btnx in the system monitor one with nice 0 and one with nice -2

daou
December 6th, 2007, 07:25 PM
hey that looks nice *adds it to liferea* :)

edit: just did a clean uninstall as described above and installed 0.4.1, seems to work just fine however i now have 2 instances of btnx in the system monitor one with nice 0 and one with nice -2

It's possible the old btnx process is still running. The newer version of btnx should not allow multiple btnx processes running, but its possible the old version did not register itself to the PID file.

You can consider it a bug if you still have 2 btnx processes running after rebooting.

jamesford
December 6th, 2007, 08:57 PM
i did reboot after uninstalling and installing the new version (i wanted to see if the btnx loading error was gone - which it was)


edit:just did another reboot to confirm. still 2x btnx running :/

francois12
December 8th, 2007, 08:37 AM
edit:just did another reboot to confirm. still 2x btnx running :/

the same here

root@francois-desktop:/var/run# ps -fe | grep btnx
root 4316 1 0 13:24 ? 00:00:00 /usr/sbin/btnx -b
root 6014 1 0 13:24 ? 00:00:00 /usr/sbin/btnx -b

root@francois-desktop:/var/run# ls | grep btnx | xargs cat
6014

root@francois-desktop:/etc/btnx# cat /etc/udev/rules.d/99-btnx.rules
BUS=="usb", SYSFS{idVendor}=="046d", SYSFS{idProduct}=="c51a", ACTION=="add", RUN+="/etc/init.d/btnx start"
BUS=="usb", SYSFS{idVendor}=="046d", SYSFS{idProduct}=="c51a", ACTION=="remove",
with two process running :
root@francois-desktop:/etc/btnx# /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
sed: impossible de lire /var/run/btnx.pid: Aucun fichier ou répertoire de ce type
btnx successfully stopped
root@francois-desktop:/etc/btnx# /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
btnx successfully stopped
root@francois-desktop:/etc/btnx# /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
btnx successfully stopped
etc.. Always one process running



my 2 cents : I think it's caused by the udev rules and the startup script not detecting other btnx running. or I don't know but Daou does :)

daou
December 8th, 2007, 09:22 AM
the same here
with two process running :

my 2 cents : I think it's caused by the udev rules and the startup script not detecting other btnx running. or I don't know but Daou does :)

I'm not getting this problem. I have one btnx process running at a time. Is it a problem? Are you getting double events (both btnx's catch a button event and send keyboard combos)?

This is because of the udev rule, yes. The problem is with the MX Revolution mouse, because it registers itself to the system as 2 devices (one for the mouse, another just for the search button). udev runs the rule twice, and tries to start btnx twice. This is why I made the PID file, and forced btnx to kill all old processes found in that file. Then again, I'm not sure why one process isn't killing the other one.

Can you make sure it's not a zombie process?

I'm just not sure why I'm not able to reproduce this bug.

francois12
December 8th, 2007, 09:53 AM
I'm not getting this problem. I have one btnx process running at a time. Is it a problem? Are you getting double events (both btnx's catch a button event and send keyboard combos)?

This is because of the udev rule, yes. The problem is with the MX Revolution mouse, because it registers itself to the system as 2 devices (one for the mouse, another just for the search button). udev runs the rule twice, and tries to start btnx twice. This is why I made the PID file, and forced btnx to kill all old processes found in that file. Then again, I'm not sure why one process isn't killing the other one.

Can you make sure it's not a zombie process?

I'm just not sure why I'm not able to reproduce this bug.

Yes, I did a reboot of my computer and a button event was catch 3 times (before it was 2) and only 2 btnx are running :


francois@francois-desktop:~$ ps -fe | grep btnx
root 4482 1 0 14:37 ? 00:00:00 /usr/sbin/btnx -b
root 6102 1 0 14:37 ? 00:00:00 /usr/sbin/btnx -b
francois 6597 6579 0 14:38 pts/0 00:00:00 grep btnx

francois@francois-desktop:~$ sudo /etc/init.d/btnx stop
[sudo] password for francois:
Stopping btnx : Button Extension - mouse button rerouter daemon
sed: impossible de lire /var/run/btnx.pid: Aucun fichier ou répertoire de ce type
btnx successfully stopped

francois@francois-desktop:~$ ps -fe | grep btnx
root 4482 1 0 14:37 ? 00:00:00 /usr/sbin/btnx -b
francois 6714 6579 0 14:41 pts/0 00:00:00 grep btnx

A button event is catched one time

francois@francois-desktop:~$ sudo /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
btnx successfully stopped

francois@francois-desktop:~$ ps -fe | grep btnx
root 4482 1 0 14:37 ? 00:00:00 /usr/sbin/btnx -b
francois 6738 6579 0 14:42 pts/0 00:00:00 grep btnx



A button event is catched one time
sudo /etc/init.d/btnx stop is not able to kill the other process running (4482) because there is no PID file for it (ls /var/run | grep btnx shows nothing)

daou
December 8th, 2007, 10:09 AM
Yes, I did a reboot of my computer and a button event was catch 3 times (before it was 2) and only 2 btnx are running :

I did a couple of reboots, still only one process for me. You are running 0.4.1?

You can try commenting out "do_stop" at lines 136 and 183 in the file "/etc/init.d/btnx"

If nothing seems to help, try disabling hot-plugging in the advanced settings tab of btnx-config.

daou
December 8th, 2007, 10:41 AM
francois12 and jamesford: could you test the new btnx in the SVN repository. I think I found and fixed the bug, but I can't test it myself.

If you have subversion installed, make a directory, check out the latest source from SVN, build btnx, and install it.

$ mkdir btnx-svn
$ cd btnx-svn
$ svn co http://svn.ollisalonen.com/btnx/trunk
$ cd trunk
$ make
$ sudo make install
Then test if it fixes the problem. I will release a new btnx version if it does. Thanks a lot for your time.

francois12
December 8th, 2007, 10:47 AM
francois12 and jamesford: could you test the new btnx in the SVN repository. I think I found and fixed the bug, but I can't test it myself.

If you have subversion installed, make a directory, check out the latest source from SVN, build btnx, and install it.

$ mkdir btnx-svn
$ cd btnx-svn
$ svn co http://svn.ollisalonen.com/btnx/trunk
$ cd trunk
$ make
$ sudo make install
Then test if it fixes the problem. I will release a new btnx version if it does. Thanks a lot for your time.

:guitar: that's working great, thanks
how did you fix this?
keep up the good work man

daou
December 8th, 2007, 10:54 AM
:guitar: that's working great, thanks
how did you fix this?
keep up the good work man

Just removed one line from the source code ;) . It was my mistake originally, but I didn't catch it because somehow it didn't cause a problem on my system.

But thanks, v.0.4.2 will be out soon.

francois12
December 8th, 2007, 11:02 AM
Just removed one line from the source code ;) . It was my mistake originally, but I didn't catch it because somehow it didn't cause a problem on my system.

But thanks, v.0.4.2 will be out soon.

ok, as I see the btnx.pid file shows now two pid's :
francois@francois-desktop:/var/run$ cat btnx.pid
7554 7596

something annoying is always here :
francois@francois-desktop:/var/run$ sudo /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
/sbin/start-stop-daemon: warning: failed to kill 7554: No such process
sed: impossible de lire /var/run/btnx.pid: Aucun fichier ou répertoire de ce type
btnx successfully stopped
pid file is gone, the process is stopped
francois@francois-desktop:/var/run$ sudo /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
btnx successfully stopped
francois@francois-desktop:/var/run$ sudo /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
btnx successfully stopped
francois@francois-desktop:/var/run$ sudo /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
btnx successfully stopped ETC..

daou
December 8th, 2007, 11:06 AM
ok, as I see the btnx.pid file shows now two pid's :
something annoying is always here :

Yes, it's leftovers from the old way the PID file was handled. It doesn't affect functionality, so I'll try to clean it up later.

daou
December 8th, 2007, 11:12 AM
If you want, you can file a bug at Launchpad: http://launchpad.net/btnx

This way I will remember to fix it. Bug reports have a habit of getting lost in this thread, because it's huge.

francois12
December 8th, 2007, 11:17 AM
If you want, you can file a bug at Launchpad: http://launchpad.net/btnx

This way I will remember to fix it. Bug reports have a habit of getting lost in this thread, because it's huge.
ok I will if I find other bugs

John.Michael.Kane
December 8th, 2007, 11:56 AM
daou are there any plans to make .deb's avilable download? Also thoughts to eventually having btnx installable through synaptic?

daou
December 8th, 2007, 12:00 PM
daou are there any plans to make .deb's avilable download? Also thoughts to eventually having btnx installable through synaptic?

I decided from the beginning not to package btnx myself. It would bog me down with maintaining the packages instead of developing and fixing bugs.

btnx was submitted to the Ubuntu wishlist a few months ago: https://bugs.launchpad.net/ubuntu/+bug/146160
It was recently changed to confirmed, and might be put into Ubuntu's repositories soon. I can't say for sure, however. I'm not responsible for it. But let's hope for the best.

jamesford
December 8th, 2007, 05:26 PM
just confirming that the 2x btnx bug is gone :)
well done

francois12
December 9th, 2007, 10:11 AM
just confirming that the 2x btnx bug is gone :)
well done

bug always here (i don't know why) and reported in launchpad.net/btnx

daou
December 9th, 2007, 10:16 AM
bug always here (i don't know why) and reported in launchpad.net/btnx
I left a question there regarding the bug.

francois12
December 9th, 2007, 10:48 AM
I left a question there regarding the bug.

did you change something from btnx-svn rev103 to btnx-0.4.2 ?

daou
December 9th, 2007, 11:01 AM
did you change something from btnx-svn rev103 to btnx-0.4.2 ?

No change... but there is a new SVN revision that might help with the bug.

francois12
December 9th, 2007, 11:38 AM
No change... but there is a new SVN revision that might help with the bug.

it works, i rebooted 2 times in order to be sure.. I hope it'll be ok for good
see launchpad

biohzrd
December 9th, 2007, 11:53 AM
Hello all,

First, great work on this program and thanks for the time and effort.

Second, I have been having difficulties with getting the new version of btnx and btnx-config to work properly. I had btnx-0.2.14 and btnx-config-0.2.14 (I THINK) installed previously, and went to upgrade making sure to "make uninstall" first on each one. The make uninstall for btnx-config was still running after about 5 minutes, so I canceled it and attempted to install 0.4.1 overtop. Needless to say, 0.4.1 would only work for operating the scroll wheel with revco, and allowing me to change the search button to middle click. No other programmed functions would work such as the thumb wheel, back and forward buttons, etc.

Now I have done a make uninstall on both btnx and btnx-config version 0.4.1, and am still left with the following:

cat /proc/bus/input/devices
I: Bus=0000 Vendor=b216 Product=0001 Version=0000
N: Name="btnx mouse"
P: Phys=
S: Sysfs=/class/input/input12
U: Uniq=
H: Handlers=mouse6 event12
B: EV=7
B: KEY=ffffffff ffffffff ffffffff 0 0 0 0 0 0 0 0
B: REL=103

I: Bus=0000 Vendor=b216 Product=0002 Version=0000
N: Name="btnx keyboard"
P: Phys=
S: Sysfs=/class/input/input11
U: Uniq=
H: Handlers=kbd event11
B: EV=100003
B: KEY=7fffffff ffffffff ffffffff ffffffff ffffffff 0 0 0 ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff



I think these are leftover from the previous btnx install, and I am not exactly sure where to go from here. I have attempted to install/uninstall 0.4.1 many times, and btnx-config-0.2.14 is no longer available to attempt to make uninstall from within it.

Please help, thank you.

daou
December 9th, 2007, 06:49 PM
Hello all,

First, great work on this program and thanks for the time and effort.

Second, I have been having difficulties with getting the new version of btnx and btnx-config to work properly. I had btnx-0.2.14 and btnx-config-0.2.14 (I THINK) installed previously, and went to upgrade making sure to "make uninstall" first on each one. The make uninstall for btnx-config was still running after about 5 minutes, so I canceled it and attempted to install 0.4.1 overtop. Needless to say, 0.4.1 would only work for operating the scroll wheel with revco, and allowing me to change the search button to middle click. No other programmed functions would work such as the thumb wheel, back and forward buttons, etc.

Now I have done a make uninstall on both btnx and btnx-config version 0.4.1, and am still left with the following:

cat /proc/bus/input/devices
I: Bus=0000 Vendor=b216 Product=0001 Version=0000
N: Name="btnx mouse"
P: Phys=
S: Sysfs=/class/input/input12
U: Uniq=
H: Handlers=mouse6 event12
B: EV=7
B: KEY=ffffffff ffffffff ffffffff 0 0 0 0 0 0 0 0
B: REL=103

I: Bus=0000 Vendor=b216 Product=0002 Version=0000
N: Name="btnx keyboard"
P: Phys=
S: Sysfs=/class/input/input11
U: Uniq=
H: Handlers=kbd event11
B: EV=100003
B: KEY=7fffffff ffffffff ffffffff ffffffff ffffffff 0 0 0 ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff

I think these are leftover from the previous btnx install, and I am not exactly sure where to go from here. I have attempted to install/uninstall 0.4.1 many times, and btnx-config-0.2.14 is no longer available to attempt to make uninstall from within it.

Please help, thank you.

Are you sure you had btnx-config installed? The last old-branch btnx was version 0.2.14, and btnx-config didn't yet exist. Plus, btnx-config never worked with this version.
The last 0.2.x version of btnx-config was 0.2.3 or 0.2.4.

You can download btnx-0.2.14 again and use that package to uninstall. http://www.ollisalonen.com/btnx/old.html

Then install btnx-0.4.3 and btnx-config-0.4.1.

Also, the detection problem could be related to your xorg.conf settings. Check the btnx manual section 12.2.1 for good InputDevice section values.

Also, if you have removed btnx from your system, the 'cat /proc/bus/input/devices' btnx devices should be gone at least after you reboot your computer. Unless you have reinstalled and run btnx again.

lazork
December 10th, 2007, 06:36 AM
I've already configured the left/right scroll buttons and so far they seem to work fine, but I'm having a little trouble getting the thumb buttons to work.
I've already changed my xorg.conf file setting Protocol to "auto" and Device to "/dev/psaux".

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/psaux"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "no"
Option "Buttons" "3"
EndSection
That prevented one of the buttons to act as a right click but now both buttons behave like middle click (actually, it's not exactly like middle click, but very similar).
Any suggestions on how to solve this?

daou
December 10th, 2007, 07:09 AM
I've already configured the left/right scroll buttons and so far they seem to work fine, but I'm having a little trouble getting the thumb buttons to work.
I've already changed my xorg.conf file setting Protocol to "auto" and Device to "/dev/psaux".

That prevented one of the buttons to act as a right click but now both buttons behave like middle click (actually, it's not exactly like middle click, but very similar).
Any suggestions on how to solve this?

You can also try setting device to "/dev/input/mice".
Do the buttons behave like this even when btnx is not running?

lazork
December 10th, 2007, 12:46 PM
You can also try setting device to "/dev/input/mice".
Do the buttons behave like this even when btnx is not running?

The device was already set to "/dev/input/mice" and it was me who changed it to "/dev/psaux" hoping that would have helped (I had read it in another post of yours concerning the same problem).
Anyway, the buttons behave like that even if btnx is not running, so it's not really its fault, but still, this doesn't allow me to use btnx properly.

BTW, your program and your support are really appreciated, keep it up! ;)

daou
December 10th, 2007, 01:22 PM
The device was already set to "/dev/input/mice" and it was me who changed it to "/dev/psaux" hoping that would have helped (I had read it in another post of yours concerning the same problem).
Anyway, the buttons behave like that even if btnx is not running, so it's not really its fault, but still, this doesn't allow me to use btnx properly.

BTW, your program and your support are really appreciated, keep it up! ;)

No problem. Glad it's of use to other people.

Yes, "/dev/psaux" usually does the trick, but some people have gotten it to work with "/dev/input/mice".

Do you have any settings or prorgams from previous efforts to get the mouse buttons working? Xmodmaps, mouseemu, udev rules?
Post the output of 'cat /proc/bus/input/devices'. Oh, and what distro/version are you using?

lazork
December 10th, 2007, 03:46 PM
No, btnx is my first attempt to get my mouse fully working. But I have to say that I have recently changed my mouse (I used to have an old logitech with no scroll-wheel, no extra buttons, no nothing)

Output of "cat /proc/bus/input/devices":
I: Bus=0017 Vendor=0001 Product=0001 Version=0100
N: Name="Macintosh mouse button emulation"
P: Phys=
S: Sysfs=/class/input/input0
U: Uniq=
H: Handlers=mouse0 event0
B: EV=7
B: KEY=70000 0 0 0 0 0 0 0 0
B: REL=3

I: Bus=0011 Vendor=0001 Product=0001 Version=ab41
N: Name="AT Translated Set 2 keyboard"
P: Phys=isa0060/serio0/input0
S: Sysfs=/class/input/input1
U: Uniq=
H: Handlers=kbd event1
B: EV=120013
B: KEY=4 2000000 3802078 f840d001 feffffdf ffefffff ffffffff fffffffe
B: MSC=10
B: LED=7

I: Bus=0003 Vendor=046d Product=c049 Version=0111
N: Name="Logitech USB Gaming Mouse"
P: Phys=usb-0000:00:1d.2-1/input0
S: Sysfs=/class/input/input2
U: Uniq=
H: Handlers=mouse1 event2
B: EV=7
B: KEY=ffff0000 0 0 0 0 0 0 0 0
B: REL=143

I: Bus=0010 Vendor=001f Product=0001 Version=0100
N: Name="PC Speaker"
P: Phys=isa0061/input0
S: Sysfs=/class/input/input3
U: Uniq=
H: Handlers=kbd event3
B: EV=40001
B: SND=6

I: Bus=0019 Vendor=0000 Product=0002 Version=0000
N: Name="Power Button (FF)"
P: Phys=button_power/button/input0
S: Sysfs=/class/input/input6
U: Uniq=
H: Handlers=kbd event6
B: EV=3
B: KEY=100000 0 0 0

I: Bus=0019 Vendor=0000 Product=0003 Version=0000
N: Name="Sleep Button (CM)"
P: Phys=PNP0C0E/button/input0
S: Sysfs=/class/input/input7
U: Uniq=
H: Handlers=kbd event7
B: EV=3
B: KEY=4000 0 0 0 0

I: Bus=0000 Vendor=b216 Product=0002 Version=0000
N: Name="btnx keyboard"
P: Phys=
S: Sysfs=/class/input/input12
U: Uniq=
H: Handlers=kbd event4
B: EV=100003
B: KEY=7fffffff ffffffff ffffffff ffffffff ffffffff 0 0 0 ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff

I: Bus=0000 Vendor=b216 Product=0001 Version=0000
N: Name="btnx mouse"
P: Phys=
S: Sysfs=/class/input/input13
U: Uniq=
H: Handlers=mouse2 event5
B: EV=7
B: KEY=ffffffff ffffffff ffffffff 0 0 0 0 0 0 0 0
B: REL=103


I'm on Ubuntu gutsy

malk_dvorak
December 10th, 2007, 05:08 PM
ive been wondering for ages where that empty file called '2' in my homedir comes from, and it keeps reappearing.

now ive found out it that file is generated every time btnx is restarted either via gui or sudo /etc/init.d/btnx restart

not a big deal but if it could be removed from the code it would be nice :)

francois12
December 10th, 2007, 07:03 PM
ive been wondering for ages where that empty file called '2' in my homedir comes from, and it keeps reappearing.

now ive found out it that file is generated every time btnx is restarted either via gui or sudo /etc/init.d/btnx restart

not a big deal but if it could be removed from the code it would be nice :)
:-O thanks I was wondering each time where that came from!!

daou
December 10th, 2007, 07:17 PM
ive been wondering for ages where that empty file called '2' in my homedir comes from, and it keeps reappearing.

now ive found out it that file is generated every time btnx is restarted either via gui or sudo /etc/init.d/btnx restart

not a big deal but if it could be removed from the code it would be nice :)

I noticed the file too, but i just thought it was leftovers from developing and debugging something. It took me a while to figure out where the problem was, it was quite subtle:

init script, when restarting btnx:
echo "Restarting $NAME :" "$DESC" &>2should have been
echo "Restarting $NAME :" "$DESC" >&2:P Interesting side-effect. Will be fixed with the next release.

Flying-Penguin
December 12th, 2007, 02:01 AM
Hello Daou, I have just installed your program as I thought it would finly let me do what I am trying to do.. but it was unable because of what I felt was a slight oversite ><.

I want to bind one of my mouse buttons to Control_L or any/all CTRL. However your program lists CTRL as a modifier but doesn't list it in the keys list.

is there anyway I can map MB4 (as I call it or large thumb button, the normal back button) to CTRL?

blazoner
December 12th, 2007, 02:52 AM
Hello Daou, I have just installed your program as I thought it would finly let me do what I am trying to do.. but it was unable because of what I felt was a slight oversite ><.

I want to bind one of my mouse buttons to Control_L or any/all CTRL. However your program lists CTRL as a modifier but doesn't list it in the keys list.

is there anyway I can map MB4 (as I call it or large thumb button, the normal back button) to CTRL?

Select the button you want to modify, then select the modifier keys underneath it.

daou
December 12th, 2007, 01:30 PM
btnx 0.4.4 fixes the "2" file bug.
btnx-config 0.4.3 includes German and Dutch translations completed at Launchpad.

biohzrd
December 13th, 2007, 01:53 PM
I'm not exactly sure that this is a problem with btnx, or with my particular Ubuntu config. I am having a problem getting the BTN_BACK and BTN_FORWARD items to work with my MX Revolution's thumb back/forward buttons. When I set either to BTN_FORWARD and BTN_BACK, the function does not work in Firefox. In fact, I get a "The URL is not valid and could not be loaded" when I use BTN_FORWARD. When I set them to KEY_RIGHT + KEY_LEFTALT and KEY_RIGHT + KEY_RIGHTALT, they work properly as back/forward buttons. Is there a way I can figure out what the culprit is or should I just stick to using my current config that works?

Also, I noticed that when I manually type in BTN_BACK or any other item in a text box, then click another tab (the "Configurations" tab for example), the value of the text box goes back to what it was, as if I did not type anything into it. It appears that the values are not saved unless I first click in another text field in the same tab before switching tabs.

This is for v 0.4.4

daou
December 13th, 2007, 02:28 PM
I'm not exactly sure that this is a problem with btnx, or with my particular Ubuntu config. I am having a problem getting the BTN_BACK and BTN_FORWARD items to work with my MX Revolution's thumb back/forward buttons. When I set either to BTN_FORWARD and BTN_BACK, the function does not work in Firefox. In fact, I get a "The URL is not valid and could not be loaded" when I use BTN_FORWARD. When I set them to KEY_RIGHT + KEY_LEFTALT and KEY_RIGHT + KEY_RIGHTALT, they work properly as back/forward buttons. Is there a way I can figure out what the culprit is or should I just stick to using my current config that works?

Also, I noticed that when I manually type in BTN_BACK or any other item in a text box, then click another tab (the "Configurations" tab for example), the value of the text box goes back to what it was, as if I did not type anything into it. It appears that the values are not saved unless I first click in another text field in the same tab before switching tabs.

This is for v 0.4.4

You should use the KEY_ALT + arrow keys, it's what I use. Applications and window managers do not always handle the BTN_* buttons correctly, it's better to use common keyboard combos. Note that key_alt+left or right works in a lot of applications for forward and backward functionality.

The bug is known, but is a low priority task. I will fix it when I have more spare time.

biohzrd
December 13th, 2007, 02:51 PM
OK, thanks for the input. Should I also not use BTN_MIDDLE for the Search button (that I have configured as a middle mouse button)? I don't see any other alternatives and, as it is, if I middle click on a link in Firefox and miss (which happens often haha) I get the error "The URL is not valid and could not be loaded"

-I just enabled autoscroll in Fx, and no longer get that message...it still seems like odd behavior, but then again, I am extremely new to Ubuntu/Linux.

dondad
December 13th, 2007, 02:56 PM
The program is great. Gives me the control that I want. One strange issue that occurs periodically (usually in Firefox, not sure if FF issue or mouse or...) is that the buttons will seem to do multiple actions (ie, I have a button set up to close a tab, and it closes all of them and after that the wheel acts as a zoom, not scroll) after which whenever I click in any box, I get a continuous string of W's that I can't stop. I can't get to btnx to restart it because I can't type the password with the W's going. If I restart x it clears, and I found that I could stop the w's by pulling out the mouse usb receiver and plugging it back in. This makes so that the continuous W's stop, but the buttons are not working correctly. If I then bring up btnx and restart it, everything works again. It does not happen a lot, but often enough that it is a bit of an issue.

daou
December 13th, 2007, 03:06 PM
The program is great. Gives me the control that I want. One strange issue that occurs periodically (usually in Firefox, not sure if FF issue or mouse or...) is that the buttons will seem to do multiple actions (ie, I have a button set up to close a tab, and it closes all of them and after that the wheel acts as a zoom, not scroll) after which whenever I click in any box, I get a continuous string of W's that I can't stop. I can't get to btnx to restart it because I can't type the password with the W's going. If I restart x it clears, and I found that I could stop the w's by pulling out the mouse usb receiver and plugging it back in. This makes so that the continuous W's stop, but the buttons are not working correctly. If I then bring up btnx and restart it, everything works again. It does not happen a lot, but often enough that it is a bit of an issue.

Use the "Force immediate button release" property for that button.

daou
December 13th, 2007, 03:08 PM
OK, thanks for the input. Should I also not use BTN_MIDDLE for the Search button (that I have configured as a middle mouse button)? I don't see any other alternatives and, as it is, if I middle click on a link in Firefox and miss (which happens often haha) I get the error "The URL is not valid and could not be loaded"

-I just enabled autoscroll in Fx, and no longer get that message...it still seems like odd behavior, but then again, I am extremely new to Ubuntu/Linux.

The BTN_LEFT BTN_RIGHT and BTN_MIDDLE are standard, and every application understands them. So yes, you can use the BTN_MIDDLE for it. If you are using the MX Revolution, you can also change the wheel mode with revoco, and you will be able to use the wheel click as a middle button.

tim71
December 14th, 2007, 12:55 PM
Now I updated to 0.4.4 and immediately got one problem - how it can be possible to define a double-click under the mouse button?

Previously it was possible to define a button in a way, that event was sent on clicking and releasing ('type=1' parameter), thus making it a double click. Now it seemed to stop working...

P.S. Downgraded back until the solution will be found. Uninstall of btnx-config 0.4.4 got stuck - killing the 'scrollkeeper-update' process helped to get it done.

daou
December 15th, 2007, 11:46 AM
Now I updated to 0.4.4 and immediately got one problem - how it can be possible to define a double-click under the mouse button?

Previously it was possible to define a button in a way, that event was sent on clicking and releasing ('type=1' parameter), thus making it a double click. Now it seemed to stop working...

P.S. Downgraded back until the solution will be found. Uninstall of btnx-config 0.4.4 got stuck - killing the 'scrollkeeper-update' process helped to get it done.

This is related to the implementation of the "Force immediate button release" property. It changed the way some event types were handled. However, it is not a big deal to change it back so type=1 will give the behavior you want. I will make it possible in the next release.

As for the scrollkeeper... nothing has changed in the way the documentation is built and installed. If you keep having problems with it, just call "./configure builddocs=no". It will not install documentation at all.

tim71
December 15th, 2007, 04:43 PM
As for the scrollkeeper... nothing has changed in the way the documentation is built and installed. If you keep having problems with it, just call "./configure builddocs=no". It will not install documentation at all.
No - scrollkeeper itself does not represent a problem. It was only the uninstall before downgrade, when this process (obviously initiated by uninstall process as was seen in system monitor) just got stuck for a long time.

Anyway - let's give it another try, when this next version will be ready.

k-o-x
December 16th, 2007, 09:47 AM
Hi and thanks for btnx which works very well :)

I'm just wondering, would it be possible to add 2 features :
- make it possible to change button behaviour based on key modifiers, for example make buttonX click and CTRL+buttonX click do two different things ?
- change button behaviour based on the current focused window properties (name/class/title), so that for example thumb buttons could have different actions associated when firefox is focused and when the desktop is focused...

daou
December 18th, 2007, 05:26 AM
Hi and thanks for btnx which works very well :)

I'm just wondering, would it be possible to add 2 features :
- make it possible to change button behaviour based on key modifiers, for example make buttonX click and CTRL+buttonX click do two different things ?
- change button behaviour based on the current focused window properties (name/class/title), so that for example thumb buttons could have different actions associated when firefox is focused and when the desktop is focused...

Glad you find btnx useful. Your first suggestion could be possible to implement. It would require a lot of work, but I will keep it in mind.

The second suggestion is a bit out of btnx's scope. It would make configuration unnecessarily complicated. And it's an unnecessary amount of code for a feature that only a handful of people will use.

daou
December 18th, 2007, 05:32 AM
Well I finally packaged btnx and btnx-config 0.4.4 as .debs, despite what I have been saying all along. I won't commit myself to keeping them up to date, so the latest features will be available from compiling yourself.

Note that the debs only work for Ubuntu 7.04 (if someone tests 7.10 and finds that they work, tell me).

Kubuntu users should still compile from source. There might be problems with the documentation, and the btnx-config menu icon will not work correctly unless you have gksu. KDE users need the desktop icon to use kdesu, which is correctly configured when the package is compiled.

neptunix
December 22nd, 2007, 09:55 AM
Hi. Could you please explain to the this phrase:
"Could not create a version stamp file."
What is a version stamp file?
A new revision of file or what?

I try translating btnx. Thanks

by the way, stange string Failed to execute command: " isn't it?

daou
December 22nd, 2007, 10:11 AM
Hi. Could you please explain to the this phrase:
"Could not create a version stamp file."
What is a version stamp file?
A new revision of file or what?

I try translating btnx. Thanks

The version stamp file is a file that contains the current version of btnx-config. The file is created when a user makes a backup of their configurations. It is placed in the backup archive. Later, when the user attempts to restore the backup, it checks whether the backup archive is compatible by comparing the versions of the backup and the current version of btnx-config.

Thanks for helping out with the translations, by the way.

daou
December 22nd, 2007, 10:13 AM
When you finish the translation, I'll try to include it in the next release as soon as possible. There has been a problem for a week with Launchpad... I've been unable to download new translations. The French translation file has been sitting there for a week.

Hopefully they will have it fixed soon. I'm actively following its status.

[S]Duke
December 23rd, 2007, 11:06 PM
I'm having a bit of an issue, btnx has completely stopped recognizing my search button. I tried it on Windows, and the button works fine, but btnx no longer recognizes it. I've even tried a new profile, but nothing.

Any clues?

unabatedshagie
December 26th, 2007, 08:15 PM
How would I go about getting the tilt left and right to sidescroll pages on firefox or images in gimp etc?

daou
December 27th, 2007, 05:20 AM
Duke;4005097']I'm having a bit of an issue, btnx has completely stopped recognizing my search button. I tried it on Windows, and the button works fine, but btnx no longer recognizes it. I've even tried a new profile, but nothing.

Any clues?

Post the output of 'cat /proc/bus/input/devices'

daou
December 27th, 2007, 05:21 AM
How would I go about getting the tilt left and right to sidescroll pages on firefox or images in gimp etc?

The left and right arrow keys should do this. Bind them to your mouse buttons. Keycodes: KEY_LEFT and KEY_RIGHT

Urgazhi
December 27th, 2007, 11:52 PM
Wonderful little turtorial, made my MX Revo work so much better, and have ALOT more function ability ^_^ wonderful tool ^_^

Now if only i could get the mouse to work this well in Windows *sigh*:guitar:

Neonavt
December 28th, 2007, 09:59 AM
Thanks for this program.

I've got 1 question: how should I launch btnx at system start?

I've written 2 lines into local.rc (I am not shure about file name) before "exit 0":
sudo btnx-config
sudo btnx


But I'm not shure it's wright (anyway, It's working :) ).


I've got Ubuntu 7.10 + latest btnx

olmari
December 28th, 2007, 10:02 AM
it starts already on it's own... you can use /etc/init.d/btnx start|stop|restart to start or stop it if you want

Neonavt
December 28th, 2007, 10:05 AM
sorry, I'm new to Ubuntu and I don't understand.
How does it starts? Whithout editting local.rc nothing works...
What should I do to start it?


Without local.rc btnx starts only when I type "btnx" in terminal.

daou
December 28th, 2007, 12:00 PM
sorry, I'm new to Ubuntu and I don't understand.
How does it starts? Whithout editting local.rc nothing works...
What should I do to start it?


Without local.rc btnx starts only when I type "btnx" in terminal.

You can use the command line command:
sudo /etc/init.d/btnx start
to start btnx.

To stop it, you can use the command
sudo /etc/init.d/btnx stop

However, btnx should be starting on its own when you reboot your computer, if you have detected and configured a mouse.

jamesford
December 28th, 2007, 07:09 PM
probably covered before but is it possible to use btnx for programming extra keys on the keyboard that might not work, such as the windows keys and play/pause/volume/standby etc to make them do somsething i might find more useful ?

daou
December 29th, 2007, 06:03 AM
probably covered before but is it possible to use btnx for programming extra keys on the keyboard that might not work, such as the windows keys and play/pause/volume/standby etc to make them do somsething i might find more useful ?

Yes and no. At the moment btnx only supports one input device, so you could only use your mouse or your keyboard with it. This can be changed. Also some other small changes to the code are needed.

I tested it before and it works to some extent. Perhaps in a new minor release down the road.

Interesting note: my Logitech keyboard sends actual mouse button signals when pressing the extra keys

daou
December 29th, 2007, 06:07 AM
Wonderful little turtorial, made my MX Revo work so much better, and have ALOT more function ability ^_^ wonderful tool ^_^

Now if only i could get the mouse to work this well in Windows *sigh*:guitar:

Glad you like it. On the Windows side, I think you can get a lot of the functionality with a program called uberoptions. I've only heard it being mentioned on this thread, never seen it myself.

Ollfried
December 29th, 2007, 02:10 PM
Moin!
Thank you for this great tool, makes me love my Revolution VX in Linux, too. Just one question: I created an action KEY_Q for the event tilt_mousewheel. I would like btnx to 'press' q when I tilt the wheel, until I release the wheel. For now, btnx send 'q's repeatedly.
Is it possible to change this behaviour? Background: I use wheel-tilting for strafing in WoW...
Thanks in advance!
Ollfried

Urgazhi
December 29th, 2007, 02:48 PM
Glad you like it. On the Windows side, I think you can get a lot of the functionality with a program called uberoptions. I've only heard it being mentioned on this thread, never seen it myself.

Hmmm

True, It looks interesting, I just didn't want to have to install Logitech's software in windows, It ruins the gaming experience overall, since it remaps the buttons including other odd things, all I use windows for is gaming usually lol

daou
December 29th, 2007, 03:03 PM
Moin!
Thank you for this great tool, makes me love my Revolution VX in Linux, too. Just one question: I created an action KEY_Q for the event tilt_mousewheel. I would like btnx to 'press' q when I tilt the wheel, until I release the wheel. For now, btnx send 'q's repeatedly.
Is it possible to change this behaviour? Background: I use wheel-tilting for strafing in WoW...
Thanks in advance!
Ollfried

Technically, thats what btnx already does. btnx only sends the press and release signals. But when btnx tells the input system that q is pressed, it automatically starts repeating the q by itself. I think it might be related to X11 settings (the repetition).

Ollfried
December 29th, 2007, 03:53 PM
Hmm, strange. If I disable keyboard repeat in Gnomes System->Keyboard Menu, it works for 'normal' keys. But btnx events still send the key repeatitily.

daou
December 29th, 2007, 04:03 PM
Hmm, strange. If I disable keyboard repeat in Gnomes System->Keyboard Menu, it works for 'normal' keys. But btnx events still send the key repeatitily.

Ah yes, I forgot... this is the way it is implemented in hardware on the MX Revolution (just tested again on my MX Revolution). The wheel side click is similar to the wheel itself: there is no separate release. For example, when you scroll up and down on the wheel, each "click" is a press and release signal. It's the same for the wheel tilting, except holding it down is the same has continuously scrolling the wheel.

I suggest you try binding strafing to other keys if possible (thumb buttons?).

Ollfried
December 29th, 2007, 04:44 PM
Okay, thank you. In Windows it works, must be implemented in the driver-monster then. Too bad.

heatpumpcontrol
January 1st, 2008, 11:47 AM
Happy NEW YEAR 2008!! to all

Hi Daou, I want to program a button to open my documents folder but when I enter the command 'nautilus /media/Documents' it opens it under the root user.

What is the correct argument command to make it open let's say john's Documents? Also, I've noticed this whenever I make it launch rhythmbox. I use /usr/bin/rhythmbox and it launches the app for the root account so my personal settings are not applied.

thanks

daou
January 1st, 2008, 01:56 PM
Happy NEW YEAR 2008!! to all

Hi Daou, I want to program a button to open my documents folder but when I enter the command 'nautilus /media/Documents' it opens it under the root user.

What is the correct argument command to make it open let's say john's Documents? Also, I've noticed this whenever I make it launch rhythmbox. I use /usr/bin/rhythmbox and it launches the app for the root account so my personal settings are not applied.

thanks

Happy new year! In many cases you can just change the UID to your user's UID. You can get it by executing "echo $UID" on the command line. However, some programs, like firefox and maybe nautilus need to be executed differently. You can do this with su (but in this case leave UID to zero, otherwise you will not have permissions to use su).

EDIT: this command won't work, involves a bug in btnx. Look at my next post for a workaround.

For example:
su -c "/usr/bin/rhythmbox" your_usernameor
su -c "nautilus --browser /home/john/Documents" john

heatpumpcontrol
January 1st, 2008, 02:31 PM
Thanks... I'll post my progress...

OK... when I enter the data into terminal it works.... but when I place it in the config gui it doesn't... hmm

But what I did was the following.... now knowing that the Process UID means....my user ID

/usr/bin/rhythmbox -->command

1000 -->Process UID

Did the same for My Documents link

/usr/bin/nautilus /media/Documents

1000

wooo hoooo It all works.

EDIT:

See my next post... when btnx-config is closed the above would not work.. Daou has a work around... thanks Daou

Thank you.

daou
January 1st, 2008, 02:41 PM
Thanks... I'll post my progress...

Actually I did some testing and found a bug in btnx concerning this. The command I posted wont work.

To get around it, you should make a script in your home directory that contains the command.
so:
echo "/usr/bin/nautilus --browser /home/john/Documents" > /home/john/btnx_exec_script
chmod u+x /home/john/btnx_exec_scriptThe commands place the nautilus command in the script and makes the script executable. Then, use the following command in btnx-config:
/bin/su -c /home/john/btnx_exec_script johnThat should work. I will try to fix this bug soon. btnx currently doesn't recognize the argument inside quotation marks as a single command, as was the case in the example I gave in the previous post.

heatpumpcontrol
January 1st, 2008, 03:44 PM
Actually I did some testing and found a bug in btnx concerning this. The command I posted wont work.

To get around it, you should make a script in your home directory that contains the command.
so:
echo "/usr/bin/nautilus --browser /home/john/Documents" > /home/john/btnx_exec_script
chmod u+x /home/john/btnx_exec_scriptThe commands place the nautilus command in the script and makes the script executable. Then, use the following command in btnx-config:
/bin/su -c /home/john/btnx_exec_script johnThat should work. I will try to fix this bug soon. btnx currently doesn't recognize the argument inside quotation marks as a single command, as was the case in the example I gave in the previous post.

GREAT!. I noticed that once I closed the config GUI the command would not work.... You are awesome... Hey there's always someone figuring something you haven't thought of.. :lolflag: thanks again

dethredic
January 1st, 2008, 03:47 PM
Hi

I have a G5 mouse (the one with 2 thumb buttons) and Ubuntu 7.10.

I had some detection problems. It thinks my left scroll and my wheel click are the same button. After I completed the middle click it wouldn't let me do my left scroll. I could do the middle click again. This is confirmed when I assign values to my left and right scroll. The left scroll and wheel click do the same thing, even though I did not configure the wheel click.

Finally, the custom configurations I had for the two side buttons don't work. Their custom values do not work.

I am going to try to un configure my mouse further, and see if it helps.

daou
January 1st, 2008, 03:58 PM
Hi

I have a G5 mouse (the one with 2 thumb buttons) and Ubuntu 7.10.

I had some detection problems. It thinks my left scroll and my wheel click are the same button. After I completed the middle click it wouldn't let me do my left scroll. I could do the middle click again. This is confirmed when I assign values to my left and right scroll. The left scroll and wheel click do the same thing, even though I did not configure the wheel click.

Finally, the custom configurations I had for the two side buttons don't work. Their custom values do not work.

I am going to try to un configure my mouse further, and see if it helps.

Did you check the manual's troubleshooting section on better xorg.conf settings?

dethredic
January 1st, 2008, 04:21 PM
Did you check the manual's troubleshooting section on better xorg.conf settings?

I completely reconfigured my Xorg.conf and made it look like the examples.

The scroll wheel still = the left scroll.

The thumb buttons do not work.

The left and right scroll work.

Any ideas?

daou
January 3rd, 2008, 08:21 AM
I completely reconfigured my Xorg.conf and made it look like the examples.

The scroll wheel still = the left scroll.

The thumb buttons do not work.

The left and right scroll work.

Any ideas?

Did you check all the other troubleshooting sections? After making changes to your xorg.conf, did you delete your configuration and detect your mouse and buttons again? You've configured and enabled the thumb buttons?

You can also post your xorg.conf InputDevice section and I'll have a look at it for any problems. And, by the way, the mouse is plugged in with a USB cable? No USB->PS/2 adapters.

daou
January 3rd, 2008, 08:24 AM
Now I updated to 0.4.4 and immediately got one problem - how it can be possible to define a double-click under the mouse button?

Previously it was possible to define a button in a way, that event was sent on clicking and releasing ('type=1' parameter), thus making it a double click. Now it seemed to stop working...

P.S. Downgraded back until the solution will be found. Uninstall of btnx-config 0.4.4 got stuck - killing the 'scrollkeeper-update' process helped to get it done.

btnx 0.4.5 allows the type=1 modification. But do not use the force release property with it, it overrides the type=1 property. I also got the stuck scrollkeeper-update, but let it run for a few minutes. It then finished by its own, no need to kill the process. It apparently happens after installing and uninstalling documentation multiple times. Perhaps the process does some intensive cleanup.

dethredic
January 3rd, 2008, 11:16 AM
Did you check all the other troubleshooting sections? After making changes to your xorg.conf, did you delete your configuration and detect your mouse and buttons again? You've configured and enabled the thumb buttons?

You can also post your xorg.conf InputDevice section and I'll have a look at it for any problems. And, by the way, the mouse is plugged in with a USB cable? No USB->PS/2 adapters.

It is plugged in via USB

I re did the configuration

Here is my xorg


Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "ImPS/2"
Option "ZAxisMapping" "4 5"
EndSection


EDIT: After re-doing the detection again, I configured the left scroll before the mouse click. Then when I did the mouse click, I would get a "Button already recognized" for like .5 of a second, then it would dissapear, and the bar would increase by 1 step.

So I am thinking that btnx thinks I hit left scroll on while the wheel is being pressed.

I don't need the scroll wheel, as I am going to map one of my thumb buttons to it, so if there is a way to disable it, that would help (for the odd time I forget to not use it).

daou
January 3rd, 2008, 11:19 AM
It is plugged in via USB

I re did the configuration

Here is my xorg


Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "ImPS/2"
Option "ZAxisMapping" "4 5"
EndSection


You should use "Protocol" "auto" and try "Device" "/dev/psaux"

dethredic
January 3rd, 2008, 11:48 AM
check out my edit.

I will check again, with the new xorg.

dethredic
January 3rd, 2008, 12:52 PM
Ok, with your new xorg suggestions:

Left and right wheel still work.

Middle click has been fixed.

Both side buttons do not work.

Any other ideas?

daou
January 3rd, 2008, 01:07 PM
Ok, with your new xorg suggestions:

Left and right wheel still work.

Middle click has been fixed.

Both side buttons do not work.

Any other ideas?

I'm at a loss to say what to try next. I will think about it, and if I come up with something I'll post here.

dethredic
January 3rd, 2008, 01:51 PM
I'm at a loss to say what to try next. I will think about it, and if I come up with something I'll post here.

I am going to try other xorg.conf configurations.

Thanks for trying.

dethredic
January 3rd, 2008, 02:53 PM
Well, this xorg gets everything to work except the forward button.


Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "ImPS/2"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "true"
Option "Buttons" "7"
Option "ButtonMapping" "1 2 3 6 7"
EndSection


I think this is as good as I am going to get.

daou
January 3rd, 2008, 03:11 PM
Well, this xorg gets everything to work except the forward button.



I think this is as good as I am going to get.

Ok. One thing: have you tried configuring your mouse with other methods? Did you undo all those settings? People with G5 mouses have gotten btnx to work on it fully. When you reinstall Ubuntu the next time, try it again on a fresh install. But don't reinstall for just that, I don't know if it will help.

dethredic
January 3rd, 2008, 03:22 PM
Ya, maybe I did something to screw this up.

Fazz Munkle
January 3rd, 2008, 04:02 PM
The installation didn't work for me. First it didn't put a btnx-config entry into the System Tools (so I don't know what command it needs) and then when I started btnx-config under sudo (because it wouldn't work correctly otherwise) it gave me all sorts of errors about btnx not running. Then I remembered I deleted the hand-typed startup program entry in the Sessions CP and I deleted the old menu entry in the System Tools menu (both from a previous install). I'm guessing I should have kept both entries, but shouldn't new subsequent installs re-enter the menu item (not the startup program item, that was my doing to get btnx to start at login)?

I think this is waaaaaaaayyyy too much trouble just to get my MX Revolution to work correctly. I think I'll wait until Logitech gets off their hands and release a utility for their Linux customers.

Please don't tell me I have to reinstall Ubuntu just to get this install to work correctly. If I have to I might as well get rid of Ubuntu altogether because I really don't want to reinstall. It's too inconvenient and I have things the way I want them and I really don't want to try to get back to everything from memory.

YoDaddeh
January 3rd, 2008, 04:04 PM
I am failing at installing this software for my MX Revoltuion.

I run
sudo apt-get install build-essential libgtk2.0-0 libgtk2.0-dev libglade2-0 libglade2-dev pkg-config

and it tells me:

Reading package lists... Done
Building dependency tree
Reading state information... Done
libgtk2.0-0 is already the newest version.
libglade2-0 is already the newest version.
pkg-config is already the newest version.
The following extra packages will be installed:
dpkg-dev g++ g++-4.1 libatk1.0-dev libcairo2-dev libexpat1-dev
libfontconfig1-dev libfreetype6-dev libglib2.0-dev libice-dev
libpango1.0-dev libpng12-dev libsm-dev libstdc++6-4.1-dev libx11-dev
libxau-dev libxcomposite-dev libxcursor-dev libxdamage-dev libxdmcp-dev
libxext-dev libxfixes-dev libxft-dev libxi-dev libxinerama-dev libxml2-dev
libxrandr-dev libxrender-dev patch x11proto-composite-dev x11proto-core-dev
x11proto-damage-dev x11proto-fixes-dev x11proto-input-dev x11proto-kb-dev
x11proto-randr-dev x11proto-render-dev x11proto-xext-dev
x11proto-xinerama-dev xtrans-dev zlib1g-dev
Suggested packages:
debian-keyring g++-multilib g++-4.1-multilib gcc-4.1-doc libcairo2-doc glade
glade-gnome libglib2.0-doc libgtk2.0-doc libpango1.0-doc libstdc++6-4.1-doc
diff-doc
The following NEW packages will be installed:
build-essential dpkg-dev g++ g++-4.1 libatk1.0-dev libcairo2-dev
libexpat1-dev libfontconfig1-dev libfreetype6-dev libglade2-dev
libglib2.0-dev libgtk2.0-dev libice-dev libpango1.0-dev libpng12-dev
libsm-dev libstdc++6-4.1-dev libx11-dev libxau-dev libxcomposite-dev
libxcursor-dev libxdamage-dev libxdmcp-dev libxext-dev libxfixes-dev
libxft-dev libxi-dev libxinerama-dev libxml2-dev libxrandr-dev
libxrender-dev patch x11proto-composite-dev x11proto-core-dev
x11proto-damage-dev x11proto-fixes-dev x11proto-input-dev x11proto-kb-dev
x11proto-randr-dev x11proto-render-dev x11proto-xext-dev
x11proto-xinerama-dev xtrans-dev zlib1g-dev
0 upgraded, 44 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B/20.0MB of archives.
After unpacking 63.0MB of additional disk space will be used.
Do you want to continue [Y/n]? y
Failed to fetch cdrom:[Ubuntu 7.10 _Gutsy Gibbon_ - Release i386 (20071016)]/pool/main/g/gcc-defaults/g++_4.1.2-9ubuntu2_i386.deb Hash Sum mismatch
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?


So now what? The cd is straight from Canonical so It shouldn't be the cd, right?

tim71
January 3rd, 2008, 04:29 PM
btnx 0.4.5 allows the type=1 modification. But do not use the force release property with it, it overrides the type=1 property. I also got the stuck scrollkeeper-update, but let it run for a few minutes. It then finished by its own, no need to kill the process. It apparently happens after installing and uninstalling documentation multiple times. Perhaps the process does some intensive cleanup.Seems like it's working fine - even made debs and installed these (btw dpkg-buildpackage failed with fakeroot).

P.S. By the way this force release property might help with wheel tilt (configured as Alt+Left/Alt+Right) kinda'... "sticking" - wheel is released, but sometimes rarely command is repeating itself and with a web browser 'Back' command it might mess things up a little (with "old btnx").

daou
January 3rd, 2008, 05:31 PM
I am failing at installing this software for my MX Revoltuion.

So now what? The cd is straight from Canonical so It shouldn't be the cd, right?

Try commenting out the cdrom from /etc/apt/sources.list
If you don't know how, you can find instructions on how to do so on these forums.

daou
January 3rd, 2008, 05:43 PM
The installation didn't work for me. First it didn't put a btnx-config entry into the System Tools (so I don't know what command it needs) and then when I started btnx-config under sudo (because it wouldn't work correctly otherwise) it gave me all sorts of errors about btnx not running. Then I remembered I deleted the hand-typed startup program entry in the Sessions CP and I deleted the old menu entry in the System Tools menu (both from a previous install). I'm guessing I should have kept both entries, but shouldn't new subsequent installs re-enter the menu item (not the startup program item, that was my doing to get btnx to start at login)?

I think this is waaaaaaaayyyy too much trouble just to get my MX Revolution to work correctly. I think I'll wait until Logitech gets off their hands and release a utility for their Linux customers.

Please don't tell me I have to reinstall Ubuntu just to get this install to work correctly. If I have to I might as well get rid of Ubuntu altogether because I really don't want to reinstall. It's too inconvenient and I have things the way I want them and I really don't want to try to get back to everything from memory.

btnx should start by its own after installing. You don't need to add an entry to the Sessions CP... besides, it wouldn't work because btnx requires root privileges to run.

If you deleted the entry in the System tools menu, it might not show up again. I remember at least KDE has preferences which remembers what menu entries you delete, and hides them from you even if you reinstall the package. Try looking for how to undo this. I'll try looking as well later and reply if I find a solution.

But you don't necessarily need the menu entry for btnx-config. You can always start it from command line with sudo. The menu entry is not a critical part of the package, just a convinience.

And yes, it would be nice for Logitech to make tools for Linux. But looking at their Windows software, I'm not sure if they would be able to make anything other than a bloated program providing minimal functionality. They have never shown any interest in Linux compatibility.

Could you post the errors you are getting when running btnx-config?

YoDaddeh
January 3rd, 2008, 05:43 PM
Try commenting out the cdrom from /etc/apt/sources.list
If you don't know how, you can find instructions on how to do so on these forums.

Okay, I'll try removing it out of the sources list and see what happens.

daou
January 3rd, 2008, 05:49 PM
Seems like it's working fine - even made debs and installed these (btw dpkg-buildpackage failed with fakeroot).

P.S. By the way this force release property might help with wheel tilt (configured as Alt+Left/Alt+Right) kinda'... "sticking" - wheel is released, but sometimes rarely command is repeating itself and with a web browser 'Back' command it might mess things up a little (with "old btnx").

I used checkinstall the make the 0.4.4 debs available on my server. It worked without problems.

And yes, the force release was implemented to fix that problem. I've no longer had any problems with stuck buttons that use the force release property.

[S]Duke
January 3rd, 2008, 10:41 PM
Post the output of 'cat /proc/bus/input/devices'

Sorry for the late reply. The problems have gotten worse, now btnx only recognizes the left and right tilts of the index wheel, while ignoring all the other buttons.

Here's the output:

I: Bus=0017 Vendor=0001 Product=0001 Version=0100
N: Name="Macintosh mouse button emulation"
P: Phys=
S: Sysfs=/devices/virtual/input/input0
U: Uniq=
H: Handlers=mouse0 event0
B: EV=7
B: KEY=70000 0 0 0 0 0 0 0 0
B: REL=3

I: Bus=0011 Vendor=0001 Product=0001 Version=ab41
N: Name="AT Translated Set 2 keyboard"
P: Phys=isa0060/serio0/input0
S: Sysfs=/devices/platform/i8042/serio0/input/input1
U: Uniq=
H: Handlers=kbd event1
B: EV=120013
B: KEY=4 2000000 3803078 f800d001 feffffdf ffefffff ffffffff fffffffe
B: MSC=10
B: LED=7

I: Bus=0003 Vendor=046d Product=c517 Version=0110
N: Name="Logitech USB Receiver"
P: Phys=usb-0000:00:0b.0-1/input0
S: Sysfs=/devices/pci0000:00/0000:00:0b.0/usb1/1-1/1-1:1.0/input/input2
U: Uniq=
H: Handlers=kbd event2
B: EV=120013
B: KEY=10000 7 ff800000 7ff febeffdf ffefffff ffffffff fffffffe
B: MSC=10
B: LED=1f

I: Bus=0003 Vendor=046d Product=c517 Version=0110
N: Name="Logitech USB Receiver"
P: Phys=usb-0000:00:0b.0-1/input1
S: Sysfs=/devices/pci0000:00/0000:00:0b.0/usb1/1-1/1-1:1.1/input/input3
U: Uniq=
H: Handlers=kbd mouse1 event3
B: EV=1f
B: KEY=37fff 4ac332f bf084444 0 0 ff0001 1f84 8a37cc00 667bfa dd71dfed 9e0000 0 0 0
B: REL=1c3
B: ABS=1 0
B: MSC=10

I: Bus=0003 Vendor=046d Product=c51a Version=0111
N: Name="Logitech USB Receiver"
P: Phys=usb-0000:00:0b.0-4/input0
S: Sysfs=/devices/pci0000:00/0000:00:0b.0/usb1/1-4/1-4:1.0/input/input4
U: Uniq=
H: Handlers=mouse2 event4
B: EV=17
B: KEY=ffff0000 0 0 0 0 0 0 0 0
B: REL=143
B: MSC=10

I: Bus=0003 Vendor=046d Product=c51a Version=0111
N: Name="Logitech USB Receiver"
P: Phys=usb-0000:00:0b.0-4/input1
S: Sysfs=/devices/pci0000:00/0000:00:0b.0/usb1/1-4/1-4:1.1/input/input5
U: Uniq=
H: Handlers=kbd event5
B: EV=1f
B: KEY=37fff ac3027 bf004444 0 0 1 f84 8a37c000 667bfa d9415fed 8e0000 0 0 0
B: REL=40
B: ABS=1 0
B: MSC=10

I: Bus=0010 Vendor=001f Product=0001 Version=0100
N: Name="PC Speaker"
P: Phys=isa0061/input0
S: Sysfs=/devices/platform/pcspkr/input/input6
U: Uniq=
H: Handlers=kbd event6
B: EV=40001
B: SND=6

I: Bus=0019 Vendor=0000 Product=0002 Version=0000
N: Name="Power Button (FF)"
P: Phys=LNXPWRBN/button/input0
S: Sysfs=/devices/virtual/input/input7
U: Uniq=
H: Handlers=kbd event7
B: EV=3
B: KEY=100000 0 0 0

I: Bus=0019 Vendor=0000 Product=0001 Version=0000
N: Name="Power Button (CM)"
P: Phys=PNP0C0C/button/input0
S: Sysfs=/devices/virtual/input/input8
U: Uniq=
H: Handlers=kbd event8
B: EV=3
B: KEY=100000 0 0 0

lledurt
January 4th, 2008, 03:10 PM
Thanks for this thread. This may be what I am looking for.

I am trying to use my thumb buttons to cut (button 8) and then paste (button 9) into a folder in nautilus file browser. I would like to be able to do each action with one button click. For example instead of selecting the file and then selecting cut(or cont x) I want to just hit button 8, and instead of selecting a folder and then right clicking and selecting paste in folder, I would like to hit button 9. It would also be great to be able to just select and paste if the mouse is not over a folder.

I have tried xbindkeys working but it still requires sever clicks or kestrokes to do exactly what I need.

This may be too much to ask but if anyone has done anything similar, let me know.

Thanks P.J.

holotone
January 6th, 2008, 06:58 PM
Thank you for this excellent tutorial for this great software - Everything worked swimmingly on my main Ubuntu box, but when I try to install the dependencies on my Asus Eee running Xubuntu, I get:


holotone@wheee:~$ sudo apt-get install build-essential libgtk2.0-0 libgtk2.0-dev libglade2-0 libglade2-dev pkg-config
[sudo] password for holotone:
Reading package lists... Done
Building dependency tree
Reading state information... Done
libgtk2.0-0 is already the newest version.
libgtk2.0-0 set to manual installed.
libglade2-0 is already the newest version.
libglade2-0 set to manual installed.
The following packages were automatically installed and are no longer required:
python-pyogg python-pyvorbis python-mutagen python-pysqlite2
python-elementtree
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
dpkg-dev g++ g++-4.1 libatk1.0-dev libc6-dev libcairo2-dev libexpat1-dev
libfontconfig1-dev libfreetype6-dev libglib2.0-dev libice-dev
libpango1.0-dev libpng12-dev libsm-dev libstdc++6-4.1-dev libx11-dev
libxau-dev libxcomposite-dev libxcursor-dev libxdamage-dev libxdmcp-dev
libxext-dev libxfixes-dev libxft-dev libxi-dev libxinerama-dev libxml2-dev
libxrandr-dev libxrender-dev linux-libc-dev x11proto-composite-dev
x11proto-core-dev x11proto-damage-dev x11proto-fixes-dev x11proto-input-dev
x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev
x11proto-xinerama-dev xtrans-dev zlib1g-dev
Suggested packages:
debian-keyring g++-multilib g++-4.1-multilib gcc-4.1-doc glibc-doc
manpages-dev libcairo2-doc glade glade-gnome libglib2.0-doc libgtk2.0-doc
libpango1.0-doc imagemagick libstdc++6-4.1-doc
The following NEW packages will be installed:
build-essential dpkg-dev g++ g++-4.1 libatk1.0-dev libc6-dev libcairo2-dev
libexpat1-dev libfontconfig1-dev libfreetype6-dev libglade2-dev
libglib2.0-dev libgtk2.0-dev libice-dev libpango1.0-dev libpng12-dev
libsm-dev libstdc++6-4.1-dev libx11-dev libxau-dev libxcomposite-dev
libxcursor-dev libxdamage-dev libxdmcp-dev libxext-dev libxfixes-dev
libxft-dev libxi-dev libxinerama-dev libxml2-dev libxrandr-dev
libxrender-dev linux-libc-dev pkg-config x11proto-composite-dev
x11proto-core-dev x11proto-damage-dev x11proto-fixes-dev x11proto-input-dev
x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev
x11proto-xinerama-dev xtrans-dev zlib1g-dev
0 upgraded, 46 newly installed, 0 to remove and 0 not upgraded.
Need to get 19.7MB/23.9MB of archives.
After unpacking 80.3MB of additional disk space will be used.
Do you want to continue [Y/n]? y
Media change: please insert the disc labeled
'Xubuntu 7.10 _Gutsy Gibbon_ - Release i386 (20071016)'
in the drive '/cdrom/' and press enter


Clearly this is a problem for me as I do not even have a CD-Rom on this lil' guy.

Any suggestions?

olmari
January 6th, 2008, 07:02 PM
You could delete CD-ROM from Synaptics, so it wouldn't try to use CD-ROM anymore as repository holder.

holotone
January 6th, 2008, 07:08 PM
You could delete CD-ROM from Synaptics, so it wouldn't try to use CD-ROM anymore as repository holder.

Aha! Fixed that right up - Does Xubuntu always require the CD-ROM to be available by default, or is this something specific to eeeXubuntu?

Thanks!

aboe
January 8th, 2008, 02:02 PM
Dear Daou,

I'm trying to use btnx with a Logitech G9 Laser Mouse,
I got al buttons working in X. (see this how to I made:
http://ubuntuforums.org/showthread.php?t=652092)

But btnx doesn't recognize the mouse.
So I can't reconfigure the buttons.

Is there a way to get the G9 Laser mouse and btnx working together? And what kind of information do you need to get it working?

daou
January 8th, 2008, 02:14 PM
Dear Daou,

I'm trying to use btnx with a Logitech G9 Laser Mouse,
I got al buttons working in X. (see this how to I made:
http://ubuntuforums.org/showthread.php?t=652092)

But btnx doesn't recognize the mouse.
So I can't reconfigure the buttons.

Is there a way to get the G9 Laser mouse and btnx working together? And what kind of information do you need to get it working?

Do you still have your settings from that howto? You need to remove the udev rule and reconfigure the xorg.conf InputDevice section according to the btnx manual's troubleshooting section 12.2.1.

so change it to:
Section "InputDevice"
Identifier "Logitech Mouse"
Driver "mouse"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Device" "/dev/input/mice"
Option "Emulate3Buttons" "no"
EndSectionFirst make sure to restart udev and X (or reboot to be safe).
Also try setting Option "Device" to "/dev/psaux" if it doesn't work. Tell me what happens.

daou
January 8th, 2008, 02:21 PM
Duke;4068417']Sorry for the late reply. The problems have gotten worse, now btnx only recognizes the left and right tilts of the index wheel, while ignoring all the other buttons.

Here's the output:

The output looks fine. Did you press the search button during mouse detection? It must be done on MX Rev and some other mice.

And since the problems got worse, have you made any edits to your xorg.conf or tried other howtos?

daou
January 8th, 2008, 02:32 PM
Thanks for this thread. This may be what I am looking for.

I am trying to use my thumb buttons to cut (button 8) and then paste (button 9) into a folder in nautilus file browser. I would like to be able to do each action with one button click. For example instead of selecting the file and then selecting cut(or cont x) I want to just hit button 8, and instead of selecting a folder and then right clicking and selecting paste in folder, I would like to hit button 9. It would also be great to be able to just select and paste if the mouse is not over a folder.

I have tried xbindkeys working but it still requires sever clicks or kestrokes to do exactly what I need.

This may be too much to ask but if anyone has done anything similar, let me know.

Thanks P.J.

You can, of course, make btnx emit a Ctrl+C and Ctrl+V for copy and paste when the file has been highlighted. This it can do.
But did you want functionality, where you only click a button once, and the file gets selected and copied/pasted? This is not possible with btnx.

aboe
January 8th, 2008, 06:36 PM
Do you still have your settings from that howto? You need to remove the udev rule and reconfigure the xorg.conf InputDevice section according to the btnx manual's troubleshooting section 12.2.1.

so change it to:
Section "InputDevice"
Identifier "Logitech Mouse"
Driver "mouse"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Device" "/dev/input/mice"
Option "Emulate3Buttons" "no"
EndSectionFirst make sure to restart udev and X (or reboot to be safe).
Also try setting Option "Device" to "/dev/psaux" if it doesn't work. Tell me what happens.


I tried it with your configuration, and product and manufacturer was detected, but btnx hangs at the discovery of buttons, because the G9 is also listed as a keyboard device.
So btnx thinks you just hit two devices but it is actually only one.

daou
January 9th, 2008, 03:52 AM
I tried it with your configuration, and product and manufacturer was detected, but btnx hangs at the discovery of buttons, because the G9 is also listed as a keyboard device.
So btnx thinks you just hit two devices but it is actually only one.

Could you describe the hang a bit more? When exactly does it happen? Does it pop up any error messages?

Some other mice also have two devices listed, for example, the MX Revolution for its search button. btnx works correctly on them as long as the keyboard device has the same vendor and product ID as the mouse device. According to your /proc/bus/input/devices the G9 is the same.

Does a certain button during mouse detection cause another handler to be detected? Try using btnx without that button and see if the hang persists.

tim71
January 10th, 2008, 03:37 PM
Something strange is going on

At first there is console output...
:~$ sudo /etc/init.d/btnx stop
Stopping btnx : Button Extension - mouse button rerouter daemon
btnx: old btnx process was not killed: 7493: No such process
btnx successfully stopped


And yes - before this command I looked at the pidfile, and it has two PID's written in it and this 7493 did not exist in a the process list. However existing one was stopped - but pidfile was left in /var/run - though it was empty after stopping btnx.

Startup goes after that as normal - I guess
~$ sudo /etc/init.d/btnx start
Starting btnx : Button Extension - mouse button rerouter daemon
btnx: uinput modprobed successfully.
btnx: Opening config file: /etc/btnx/btnx_config_000
btnx: Opened handler: /dev/input/event0
btnx: Opened handler: /dev/input/event1
btnx: Opened handler: /dev/input/event2
btnx: Opened handler: /dev/input/event0
btnx: Opened handler: /dev/input/event1
btnx: Opened handler: /dev/input/event2
btnx: Opened handler: /dev/input/event3
btnx: Opened handler: /dev/input/event4
btnx: Opened handler: /dev/input/event5
btnx: Opened handler: /dev/input/uinput
btnx: Opened handler: /dev/input/uinput
btnx: revoco not started. Disabled in configuration.
btnx: No startup errors
btnx successfully started

...but there is pretty big BUT :) - sometimes btnx does work, sometimes not. At first I made deb's and installed these - then I just thought that something did go wrong with these and removed everything btnx-related from system folders after complete uninstall. Then I installed all with "make install" and again same thing happened - everything looks like in place, service is running and btnx-config recognizes configuration and so on, BUT nothing is actually working - restarting btnx did not help either.

Then I just rebooted and now it works again - but this duplicated PID thing is still there and it's not quite sure yet, why all this is happening....

daou
January 10th, 2008, 04:45 PM
Something strange is going on

At first there is console output...
And yes - before this command I looked at the pidfile, and it has two PID's written in it and this 7493 did not exist in a the process list. However existing one was stopped - but pidfile was left in /var/run - though it was empty after stopping btnx.

Startup goes after that as normal - I guess
...but there is pretty big BUT :) - sometimes btnx does work, sometimes not. At first I made deb's and installed these - then I just thought that something did go wrong with these and removed everything btnx-related from system folders after complete uninstall. Then I installed all with "make install" and again same thing happened - everything looks like in place, service is running and btnx-config recognizes configuration and so on, BUT nothing is actually working - restarting btnx did not help either.

Then I just rebooted and now it works again - but this duplicated PID thing is still there and it's not quite sure yet, why all this is happening....

The problem, which doesn't affect function, is that when btnx quits it doesn't bother to remove its pid from the pid file. So when you start btnx, the parent process makes the pid file and adds itself to it to prevent race conditions. It then forks a child to the background with daemon() and exits, but doesn't remove its pid. Now the child has a different pid, so it needs to add itself to the pid file as well. Then btnx runs as normal.

When you stop btnx, it sees two pids. The dead parent and the child. It tries to kill the parent which no longer exists and you get a warning message. Then it kills the child, which is the running btnx process.

Its more of a cosmetic error, but one that I will fix. I suppose one possibility is that if your pid numbers wrap around and the process of a different program uses the btnx parent's old pid, it can mistakenly get killed. Very low chance, but it would be quite a big problem.

But this isn't related to the problem you are experiencing. I'm not sure what it could be.

tim71
January 10th, 2008, 06:32 PM
When you stop btnx, it sees two pids. The dead parent and the child. It tries to kill the parent which no longer exists and you get a warning message. Then it kills the child, which is the running btnx process.

Its more of a cosmetic error, but one that I will fix. I suppose one possibility is that if your pid numbers wrap around and the process of a different program uses the btnx parent's old pid, it can mistakenly get killed. Very low chance, but it would be quite a big problem.

But this isn't related to the problem you are experiencing. I'm not sure what it could be.
OK... at least now I know that this PID-related thing is not some kind of install error on something...

THE thing was, that if nothing worked, then restart of btnx did not help - process was there as it sould be, but mouse buttons did not function.

I am not sure either, what could be wrong, but the thing, which makes me wonder, is that normal functioning got restored only after reboot - nothing else helped, although btnx was running and reacted to start/stop commands in a predictable way.

Let's see, how it will behave for a few days - maybe something will reveal the problem.

P.S. still - pidfile is not removed, when btnx is stopped - it is just empty after that. Don't know if it is intentional or not...

UPDATE:

After searching through files I noticed, that now there is two links to /etc/init.d/btnx script in /etc/rc2.d - S49btnx and S49btnx.dpkg-new, so the script seems to be running twice on startup (maybe even simultaneously as both have the same number) and in this case all seems to work after that. I thought that the second link was some kind of "leftover" from the old install - I temporarily removed it and guess what? After the restart it was exactly like I described before - everything looks like it should, but nothing works - even multiple stop/start commands did not gave any result - all response from command line was as expected, but nothing worked.

Then I put this second link back in /etc/rc2.d/ and after rebooting everything seems to be fine again - this maybe the answer to the puzzling fact, that mouse buttons started to work only when system was rebooted after the install. It seems somehow that at the moment btnx will work as it should only after this "duplicate" script has been run at startup. What is interesting - when btnx works properly, then it works also after daemon stop/start/restart IF this sequence at the startup has been run succesfully.

I also tried to go to runlevel 1 and come back to runlevel 2 to make these startup scripts run, but it did not help...

C00P88
January 11th, 2008, 03:02 AM
I installed BTNX and it seemed to be working, however I wanted to go back and change some of the settings. How can I launch BTNX? When I go to Applications, System Tools, BTNX, I am prompted for my password but nothing happens. I've also tried launching from the terminal. I get an error code 150 when I try this command:

sudo /etc/init.d/btnx start

Is there another way to access btnx? It does not seem to be running at the moment, and I'd rather not re-install btnx again (already re-installed twice to adjust settings, seems to be the only way to access the GUI).

This is a great tool! Just need to know how to get to it.

Edit: I'm running 7.10 32bit.

2nd Edit: Just re-installed again, I can now access btnx via the applications menu just fine. No idea what I changed (if anything), but it works! :)

daou
January 11th, 2008, 05:14 AM
I installed BTNX and it seemed to be working, however I wanted to go back and change some of the settings. How can I launch BTNX? When I go to Applications, System Tools, BTNX, I am prompted for my password but nothing happens. I've also tried launching from the terminal. I get an error code 150 when I try this command:

sudo /etc/init.d/btnx startIs there another way to access btnx? It does not seem to be running at the moment, and I'd rather not re-install btnx again (already re-installed twice to adjust settings, seems to be the only way to access the GUI).

This is a great tool! Just need to know how to get to it.

Edit: I'm running 7.10 32bit.

2nd Edit: Just re-installed again, I can now access btnx via the applications menu just fine. No idea what I changed (if anything), but it works! :)

The error code 150 meant you had no configuration file. If you ever need to run the GUI from the command line, use
sudo btnx-config

daou
January 11th, 2008, 05:29 AM
P.S. still - pidfile is not removed, when btnx is stopped - it is just empty after that. Don't know if it is intentional or not...

UPDATE:

After searching through files I noticed, that now there is two links to /etc/init.d/btnx script in /etc/rc2.d - S49btnx and S49btnx.dpkg-new, so the script seems to be running twice on startup (maybe even simultaneously as both have the same number) and in this case all seems to work after that. I thought that the second link was some kind of "leftover" from the old install - I temporarily removed it and guess what? After the restart it was exactly like I described before - everything looks like it should, but nothing works - even multiple stop/start commands did not gave any result - all response from command line was as expected, but nothing worked.

Then I put this second link back in /etc/rc2.d/ and after rebooting everything seems to be fine again - this maybe the answer to the puzzling fact, that mouse buttons started to work only when system was rebooted after the install. It seems somehow that at the moment btnx will work as it should only after this "duplicate" script has been run at startup. What is interesting - when btnx works properly, then it works also after daemon stop/start/restart IF this sequence at the startup has been run succesfully.

I also tried to go to runlevel 1 and come back to runlevel 2 to make these startup scripts run, but it did not help...

btnx only truncates the file, never deletes it after removing processes from the pid file. Perhaps I should make it remove it as well.

It seems to be a problem with the package you built, if I understood correctly. Did you try removing both init scripts one at a time?

Try using checkinstall to make the package and see if it works any better.

EDIT: I see I have two as well... including one called K49btnx.dpkg-new. This was with checkinstall, and I have removed the packages with dpkg. It seems that removing the package doesn't correctly remove the init script it installs. This isn't a problem when installing/uninstalling with the source tarball. Note that links to the init scripts also live in other rcX.d directories, not just rc2.d. Correctly removing init scripts is done with the update-rc.d utility.

tim71
January 11th, 2008, 06:17 AM
btnx only truncates the file, never deletes it after removing processes from the pid file. Perhaps I should make it remove it as well.

It seems to be a problem with the package you built, if I understood correctly. Did you try removing both init scripts one at a time?

Try using checkinstall to make the package and see if it works any better..
I tried install from the tarball with 'make install' and also with checkinstall which gave the deb's too (I had some problems with checkinstall before that, but I just made it in a wrong way before).

This last update was after the install from these newly built deb's - so I don't think that the packages are at blame now.

I removed all scripts and other "leftovers" before the last install.


EDIT: I see I have two as well... including one called K49btnx.dpkg-new. This was with checkinstall, and I have removed the packages with dpkg. It seems that removing the package doesn't correctly remove the init script it installs. This isn't a problem when installing/uninstalling with the source tarball. Note that links to the init scripts also live in other rcX.d directories, not just rc2.d. Correctly removing init scripts is done with the update-rc.d utility.

However the fact is, that when I removed the second S49-link, nothing worked, as I explained before.

I did not bother to remove links from other rcX.d folders, because they all were starting with K, not an S - because K-links are not involved in starting something and runlevels 3...5 are not used in ubuntu anyway :)

Will try to tinker some more tonight...

IgnacioMiller
January 11th, 2008, 05:07 PM
Hey,

First off, thanks for a great program to configure some of these multibutton mice. It makes things a lot easier! I have run into a problem though, but it occurred only after I got my mouse configured which is a bit odd, but I thought I'd report it anyways in case I wanted to change the functionality of a button. I tried searching the forums and this thread, but I couldn't find anything and I apologize if this issue has already been resolved elsewhere.

When I try to run btnx-config in a terminal, I recieve this error message:

dan@dan-desktop:~$ btnx-config
/usr/share/btnx-config/btnx-config.glade
/home/dan/.themes/Alphacube GTK 0.5/gtk-2.0/gtkrc:63: Clearlooks configuration option "menuitemstyle" is not supported and will be ignored.
/home/dan/.themes/Alphacube GTK 0.5/gtk-2.0/gtkrc:64: Clearlooks configuration option "listviewitemstyle" is not supported and will be ignored.
/home/dan/.themes/Alphacube GTK 0.5/gtk-2.0/gtkrc:65: Clearlooks configuration option "progressbarstyle" is not supported and will be ignored.
Warning: configuration file for configuration "Default" does not exist. Deleting configuration.
Aborted (core dumped)
dan@dan-desktop:~$


Is there anything I can do to restore the program's functionality?

Thanks, and thanks for your great contribution!
Dan

tim71
January 11th, 2008, 10:11 PM
Still it looks like it was some kind of failure with these deb packages.

At first I uninstalled both btnx and btnx-config packages with "complete uninstall" option. Then I looked up and removed btnx init-script and all these links in /rcX.d folders.

Then I tried to reinstall these packages I made and got an interesting output
Selecting previously deselected package btnx.
(Reading database ... 299014 files and directories currently installed.)
Unpacking btnx (from btnx_0.4.5-1_i386.deb) ...
dpkg: btnx: warning - conffile `etc/btnx' is not a plain file or symlink (= `/etc/btnx')
dpkg: btnx: warning - conffile `etc/init.d' is not a plain file or symlink (= `/etc/init.d')
dpkg: btnx: warning - conffile `etc/rc0.d' is not a plain file or symlink (= `/etc/rc0.d')
dpkg: btnx: warning - conffile `etc/rc1.d' is not a plain file or symlink (= `/etc/rc1.d')
dpkg: btnx: warning - conffile `etc/rc2.d' is not a plain file or symlink (= `/etc/rc2.d')
dpkg: btnx: warning - conffile `etc/rc3.d' is not a plain file or symlink (= `/etc/rc3.d')
dpkg: btnx: warning - conffile `etc/rc4.d' is not a plain file or symlink (= `/etc/rc4.d')
dpkg: btnx: warning - conffile `etc/rc5.d' is not a plain file or symlink (= `/etc/rc5.d')
dpkg: btnx: warning - conffile `etc/rc6.d' is not a plain file or symlink (= `/etc/rc6.d')
Selecting previously deselected package btnx-config.
Setting up btnx (0.4.5-1) ...
Then I looked into /etc/init.d and /etc/rcX.d folders and all links and scripts were missing. It is possible, that this kind of output was not generated previously because the script and links were already there.
It was obvious, that something was going wrong. I made one more "complete uninstall" from synaptic.
Then I installed btnx and btnx-config straight from the compiled source and noticed that there was no "duplicate" links anywhere in /etc/rcX.d folders any more and everything worked as it should immediately after 'start' command.

So it is obvious that something went wrong with checkinstall and these deb packages.

tim71
January 11th, 2008, 10:18 PM
Hey,

First off, thanks for a great program to configure some of these multibutton mice. It makes things a lot easier! I have run into a problem though, but it occurred only after I got my mouse configured which is a bit odd, but I thought I'd report it anyways in case I wanted to change the functionality of a button. I tried searching the forums and this thread, but I couldn't find anything and I apologize if this issue has already been resolved elsewhere.

When I try to run btnx-config in a terminal, I recieve this error message:

dan@dan-desktop:~$ btnx-config
/usr/share/btnx-config/btnx-config.glade
/home/dan/.themes/Alphacube GTK 0.5/gtk-2.0/gtkrc:63: Clearlooks configuration option "menuitemstyle" is not supported and will be ignored.
/home/dan/.themes/Alphacube GTK 0.5/gtk-2.0/gtkrc:64: Clearlooks configuration option "listviewitemstyle" is not supported and will be ignored.
/home/dan/.themes/Alphacube GTK 0.5/gtk-2.0/gtkrc:65: Clearlooks configuration option "progressbarstyle" is not supported and will be ignored.
Warning: configuration file for configuration "Default" does not exist. Deleting configuration.
Aborted (core dumped)
dan@dan-desktop:~$


Is there anything I can do to restore the program's functionality?

Thanks, and thanks for your great contribution!
Dan
btnx-config has to be run as root - so try
sudo btnx-configwithout this btnx-config cannot write to configuration files.

IgnacioMiller
January 11th, 2008, 11:58 PM
Hey Tim71,

Thanks for the reply! I had tried that as well, but I receive the error:

dan@dan-desktop:~$ sudo btnx-config
[sudo] password for dan:
/usr/share/btnx-config/btnx-config.glade
Warning: configuration file for configuration "Default" does not exist. Deleting configuration.
Aborted (core dumped)
dan@dan-desktop:~$



I am guessing I somehow deleted the Profile entitled default, and maybe that is causing the crash. I would try to restore, but I wouldn't know what folder to look in or anything.

Thanks!
Dan

daou
January 12th, 2008, 02:11 PM
Hey Tim71,

Thanks for the reply! I had tried that as well, but I receive the error:

dan@dan-desktop:~$ sudo btnx-config
[sudo] password for dan:
/usr/share/btnx-config/btnx-config.glade
Warning: configuration file for configuration "Default" does not exist. Deleting configuration.
Aborted (core dumped)
dan@dan-desktop:~$

I am guessing I somehow deleted the Profile entitled default, and maybe that is causing the crash. I would try to restore, but I wouldn't know what folder to look in or anything.

Thanks!
Dan

In the /etc/btnx folder, try deleting the files btnx_manager, btnx_settings and btnx_config_Default if it exists. Then try running btnx-config again. If all else fails, reinstall the application.

daou
January 12th, 2008, 02:16 PM
Still it looks like it was some kind of failure with these deb packages.

At first I uninstalled both btnx and btnx-config packages with "complete uninstall" option. Then I looked up and removed btnx init-script and all these links in /rcX.d folders.

Then I tried to reinstall these packages I made and got an interesting output
Selecting previously deselected package btnx.
(Reading database ... 299014 files and directories currently installed.)
Unpacking btnx (from btnx_0.4.5-1_i386.deb) ...
dpkg: btnx: warning - conffile `etc/btnx' is not a plain file or symlink (= `/etc/btnx')
dpkg: btnx: warning - conffile `etc/init.d' is not a plain file or symlink (= `/etc/init.d')
dpkg: btnx: warning - conffile `etc/rc0.d' is not a plain file or symlink (= `/etc/rc0.d')
dpkg: btnx: warning - conffile `etc/rc1.d' is not a plain file or symlink (= `/etc/rc1.d')
dpkg: btnx: warning - conffile `etc/rc2.d' is not a plain file or symlink (= `/etc/rc2.d')
dpkg: btnx: warning - conffile `etc/rc3.d' is not a plain file or symlink (= `/etc/rc3.d')
dpkg: btnx: warning - conffile `etc/rc4.d' is not a plain file or symlink (= `/etc/rc4.d')
dpkg: btnx: warning - conffile `etc/rc5.d' is not a plain file or symlink (= `/etc/rc5.d')
dpkg: btnx: warning - conffile `etc/rc6.d' is not a plain file or symlink (= `/etc/rc6.d')
Selecting previously deselected package btnx-config.
Setting up btnx (0.4.5-1) ...Then I looked into /etc/init.d and /etc/rcX.d folders and all links and scripts were missing. It is possible, that this kind of output was not generated previously because the script and links were already there.
It was obvious, that something was going wrong. I made one more "complete uninstall" from synaptic.
Then I installed btnx and btnx-config straight from the compiled source and noticed that there was no "duplicate" links anywhere in /etc/rcX.d folders any more and everything worked as it should immediately after 'start' command.

So it is obvious that something went wrong with checkinstall and these deb packages.

I'm going to put btnx development on a hold for about a month or so. I'm going to be involved in another open source project that needs my full attention for a while. But if you figure out how to make working packages for btnx and btnx-config, let me know and I'll replace the ones on the btnx homepage with them.

Thought I would add, for everyone, that btnx has been nominated for inclusion into Hardy Heron. See this page for more details: https://bugs.launchpad.net/ubuntu/+bug/146160

tim71
January 12th, 2008, 06:17 PM
But if you figure out how to make working packages for btnx and btnx-config, let me know and I'll replace the ones on the btnx homepage with them.If I can find the way, then it would be only 32bit packages, because I do not have any 64bit machine at my disposal at the moment...

kamicosmos
January 12th, 2008, 07:29 PM
Thanks for this utility and your excellent documentation on how to use it! I didn't realize how attached I was to the Back Button until it quit working!

tim71
January 18th, 2008, 06:14 AM
Now it finally starts to look like I have found out what is going on with this occasional "some-mouse-buttons-not-working-after-restart" issue.

If I open bntx-config after finding out, that some buttons do not work, and try to detect mouse buttons again ,then it looks like these "lost" buttons are being detected as new ones because the event codes are suddenly changed after the restart. Interesting thing is, that it does not concern ALL buttons.

For "workaround" I have made up different configuration file every time this happened and previous configuration isn't working - then I can select between existing configurations to see, if any of them will work. It remains to be seen, how many different configurations will be made after some time :)

It is a strange problem, because it has not occured before (yes - I have checked mouse configuration in xorg.conf and it has not been changed in any way since the time before the problem surfaced), but at least I can live with it with this "workaround".

ffffff
January 22nd, 2008, 03:59 PM
What a great program! I love it, works great, and makes my MX Revolution a joy to use.

Is there any way to make a button equal to JUST a modifier key?

As in, "As long as I hold down button X, it acts like the ALT key is being held down?"

I use alt+left-hold to move my windows around all the time, and I'd love to be able to do this without having to hold down ALT on the keyboard. Thanks!

holotone
January 22nd, 2008, 04:21 PM
Why not map the button to Alt+Left Click and save yourself the trouble of holding down two keys at once?

ffffff
January 22nd, 2008, 04:31 PM
Why not map the button to Alt+Left Click and save yourself the trouble of holding down two keys at once?

Opps. Doh! Thanks, that works great!


---

Now I'm trying to get Scale in compiz to work correctly. How do you all set that up?

neptunix
January 23rd, 2008, 06:32 AM
I simple question :)
I've got Vx nano - it works fine, except pressing "Up" key.
By default this key seems to work as right-mouse-button - it simply opens right-click menu.
When i bind a different action - new action works with right-click menu simultaneously.
Can I get rid of default action?
Thanks

daou
January 23rd, 2008, 06:40 AM
I simple question :)
I've got Vx nano - it works fine, except pressing "Up" key.
By default this key seems to work as right-mouse-button - it simply opens right-click menu.
When i bind a different action - new action works with right-click menu simultaneously.
Can I get rid of default action?
Thanks

Check the btnx manual's troubleshooting section 12.2.1 for better xorg.conf InputDevice section values. If you are unsure, post your InputDevice section here and I'll point out what needs to be changed.

daou
January 23rd, 2008, 06:41 AM
Now it finally starts to look like I have found out what is going on with this occasional "some-mouse-buttons-not-working-after-restart" issue.

If I open bntx-config after finding out, that some buttons do not work, and try to detect mouse buttons again ,then it looks like these "lost" buttons are being detected as new ones because the event codes are suddenly changed after the restart. Interesting thing is, that it does not concern ALL buttons.

For "workaround" I have made up different configuration file every time this happened and previous configuration isn't working - then I can select between existing configurations to see, if any of them will work. It remains to be seen, how many different configurations will be made after some time :)

It is a strange problem, because it has not occured before (yes - I have checked mouse configuration in xorg.conf and it has not been changed in any way since the time before the problem surfaced), but at least I can live with it with this "workaround".

Do you suspect this has something to do with the deb packages?

daou
January 23rd, 2008, 07:09 AM
What a great program! I love it, works great, and makes my MX Revolution a joy to use.

Is there any way to make a button equal to JUST a modifier key?

As in, "As long as I hold down button X, it acts like the ALT key is being held down?"

I use alt+left-hold to move my windows around all the time, and I'd love to be able to do this without having to hold down ALT on the keyboard. Thanks!

Good to hear you find btnx useful. Although your issue was solved, it is possible to set the Keycode to a modifier key (they are also in the keycodes list).

Perhaps the next step is to implement a function button, that allows modified behavior to be sent with other buttons when it is pressed. However, this will not be done until btnx-config has been rewritten in C++ and that could take some time.

tim71
January 23rd, 2008, 07:22 AM
Do you suspect this has something to do with the deb packages?Actually not, because btnx is installed straight from the compiled source - and I am not sure how btnx itself can affect the event codes, that are coming from mouse input. And the codes are not changing randomly, but up to now I have 3 configurations - if buttons are not working after booting the system, then just switching to one of two other configurations has solved the problem.

P.S. Not sure can this be related to hotplugging/wait_for_sysfs thing or not - at least this the first thing I thought about...

daou
January 23rd, 2008, 08:59 AM
Actually not, because btnx is installed straight from the compiled source - and I am not sure how btnx itself can affect the event codes, that are coming from mouse input. And the codes are not changing randomly, but up to now I have 3 configurations - if buttons are not working after booting the system, then just switching to one of two other configurations has solved the problem.

P.S. Not sure can this be related to hotplugging/wait_for_sysfs thing or not - at least this the first thing I thought about...

Sounds like a great anti-btnx hack :).

btnx doesn't affect the event codes, it can only read from the event handler that sends the events. First we should establish whether the rawcodes are actually changing in the input handler or whether it is a problem with btnx's interpretation of them.

I would be interested in seeing the hexdumps from the mouse's event handler when a single button is being pressed (one that changes between boots). hexdumps before a change, then hexdumps after a change. You can hexdump by issuing the command
sudo hexdump /dev/input/eventXwhere X is the event handler number for the mouse.

Are you using any other software that could change the mouse behavior? Could you post your xorg.conf InputDevice section so I can make sure it's not a problem there. Could be a problem if your Driver or Device changes between boots (autodetection?).

neptunix
January 23rd, 2008, 07:22 PM
Check the btnx manual's troubleshooting section 12.2.1 for better xorg.conf InputDevice section values. If you are unsure, post your InputDevice section here and I'll point out what needs to be changed.

Thanks. Works fine now!

kondado
January 24th, 2008, 02:01 PM
I just created my account only for one thing:

Say thanks to daou for the "btnx" tool. And for the help on the MX Revolution mouse buttons on pages 6 and 7 ... Now I can use the Firefox the same way as I do on windows. This is a real improvement on productivity!

Thank you!

daou
January 24th, 2008, 03:28 PM
I just created my account only for one thing:

Say thanks to daou for the "btnx" tool. And for the help on the MX Revolution mouse buttons on pages 6 and 7 ... Now I can use the Firefox the same way as I do on windows. This is a real improvement on productivity!

Thank you!

Thanks for the positive feedback. It always makes the development and maintenance easier when I know it's of use to others. Keep enjoying btnx!

unabatedshagie
January 24th, 2008, 04:21 PM
Is anyone using btnx successfully with hardy?

The button detection wizard doesn't seem to detect any of the buttons except for the scroll wheel up and down.

I'm using the latest svn with a MX Revolution

tim71
January 24th, 2008, 05:53 PM
Sounds like a great anti-btnx hack :).

btnx doesn't affect the event codes, it can only read from the event handler that sends the events. First we should establish whether the rawcodes are actually changing in the input handler or whether it is a problem with btnx's interpretation of them.

I would be interested in seeing the hexdumps from the mouse's event handler when a single button is being pressed (one that changes between boots). hexdumps before a change, then hexdumps after a change. You can hexdump by issuing the command
sudo hexdump /dev/input/eventXwhere X is the event handler number for the mouse.

Are you using any other software that could change the mouse behavior? Could you post your xorg.conf InputDevice section so I can make sure it's not a problem there. Could be a problem if your Driver or Device changes between boots (autodetection?).
Section "InputDevice"

# generated from default
Identifier "Mouse0"
Driver "mouse"
Option "Protocol" "ExplorerPS/2"
Option "Device" "/dev/input/mice"
Option "Emulate3Buttons" "no"
Option "ZAxisMapping" "4 5"
EndSection
I do not remember changing it for a quite some time.

What comes to the event codes - actually they can be seen in btnx-config and they are different in these configuration files I have made by now.
When I see, that some of buttons are not working and try to detect buttons again, they are detected as new ones, but only once - if I try immediately same buttons again, then I get message "This button is already detected", so it does not look like buttons are generating duplicate events...

UPDATE: tried to change Xorg.conf to "Protocol" "auto" and "Device" "/dev/psaux" - will see, what happens now. At least all is working for a moment...
UPDATE 2: nope - same behaviour after making changes...

Gigamo
January 25th, 2008, 10:55 AM
Hi. I just got myself an MX Revolution, and I set up btnx + btnx config and it recognized all my buttons. I also mirrored my xorg.conf to the one in the troubleshooting section. However, none of my buttons except the scrollwheel are actually doing anything. The thumb buttons don't go back and forward in firefox, for example. Nothing works except scrolling and pressing left and right mousebuttons. And the button to change into free scrolling mode / click scrolling mode, that one works too (recovo or how its called). But that's it.

Anyone hjälp?

Neat little program btw.

arigram
January 25th, 2008, 11:17 AM
Is this tool or something similar for the configuration of mice going to be included in Hardy?

daou
January 25th, 2008, 12:02 PM
Hi. I just got myself an MX Revolution, and I set up btnx + btnx config and it recognized all my buttons. I also mirrored my xorg.conf to the one in the troubleshooting section. However, none of my buttons except the scrollwheel are actually doing anything. The thumb buttons don't go back and forward in firefox, for example. Nothing works except scrolling and pressing left and right mousebuttons. And the button to change into free scrolling mode / click scrolling mode, that one works too (recovo or how its called). But that's it.

Anyone hjälp?

Neat little program btw.

Did you enable the buttons with the Enabled checkbox?
Make sure btnx is running by executing it on the command line and see if it quits because of an error.
sudo btnxEDIT: what key combination are you using for firefox back&forward? Try using Alt+Left and Alt+Right

daou
January 25th, 2008, 12:07 PM
Is this tool or something similar for the configuration of mice going to be included in Hardy?

I don't know. The suggestion has been made but nothing has been decided. You can follow the situation here: https://bugs.launchpad.net/ubuntu/+bug/146160

Gigamo
January 25th, 2008, 12:09 PM
Did you enable the buttons with the Enabled checkbox?
Make sure btnx is running by executing it on the command line and see if it quits because of an error.
sudo btnx

EDIT: what key combination are you using for firefox back&forward?

Yep, I enabled all the buttons, and btnx is running.

I'm using the thumb buttons for firefox back/forward, but I have no idea how map keycodes or anything or bind keys to my mousebuttons etc. So i don't know which key combination you mean. :D

My xorg.conf:

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "true"
EndSection

Here's a look in my btnx buttons section for reference (all my buttons are similar to this one in terms of configuredness)

daou
January 25th, 2008, 12:48 PM
Yep, I enabled all the buttons, and btnx is running.

I'm using the thumb buttons for firefox back/forward, but I have no idea how map keycodes or anything or bind keys to my mousebuttons etc. So i don't know which key combination you mean. :D

My xorg.conf:

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "auto"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "true"
EndSectionHere's a look in my btnx buttons section for reference (all my buttons are similar to this one in terms of configuredness)

It seems you have not configured the mouse buttons to do anything. To configure buttons, select a key from the "Keycode" combobox/entry and set any (optional) modifier keys in the "Modifier #" comboboxes. For example, if button 4 is a thumb button and you want to use firefox back with it, do this:

Keycode: KEY_LEFT
Modifier 1: KEY_LEFTALT

Then restart btnx. By the way, you should name your buttons in a more intuitive way... like "Thumb button up" or similar so you can easily know which button you are editing.
Another example (for moving windows while holding a button over them):

Keycode: BTN_LEFT
Modifier 1: KEY_LEFTALT

If a Keycode starts with KEY_ it is a keyboard button. If it starts with BTN_ it is a mouse button. So the firefox example does a Alt+Left arrow combination. The second example does a Alt+Left mouse button combination.

EDIT: blazoner posted some useful key combos you can use: http://ubuntuforums.org/showpost.php?p=3812017&postcount=550