How to put BlueZ stack into MangOH board?


#1

The board runs Leagato17.09.0 and has WP76xx as controller. How can I put BlueZ stack into this ?

I know you have provided provisions to put some utilities into the board but I am trying to develop a BLE application and I think I would need the whole stack APIs on target.


#2

I’m in the process of trying to figure this out right now. There’s a relevant recipe in poky/meta/recipes-connectivity/bluez5/

I built it successfully a week or so ago, but I never tried actually using it because I decided to step back to a higher level and better understand the bluez stack on desktop Linux before I got bogged down with the yocto/mangOH/Legato specific details of it.


#3

Can you tell me how to include this in yocto build recipe; as this is not usually built with the kernel ?
Also does this recipe create bluez libraries with BLE suport ?


#4

I have built a small yocto layer to enable bluetooth support for WP76/WP77. Note that this is super unofficial at this point which is why I posted it on my personal github rather than the mangOH github. Please read the README in the layer repository. Note that this does not provide support for the onboard mangOH Red bluetooth. It just enables bluetooth support in the kernel and provides bluez libraries. I haven’t really tested it yet other than bringing up the bluetooth interface using the wifi/bt IoT card.


#5

Hi David,

I tried following the instructions in you git page. I seem to be facing some issue either with flashing or the .cwe file; I am not sure at this point in time.

The flashed board does not contain any Bluetooth utilities nor any BlueZ files. Any pointers ?

I am flashing the file using swiflash.
swiflash -m WP76XX -i yocto_wp76xx.4k.cwe

  • The meta-bluetooth folder didnot exist in my source so I created one and copied your repository into it.
  • The file swi-meta/build.sh was also not present; so I created a file, copied your code into it and renamed it build.sh, within swi-meta

#6

@dfrey Hi I figured this out on my own.

You need to edit the yocto/build_bin/conf/local.conf, and add the line:
IMAGE_INSTALL_append = " bluez5 bluezhcidump"

Use the following command to make sure bluez5 is available in the yocto source and so is bluezhcidump.
bitbake-layers show-recipes

If hcidump is not available it can be ignored. So the addition to local.conf will become:
IMAGE_INSTALL_append = " bluez5"

Run bitbake, double check that the package has been added using:
bitbake image -g -u depexp

Flash and BlueZ away. :slight_smile: