On my Arduino Yun (openwrt-yun, updated to latest version), I have a bluetooth dongle in the usb port; I have installed bluez-libs and bluez-utils (and python-bluez). They show up as version 5.13. hciconfig and hcitool work properly. There does not seem to be any utility installed to pair with a device, nor can I figure out how to get pairing to work by editing config files.

I can find the device with hciconfig and hcitool, but rfcomm can't connect without the pin. If I try the same sequence on my Linux laptop after pairing with the gui, rfcomm is able to connect, so I know the device is working properly (JY-MCU HC-06 on another Arduino).

All the recommendations I can find on the web indicate I should be able to use simple-agent or bluez-simple-agent, but they are not installed with these packages (there is no bluez-tools package for this distro). If I manually copy the python script for the agent to the device and run it, it fails, saying that org.bluez can't be found with dbus. There is no bluetoothd running, and no init script for any bluetooth demon. None of the bt* tools are available.

I also found a description of how to set a pin code in /var/lib/bluetooth/[bt-addr]/pincodes (where bt-addr is my dongle address) containing a line of the form:

[device-addr] [pincode]

but this seems to have no effect.

I have also tried settings in /etc/bluetooth/main.conf and /etc/bluetooth/rfcomm.conf, but I think they may only be for incoming connections.

Any help would be greatly appreciated.

2 Answers 2


It takes me some time to make it work :

1) update drivers

opkg update 

opkg install kmod-bluetooth bluez-libs bluez-utils

2) add configuration files in directory /etc/bluetooth

root@Arduino:~# cat /etc/bluetooth/hcid.conf

options {
  autoinit yes;
  security auto;
  pairing multi;
  passkey "0000";
device {
  name "OpenWrt";
  class 0x000100;
  lm accept,master;
  lp rswitch,hold,sniff,park;

root@Arduino:~# cat /etc/bluetooth/rfcomm.conf 

 bind yes;
 device 00:1B:C1:02:B0:F5;
 channel 1;
 comment "Holux M-1000";

3) Reboot the card

4) test if all is OK


5) put the interface up

hciconfig hci0 up

6) Search for devices

hcitool scan

7) Look for Serial Port capability on the devices

sdptool search SP

8) bind the serial dev

rfcomm -i hci0 connect /dev/rfcomm0 00:1B:C1:02:B0:F5

9) see the information comming from the device (bluetooth GPS in my case)

cat /dev/rfcomm0

Bluetooth support on OpenWRT is broken, simply does not work.

  • 3
    Welcome to Arduino SE! Can you please add more information to your post to explain why it doesn't work on the Yun? Is there an alternative? Thanks! Mar 10, 2015 at 22:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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