1

From a lot of time my bluetooth does not work on elementary OS. On Ubuntu is okay, in Windows also, but elementary OS bluetooth icon is always gray even if I switch it on from wingpanel and cannot discover any device. So, I have tried a lot of 'solutions' found by google and finally manage to found devices using blueman, but still cannot connect to audio devices or make file exchanges.

Does anyone know which commands I can use in order to reinstall the elementary OS bluetooth packages instead of installing some another apps like blueman, which do not work good as well?

the output of rfkill list command is

1: hci0: Bluetooth Soft blocked: yes Hard blocked: no

2

First, unblocking solution found there

rfkill unblock bluetooth systemctl enable bluetooth.service systemctl start bluetooth.service

afterwords the solution for the bluetooth audio from this link

sudo apt-get install pulseaudio-module-bluetooth pactl load-module module-bluetooth-discover

Then try deleting/removing the device from bluetooth devices and pair it again.

..and I have bluetooth audio working.

2

So, I tried a lot of different ways of doing this.

First, make sure your user is in the bluetooth group.

$ sudo usermod -G bluetooth -a <your_username>

Restarting your bluetooth service (and making sure it is enabled to start on boot) should be the next thing you try after checking the rfkill status - see other answers here on that.

$ sudo systemctl restart bluetooth    
$ sudo systemctl enable bluetooth
Synchronizing state of bluetooth.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable bluetooth

Finally, some bluetooth controllers need to first remove the definition - perhaps you dual boot, or have a previous install - and then add the definition back in.

I needed to use the bluetoothctl command line tool to remove and add back, perhaps because I needed to enter a PIN for my bluetooth-enabled amplifier. Like so...

$ bluetoothctl
[NEW] Controller 00:1B:63:43:9B:E6 imac [default]
[NEW] Device 00:F4:8D:2C:BD:27 STR-DH190
Agent registered
[STR-DH190]# help
Menu main:
Available commands:
-------------------
advertise                                         Advertise Options Submenu
scan                                              Scan Options Submenu
gatt                                              Generic Attribute Submenu
list                                              List available controllers
show [ctrl]                                       Controller information
select <ctrl>                                     Select default controller
devices                                           List available devices
paired-devices                                    List paired devices
system-alias <name>                               Set controller alias
reset-alias                                       Reset controller alias
power <on/off>                                    Set controller power
pairable <on/off>                                 Set controller pairable mode
discoverable <on/off>                             Set controller discoverable mode
agent <on/off/capability>                         Enable/disable agent with given capability
default-agent                                     Set agent as the default one
advertise <on/off/type>                           Enable/disable advertising with given type
set-alias <alias>                                 Set device alias
scan <on/off>                                     Scan for devices
info [dev]                                        Device information
pair [dev]                                        Pair with device
trust [dev]                                       Trust device
untrust [dev]                                     Untrust device
block [dev]                                       Block device
unblock [dev]                                     Unblock device
remove <dev>                                      Remove device
connect <dev>                                     Connect device
disconnect [dev]                                  Disconnect device
menu <name>                                       Select submenu
version                                           Display version
quit                                              Quit program
exit                                              Quit program
help                                              Display help about this program
[STR-DH190]# remove 00:F4:8D:2C:BD:27
[CHG] Device 00:F4:8D:2C:BD:27 ServicesResolved: no
Device has been removed
[CHG] Device 00:F4:8D:2C:BD:27 Connected: no
[DEL] Device 00:F4:8D:2C:BD:27 STR-DH190
[bluetooth]# scan on
Discovery started
[CHG] Controller 00:1B:63:43:9B:E6 Discovering: yes
[NEW] Device 00:F4:8D:2C:BD:27 STR-DH190
[bluetooth]# pair 00:F4:8D:2C:BD:27
Attempting to pair with 00:F4:8D:2C:BD:27
[CHG] Device 00:F4:8D:2C:BD:27 Connected: yes
Request PIN code
[STR-1m[agent] Enter PIN code: xxxx
[CHG] Device 00:F4:8D:2C:BD:27 Modalias: bluetooth:xxxxxxxxxxxxxxxx
[CHG] Device 00:F4:8D:2C:BD:27 ServicesResolved: yes
[CHG] Device 00:F4:8D:2C:BD:27 Paired: yes
Pairing successful
[CHG] Device 00:F4:8D:2C:BD:27 ServicesResolved: no
[CHG] Device 00:F4:8D:2C:BD:27 Connected: no
[CHG] Device 00:F4:8D:2C:BD:27 RSSI: -56
[CHG] Device 00:F4:8D:2C:BD:27 RSSI: -48
[bluetooth]# trust 00:F4:8D:2C:BD:27
[CHG] Device 00:F4:8D:2C:BD:27 Trusted: yes
Changing 00:F4:8D:2C:BD:27 trust succeeded
[bluetooth]# list
Controller 00:1B:63:43:9B:E6 imac [default]
[CHG] Device 00:F4:8D:2C:BD:27 RSSI: -56
[bluetooth]# system-alias big-imac
Changing big-imac succeeded
[CHG] Controller 00:1B:63:43:9B:E6 Alias: big-imac
[bluetooth]# info 00:F4:8D:2C:BD:27
Device 00:F4:8D:2C:BD:27 (public)
    Name: STR-DH190
    Alias: STR-DH190
    Class: 0x00240414
    Icon: audio-card
    Paired: yes
    Trusted: yes
    Blocked: no
    Connected: no
    LegacyPairing: yes
    UUID: Serial Port               (...)
    UUID: Audio Sink                (...)
    UUID: A/V Remote Control Target (...)
    UUID: A/V Remote Control        (...)
    UUID: PnP Information           (...)
    Modalias: bluetooth:xxxxxxxxxxxx
    RSSI: -56
[bluetooth]# exit
Agent unregistered
[DEL] Controller 00:1B:63:43:9B:E6 big-imac [default]
phil@imac:~$ 

You can now use the widget in the toolbar to control the connection(s) you just created, and the Bluetooth menu in System Settings works as expected.

Happy bluetoothing!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.