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
13
votes
1 answer

Read battery status bluetooth headset linux

I use Bluetooth headset that use Bluetooth version 4.1. When I connect with android it shows the battery status. But with Linux (Ubuntu 18.04) I cannot get battery status. I tried with bluetoothctl, looking file in /sys/class/power_supply as in…
Lakindu Akash
  • 964
  • 1
  • 11
  • 28
13
votes
3 answers

HFP/HSP profile in linux

I have Ubuntu 16.04 and already installed BlueZ 5.37, PulseAudio 10.0, and ofono 1.20 (clone from github). And I need to use phone like modem for transmitting my phone calls to computer. I paired my telephone with PC, made device trust and connect…
13
votes
2 answers

Which tool has replaced gatttool in bluez5?

It seems like since commit b1eb2c4cd057624312e0412f6c4be000f7fc3617 gatttool has been deprecated but I'm unable to find any information on what has replaced gattool. Every Python Bluetooth LE packages I looked into relays on gatttool and is now…
Henrik Pingel
  • 3,083
  • 1
  • 19
  • 27
13
votes
1 answer

Change Tx Bluetooth Linux No Effect

I would like to change the signal strength of my bluetooth device using linux command line (ubuntu 14.04). I have found that I need to use the command sudo hciconfig hci0 inqtpl to change the signal strength but it's not working sudo hciconfig…
Orelsanpls
  • 22,456
  • 6
  • 42
  • 69
13
votes
3 answers

Bluetooth Low Energy: Use BlueZ stack as a peripheral (with custom services and characteristics)

I am trying to use the BlueZ stack on a Linux machine to create a GATT server with custom services and characteristics. The final goal is to use any central device (e.g. iOS or Android device) to connect to the GATT server, discover the services and…
Youssif Saeed
  • 11,789
  • 4
  • 44
  • 72
12
votes
1 answer

Direct Control of HCI Device (Bypass Bluetooth Drivers) on Linux

I need to control an HCI device directly without the Linux drivers/kernel interfering. For example, when creating an LE connection to a peripheral, the driver is independently sending an "LE Connection Update" command which I would like to avoid. I…
Dan Shemesh
  • 464
  • 3
  • 13
12
votes
2 answers

C/C++ BLE read/write example with Bluez

I am starting to build up a simple BLE network with a microcontroller and a raspberry pi (tardis BLE dongle). As a starting point, I am looking for a simple C or C++ example to read/write a BLE device, similar to what I am able to do over the…
Cole Wilson
  • 121
  • 1
  • 1
  • 4
11
votes
1 answer

Bluez Architecture : Explain this Architecture

here i want to understand the architecture of bluez (Bluetooth Stack Protocol). I understood how bluetooth enable in module. its enable by up the BT_EN pin in this Bluetooth Chip. After attacth this device with HCI UART to Bluez for communication. i…
user1089679
  • 2,328
  • 8
  • 41
  • 51
11
votes
2 answers

Bluetooth over uart using hciattach?

I am using QN9021 SoC working in controller mode (BLE Bluetooth core specification v4.0). It supports some standard HCI commands as well as some vendor specific commands. I am trying to attach it in my ubuntu laptop. The command that i have used is…
abhiarora
  • 9,743
  • 5
  • 32
  • 57
11
votes
1 answer

Android 4.0 & 4.1 Bluetooth issues. Detect broken comms & dropping pairing

Hey All, I understand that Android's bluetooth stack(bluez) was replaced on 4.2. Even though they might have fixed a lot of the previous issues, due to a need to support older versions, i still need to battle with them. I would appreciate…
ehanoc
  • 2,187
  • 18
  • 23
11
votes
1 answer

creating virtual bluetooth device/service and let executing computer discover/use them

Reading this question I sarted to wonder, whether it would be possible to not only let a program emulate a bluetooth device, but also let the (executing) computer think, that it is actually an external bluetooth device he'd be communicating with. I…
Sim
  • 4,199
  • 4
  • 39
  • 77
10
votes
1 answer

BlueZ: Adding services, attributes, and profiles without sdptool command

Prior to BlueZ 5, the way to add/remove Bluetooth services/attributes/profiles on Linux was done through the sdptool as follows:- To browse local records #sdptool browse local Browsing FF:FF:FF:00:00:00 ... To add a service #sdptool add SP Serial…
Youssif Saeed
  • 11,789
  • 4
  • 44
  • 72
10
votes
3 answers

Bluetooth Low Energy GATT Security Levels

I am investigating the types of security available in Bluetooth Low Energy (BLE) related to GATT. More specifically, what kind of operations are done when using gatttool with different security levels specified (low, med, high)? My understanding is…
1nc1n3rat0r
  • 103
  • 1
  • 1
  • 5
10
votes
2 answers

Grep hcitool lescan output

How do I grep the output of 'hcitool lescan' or for that matter pipe it to anything. It seems when I pipe anything from 'hcitool lescan' I get no output. root@edison:/mnt/rtd# hcitool lescan |grep B ^Croot@edison:/mnt/rtd# hcitool lescan | tee…
mw.
  • 357
  • 3
  • 18
10
votes
3 answers

Python code for Bluetooth throws error after I had to reset the adapter

I was trying out bluetooth programming in python. It was working fine till yesterday. This morning, there was a power outage and for some reason, the bluetooth module got disabled and it could not be turned on. So, I did a sudo hciconfig hci0 reset…
Sidmeister
  • 856
  • 2
  • 14
  • 27
1 2
3
65 66