You are not logged in.

#1 2014-12-11 16:46:04

samtech09
Member
Registered: 2014-12-10
Posts: 50

[solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

I have arch with Gnome and KDE desktop.

In Gnome when i turn off Bluetooth from Settings or from nm applet, it also turn off bluetooth hardware (LED turns off too).
But on KDE desktop, if i turn off bluetooth from System Settings or from nm applet, it turn it off only at software but not the hardware (LED doesn't turn off).

Here is info about bluetooth device

[samtech@M4800 ~]$ dmesg | grep Blue
[   10.026565] Bluetooth: Core ver 2.19
[   10.026576] Bluetooth: HCI device and connection manager initialized
[   10.026580] Bluetooth: HCI socket layer initialized
[   10.026581] Bluetooth: L2CAP socket layer initialized
[   10.026585] Bluetooth: SCO socket layer initialized
[   10.076714] Bluetooth: hci0: read Intel version: 370710018002030d00
[   10.103738] Bluetooth: hci0: Intel Bluetooth firmware file: intel/ibt-hw-37.7.10-fw-1.80.2.3.d.bseq
[   10.307009] Bluetooth: hci0: Intel Bluetooth firmware patch completed and activated
[samtech@M4800 ~]$
[samtech@M4800 ~]$ bluetoothctl 
[NEW] Controller 80:19:34:97:4D:97 M4800 [default]
[bluetooth]# show
Controller 80:19:34:97:4D:97
        Name: M4800
        Alias: M4800
        Class: 0x1c010c
        Powered: yes
        Discoverable: no
        Pairable: yes
        UUID: PnP Information           (00001200-0000-1000-8000-00805f9b34fb)
        UUID: Generic Access Profile    (00001800-0000-1000-8000-00805f9b34fb)
        UUID: Generic Attribute Profile (00001801-0000-1000-8000-00805f9b34fb)
        UUID: A/V Remote Control        (0000110e-0000-1000-8000-00805f9b34fb)
        UUID: A/V Remote Control Target (0000110c-0000-1000-8000-00805f9b34fb)
        UUID: Message Notification Se.. (00001133-0000-1000-8000-00805f9b34fb)
        UUID: Message Access Server     (00001132-0000-1000-8000-00805f9b34fb)
        UUID: Phonebook Access Server   (0000112f-0000-1000-8000-00805f9b34fb)
        UUID: IrMC Sync                 (00001104-0000-1000-8000-00805f9b34fb)
        UUID: OBEX File Transfer        (00001106-0000-1000-8000-00805f9b34fb)
        UUID: OBEX Object Push          (00001105-0000-1000-8000-00805f9b34fb)
        UUID: Vendor specific           (00005005-0000-1000-8000-0002ee000001)
        UUID: Audio Source              (0000110a-0000-1000-8000-00805f9b34fb)
        UUID: Audio Sink                (0000110b-0000-1000-8000-00805f9b34fb)
        Modalias: usb:v1D6Bp0246d0519
        Discovering: no

I tried to turn it on/off using hciconfig hci0 up/down and bluetoothctl's power on/off commands but all are only turning it off at software.

How do i turn off bluetooth radio at software as well as at hardware from KDE as it is doing from Gnome ?

Last edited by samtech09 (2014-12-12 15:31:32)

Offline

#2 2014-12-11 17:02:42

TheSaint
Member
From: my computer
Registered: 2007-08-19
Posts: 1,523

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

# rfkill list

What program/applet are you using on gnome to disable bluetooth?


do it good first, it will be faster than do it twice the saint wink

Offline

#3 2014-12-11 17:41:45

samtech09
Member
Registered: 2014-12-10
Posts: 50

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

TheSaint wrote:

What program/applet are you using on gnome to disable bluetooth?

Bluez and gnome-bluetooth

here is rfkill list output

From KDE - It gives same output regardless of bluetooth turned on/off from system settings.

[samtech@M4800 ~]$ rfkill list
0: hci0: Bluetooth
	Soft blocked: no
	Hard blocked: no
1: dell-wifi: Wireless LAN
	Soft blocked: no
	Hard blocked: no
2: dell-bluetooth: Bluetooth
	Soft blocked: no
	Hard blocked: no
3: phy0: Wireless LAN
	Soft blocked: no
	Hard blocked: no

From Gnome - Bluetooth turned On

[samtech@M4800 ~]$ rfkill list
0: hci0: Bluetooth
	Soft blocked: no
	Hard blocked: no
1: dell-wifi: Wireless LAN
	Soft blocked: no
	Hard blocked: no
2: dell-bluetooth: Bluetooth
	Soft blocked: no
	Hard blocked: no
3: phy0: Wireless LAN
	Soft blocked: no
	Hard blocked: no

From Gnome - Bluetooth turned Off

[samtech@M4800 ~]$ rfkill list
1: dell-wifi: Wireless LAN
	Soft blocked: no
	Hard blocked: no
2: dell-bluetooth: Bluetooth
	Soft blocked: yes
	Hard blocked: no
3: phy0: Wireless LAN
	Soft blocked: no
	Hard blocked: no
[samtech@M4800 ~]$ 

Offline

#4 2014-12-12 06:02:30

TheSaint
Member
From: my computer
Registered: 2007-08-19
Posts: 1,523

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

My conclusion : gnome uses soft blocking the bluetooth.
You may go back to KDE and in a console

# rfkill block bluetooth

Then see what happen and resuming by

# rfkill unblock bluetooth

do it good first, it will be faster than do it twice the saint wink

Offline

#5 2014-12-12 14:17:33

samtech09
Member
Registered: 2014-12-10
Posts: 50

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

That's great!!
It's working!

Is there any way to tell KDE applet to run those commands when i turn on/off bluetooth from applet menu or from System Settings ?

Offline

#6 2014-12-12 15:07:15

TheSaint
Member
From: my computer
Registered: 2007-08-19
Posts: 1,523

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

That's a bit of reading bluedevil code. Sorry I can't help you.


do it good first, it will be faster than do it twice the saint wink

Offline

#7 2014-12-12 15:30:20

samtech09
Member
Registered: 2014-12-10
Posts: 50

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

No problem, i can live with it and can manually issue command when required.

Anyways, it was a great help. Thanks a lot.

I started loving Arch smile

Offline

#8 2014-12-12 16:45:12

TheSaint
Member
From: my computer
Registered: 2007-08-19
Posts: 1,523

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

You may write a shell script that will keep watching the bluetooth status and issue the command for you.


do it good first, it will be faster than do it twice the saint wink

Offline

#9 2014-12-12 17:24:12

samtech09
Member
Registered: 2014-12-10
Posts: 50

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

Ya, i will try that.
But first i need to consult wiki to know how to watch bluetooth status.

Offline

#10 2014-12-12 17:58:20

l0vot
Member
Registered: 2011-08-26
Posts: 117

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

samtech09 wrote:

Ya, i will try that.
But first i need to consult wiki to know how to watch bluetooth status.

You could make a couple custom application launchers that you could click to control bluetooth. One for off and another for on, or if you want to get fancy write a script that works as a toggle. I did something similar to control cpu frequency scaling. I assume you can  add custom items to Gnome panels and KDE panels. It's been a while since I tried using Gnome3 or KDE. This solution will work regardless of desktop environment provided you can make custom items.

Last edited by l0vot (2014-12-12 17:59:59)

Offline

#11 2014-12-12 18:20:47

samtech09
Member
Registered: 2014-12-10
Posts: 50

Re: [solved]Turn on/off bluetooth hardware working in GNOME but not in KDE

Just wrote a toggle script and assigned keyboard shortcut Ctrl+Alt+B
Working like a charm smile

Offline

Board footer

Powered by FluxBB