SyNtEr
Posts: 1
Joined: Wed Mar 03, 2021 10:00 am

Re: Does Bluetooth even work on new RPI4 ?

Thu Mar 04, 2021 5:32 pm

Same problem on both my Pi400. This is very frustrating. When i put the same SD card to pi4 then everything work fine..

fruitoftheloom
Posts: 26841
Joined: Tue Mar 25, 2014 12:40 pm
Location: Delightful Dorset

Re: Does Bluetooth even work on new RPI4 ?

Thu Mar 04, 2021 8:54 pm

SyNtEr wrote:
Thu Mar 04, 2021 5:32 pm
Same problem on both my Pi400. This is very frustrating. When i put the same SD card to pi4 then everything work fine..

Put the SD Card in the RPi 4B and update / full-upgrade:

https://www.raspberrypi.org/documentati ... pdating.md
The information is out there....you just have to let it in.

My other Linux machines: ChromeBox
https://www.aliexpress.com/item/32966393971.html
& Stone Desktop Intel CoreDuo circa 2010

DarkElvenAngel
Posts: 1695
Joined: Tue Mar 20, 2018 9:53 pm

Re: Does Bluetooth even work on new RPI4 ?

Thu Mar 11, 2021 4:17 am

I had this same problem and fixed it.

If anyone else hasn't tried this install

Code: Select all

sudo apt install pulseaudio-module-bluetooth
You will want to reboot after, as restarting all the sound systems and bluetooth can be cumbersome.

I'm using a fully updated Raspberry Pi OS 32bit with desktop, on a Pi 4 8GB, in an argon one case with the wifi turned on and in use. (I'm listing everything as it may be important) I paired my headphones with the the bluetooth applet and then use the volume control to enable the sound out on my headphones.

Hope this is helpful and works for you too.

User avatar
HawaiianPi
Posts: 6337
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: Does Bluetooth even work on new RPI4 ?

Thu Mar 11, 2021 9:26 pm

DarkElvenAngel wrote:
Thu Mar 11, 2021 4:17 am
If anyone else hasn't tried this install

Code: Select all

sudo apt install pulseaudio-module-bluetooth
You will want to reboot after, as restarting all the sound systems and bluetooth can be cumbersome.
If you upgraded from an older version of RasPiOS this was covered in the December Blog post.

The other option is to start fresh with a newer image.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

conwycastle
Posts: 1
Joined: Fri Mar 12, 2021 3:58 pm

Re: Does Bluetooth even work on new RPI4 ?

Fri Mar 12, 2021 4:05 pm

DarkElvenAngel wrote:
Thu Mar 11, 2021 4:17 am
I had this same problem and fixed it.

If anyone else hasn't tried this install

Code: Select all

sudo apt install pulseaudio-module-bluetooth
You will want to reboot after, as restarting all the sound systems and bluetooth can be cumbersome.

I'm using a fully updated Raspberry Pi OS 32bit with desktop, on a Pi 4 8GB, in an argon one case with the wifi turned on and in use. (I'm listing everything as it may be important) I paired my headphones with the the bluetooth applet and then use the volume control to enable the sound out on my headphones.

Hope this is helpful and works for you too.
Thanks for this. This worked. I did a full-upgrade of raspberry pi os and that did not work. I'm using the Raspberry Pi 400.

SRmax
Posts: 1
Joined: Wed Mar 17, 2021 11:29 pm

Re: Does Bluetooth even work on new RPI4 ?

Wed Mar 17, 2021 11:47 pm

I have seen this issue on three new pi 4 8gb models ordered from different Amazon vendors. It appears to be a hardware issue as I can use the same software SD card in both an older 8gb pi4 and a 4gb pi4 without any issues. Bluetooth hardware seems to receive OK, but has issue confirming the pairing. Thus causing the connect followed by the disconnect.

Rudolf
Posts: 168
Joined: Mon Nov 09, 2020 1:44 pm

Re: Does Bluetooth even work on new RPI4 ?

Thu Mar 18, 2021 3:53 pm

I am also struggling with the current OS and bluetooth, i.e. neither Pi3 nor Pi4 seem actually to be stable basis for using HFP profiles. I was almost loosing faith in my abilities, when a friend gave me a BT dongle and all worked like a charm. Is the internal BT chip such a bad bitch?

swysham
Posts: 1
Joined: Thu Mar 18, 2021 4:52 pm

Re: Does Bluetooth even work on new RPI4 ?

Fri Mar 19, 2021 12:30 am

I have to concur. Recent Rpi 4B booted with most recent Buster release (2021-01-11-raspios-buster-armhf-full): bluetoothctl connects and immediately disconnects a Logitech M535 mouse. The gui is worse: it times out when you try to pair. When you try to pair again it says "no dice, I already know this mouse" but said mouse doesn't appear in the list of paired devices. Reboot the rpi 4B and there is the mouse in the list of paired devices. At this point the mouse can be deleted. But, to no avail. It still won't pair. Around the barn again.

I then started with a fresh install of the August 2020 release of Buster (2020-08-20-raspios-buster-armhf) to try and determine when bluetooth went into the ditch. That release is fine with the 4B and the M535 mouse. But, when I upgraded to all the "latest," bluetooth was in the ditch.

I decided to go with Manjaro-ARM-xfce-rpi4-21.02. Bluetooth works just fine.

headsettrouble
Posts: 6
Joined: Fri Mar 19, 2021 7:55 pm

Re: Does Bluetooth even work on new RPI4 ?

Fri Mar 19, 2021 7:59 pm

I also have two days of troubleshooting behind me when trying to connect a bluetooth headset to a RPi 4.
By accident I found out, that pairing only works properly when I have restarted bluetooth (sudo /etc/init.d/bluetooth restart) after the Raspberry desktop has started.

Rudolf
Posts: 168
Joined: Mon Nov 09, 2020 1:44 pm

Re: Does Bluetooth even work on new RPI4 ?

Sun Mar 21, 2021 7:19 am

headsettrouble wrote:
Fri Mar 19, 2021 7:59 pm
I also have two days of troubleshooting behind me when trying to connect a bluetooth headset to a RPi 4.
By accident I found out, that pairing only works properly when I have restarted bluetooth (sudo /etc/init.d/bluetooth restart) after the Raspberry desktop has started.
Thanks for the comment, I also fear bluetooth@raspberry pi os in its current stage is a bit voodoo and dig a living cat upside down at half moon whistling backwards hex counts.

User avatar
craigevil
Posts: 208
Joined: Wed Jan 27, 2021 5:22 am
Location: OZ

Re: Does Bluetooth even work on new RPI4 ?

Sun Mar 21, 2021 12:47 pm

I pretty much gave up on using the bluetooth in Pi OS/Debian.
On Manjaro kde it just works, even managed to connect my phone and transfer some files.
None of the commands work on PI OS.

Code: Select all

bluetoothctl
Agent registered
[bluetooth]# scan on
No default controller available
Running inxi/pinxi fails to show anything for Bluetooth.pinxi -zyv8
shows:
Bluetooth:
Message: No Bluetooth data was found.
Raspberry PI 400 Raspberry Pi OS (Unstable) Kernel: 5.10.17-v8+ aarch64 DE: MATE Ram 4GB
Debian - "If you can't apt install something, it isn't useful or doesn't exist"

User avatar
CaxtonPi
Posts: 40
Joined: Fri May 08, 2020 10:45 am
Location: Cambridgshire, United Kingdom

Re: Does Bluetooth even work on new RPI4 ?

Sun Mar 21, 2021 2:27 pm

No, it doesn't work very well or very often, if at all. Whenever I have managed to get it working an update soon follows which causes it to fail completely.
I find USB for data and jack plug for analog audio is much more reliable and much less frustrating in the long run.

However my enthusiasm for computers from Cambridge continues, unabated since I bought my first, an Acorn Atom, in 1981

beccon
Posts: 1
Joined: Mon Mar 22, 2021 12:29 pm

Re: Does Bluetooth even work on new RPI4 ?

Mon Mar 22, 2021 12:40 pm

headsettrouble wrote:
Fri Mar 19, 2021 7:59 pm
By accident I found out, that pairing only works properly when I have restarted bluetooth (sudo /etc/init.d/bluetooth restart) after the Raspberry desktop has started.
You saved my day and my Raspi. I was about to send it back to the vendor for being "broken" which their hotline suggested.

With that simple workaround I was able to connect my Bluetooth mouse to the Raspi 400 running the latest Raspberry OS. Let's hope the developers fix that really nasty problem soon - which seems to be an easy change in the boot sequence which is nothing but overcasts the joy you have with your Raspi :-(

BTW: Restarting the system requires the nasty Bluetooth restart again to get the mouse working! Not nice at all.

iamnapo
Posts: 6
Joined: Wed Mar 24, 2021 10:18 pm

Re: Does Bluetooth even work on new RPI4 ?

Wed Mar 24, 2021 10:33 pm

headsettrouble wrote:
Fri Mar 19, 2021 7:59 pm
I also have two days of troubleshooting behind me when trying to connect a bluetooth headset to a RPi 4.
By accident I found out, that pairing only works properly when I have restarted bluetooth (sudo /etc/init.d/bluetooth restart) after the Raspberry desktop has started.
Thanks for sharing this! This also worked for me. (RPi4, Logitech K380)
beccon wrote:
Mon Mar 22, 2021 12:40 pm
BTW: Restarting the system requires the nasty Bluetooth restart again to get the mouse working! Not nice at all.
Indeed. Moreover, I tried adding it to /etc/rc.local, but I still had to remove and re-pair the keyboard to get it to work again.

User avatar
Sxx
Posts: 1
Joined: Thu Mar 25, 2021 2:00 pm

Re: Does Bluetooth even work on new RPI4 ?

Thu Mar 25, 2021 3:00 pm

iamnapo wrote: Indeed. Moreover, I tried adding it to /etc/rc.local, but I still had to remove and re-pair the keyboard to get it to work again.
/etc/rc.local works for me, no need to remove and re-pair ;)

Raspberry Pi 4 Model B - 8GB
Ubuntu MATE 20.10 64-bit
Microsoft Sculpt Comfort Mouse


If you don't have /etc/rc.local, just create it.

Code: Select all

sudo nano /etc/rc.local

paste & save

Code: Select all

#!/bin/sh -e
/etc/init.d/bluetooth restart
exit 0

Give the file execute permission.

Code: Select all

sudo chmod 744 /etc/rc.local

Restart & enjoy!
Last edited by Sxx on Sun Mar 28, 2021 2:03 pm, edited 4 times in total.

iamnapo
Posts: 6
Joined: Wed Mar 24, 2021 10:18 pm

Re: Does Bluetooth even work on new RPI4 ?

Fri Mar 26, 2021 4:03 pm

Hmm,

I tried again, same results. Also, I tried adding something like

Code: Select all

systemctl status bluetooth >> /home/pi/blah.txt
to try to inspect what's going on and the service hasn't even started, when rc.local gets executed.

Maybe it's OS specific? I'm on the latest RPi OS.

User avatar
craigevil
Posts: 208
Joined: Wed Jan 27, 2021 5:22 am
Location: OZ

Re: Does Bluetooth even work on new RPI4 ?

Fri Mar 26, 2021 4:47 pm

Code: Select all

systemctl status bluetoothbluetooth.service - Bluetooth service
     Loaded: loaded (/lib/systemd/system/bluetooth.service; enabled; vendor preset: enabled)
     Active: active (running) since Fri 2021-03-26 11:37:09 CDT; 35s ago
       Docs: man:bluetoothd(8)
   Main PID: 61959 (bluetoothd)
     Status: "Running"
      Tasks: 1 (limit: 4242)
        CPU: 50ms
     CGroup: /system.slice/bluetooth.service
             └─61959 /usr/libexec/bluetooth/bluetoothd

Mar 26 11:37:09 raspberrypi bluetoothd[61959]: src/main.c:parse_controller_config() Key file does not have key “LEScanIntervalConnect” in group “Con>
Mar 26 11:37:09 raspberrypi systemd[1]: Started Bluetooth service.
Mar 26 11:37:09 raspberrypi bluetoothd[61959]: src/main.c:parse_controller_config() Key file does not have key “LEScanWindowConnect” in group “Contr>
Mar 26 11:37:09 raspberrypi bluetoothd[61959]: src/main.c:parse_controller_config() Key file does not have key “LEMinConnectionInterval” in group “C>
Mar 26 11:37:09 raspberrypi bluetoothd[61959]: src/main.c:parse_controller_config() Key file does not have key “LEMaxConnectionInterval” in group “C>
Mar 26 11:37:09 raspberrypi bluetoothd[61959]: src/main.c:parse_controller_config() Key file does not have key “LEConnectionLatency” in group “Contr>
Mar 26 11:37:09 raspberrypi bluetoothd[61959]: src/main.c:parse_controller_config() Key file does not have key “LEConnectionSupervisionTimeout” in g>
Mar 26 11:37:09 raspberrypi bluetoothd[61959]: src/main.c:parse_controller_config() Key file does not have key “LEAutoconnecttimeout” in group “Cont>
Mar 26 11:37:09 raspberrypi bluetoothd[61959]: Starting SDP server
Mar 26 11:37:09 raspberrypi bluetoothd[61959]: Bluetooth management interface 1.18 initialized
 
From inxi:

Code: Select all

Bluetooth: Device-1: pl011 driver: uart_pl011 bus-ID: N/A chip-ID: arm:fe201000 class-ID: serial 
           Report: ID: hci0 state: down bt-service: enabled, running address: AA:AA:AA:AA:AA:AA 
Notice the State is down.
Nothing and I mean absolutely nothing seems to make the bluetooth actually work.

Code: Select all

sudo lsmod | grep bluetooth
bluetooth             446464  10 hci_uart,btbcm,bnep
ecdh_generic           16384  1 bluetooth
rfkill                 36864  7 bluetooth,cfg80211

Code: Select all

dmesg | grep Bluetooth
[    4.637662] Bluetooth: Core ver 2.22
[    4.637739] Bluetooth: HCI device and connection manager initialized
[    4.637753] Bluetooth: HCI socket layer initialized
[    4.637759] Bluetooth: L2CAP socket layer initialized
[    4.637771] Bluetooth: SCO socket layer initialized
[    4.755897] Bluetooth: HCI UART driver ver 2.3
[    4.755908] Bluetooth: HCI UART protocol H4 registered
[    4.755964] Bluetooth: HCI UART protocol Three-wire (H5) registered
[    4.756094] Bluetooth: HCI UART protocol Broadcom registered
[    5.603646] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[    5.603656] Bluetooth: BNEP filters: protocol multicast
[    5.603670] Bluetooth: BNEP socket layer initialized

Code: Select all

rfkill list
0: phy0: Wireless LAN
	Soft blocked: no
	Hard blocked: no
1: hci0: Bluetooth
	Soft blocked: no
	Hard blocked: no

Code: Select all

sudo bluetoothctl
Agent registered
[bluetooth]# scan on
No default controller available
blueman just crashes when it opens. Bluedevil for kde just sits and spins.
Funny thing is Manjaro KDE bluetooth works perfectly with the same kernel.
Raspberry PI 400 Raspberry Pi OS (Unstable) Kernel: 5.10.17-v8+ aarch64 DE: MATE Ram 4GB
Debian - "If you can't apt install something, it isn't useful or doesn't exist"

iamnapo
Posts: 6
Joined: Wed Mar 24, 2021 10:18 pm

Re: Does Bluetooth even work on new RPI4 ?

Sun Mar 28, 2021 6:11 pm

Ok, so I tried with systemd and it works fine. I don't have to manually restart the bluetooth service after each reboot anymore.
Here's what I did:

  • Created a new service:

    Code: Select all

    sudo nano /lib/systemd/system/bt-hack.service
  • Added this configuration:

    Code: Select all

    [Unit]
    Description=Hack to fix bluetooth
    Wants=multi-user.target
    After=multi-user.target
    
    [Service]
    Type=simple
    ExecStart=/etc/init.d/bluetooth restart
    Restart=on-abort
    
    [Install]
    WantedBy=multi-user.target
    
  • Enabled the service:

    Code: Select all

    sudo systemctl enable bt-hack

tekate
Posts: 1
Joined: Tue Mar 30, 2021 10:29 am

Re: Does Bluetooth even work on new RPI4 ?

Tue Mar 30, 2021 10:35 am

headsettrouble wrote:
Fri Mar 19, 2021 7:59 pm
By accident I found out, that pairing only works properly when I have restarted bluetooth (sudo /etc/init.d/bluetooth restart) after the Raspberry desktop has started.
Dude, thank you so much !
Just registered an account to thank you, I was struggling with the pairing of my bluetooth keyboard for hours, and you just pointed the right fix.


I also have to restart the service and reconnect the keyboard each time I restart my R4B (even with the systemd and the rc.local scripts) so I created a script on my desktop to manualy restart it with only a mouse.

User avatar
craigevil
Posts: 208
Joined: Wed Jan 27, 2021 5:22 am
Location: OZ

Re: Does Bluetooth even work on new RPI4 ?

Tue Mar 30, 2021 3:18 pm

PI400

Code: Select all

Bluetooth:
  Device-1: pl011 driver: uart_pl011 bus-ID: N/A chip-ID: arm:fe201000 
  class-ID: serial 
  Report: ID: hci0 state: up address: <filter> bt-v: 3.0 lmp-v: 5.0 
  sub-v: 6606 hci-v: 5.0 rev: 36 
  Info: acl-mtu: 1021:8 sco-mtu: 64:1 link-policy: rswitch sniff 
  link-mode: slave accept service-classes: rendering, capturing 
I would like to apologize, Bluetooth works just fine. Trying to update using Debian repos breaks it.
I reinstalled PI OS on my PI400 and Bluetooth works great. I am back to loving my little computer.
Raspberry PI 400 Raspberry Pi OS (Unstable) Kernel: 5.10.17-v8+ aarch64 DE: MATE Ram 4GB
Debian - "If you can't apt install something, it isn't useful or doesn't exist"

rhmuc
Posts: 2
Joined: Wed Apr 07, 2021 5:30 pm

Re: Does Bluetooth even work on new RPI4 ?

Wed Apr 07, 2021 5:40 pm

Hi guys, I am another person struggling with BT on the newest Raspbian. But thanks to the information here and elsewhere I am almost there.

The first two things you need to do are the SAP fix and the Privacy fix. They are described well at https://peppe8o.com/fixed-connect-bluet ... pberry-pi/ Once this is done, the BT service now runs. Pairing still fails. The fix for that, as described above is running "sudo /etc/init.d/bluetooth restart". Then everything works.

There is one last problem though, and I don't know how to solve that:

As described above, the bluetooth service restart command needs to be launched after every reboot. However I do not know how to integrate this into my system. That is because I am using rc.local to launch "moonlight-qt" immediately after booting. How do I issue the BT service reboot command before starting moonlight-qt? The solutions by iamnapo via a service or the solution by Sxx via rc.local are not working for me. Any other suggestions?

The only solution I know of right now, is to let moonlight-qt launch, ssh in from another computer, and issue "sudo /etc/init.d/bluetooth restart" via SSH. This works perfectly, but is obviously extremely inconvenient.

Thanks a lot!

iamnapo
Posts: 6
Joined: Wed Mar 24, 2021 10:18 pm

Re: Does Bluetooth even work on new RPI4 ?

Thu Apr 08, 2021 12:09 pm

rhmuc wrote:
Wed Apr 07, 2021 5:40 pm
Hi guys, I am another person struggling with BT on the newest Raspbian. But thanks to the information here and elsewhere I am almost there.

The first two things you need to do are the SAP fix and the Privacy fix. They are described well at https://peppe8o.com/fixed-connect-bluet ... pberry-pi/ Once this is done, the BT service now runs. Pairing still fails. The fix for that, as described above is running "sudo /etc/init.d/bluetooth restart". Then everything works.

There is one last problem though, and I don't know how to solve that:

As described above, the bluetooth service restart command needs to be launched after every reboot. However I do not know how to integrate this into my system. That is because I am using rc.local to launch "moonlight-qt" immediately after booting. How do I issue the BT service reboot command before starting moonlight-qt? The solutions by iamnapo via a service or the solution by Sxx via rc.local are not working for me. Any other suggestions?

The only solution I know of right now, is to let moonlight-qt launch, ssh in from another computer, and issue "sudo /etc/init.d/bluetooth restart" via SSH. This works perfectly, but is obviously extremely inconvenient.

Thanks a lot!
Hi,

what if you tried removing moonlight-qt from rc.local and starting it from a service as well? To do that, after creating the bt-hack.service, as described above, create another moonlight-qt-start.service, following the same procedure, except changing multi-user.target to bt-hack.service and adjusting the ExecStart command.

PS: If the bluetooth doesn't work and you're starting the pi into GUI and not into command line, try also changing multi-user.target to graphical.target in bt-hack.service to delay its execution a little bit more.

rhmuc
Posts: 2
Joined: Wed Apr 07, 2021 5:30 pm

Re: Does Bluetooth even work on new RPI4 ?

Thu Apr 08, 2021 6:57 pm

iamnapo wrote: Hi,

what if you tried removing moonlight-qt from rc.local and starting it from a service as well? To do that, after creating the bt-hack.service, as described above, create another moonlight-qt-start.service, following the same procedure, except changing multi-user.target to bt-hack.service and adjusting the ExecStart command.

PS: If the bluetooth doesn't work and you're starting the pi into GUI and not into command line, try also changing multi-user.target to graphical.target in bt-hack.service to delay its execution a little bit more.

Hi, thanks for your reply.

I found a different solution, and everything works now. I have written up my solution on Stack Exchange: https://raspberrypi.stackexchange.com/a/123914/131922

Cheers!

iamnapo
Posts: 6
Joined: Wed Mar 24, 2021 10:18 pm

Re: Does Bluetooth even work on new RPI4 ?

Thu Apr 08, 2021 7:34 pm

rhmuc wrote:
Thu Apr 08, 2021 6:57 pm
iamnapo wrote: Hi,

what if you tried removing moonlight-qt from rc.local and starting it from a service as well? To do that, after creating the bt-hack.service, as described above, create another moonlight-qt-start.service, following the same procedure, except changing multi-user.target to bt-hack.service and adjusting the ExecStart command.

PS: If the bluetooth doesn't work and you're starting the pi into GUI and not into command line, try also changing multi-user.target to graphical.target in bt-hack.service to delay its execution a little bit more.

Hi, thanks for your reply.

I found a different solution, and everything works now. I have written up my solution on Stack Exchange: https://raspberrypi.stackexchange.com/a/123914/131922

Cheers!
I checked your solution and it works fine for me as well. Thank you, too!

Muskateer10
Posts: 17
Joined: Tue Apr 10, 2018 6:06 pm

Re: Does Bluetooth even work on new RPI4 ?

Sat Apr 10, 2021 9:07 pm

I have been struggling with my Logitech Bluetooth mouse M335 for two weeks (which is when I received my Pi 4). I get it to connect and pair about 1 out of 1000 times.
And even after issuing the <trust> command, the mouse is gone upon reboot. I have tried everything I can think of "and yes, of course I did the update and upgrade commands," which is the only answer people seem to be able to provide. I have even tried installing the bluez 5.8 from source at bluez.org (currently running), to no avail. I have also tried a fresh install of Raspbian Buster ....to no avail.
However when I run the commands you listed:
sudo systemctl daemon-reload
sudo systemctl restart bluetooth
My Bluetooth mouse connects pretty much right away.

The problem now is I have to run those two commands after "every" system reboot. But at least the Bluetooth mouse is getting reliably connected.

Running one or the other of the two commands above does not work. Both commands must be run.
System:
Raspberry Pi 4 8g ram.

Return to “General discussion”