You are not logged in.

#1 2009-06-02 10:43:35

subatomic
Member
From: Berlin
Registered: 2005-06-26
Posts: 180

does anyone have bluetooth working? [solved]

I can't believe this. For months I can't even use a bluetooth mouse!

Once working fine, then there appeared to be a bluez issue, so I got the latest release 4.40
got my /var/lib/bluetooth/MAC/trusts file and finally had my mouse back until...

after a few minutes it lost the connection and refuses to reconnect.

Now kbluetooth won't start, that is, it doesn't appear and says it's already running!

I've tried blueman but that wants to pair the mouse with a passkey.

So if anyone has a working kbluetooth please post the configuration here.

Many thanks!

Last edited by subatomic (2009-06-28 14:46:16)

Offline

#2 2009-06-04 08:21:22

subatomic
Member
From: Berlin
Registered: 2005-06-26
Posts: 180

Re: does anyone have bluetooth working? [solved]

OK I've read all wiki and the forums, pieced it all together and have narrowed it down.

I've got HIDD_OPTIONS="--connect 00:12:A1:61:BC:1D" in the daemon but it won't autoconnect. When I run
hidd --connect 00:12:A1:61:BC:1D after booting it says "host is down" so I have to make the mouse discoverable then it will connect.

But still after a few minutes it loses the connection and I have to reset it and run hidd.

Now obviously my question is how to auto-connect without having to reset the mouse?

I've edited the title of this post since I've abandoned kbluetooth and relying solely on bluez.

Last edited by subatomic (2009-06-04 09:10:43)

Offline

#3 2009-06-04 10:49:20

.:B:.
Forum Fellow
Registered: 2006-11-26
Posts: 5,819

Re: does anyone have bluetooth working? [solved]

Bluez 4.x imho is a total POS (excuse my language).

I have tried like ten times to get it to work - my setup, a bluetooth Apple aluminum keyboard and a bluetooth Logitech mouse - work mighty fine on bluez 3.x. From the moment I switch to 4.x it stops reconnecting and reauthenticating on reboots/wakeups/cold start. On top of that, documentation for 4.x is completely non-existent. Even my brainwaves are more documented than bluez 4.x (and more stable tongue).

As for the documentation (or lack thereof): configuration files are awfully silent about the options you may or would like to use, so is the central bluetoothd daemon. The project's page has documentation, but 99% of it is for 3.x, and what's there for 4.x doesn't get you any further.


Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy

Offline

#4 2009-06-05 12:14:59

subatomic
Member
From: Berlin
Registered: 2005-06-26
Posts: 180

Re: does anyone have bluetooth working? [solved]

I read on ubuntu that some were changing the mode from "discoverable" to "always visible". I'd try this but I've no idea how or where to do it with the arch bluetooth .conf files.

Offline

#5 2009-06-08 19:54:59

mits
Member
From: Bucharest/Romania
Registered: 2008-01-10
Posts: 129

Re: does anyone have bluetooth working? [solved]

I have same unsolved problem with usb bluetooth and bluetooth/kdebluetooth/blueman/gnome-bluetooth, and is working nothing.
Sometime with newest bluez and kdebluetooth4 I can send but I can't recive.
I try old packages from here: http://schlunix.org/archlinux/, but i can't solve these.
Old bluez libs don't work with newest kdebluetooth4/blueman.
If does have someone any solution for these problem please post it.

Offline

#6 2009-06-11 00:27:10

dmartins
Member
Registered: 2006-09-23
Posts: 360

Re: does anyone have bluetooth working? [solved]

subatomic, I don't mean to highjack your thread here.. Just thought we could all pool our resources on this one wink

I too am struggling with this. Any "guides" I find online seem to refer to an older version of bluez where the config files are different. At this point, I am trying to pair my mouse with my laptop. I'd like the connection to be made automatically at boot using the bluetooth daemon (and hidd daemon if need be). I'd like to avoid any GUIs.

If I start the bluetooth daemon and put the mouse in discoverable mode, I can connect to it using hidd --search. Most guides mention passing the --connect <address> option to hidd but this only seems to work if the mouse is already in discoverable mode. I'd rather not have to do this every time I want to get the mouse working. I get the impression that my laptop needs to remember the mouse somehow and that "pairing" them would do this, but I have no idea what config file I need to edit to accomplish this.

Has anyone figured this out?

Offline

#7 2009-06-19 10:56:11

subatomic
Member
From: Berlin
Registered: 2005-06-26
Posts: 180

Re: does anyone have bluetooth working? [solved]

I'm just going to bump this

Offline

#8 2009-06-22 02:49:50

biloky
Member
Registered: 2008-03-02
Posts: 61

Re: does anyone have bluetooth working? [solved]

@subatomic: could you try upgrading your kernel to 2.6.30 in testing? My case was: I can pair my mouse using bluetooth-applet (gnome) and it will function properly.  But after it gets disconnected (either timeout or turning it off then on), it refuses to connect. Using hcidump, I can see it connects, and immediately disconnects when I move the mouse. Upgrading the kernel to 2.6.30 (testing) and bluez to 4.41 solved this problem. And the mouse automatically gets connected on bootup too.

Offline

#9 2009-06-23 09:50:06

bukanan
Member
Registered: 2009-06-23
Posts: 2

Re: does anyone have bluetooth working? [solved]

I had the same problem, my bluetooth mouse stop working when I upgraded to bluez 4.x
    $hidd --connect xx:xx:xx:xx:xx:xx --server
is deprecated and documentation about bluez ActivateService is not working with bluez4.x:
    $dbus-send --system --print-reply --dest=org.bluez /org/bluez org.bluez.Manager.DefaultAdapter
    Error org.freedesktop.DBus.Error.UnknownMethod: Method "DefaultAdapter" with signature "" on interface "org.bluez.Manager" doesn't exist

Google suggest me to install d-feet and look into dbus to correct the python scripts and finally I got my bt mouse back again.
bt_mouse_create.py:
    import dbus
    bus = dbus.SystemBus()
    manager = dbus.Interface(bus.get_object('org.bluez', '/'), 'org.bluez.Manager')
    adapterpath = manager.DefaultAdapter()
    adapter = dbus.Interface(bus.get_object('org.bluez', adapterpath), 'org.bluez.Adapter')
    devicepath = adapter.CreateDevice('xx:xx:xx:xx:xx:xx')
    print devicepath

Replace xx with your mouse's mac
Run once and take note about the output string.
Replace it in the next script.

bt_mouse_connect.py:
    import dbus
    bus = dbus.SystemBus()
    devicepath='/org/bluez/7077/hci0/dev_xx_xx_xx_xx_xx_xx'
    device = dbus.Interface(bus.get_object('org.bluez', devicepath), 'org.bluez.Input')
    device.Connect()


I Hope it works for you too.

Offline

#10 2009-06-23 10:11:59

panosk
Member
From: Athens, Greece
Registered: 2008-10-29
Posts: 241

Re: does anyone have bluetooth working? [solved]

Hi,

I have been using a Microsoft Bluetooth Notebook mouse with success for a while now. A couple of days ago I performed a fresh install of Arch 64bit, and bluetooth again works as expected. Here are the steps I followed (Dell XPS M1330 lap with KDE):

After installing base system and KDE, I installed kbluetooth. I added HIDD_OPTIONS="--connect MOUSE-ADDRESS" in /etc/conf.d/bluetooth and added the bluetooth daemon in rc.conf (I am not sure if this is necessary though). Then I added an autostart entry in KDE for kbluetooth. After rebooting, kbluetooth asked if I wanted to trust the mouse. Answering yes, made the connection permanent, so the mouse succesfully reconnects after suspending, rebooting, activating/deactivating bluetooth module, etc. Before adding the autostart entry for kbluetooth, I could still connect the mouse but the option to make it trusted wouldn't appear, so I had to manually connect it every time.

I would suggest you first try the above steps without tampering the /etc/conf.d/bluetooth file and see if it works.

Panos

Offline

#11 2009-06-24 09:42:49

bukanan
Member
Registered: 2009-06-23
Posts: 2

Re: does anyone have bluetooth working? [solved]

I forgot to mention that you need to change the 'Trust' property to get the mouse reconnected automatically on reboot.

    import dbus
    bus = dbus.SystemBus()
    manager = dbus.Interface(bus.get_object('org.bluez', '/'), 'org.bluez.Manager')
    adapterpath = manager.DefaultAdapter()
    adapter = dbus.Interface(bus.get_object('org.bluez', adapterpath), 'org.bluez.Adapter')
    devicepath = adapter.FindDevice('XX:XX:XX:XX:XX:XX')
    device = dbus.Interface(bus.get_object("org.bluez", devicepath), "org.bluez.Device")
    value = dbus.Boolean(1)
    device.SetProperty("Trusted", value)

I'm using a logitech v470 mouse.

Offline

#12 2009-06-24 12:03:09

dmartins
Member
Registered: 2006-09-23
Posts: 360

Re: does anyone have bluetooth working? [solved]

bukanan, that looks like exactly what I need. I will give it a try a bit later today.

Did you write those scripts yourself? Where did you find information on the bluez dbus interface?

Offline

#13 2009-06-24 16:15:09

dmartins
Member
Registered: 2006-09-23
Posts: 360

Re: does anyone have bluetooth working? [solved]

I've been playing around with python and dbus this morning and now have my mouse working just the way I had hoped. As soon as it comes within range of my laptop it is recognized and begins to work. The scripts you posted worked perfectly, bukanan. Thanks a lot.

I'd like to write a lightweight cli bluetooth manager at some point. At least something that can pair a mouse or keyboard and remove them again later if wanted. I don't see why I should have to install 100+ MB to easily set up my mouse using blueman!

Offline

#14 2009-06-26 12:22:31

mukl
Member
From: Vienna, Austria
Registered: 2008-01-30
Posts: 43

Re: does anyone have bluetooth working? [solved]

I got my bluetooth mouse working now.

I installed bluez 4.40 and disabled the hidd server in /etc/conf.d/bluetooth (which is the case by default).

Now the mouse is recognized and working in kdm and in the kde-sessions.

I think that kdebluetooth interferes with the bluez hidd server, because i recognized that the mouse was repeatetly connecting for a short time before i did above steps.

Offline

#15 2009-06-28 14:43:38

subatomic
Member
From: Berlin
Registered: 2005-06-26
Posts: 180

Re: does anyone have bluetooth working? [solved]

I don't believe it! It works!

I've had the 2.6.30 kernel since it was in testing and had bluez-4.40 but it was the upgrade to 4.42 that did it.
Perhaps now Arch will finally update BlueZ in the repository where it is stuck at 4.39

I hope it's working for everyone else, I'm tagging this as solved.

Offline

#16 2009-07-26 23:52:14

codonnell
Member
Registered: 2009-07-26
Posts: 1

Re: does anyone have bluetooth working? [solved]

subatomic wrote:

I don't believe it! It works!

I've had the 2.6.30 kernel since it was in testing and had bluez-4.40 but it was the upgrade to 4.42 that did it.
Perhaps now Arch will finally update BlueZ in the repository where it is stuck at 4.39

I hope it's working for everyone else, I'm tagging this as solved.

Hi, how did you upgrade to 4.42?

Last edited by codonnell (2009-07-27 00:33:26)

Offline

#17 2009-12-25 06:48:29

venky80
Member
Registered: 2007-05-13
Posts: 1,002

Re: does anyone have bluetooth working? [solved]

could someone tell me how to pair my keyboard after it sleeps dude to non usage?


Acer Aspire V5-573P Antergos KDE

Offline

#18 2009-12-27 01:09:33

venky80
Member
Registered: 2007-05-13
Posts: 1,002

Re: does anyone have bluetooth working? [solved]

My keyboard always asks to be retrusted after resuming from sleep. I did intially set the keyboard with "permanent trust" but i lose it after the keyboard resumes from sleep.
here is the bug i opened in kde
https://bugs.kde.org/show_bug.cgi?id=220207


Acer Aspire V5-573P Antergos KDE

Offline

Board footer

Powered by FluxBB