Bluetooth issue headphones Philips SHB3060 [Solved]

Issues Related to Hardware (Sound, Video, Printers, Scanners, Webcams, Touchpads, Keyboards, Sensors, Drives, GRUB, etc.)

Moderator: Moderators

Post Reply
User avatar
sabaton
Baby Hen
Posts: 5
Joined: Tue Apr 17, 2018 14:28
Location: Belgium

Bluetooth issue headphones Philips SHB3060 [Solved]

Post by sabaton » Tue Apr 17, 2018 15:25

Hi all. New Sabayon user here! Switched from Fedora and very pleased with Sabayon so far. Unfortunately, I'm facing a few issues that I've been desperately trying to resolve so your input would be much appreciated.

One of the most painful issues I'm having is getting my Bluetooth headphones to work. As I suppose most of us do, I'm constantly listening to music while I'm busy so I really need these to work properly. I did manage to use them correctly under Fedora (though it was never exactly plug & play) but this time I'm out of luck.

This is the system I'm running:

Code: Select all

Linux sabayon.local 4.15.0-sabayon #1 SMP Sun Apr 1 16:11:26 UTC 2018 x86_64 Intel(R) Core(TM) i3-6006U CPU @ 2.00GHz GenuineIntel GNU/Linux
Sabayon Linux 17.03 amd64 KDE
Sabayon Linux[b] amd64 18.04
I am running KDE 5.12 as my desktop.

Here's my dmesg output for Bluetooth:

Code: Select all

$ dmesg | grep -i bluetooth
[    2.736196] usb 1-8: Product: Bluetooth Radio 
[   27.847559] Bluetooth: Core ver 2.22
[   27.847561] Bluetooth: Starting self testing
[   27.847562] Bluetooth: Finished self testing
[   27.847583] Bluetooth: HCI device and connection manager initialized
[   27.847588] Bluetooth: HCI socket layer initialized
[   27.847592] Bluetooth: L2CAP socket layer initialized
[   27.847599] Bluetooth: SCO socket layer initialized
[   28.228251] Bluetooth: hci0: rtl: examining hci_ver=06 hci_rev=000b lmp_ver=06 lmp_subver=8723
[   28.228255] Bluetooth: hci0: rtl: loading rtl_bt/rtl8723b_config.bin
[   28.258846] bluetooth hci0: Direct firmware load for rtl_bt/rtl8723b_config.bin failed with error -2
[   28.258857] Bluetooth: hci0: rtl: loading rtl_bt/rtl8723b_fw.bin
[   28.283256] Bluetooth: hci0: rom_version status=0 version=1
[   28.283269] Bluetooth: hci0: cfg_sz 0, total size 22496
[   35.997941] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[   35.997945] Bluetooth: BNEP filters: protocol multicast
[   35.997951] Bluetooth: BNEP socket layer initialized
[   45.863041] Modules linked in: ip6table_nat(+) nf_conntrack_ipv6 nf_defrag_ipv6 nf_nat_ipv6 ip6table_mangle ip6table_security ip6table_raw iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack iptable_mangle iptable_security iptable_raw ebtable_filter ebtables ip6table_filter ip6_tables iptable_filter ip_tables x_tables bnep mmc_block rtsx_pci_sdmmc mmc_core rtsx_pci_ms memstick iTCO_wdt iTCO_vendor_support intel_rapl uvcvideo x86_pkg_temp_thermal intel_powerclamp hid_multitouch coretemp videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 videobuf2_core videodev kvm_intel media snd_hda_codec_hdmi kvm btusb btrtl btbcm joydev irqbypass btintel rtl8723be bluetooth btcoexist crct10dif_pclmul rtl8723_common rtl_pci rtlwifi snd_soc_skl mac80211 snd_soc_skl_ipc snd_soc_sst_ipc crc32_pclmul
[  106.628224] Bluetooth: RFCOMM TTY layer initialized
[  106.628239] Bluetooth: RFCOMM socket layer initialized
[  106.628257] Bluetooth: RFCOMM ver 1.11
[ 1259.746416] Bluetooth: Unexpected start frame (len 12)
As you can see, it mentions

Code: Select all

bluetooth hci0: Direct firmware load for rtl_bt/rtl8723b_config.bin failed with error -2
I managed to downloaded the file thanks to others who reported similar issues elsewhere. However, I'm not sure where to actually put the file under Sabayon as there is no /usr/lib/firmware directory.

I've had to play around restaring bluetooth.service and Pulseaudio, reconnecting through bluetoothctl or the bluetooth manager and use the following to get it to use a2dp as it initially would always fail:

Code: Select all

$ sudo systemctl restart bluetooth; pulseaudio -k; pulseaudio --start
$ bluetoothctl 
$ pacmd set-card-profile bluez_card.00_11_67_2B_8C_5C a2dp_sink                                            
Failed to set card profile to 'a2dp_sink'.
I did get it to work by selecting "off" as profile, then repeating the above steps and selecting a2dp_sink. Even so, the result is unstable and audio playback involves lots of skipping. Sometimes the connection is lost so I have to reconnect but then there's no ouput, etc. It's really quite a mess.

Moreover, after a system reboot it no longer works and I need to repeat the tedious process of restarting the Bluetooth service, Pulseaudio, disconnecting and reconnecting my device and tampering with it until it works.If at all.

On a previous Sabayon install (amd64 17.03 GNOME edition, upgraded to 18.04, using Cinnamon) I had to take similar steps. Installing the package linux_firmware and rebooting somehow did the trick and made the firmware error go away. No more skipping, just smooth playback, but I was still forced to do a systemctl restart bluetooth manually for some bizarre reason.

Am I overlooking something? Please note that I'm running the latest available updates of Pulseaudio (11.1) and Bluez (5.48).

Does anyone of you have any suggestions? Thanks!
Last edited by sabaton on Wed Apr 18, 2018 20:07, edited 1 time in total.

User avatar
sabaton
Baby Hen
Posts: 5
Joined: Tue Apr 17, 2018 14:28
Location: Belgium

Re: Bluetooth issue headphones Philips SHB3060

Post by sabaton » Tue Apr 17, 2018 21:22

Update

I did finally figure out I had to put the rtl8723b_config.bin file into the /usr/lib64/rtl_bt/ folder. It was missing there. Having done that, I rebooted and no longer had any error message in Dmesg:

Code: Select all

$ dmesg | grep -i bluetooth
[    2.998856] usb 1-8: Product: Bluetooth Radio 
[   46.940554] Bluetooth: Core ver 2.22
[   46.940556] Bluetooth: Starting self testing
[   46.940556] Bluetooth: Finished self testing
[   46.940574] Bluetooth: HCI device and connection manager initialized
[   46.940578] Bluetooth: HCI socket layer initialized
[   46.940581] Bluetooth: L2CAP socket layer initialized
[   46.940586] Bluetooth: SCO socket layer initialized
[   47.423094] Bluetooth: hci0: rtl: examining hci_ver=06 hci_rev=000b lmp_ver=06 lmp_subver=8723
[   47.423096] Bluetooth: hci0: rtl: loading rtl_bt/rtl8723b_config.bin
[   47.495666] Bluetooth: hci0: rtl: loading rtl_bt/rtl8723b_fw.bin
[   47.511074] Bluetooth: hci0: rom_version status=0 version=1
[   47.511086] Bluetooth: hci0: cfg_sz 44, total size 22540
[   50.813578] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[   50.813580] Bluetooth: BNEP filters: protocol multicast
[   50.813583] Bluetooth: BNEP socket layer initialized
[   71.284437] Bluetooth: RFCOMM TTY layer initialized
[   71.284445] Bluetooth: RFCOMM socket layer initialized
[   71.284452] Bluetooth: RFCOMM ver 1.11
So far, so good.

Although I'm not sure it was necessary, I installed bluez-firmware and restarted the bluetooth service. I once again attempted to connect to my headphones, but got "Device is unreachable" using the GUI.

I decided to remove the headphones entry, restarted the bluetooth service, then paired the headphones again using bluetoothctl which worked just fine. It managed to connect but then suddenly disconnected for some reason, and when I tried to reconnect the headphones I once again was stuck with "Device is unreachable" even though the headphones were most certainly pairable.

I rebooted and repeated all these steps several times but still the problem persists. Using bluetoothctl leads to the same error. Unless my Linux installation is somehow cursed, I still believe there's a normal solution to this not involving any magic so any input would be very much appreciated. :mrgreen:

But for now, back to the drawing board:

Code: Select all

[bluetooth]# connect 00:11:67:2B:8C:5C 
Attempting to connect to 00:11:67:2B:8C:5C
Failed to connect: org.bluez.Error.Failed
while using wired headphones (ugh).

User avatar
sabaton
Baby Hen
Posts: 5
Joined: Tue Apr 17, 2018 14:28
Location: Belgium

Re: Bluetooth issue headphones Philips SHB3060

Post by sabaton » Tue Apr 17, 2018 22:32

Update #2

I disabled laptop-mode and rebooted the system. It booted with the following:

Code: Select all

[  113.764954] Bluetooth: Core ver 2.22
[  113.764955] Bluetooth: Starting self testing
[  113.764956] Bluetooth: Finished self testing
[  113.764970] NET: Registered protocol family 31
[  113.764970] Bluetooth: HCI device and connection manager initialized
[  113.764973] Bluetooth: HCI socket layer initialized
[  113.764974] Bluetooth: L2CAP socket layer initialized
[  113.764978] Bluetooth: SCO socket layer initialized
[  113.815093] usbcore: registered new interface driver btusb
[  113.816126] Bluetooth: hci0: rtl: examining hci_ver=06 hci_rev=000b lmp_ver=06 lmp_subver=8723
[  113.816129] Bluetooth: hci0: rtl: loading rtl_bt/rtl8723b_config.bin
[  113.854499] Bluetooth: hci0: rtl: loading rtl_bt/rtl8723b_fw.bin
[  113.870121] Bluetooth: hci0: rom_version status=0 version=1
[  113.870141] Bluetooth: hci0: cfg_sz 44, total size 22540
and

Code: Select all

[  130.407998] ------------[ cut here ]------------
[  130.408031] rtl8723be: error H2C cmd because of Fw download fail!!!
[  130.408081] WARNING: CPU: 1 PID: 33 at drivers/net/wireless/realtek/rtlwifi/rtl8723be/fw.c:227 rtl8723be_fill_h2c_cmd+0x3da/0x410 [rtl8723be]
[  130.408134] Modules linked in: ebtable_nat ebtable_broute bridge stp llc ip6table_nat nf_conntrack_ipv6 nf_defrag_ipv6 nf_nat_ipv6 ip6table_mangle ip6table_security ip6table_raw iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack iptable_mangle iptable_security iptable_raw ebtable_filter ebtables ip6table_filter ip6_tables iptable_filter ip_tables x_tables bnep uvcvideo videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 videobuf2_core videodev media uas mmc_block iTCO_wdt iTCO_vendor_support joydev rtsx_pci_ms btusb btrtl hid_multitouch btbcm btintel memstick bluetooth rtsx_pci_sdmmc mmc_core ecdh_generic intel_rapl x86_pkg_temp_thermal intel_powerclamp snd_hda_codec_hdmi rtl8723be coretemp kvm_intel btcoexist snd_soc_skl rtl8723_common kvm snd_soc_skl_ipc rtl_pci snd_soc_sst_ipc
[  130.408431]  rtlwifi snd_hda_codec_realtek snd_soc_sst_dsp mac80211 irqbypass snd_hda_ext_core snd_hda_codec_generic crct10dif_pclmul efi_pstore cfg80211 snd_soc_acpi crc32_pclmul crc32c_intel ghash_clmulni_intel snd_soc_core snd_compress ac97_bus snd_pcm_dmaengine i2c_i801 idma64 efivars pcbc processor_thermal_device intel_lpss_pci aesni_intel crypto_simd glue_helper int340x_thermal_zone intel_lpss cryptd snd_hda_intel input_leds asus_nb_wmi asus_wmi rtsx_pci pcspkr serio_raw sparse_keymap tpm_crb intel_soc_dts_iosf shpchp intel_pch_thermal i2c_hid tpm_tis tpm_tis_core tpm acpi_pad int3400_thermal asus_wireless acpi_thermal_rel sch_fq_codel efivarfs ipv6 crc_ccitt dm_thin_pool dm_persistent_data dm_bio_prison dm_service_time dm_round_robin dm_queue_length dm_multipath dm_log_userspace dm_flakey
[  130.408725]  dm_delay virtio_pci virtio_scsi virtio_blk virtio_console virtio_balloon xts aes_x86_64 sha512_generic sha256_generic iscsi_tcp libiscsi_tcp ixgb ixgbe samsung_sxgbe tulip cxgb cxgb4 vxge bonding vxlan ip6_udp_tunnel udp_tunnel macvlan vmxnet3 virtio_net virtio_ring virtio tg3 sky2 pcnet32 igb ptp pps_core dca e1000 atl1c fuse overlay xfs nfs lockd grace sunrpc jfs reiserfs ext4 jbd2 fscrypto ext2 mbcache firewire_core sl811_hcd xhci_plat_hcd ohci_pci ohci_hcd uhci_hcd ehci_pci ehci_hcd lpfc nvmet_fc nvmet configfs qla2xxx nvme_fc nvme_fabrics sx8 imm parport pata_pcmcia pcmcia hid_generic snd_hda_codec r8169 snd_hda_core snd_hwdep i915 snd_pcm snd_timer snd mii drm_kms_helper drm intel_gtt agpgart xhci_pci fb_sys_fops syscopyarea sysfillrect xhci_hcd sysimgblt i2c_algo_bit
[  130.409037] CPU: 1 PID: 33 Comm: kworker/1:1 Not tainted 4.15.0-sabayon #1
[  130.409067] Hardware name: ASUSTeK COMPUTER INC. X541UAK/X541UAK, BIOS X541UAK.306 07/05/2017
[  130.409107] Workqueue: rtl8723be_pci rtl_c2hcmd_wq_callback [rtlwifi]
[  130.409138] RIP: 0010:rtl8723be_fill_h2c_cmd+0x3da/0x410 [rtl8723be]
[  130.409166] RSP: 0018:ffffc90001a03d70 EFLAGS: 00010286
[  130.409191] RAX: 0000000000000037 RBX: ffff88034cd51500 RCX: 0000000000000006
[  130.409233] RDX: 0000000000000007 RSI: 0000000000000092 RDI: ffff88035ec96850
[  130.409263] RBP: 0000000000000000 R08: 0000000000000000 R09: 00000000000003e2
[  130.409294] R10: ffffc90001933e98 R11: ffffffff8210c920 R12: 0000000000000000
[  130.409325] R13: 0000000000000000 R14: ffffc90001a03e07 R15: dead000000000100
[  130.409356] FS:  0000000000000000(0000) GS:ffff88035ec80000(0000) knlGS:0000000000000000
[  130.409390] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[  130.409416] CR2: 00000000021ba000 CR3: 000000000460a002 CR4: 00000000003606e0
[  130.409447] Call Trace:
[  130.409465]  ? iscsi_session_setup+0x260/0x2c0
[  130.409489]  halbtc_set_bt_reg+0xcc/0x410 [btcoexist]
[  130.409515]  ex_btc8723b1ant_bt_info_notify+0x629/0x690 [btcoexist]
[  130.409545]  rtl_c2hcmd_launcher+0xa7/0x100 [rtlwifi]
[  130.409569]  process_one_work+0x19a/0x340
[  130.409589]  worker_thread+0x42/0x3f0
[  130.409608]  ? __schedule+0x22b/0x590
[  130.409627]  kthread+0xeb/0x120
[  130.409643]  ? process_one_work+0x340/0x340
[  130.409664]  ? kthread_create_on_node+0x40/0x40
[  130.409686]  ret_from_fork+0x35/0x40
[  130.409706] Code: e8 a1 2f 1d e0 31 c9 31 f6 66 89 4c 24 16 66 89 74 24 14 e9 79 fd ff ff 48 c7 c7 80 d6 ee a0 c6 05 db 2f 01 00 01 e8 d6 97 18 e0 <0f> 0b e9 60 fc ff ff 44 89 e6 48 89 df ff 93 50 09 00 00 e9 4d 
[  130.409811] ---[ end trace ed4e270be42285c4 ]---
Which, I suppose, means there's something wrong with the rtl8723b_config.bin file?

Apart from that, bluetooth status is just fine and I was finally able to connect my headphones with a2dp. However, output is pretty bad as there's a lot of skipping when listening to mp3 files and eventually the headphones disconnect. I can reconnect but playback remains problematic and eventually it just ends working altogether with the device being unreachable again, unable to connect (etc.) so yet another reboot (etc.) ad infinitium ad nauseam.

Frankly, I'm clueless as to how to proceed now as I've already spent way too much time trying to accomplish something that should take only a minute. Please advise.

joost
Sagely Hen
Posts: 2718
Joined: Fri Nov 17, 2006 12:11
Location: The Netherlands
Contact:

Re: Bluetooth issue headphones Philips SHB3060

Post by joost » Wed Apr 18, 2018 9:41

You shouldn't been messing around with firmware files like this.
That message got you on the wrong track it seems. (could be wrong here)

https://github.com/lwfinger/rtl8723bu/i ... -307400385
Yes. The "config.bin" files are for modifying the BlueTooth firmware, if necessary. They have absolutely no effect on wifi. In addition, the BT part of RTL8723BE does not need such a file. The message has been removed in later versions
.

Maybe it is the kernel version you are using? Do you have the same problems with the 4.14 (LTS) kernel?
Image
My blog | Twitter | Please support Sabayon: Image

User avatar
sabaton
Baby Hen
Posts: 5
Joined: Tue Apr 17, 2018 14:28
Location: Belgium

Re: Bluetooth issue headphones Philips SHB3060

Post by sabaton » Wed Apr 18, 2018 13:40

joost wrote:You shouldn't been messing around with firmware files like this.
That message got you on the wrong track it seems. (could be wrong here)
Thanks for your reply, Joost.

So basically adding this file doesn't make a difference if I'm reading this right?
joost wrote:Maybe it is the kernel version you are using? Do you have the same problems with the 4.14 (LTS) kernel?
I've been having issues with all of the latest kernels on my ASUS A541UA laptop. When I was running Fedora, upgrading to 4.14 caused my laptop to freeze on boot due to some firmware issue even though I had set the grub parameters to "pci=nomsi pci=noaer" which did work fine under 4.13. This is what I'm talking about. I'm not the only one facing these problems, apparently.

In fact, I didn't even manage to boot from any Sabayon (or Fedora, Manjaro or any other distro for that matter) live CD having a kernel beyond 4.9. My screen would get flooded with these PCI error messages and the laptop would just freeze. Only installing Sabayon 17.03 with kernel 4.9 worked. I'd still get spammed with PCI errors but at least changing the grub parameters mentioned above and rebuilding grub did the trick.

But to get back to Bluetooth, when I did manage to get it to work (with lots of tampering but getting good audio playback) under a previous Sabayon installation (17.03 GNOME edition upgraded to 18.04 with kernel 4.15) I was using GNOME and Cinnamon rather than KDE. I'm wondering if this could make a difference as I suppose these UIs interact in different ways with Pulseaudio and Bluez? I once tested openSUSE with KDE on the same pc and couldn't get bluetooth to work properly either.

Any input would be much appreciated. I've used about all the tricks I have up my sleeve so I have no idea how to proceed from here...

User avatar
sabaton
Baby Hen
Posts: 5
Joined: Tue Apr 17, 2018 14:28
Location: Belgium

Re: Bluetooth issue headphones Philips SHB3060

Post by sabaton » Wed Apr 18, 2018 19:39

Update #3

It turns out there's some bug in Pulseaudio. I followed the advice I found here, rebooted the system and now it works for me. Too bad I didn't come across that earlier but at least I've learned a thing or two in the process! :mrgreen:

For reference, here are the steps to take:

Code: Select all

$ sudo nano /etc/pulse/default.pa 
Comment out this line:

Code: Select all

#load-module module-bluetooth-discover
Then

Code: Select all

$ sudo nano /usr/bin/start-pulseaudio-x11
and add the following at the end of the file:

Code: Select all

/usr/bin/pactl load-module module-bluetooth-discover
Reboot.

If necessary, run this:

Code: Select all

$ pactl set-card-profile <card> a2dp_sink 
Hope this helps anyone having similar issues!

Post Reply