Questions tagged [bluez]

BlueZ is the Bluetooth stack implemented in most Linux kernels.

Its goal is to make an implementation of the Bluetooth wireless standards specifications for Linux.
As of 2006, the BlueZ stack supports all core Bluetooth protocols and layers.
It was initially developed by Qualcomm and is available for Linux kernel versions 2.4.6 and up.

For user space applications, BlueZ essentially provides two ways to implement the stack in the application: Through DBus or through the so-called MGMT API. These methods are high- and low level respectively.

In addition to the basic stack, the bluez-utils and bluez-firmware packages contain low-level utilities such as dfutool, which can interrogate the Bluetooth adapter chipset to determine whether its firmware can be upgraded.

Further information about BlueZ:

Aditionally there are two IRC channels available on freenode.net where you can find developers and other users of BlueZ:

#bluez (development related topics)
#bluez-users (non-development related topics)
979 questions
10
votes
4 answers

How to perform a bluetooth low-energy scan via BlueZ C library

I'm new in programming Bluetooth low energy using BlueZ. I want to develop a native code c to scan nearby devices using a BlueZ API for Bluetooth low energy on Intel Edison. I've seen this question, but the answer doesn't really help. Any advice?
Longes
  • 113
  • 1
  • 1
  • 4
10
votes
2 answers

Finding Bluetooth low energy with python

Is it possible for this code to be modified to include Bluetooth Low Energy devices as well? https://code.google.com/p/pybluez/source/browse/trunk/examples/advanced/inquiry-with-rssi.py?r=1 I can find devices like my phone and other bluetooth 4.0…
user3582887
  • 403
  • 3
  • 6
  • 19
9
votes
4 answers

Can't create RFCOMM TTY: Address already in use

I listen for a Bluetooth connection in my server doing: rfcomm listen rfcomm1 1 Then I connect with my Bluetooth client and this message appears: Connection from XX:XX:XX:XX:XX:XX to /dev/rfcomm1 Press CTRL-C for hangup This means that everything…
Sergio
  • 844
  • 2
  • 9
  • 26
9
votes
3 answers

Making bluetooth discoverable using c code

I want to make a bluetooth server that starts and other devices can pair with it. I can get the code to compile fine, the server starts, but I cannot see the advertisement when I scan for bluetooth devices from android phone. I think i need to…
Yogesh Ghaturle
  • 307
  • 3
  • 17
9
votes
3 answers

bluez 5.30: "Not enough free handles to register service" error in starting bluetoothd

What I have done correctly: in linux environment hciattach /dev/ttyUSB0 any 115200 hciconfig hci0 up addgroup -S messagebus adduser -S messagebus -G messagebus dbus-daemon --system syslogd In executing /libexec/bluetooth/bluetoothd --plugin=time -d…
Daniel
  • 91
  • 1
  • 1
  • 3
8
votes
1 answer

How to get notifications from BLE Device using pygatt in python?

I am developing a Linux application using python that will connect to my BLE Device and get the data by notifying characteristic. I am using pygatt for BLE Communications. I can successfully connect and bond to device and read from/write to…
Alican Uzun
  • 349
  • 1
  • 6
  • 20
8
votes
2 answers

LEAdvertisingManager1 missing from DBus.ObjectManager.GetManagedObjects

I'm running tests with my home computer running Ubuntu and Python 2.7 in the hopes of having Raspberry Pi 3 advertise using BLE with custom services and characteristics. I've installed Bluez Version 5.42 (using the recommended method) on both…
Bryan McGrane
  • 498
  • 6
  • 14
8
votes
3 answers

Bluetooth LE L2CAP CID vs. PSM

I've been teaching myself how to write programs in C for BLE devices using the BlueZ API. However, I seem to be stumped on one particular aspect of the sockaddr_l2 struct. The definition I am using is the following: struct sockaddr_l2 { …
Jeremy Roy
  • 324
  • 1
  • 3
  • 10
8
votes
3 answers

How to program a Bluetooth LE device using C on Linux x86?

I have a bluetooth device which I can control using gatttool on linux. I want to develop my own c program that can send commands to it. I have done bluetooth programming in the past and it is relatively straightforward, similar to network…
oneb1got
  • 153
  • 1
  • 4
  • 8
8
votes
3 answers

Raspberry Pi iBeacon connection timing out

I am currently attempting the Raspberry Pi iBeacon tutorial posted by RadiusNetworks at http://developer.radiusnetworks.com/2013/10/09/how-to-make-an-ibeacon-out-of-a-raspberry-pi.html but I am having issues with the connection timing out after a…
Chris Sparrow
  • 83
  • 1
  • 1
  • 4
8
votes
3 answers

How to find methods exposed in a D-Bus interface

Question: Is there any way in which we can find out the methods (and their signatures) which are exposed in a D-Bus interface? Issue Description: In my phone, I am calling BlueZ methods using D-Bus to adapter interface, when checked on phone 2 of…
ashish
  • 1,384
  • 1
  • 12
  • 21
8
votes
1 answer

Can't get any replies to dbus-send

I am trying to create some scripts to discover and pair bluetooth devices on a embedded arch linux platform and seem unable to get any replies to dbus-send commands. The error message is pretty much always the same (method does not exist), however…
crankshaft
  • 2,607
  • 4
  • 45
  • 77
8
votes
1 answer

Raspberry Pi Bluetooth 4.0 Connection

I am trying to connect to a Raspberry Pi via iPhone using CoreBluetooth (bluetooth 4.0). I have discovered the device and send out a connection request using this code: if (peripheral != self.foundPeripheral) { NSLog(@"Try to connect to %@",…
7
votes
1 answer

Error with Go program ( Bettercap 2 ) depending on which bluetooth dongle I use on Ubuntu/Raspberry Pi OS when running ble scan

I use this on Ubuntu 20.04 and Raspberry Pi OS 5.10 but this is not a Linux related issue. I'm having an issue with a Go program called Bettercap 2 ( https://www.bettercap.org/ and the repository: https://github.com/bettercap/bettercap ) when I use…
Jimmy
  • 105
  • 15
7
votes
1 answer

how do i install bluez on ubuntu for development?

Beginner Question: I'd like to use the BlueZ driver in my Raspberry Pi for a simple way to connect to an iPhone app I'm writing, but I'm trying to prototype it first on my Ubuntu boot (I dual boot a macbook pro w/ macOS sierra/Ubuntu 16.04). I am…
iiian
  • 393
  • 1
  • 5
  • 17