How to check Bluetooth status on Raspberry Pi

All of the latest Raspberry Pi models have Bluetooth built in, giving users another medium by which they can connect their peripheral devices such as headphones, keyboard, mouse, etc. Ideally, Bluetooth devices should be easy to connect to your Raspberry Pi. The connection process usually involves making your peripheral device discoverable, and then selecting the devices from the Bluetooth list on your Raspberry Pi.

If your Bluetooth devices are not syncing to your Raspberry Pi, there are some troubleshooting steps you can take to check the Bluetooth status on your Raspberry Pi. In this tutorial, we will go over the step by step instructions of connecting a Bluetooth device to the Raspberry Pi, and checking the status of the Bluetooth service.

In this tutorial you will learn:

  • How to connect a Bluetooth device to a Raspberry Pi
  • How to check Bluetooth status on Raspberry Pi
How to check Bluetooth status on Raspberry Pi
How to check Bluetooth status on Raspberry Pi
Software Requirements and Linux Command Line Conventions
Category Requirements, Conventions or Software Version Used
System Raspberry Pi
Software N/A
Other Privileged access to your Linux system as root or via the sudo command.
Conventions # – requires given linux commands to be executed with root privileges either directly as a root user or by use of sudo command
$ – requires given linux commands to be executed as a regular non-privileged user

Connect Bluetooth device to a Raspberry Pi




First, let’s quickly cover the step by step instructions to connect a Bluetooth capable device to your Raspberry Pi. If these steps fail somewhere along the way, then it is recommended to proceed to the next section which contains commands for checking the Bluetooth status, restarting the service, etc.

  1. The easiest way to pair a Bluetooth device with your Raspberry Pi is to select the Bluetooth icon from the upper right corner of the desktop.
    Bluetooth menu on Raspberry Pi
    Bluetooth menu on Raspberry Pi

    On this menu, you can select ‘Make Discoverable’ if you plan to do the pairing from your other device. Otherwise, select ‘Add Device.’

  2. After selecting ‘Add Device’ you will see your Bluetooth devices listed in the window that pops up. If you do not see your device listed here, then you need to ensure that it is currently discoverable. Select the device you wish to pair your Raspberry Pi with.
    Selecting a Bluetooth device to pair the Raspberry Pi with
    Selecting a Bluetooth device to pair the Raspberry Pi with


Checking Bluetooth Status

To check the current status of the Bluetooth service on Raspberry Pi, execute:

$ systemctl status bluetooth
Output of the Bluetooth status on Raspberry Pi
Output of the Bluetooth status on Raspberry Pi

In case you are encountering problems with the Bluetooth on your Raspberry Pi, it can be useful to restart the service:

$ sudo systemctl restart bluetooth

Further command line options for controlling the Raspberry Pi’s Bluetooth can be found within the bluetoothctl menu.

$ bluetoothctl
[bluetooth]# help
Bluetooth control commands help menu
Bluetooth control commands help menu
DID YOU KNOW?
The Bluetooth commands can be executed from within the bluetoothctl terminal, and allow for advanced control over the Bluetooth hardware on your Raspberry Pi. It can be used for additional troubleshooting or to pair devices from the command line.

Any of the commands shown in the help menu output can then be execute. For example, to turn the Bluetooth hardware controller on or off:

$ power on
Changing power on succeeded

Or:

$ power off
Changing power off succeeded
[CHG] Controller A0:E7:0B:C8:64:27 Powered: no
[CHG] Controller A0:E7:0B:C8:64:27 Discovering: no
[CHG] Controller A0:E7:0B:C8:64:27 Class: 0x00000000

Closing Thoughts




In this tutorial, we saw how to pair a Bluetooth device with a Raspberry Pi system. We also learned how to check the Bluetooth status on a Raspberry Pi, and how to restart the Bluetooth service. It can be frustrating when a peripheral device refuses to pair via Bluetooth, but oftentimes a simple restart of the Bluetooth service can be all that is needed to fix the problem. There is always the bluetoothctl command in case advanced troubleshooting or device pairing is needed.



Comments and Discussions
Linux Forum