Camel Bluetooth component

Camel Bluetooth component can retrieve information about the bluetooth devices available within the device range. Under the hood Bluetooth component uses bluecove library ( Bluetooth component supports both the consumer and producer endpoints.

Maven dependency

Maven users should add the following dependency to their POM file:


Avaliable for rhiot.version >= 0.1.3

URI format


For example to find all bluetooth devices available near the device, the following route can be used:


The message body is a io.rhiot.component.bluetooth.BluetoothDevice instance:

BluetoothDevices[] devices = consumerTemplate.receiveBody("bluetooth:scan", BluetoothDevices[].class);

You can also request the bluetooth device scanning using the producer endpoint:


Or using the producer template directly:

BluetoothDevices[] devices = template.requestBody("bluetooth:scan", BluetoothDevices[].class);



The Bluetooth component installs it's own dependencies for Debian-based systems using apt-get, these include blueman and libbluetooth-dev, as well as their dependencies. You can configure the installer or set an alternate one on the component:

BluetoothComponent bluetooth = new BluetoothComponent();
bluetooth.setInstaller(new CustomInstaller());
camelContext.addComponent("bluetooth", bluetooth);

You can also specify alternate/additional dependencies for your platform, if your platform uses my-custom-tools for example, you should configure the component as follows:

BluetoothComponent bluetooth = new BluetoothComponent();
bluetooth.setRequiredPackages("my-custom-tools,blueman,libbluetooth-dev"); //comma-separated list of packages to install
camelContext.addComponent("bluetooth", bluetooth);

If an Installer is not set on the component, Camel will try to find an instance in the registry. So for example for Spring application, you can configure the installer as a bean:

Installer myInstaller() {
    new CustomInstaller();

Last updated