Difference between revisions of "Bluetooth mouse"
m (quick corrections)
(Merge from Bluetooth mouse configuration.)
|Line 3:||Line 3:|
This article to mouse
, the be the .
== Required software ==
== Required software ==
Revision as of 02:55, 6 May 2013
This article describes how to set up a Bluetooth mouse manually with no desktop assistance for Bluetooth. For example, a minimalist XFCE installation.
Prerequisites and tested hardware
The method described here is based in three steps, in this order:
- Make the PC learn about the bluetooth mouse.
- Grant the mouse permissions to connect.
- Make the mouse learn about the PC.
For the first two steps the utility called dbus-send is used (it is provided by dbus-core 1.2.24, a bluez dependency). For the last step we'll use the hidd tool (from bluez).
At least in the above reported bluez, dbus and X.Org versions it is not necessary to edit any system configuration file (in fact, the hidd service can perfectly be disabled in the bluetooth configuration).
You need thepackage from the extra repository.
The pertinent options in /etc/conf.d/bluetooth are
after that, start bluetooth services with
# systemctl enable bluetooth.service # systemctl start bluetooth.service
If you don't use systemd use following command instead
Finding out your mouse's bdaddr
It is of the form 12:34:56:78:9A:BC. Either find it in the documentation of your mouse, on the mouse itself or with the hcitool scan command.
No additional actions are necessary if the bluetooth service is started using systemd. If it does not work try following.
# modprobe -v btusb bluetooth hidp l2cap
loads the kernel modules you need, if they weren't loaded automatically.
(See below for some tips if you're stuck at this point)
Connecting the mouse
hidd --search hcitool inq
are good for device scanning (I needed to use sudo for 'hidd --search' to automatically connect mouse, searching worked even without sudo).
hidd --connect <bdaddr>
to actually connect.
will show your currently connected devices. The mouse should show up in this list. If it doesn't, press the reset button to make it discoverable.
Note: If you have the ipw3945 module loaded (wifi on HP computer) the bluetooth wont work.
Connecting the mouse at startup
# Arguments to hidd HIDD_OPTIONS="--connect <enter here your bluetooth mouse address>"
and test the new settings:
/etc/rc.d/bluetooth stop hidd --killall (drop mouse connection) /etc/rc.d/bluetooth start
Note: The above instructions to start the mouse at startup do not work with the now outdated 3.11 bluetooth packages. New versions such as the current (3.32) packages are not affected. If you are using an older version, then to start the mouse at startup, add:
hidd --connect <enter here your bluetooth mouse address (No capitals!!!)>
to your /etc/rc.local file.
Note #2: You can connect any bluetooth mouse and/or keyboard without any further configuration and without knowing the device address. You can do it by adding the --master and/or --server option in HIDD_OPTIONS depending on your device.
If you have trouble with your USB dongle, you may also want to try
# modprobe -v rfcomm
At this point, you should get an hci0 device with
# hcitool dev
Sometimes the device is not active right away - try starting the interface with
# hciconfig hci0 up
and searching for devices as shown above.