mightymike
Posts: 2
Joined: Sun Sep 13, 2015 11:06 am

Using bluez 5.37 on RPi3

Sun Mar 06, 2016 1:15 pm

Hi,
I am trying to run bluez 5.37 on a newly received RPi3 with Raspbian installed. I uninstalled the distribution bluez package and reinstalled the pi-bluetooth package ignoring the dependencies. The package bluez-firmware is also still installed. I compiled bluez with the switch --disable-systemd. Not sure if this is correct since systemd is used with Raspbian, isn't it.

After boot I checked the output on dmesg and it looks identical to the output I get with the original image.

Then I ran:
sudo hciconfig hci0 up
sudo bluetoothd -n -d

But it is not working and hciconfig gives me an device with the following MAC address:
BD Address: AA:AA:AA:AA:AA:AA
Which is probably not correct.

What am I missing?
Best regards,
Mike

robert_heinze
Posts: 6
Joined: Wed Mar 02, 2016 7:43 pm

Re: Using bluez 5.37 on RPi3

Fri Apr 01, 2016 9:51 am

Do you have any progress on that? I am having the same issue ...

phelum
Posts: 100
Joined: Thu Jul 17, 2014 7:05 am
Location: Sydney, AUS

Re: Using bluez 5.37 on RPi3

Fri Apr 01, 2016 10:51 am

Hi,

Can you check if you have a /lib/firmware/brcm directory and it contains BCM43430A1.hcd ? This is the firmware file for the BT chip. It also needs to be loaded into the chip and I assume there is a program somewhere in the bluetooth package to do this. This program also loads the BT MAC addr. I'm not sure where it gets the MAC addr from.

I've got BT working on my RPi3 but I'm using a custom kernel and Wheezy so I don't actually know how the official version works.

Cheers,
Steven

robert_heinze
Posts: 6
Joined: Wed Mar 02, 2016 7:43 pm

Re: Using bluez 5.37 on RPi3

Fri Apr 01, 2016 10:57 am

Hi Steven,

thanks for your feedback. No the file is missing, so I gotta figure it out, how to get that in ;)

Cheers
Robert

phelum
Posts: 100
Joined: Thu Jul 17, 2014 7:05 am
Location: Sydney, AUS

Re: Using bluez 5.37 on RPi3

Fri Apr 01, 2016 11:08 am

Hi,

As well as the BT file there are two files for the Wi-Fi part of the chip. I've uploaded all three.
http://phelum.net/temp/BCM43430A1.hcd
http://phelum.net/temp/brcmfmac43430-sdio.bin
http://phelum.net/temp/brcmfmac43430-sdio.txt

Grab these and put them in /lib/firmware/brcm .

Cheers,
Steven

robert_heinze
Posts: 6
Joined: Wed Mar 02, 2016 7:43 pm

Re: Using bluez 5.37 on RPi3

Fri Apr 01, 2016 12:07 pm

I have the bin and txt, but I am missing the hcd file.

Unfortunately your url's don't work anymore

robert_heinze
Posts: 6
Joined: Wed Mar 02, 2016 7:43 pm

Re: Using bluez 5.37 on RPi3

Fri Apr 01, 2016 1:54 pm

It works well, when BT is on ttyAMA0 after intalling pi-bluetooth, but I tried to get it on ttyS0 (in order to use AMA0 on the pins) and this makes problems in having hciuart running even with all the recommended changes in other postings.

thanks for your help!

amuxie
Posts: 4
Joined: Wed May 18, 2016 6:34 am

Re: Using bluez 5.37 on RPi3

Tue Aug 02, 2016 7:02 am

hi robert_heinze

you means that u can use bluez 5.37 on the platform of pi3?

wiso
Posts: 4
Joined: Fri Dec 27, 2013 2:34 pm

Re: Using bluez 5.37 on RPi3

Wed Sep 07, 2016 6:53 am

I'd also like to know if you got this figured out. Also on rpi3 added getting the AA:... address after installing bluez 5.33, 5.39, and 5.41. I guess these miss the drivers for the built in bluetooth? Any guide to doing this right would be greatly appreciated.

User avatar
Douglas6
Posts: 5144
Joined: Sat Mar 16, 2013 5:34 am
Location: Chicago, USA

Re: Using bluez 5.37 on RPi3

Wed Sep 07, 2016 12:58 pm

You might try (re-)installing pi-bluetooth and raspberrypi-sys-mods.

wiso
Posts: 4
Joined: Fri Dec 27, 2013 2:34 pm

Re: Using bluez 5.37 on RPi3

Wed Sep 07, 2016 5:45 pm

I was able to get bluez-5.39 installed following the instructions here. This leads to patching the 5.39 source, then config, make, install. I can bluetoothctl, scan, see devices, connect, etc. I seem to have another issue though. When I run

Code: Select all

bluetoothd
I get:

Code: Select all

pi@raspberrypi:~ $ bluetoothd
D-Bus setup failed: Name already in use
The service itself seems to be up:

Code: Select all

pi@raspberrypi:~ $ sudo service dbus status
● dbus.service - D-Bus System Message Bus
   Loaded: loaded (/lib/systemd/system/dbus.service; static)
   Active: active (running) since Wed 2016-09-07 19:39:36 CEST; 1min 7s ago
     Docs: man:dbus-daemon(1)
 Main PID: 462 (dbus-daemon)
   CGroup: /system.slice/dbus.service
           └─462 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation

Sep 07 19:39:37 raspberrypi dbus[462]: [system] Successfully activated service 'org.freedesktop.systemd1'
Sep 07 19:39:37 raspberrypi dbus[462]: [system] Successfully activated service 'org.freedesktop.login1'
Sep 07 19:39:38 raspberrypi dbus[462]: [system] Activating via systemd: service name='org.freedesktop.hostname1' unit='dbus-org.freedesktop.hostname1.service'
Sep 07 19:39:39 raspberrypi dbus[462]: [system] Successfully activated service 'org.freedesktop.hostname1'
Sep 07 19:39:50 raspberrypi dbus[462]: [system] Activating via systemd: service name='org.freedesktop.PolicyKit1' unit='polkitd.service'
Sep 07 19:39:50 raspberrypi dbus[462]: [system] Successfully activated service 'org.freedesktop.PolicyKit1'
Sep 07 19:39:51 raspberrypi dbus[462]: [system] Activating via systemd: service name='org.freedesktop.UDisks2' unit='udisks2.service'
Sep 07 19:39:51 raspberrypi dbus[462]: [system] Activating via systemd: service name='org.freedesktop.RealtimeKit1' unit='rtkit-daemon.service'
Sep 07 19:39:51 raspberrypi dbus[462]: [system] Successfully activated service 'org.freedesktop.RealtimeKit1'
Sep 07 19:39:52 raspberrypi dbus[462]: [system] Successfully activated service 'org.freedesktop.UDisks2'
Anyone know I I can hook up bluez to dbus?

User avatar
Douglas6
Posts: 5144
Joined: Sat Mar 16, 2013 5:34 am
Location: Chicago, USA

Re: Using bluez 5.37 on RPi3

Wed Sep 07, 2016 6:07 pm

Looks to me like bluetoothd is already running. What does this tell you?

Code: Select all

systemctl status bluetooth 

wiso
Posts: 4
Joined: Fri Dec 27, 2013 2:34 pm

Re: Using bluez 5.37 on RPi3

Wed Sep 07, 2016 8:05 pm

I think I'm pretty hosed. Now bt doesn't seem to be working at all!

Code: Select all

pi@raspberrypi:~ $ systemctl status bluetooth
● bluetooth.service - Bluetooth service
   Loaded: loaded (/lib/systemd/system/bluetooth.service; enabled)
   Active: inactive (dead)
     Docs: man:bluetoothd(8)
I can't seem to go back either. Attempting to install bluez 5.23 leaves them without configuration for some reason.

I guess I might back up my sd card and start fresh. pity.

DNPNWO
Posts: 126
Joined: Fri Jul 08, 2016 1:51 am

Re: Using bluez 5.37 on RPi3

Wed Sep 07, 2016 8:43 pm

This guy got it working and also has it set up for bluetooth audio on the newer up to date version of raspbian jessie. He is offering the OS download to whomever wants it (i installed it).

Just figure out how he set it up.
https://youtu.be/BDaak5W2mSk

Return to “Troubleshooting”