3rd Party Bluetooth Binding. Beta testers needed

bluetooth
binding
Tags: #<Tag:0x00007f015a03b210> #<Tag:0x00007f015a03b080>

(Vlad Kolotov) #807

I don’t think TinyB is going to fix it. There are some works that aimed to get rid of TinyB by implementing a new transport module that talks to Bluez directly via DBus. It is wip by @xrucka, see hi post here:

3rd Party Bluetooth Binding. Beta testers needed


(Marek) #808

ok, thanks. I’ll check that.


(jimmy loyens) #809

Do you have an example of a .thing file for this binding? Or is it only possible to configure using paperUI?
Thanks


(Grzegorz Golec) #810

Hi all, I need your help. I have two sensors [Xiaomi Mijia Bluetooth Temperature Smart Humidity Sensor] one has been detected with options temperature/humidity/last updated etc. but second one can’t get all these options. I tried to remove but once detected again and added from Inbox it takes the same parameters including name. How to remove from db all historical informations about this sensor? Some cache? Is it any karaf cli command? I already tried smarthome:things remove but effect the same as removing from PaperUI - does not forget previous data.


(Vlad Kolotov) #811

Hi @Grzegorz_Golec, make sure your Temp/Humidity sensor is of most recent firmware version. Connect it to your phone and update it through Mi app.


(Grzegorz Golec) #812

it seems to both sensors are in the same latest firmware 1.0.1_0066.
Any other suggestions appreciated


(G) #813

I’m regularly (about once a day) getting these errors on my syslog:

Jan  8 05:44:04 raspberrypi kernel: [19732.559920] Bluetooth: hci0 command 0x200c tx timeout
Jan  8 05:44:04 raspberrypi kernel: [19732.559961] Bluetooth: Failed to disable LE scan: status 0x1f

and from that moment this breaks bluetooth (devices get no later updates), until I do a sudo systemctl restart bluetooth

This then thows a bunch of errors in openhab.log, but it starts working again:

Jan  8 10:00:35 raspberrypi systemd[1]: Stopping Bluetooth service...
Jan  8 10:00:35 raspberrypi bluetoothd[763]: Terminating
Jan  8 10:00:35 raspberrypi kernel: [35123.238016] Bluetooth: hci0: Frame reassembly failed (-84)
Jan  8 10:00:37 raspberrypi kernel: [35125.260539] Bluetooth: hci0 command 0x200c tx timeout
Jan  8 10:00:41 raspberrypi bluetoothd[763]: Stopping SDP server
Jan  8 10:00:41 raspberrypi bluetoothd[763]: Exit
Jan  8 10:00:41 raspberrypi systemd[1]: Starting Bluetooth service...
Jan  8 10:00:41 raspberrypi bluetoothd[25375]: Bluetooth daemon 5.48
Jan  8 10:00:41 raspberrypi systemd[1]: Started Bluetooth service.
Jan  8 10:00:41 raspberrypi bluetoothd[25375]: Starting SDP server
Jan  8 10:00:41 raspberrypi bluetoothd[25375]: Bluetooth management interface 1.14 initialized
Jan  8 10:00:41 raspberrypi dbus[495]: [system] Activating via systemd: service name='org.freedesktop.hostname1' unit='dbus-org.freedesktop.hostname1.service'
Jan  8 10:00:41 raspberrypi systemd[1]: Starting Hostname Service...
Jan  8 10:00:41 raspberrypi systemd[1]: Failed to reset devices.list on /system.slice: Invalid argument
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi karaf[927]: (process:927): GLib-GIO-CRITICAL **: g_dbus_interface_get_info: assertion 'G_IS_DBUS_INTERFACE (interface_)' failed
Jan  8 10:00:41 raspberrypi systemd-hostnamed[25406]: Warning: nss-myhostname is not installed. Changing the local hostname might make it unresolveable. Please install nss-myhostname!
Jan  8 10:00:41 raspberrypi dbus[495]: [system] Successfully activated service 'org.freedesktop.hostname1'
Jan  8 10:00:41 raspberrypi systemd[1]: Started Hostname Service.
Jan  8 10:00:49 raspberrypi karaf[927]: ** (process:927): WARNING **: Error setting property 'Powered' on interface org.bluez.Adapter1: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name :1.3 was not provided by any .service files (g-dbus-error-quark, 2)

Previously I used to pick up my bluetooth device updates through regularly cron-ed python scripts, and that didn’t cause any issues. I did upgrade bluetooth to 5.48 from 5.43 at the same time as switched to this binding though.


(Christoph) #814

Have a look in the first post:


(G) #815

Sorry, had missed that note! Gone down to 5.47 now, and running; will see how it holds up.
Thanks


(Nanna Agesen) #816

Hi

I’m Trying to get this to work - I have followed the install instruction but stuck here:

openhab> bundle:list | grep bluetooth
264 │ Waiting  │  80 │ 1.1.3                  │ org.sputnikdev:org.eclipse.smarthome.binding.bluetooth.transport.tinyb
265 │ Active   │  80 │ 1.1.6                  │ org.sputnikdev:org.eclipse.smarthome.binding.bluetooth

The .bluetooth.transport.tinyb never starts keeps waiting

Blues are running and within the version required

]# systemctl status bluetooth -l
● bluetooth.service - Bluetooth service
   Loaded: loaded (/usr/lib/systemd/system/bluetooth.service; enabled; vendor preset: enabled)
   Active: active (running) since Wed 2019-01-09 01:27:41 CET; 6h ago
     Docs: man:bluetoothd(8)
 Main PID: 1310 (bluetoothd)
   Status: "Running"
    Tasks: 1
   CGroup: /system.slice/bluetooth.service
           └─1310 /usr/libexec/bluetooth/bluetoothd

Jan 09 01:27:41 openhab.agesen.dk systemd[1]: Starting Bluetooth service...
Jan 09 01:27:41 openhab.agesen.dk bluetoothd[1310]: Bluetooth daemon 5.44
Jan 09 01:27:41 openhab.agesen.dk systemd[1]: Started Bluetooth service.
Jan 09 01:27:41 openhab.agesen.dk bluetoothd[1310]: Starting SDP server
Jan 09 01:27:41 openhab.agesen.dk bluetoothd[1310]: Bluetooth management interface 1.14 initialized
Jan 09 01:27:41 openhab.agesen.dk bluetoothd[1310]: Endpoint registered: sender=:1.130 path=/MediaEndpoint/A2DPSource
Jan 09 01:27:41 openhab.agesen.dk bluetoothd[1310]: Endpoint registered: sender=:1.130 path=/MediaEndpoint/A2DPSink

Could this have anything to with TinyB wrong path?

java.lang.IllegalStateException: Could not load native libraries for TinyB
	at org.sputnikdev.esh.binding.bluetooth.transport.tinyb.activator.TinyBActivator.activate(TinyBActivator.java:19) ~[?:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:?]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:?]
	at org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:228) ~[39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41) ~[39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:664) ~[39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:510) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.inject.methods.ActivateMethod.invoke(ActivateMethod.java:317) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.inject.methods.ActivateMethod.invoke(ActivateMethod.java:307) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.manager.SingleComponentManager.createImplementationObject(SingleComponentManager.java:341) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.manager.SingleComponentManager.createComponent(SingleComponentManager.java:114) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:983) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.manager.SingleComponentManager.getServiceInternal(SingleComponentManager.java:956) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:765) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.manager.AbstractComponentManager.enableInternal(AbstractComponentManager.java:666) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.manager.AbstractComponentManager.enable(AbstractComponentManager.java:432) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.manager.ConfigurableComponentHolder.enableComponents(ConfigurableComponentHolder.java:665) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.BundleComponentActivator.initialEnable(BundleComponentActivator.java:339) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:381) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.Activator.access$200(Activator.java:49) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.Activator$ScrExtension.start(Activator.java:263) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.AbstractExtender.createExtension(AbstractExtender.java:196) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.AbstractExtender.modifiedBundle(AbstractExtender.java:169) [39:org.apache.felix.scr:2.1.14]
	at org.apache.felix.scr.impl.AbstractExtender.modifiedBundle(AbstractExtender.java:49) [39:org.apache.felix.scr:2.1.14]
	at org.osgi.util.tracker.BundleTracker$Tracked.customizerModified(BundleTracker.java:482) [?:?]
	at org.osgi.util.tracker.BundleTracker$Tracked.customizerModified(BundleTracker.java:415) [?:?]
	at org.osgi.util.tracker.AbstractTracked.track(AbstractTracked.java:232) [?:?]
	at org.osgi.util.tracker.BundleTracker$Tracked.bundleChanged(BundleTracker.java:444) [?:?]
	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:908) [?:?]
	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230) [?:?]
	at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148) [?:?]
	at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEventPrivileged(EquinoxEventPublisher.java:213) [?:?]
	at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEvent(EquinoxEventPublisher.java:120) [?:?]
	at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEvent(EquinoxEventPublisher.java:112) [?:?]
	at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor.publishModuleEvent(EquinoxContainerAdaptor.java:168) [?:?]
	at org.eclipse.osgi.container.Module.publishEvent(Module.java:476) [?:?]
	at org.eclipse.osgi.container.Module.start(Module.java:467) [?:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1634) [?:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1614) [?:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1585) [?:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1528) [?:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1) [?:?]
	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230) [?:?]
	at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340) [?:?]

(druciak) #817

@vkolotov is there any chance to get this binding working with bluez 5.50?


(Thomas Bail) #818

I am running the binding with bluez 5.50 on a debian virtual machine


(druciak) #819

I thought it does not work with versions > 5.47 as stated in the first post.
Do you have any issues with 5.50?


(Thomas Bail) #820

Yes on my last system i used the 5.47, but an the new system i forgot to change it. I think i have no problem with the 5.5, because ich do not see any problems, but … The debian version is the testing of the version after stretch


(G) #821

Actually, just happened again, on 5.47.

Jan 10 23:15:59 raspberrypi kernel: [11496.878881] Bluetooth: hci0: Frame reassembly failed (-84)
Jan 10 23:15:59 raspberrypi kernel: [11496.878887] Bluetooth: hci0 advertising data length corrected
Jan 10 23:15:59 raspberrypi kernel: [11496.878943] Bluetooth: hci0: Frame reassembly failed (-84)
Jan 10 23:16:05 raspberrypi kernel: [11502.765129] Bluetooth: hci0 command 0x200c tx timeout
Jan 10 23:16:05 raspberrypi kernel: [11502.765169] Bluetooth: Failed to disable LE scan: status 0x1f

and on
sudo service bluetooth restart

got pretty much the same log as before, but I’ll highlight the new version number:

Jan 11 02:30:44 raspberrypi bluetoothd[30652]: Bluetooth daemon 5.47
Jan 11 02:30:44 raspberrypi systemd[1]: Started Bluetooth service.

(Thomas Bail) #822

I am still having sme problems with the binding. Currentliy 5 bluetooth dongles are connected.

1 - Usb Port off my synology redirected to the vm with openhab - Stable
2 - HCI Adapter propagated from a raspi 1 with usbip - Until now stable
3 - HCI Adapter propagated from a raspi 1 with usbip - Seems to be stable after changing the prower supply
4 - Blugiga Adapter propagated from raspi 1 with ser2net/socat - Connection gets regulary lost even if the local port is there an the bled script from bluegiga is able to receiver datat
5 - same as 4

Today i decides to restart the blugiga bundle from with in karaf aand i get this error.

Failed to connect on port: /dev/ttyNET3 exception:
gnu.io.PortInUseException: NRSerialPort
        at gnu.io.CommPortIdentifier.open(CommPortIdentifier.java:459)
        at gnu.io.factory.RxTxPortCreator.createPort(RxTxPortCreator.java:37)
        at gnu.io.NRSerialPort.connect(NRSerialPort.java:99)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaHandler.openSerialPort(BluegigaHandler.java:669)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaHandler.init(BluegigaHandler.java:645)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaHandler.create(BluegigaHandler.java:145)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaFactory.createAdapter(BluegigaFactory.java:226)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaFactory.tryToCreateAdapter(BluegigaFactory.java:329)
        at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
        at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:175)
        at java.util.HashMap$KeySpliterator.forEachRemaining(HashMap.java:1556)
        at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
        at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
        at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
        at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
        at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaFactory.discoverAdapters(BluegigaFactory.java:284)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaFactory.getDiscoveredAdapters(BluegigaFactory.java:137)
        at org.sputnikdev.bluetooth.manager.impl.BluetoothManagerImpl$AdapterDiscoveryJob.discoverAdapters(BluetoothManagerImpl.java:817)
        at org.sputnikdev.bluetooth.manager.impl.BluetoothManagerImpl$AdapterDiscoveryJob.run(BluetoothManagerImpl.java:810)
        at org.sputnikdev.bluetooth.manager.impl.BluetoothManagerImpl.scheduleDiscovery(BluetoothManagerImpl.java:853)
        at org.sputnikdev.bluetooth.manager.impl.BluetoothManagerImpl.lambda$registerFactory$1(BluetoothManagerImpl.java:126)
        at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1660)
        at org.sputnikdev.bluetooth.manager.impl.BluetoothManagerImpl.registerFactory(BluetoothManagerImpl.java:124)
        at org.sputnikdev.esh.binding.bluetooth.internal.BluetoothHandlerFactory.registerBluetoothObjectFactory(BluetoothHandlerFactory.java:112)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:228)
        at org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41)
        at org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:664)
        at org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:510)
        at org.apache.felix.scr.impl.inject.methods.BindMethod.invoke(BindMethod.java:42)
        at org.apache.felix.scr.impl.manager.DependencyManager.doInvokeBindMethod(DependencyManager.java:1809)
        at org.apache.felix.scr.impl.manager.DependencyManager.invokeBindMethod(DependencyManager.java:1784)
        at org.apache.felix.scr.impl.manager.SingleComponentManager.invokeBindMethod(SingleComponentManager.java:409)
        at org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.addedService(DependencyManager.java:333)
        at org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.addedService(DependencyManager.java:302)
        at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1216)
        at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1137)
        at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.trackAdding(ServiceTracker.java:944)
        at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.track(ServiceTracker.java:880)
        at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:1168)
        at org.apache.felix.scr.impl.BundleComponentActivator$ListenerInfo.serviceChanged(BundleComponentActivator.java:125)
        at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:109)
        at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:920)
        at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
        at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
        at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:862)
        at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry$1.run(ServiceRegistry.java:805)
        at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry$1.run(ServiceRegistry.java:1)
        at java.security.AccessController.doPrivileged(Native Method)
        at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:803)
        at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:127)
        at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:225)
        at org.eclipse.osgi.internal.framework.BundleContextImpl.registerService(BundleContextImpl.java:469)
        at org.eclipse.osgi.internal.framework.BundleContextImpl.registerService(BundleContextImpl.java:487)
        at org.sputnikdev.esh.binding.bluetooth.transport.bluegiga.activator.BlueGigaActivator.activate(BlueGigaActivator.java:30)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:228)
        at org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41)
        at org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:664)
        at org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:510)
        at org.apache.felix.scr.impl.inject.methods.ActivateMethod.invoke(ActivateMethod.java:317)
        at org.apache.felix.scr.impl.inject.methods.ActivateMethod.invoke(ActivateMethod.java:307)
        at org.apache.felix.scr.impl.manager.SingleComponentManager.createImplementationObject(SingleComponentManager.java:334)
        at org.apache.felix.scr.impl.manager.SingleComponentManager.createComponent(SingleComponentManager.java:114)
        at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:947)
        at org.apache.felix.scr.impl.manager.SingleComponentManager.getServiceInternal(SingleComponentManager.java:919)
        at org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:750)
        at org.apache.felix.scr.impl.manager.AbstractComponentManager.enableInternal(AbstractComponentManager.java:661)
        at org.apache.felix.scr.impl.manager.AbstractComponentManager.enable(AbstractComponentManager.java:427)
        at org.apache.felix.scr.impl.manager.ConfigurableComponentHolder.enableComponents(ConfigurableComponentHolder.java:665)
        at org.apache.felix.scr.impl.BundleComponentActivator.initialEnable(BundleComponentActivator.java:339)
        at org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:381)
        at org.apache.felix.scr.impl.Activator.access$200(Activator.java:49)
        at org.apache.felix.scr.impl.Activator$ScrExtension.start(Activator.java:263)
        at org.apache.felix.scr.impl.AbstractExtender.createExtension(AbstractExtender.java:196)
        at org.apache.felix.scr.impl.AbstractExtender.modifiedBundle(AbstractExtender.java:169)
        at org.apache.felix.scr.impl.AbstractExtender.modifiedBundle(AbstractExtender.java:49)
        at org.osgi.util.tracker.BundleTracker$Tracked.customizerModified(BundleTracker.java:482)
        at org.osgi.util.tracker.BundleTracker$Tracked.customizerModified(BundleTracker.java:415)
        at org.osgi.util.tracker.AbstractTracked.track(AbstractTracked.java:232)
        at org.osgi.util.tracker.BundleTracker$Tracked.bundleChanged(BundleTracker.java:444)
        at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:908)
        at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
        at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
        at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEventPrivileged(EquinoxEventPublisher.java:213)
        at org.eclipse.osgi.internal.framework.EquinoxEventPublisher$1.run(EquinoxEventPublisher.java:124)
        at org.eclipse.osgi.internal.framework.EquinoxEventPublisher$1.run(EquinoxEventPublisher.java:1)
        at java.security.AccessController.doPrivileged(Native Method)
        at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEvent(EquinoxEventPublisher.java:122)
        at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEvent(EquinoxEventPublisher.java:112)
        at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor.publishModuleEvent(EquinoxContainerAdaptor.java:168)
        at org.eclipse.osgi.container.Module.publishEvent(Module.java:476)
        at org.eclipse.osgi.container.Module.start(Module.java:467)
        at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:383)
        at org.apache.karaf.bundle.command.Restart.doExecute(Restart.java:51)
        at org.apache.karaf.bundle.command.BundlesCommand.execute(BundlesCommand.java:55)
        at org.apache.karaf.shell.impl.action.command.ActionCommand.execute(ActionCommand.java:84)
        at org.apache.karaf.shell.impl.console.osgi.secured.SecuredCommand.execute(SecuredCommand.java:68)
        at org.apache.karaf.shell.impl.console.osgi.secured.SecuredCommand.execute(SecuredCommand.java:86)
        at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:599)
        at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:526)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:415)
        at org.apache.felix.gogo.runtime.Pipe.doCall(Pipe.java:416)
        at org.apache.felix.gogo.runtime.Pipe.call(Pipe.java:229)
        at org.apache.felix.gogo.runtime.Pipe.call(Pipe.java:59)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at java.lang.Thread.run(Thread.java:748)
java.lang.NullPointerException
        at gnu.io.NRSerialPort.getInputStream(NRSerialPort.java:124)
        at gnu.io.NRSerialPort.disconnect(NRSerialPort.java:151)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaHandler.lambda$closeBGHandler$19(BluegigaHandler.java:703)
        at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1626)
        at java.util.concurrent.CompletableFuture$AsyncRun.exec(CompletableFuture.java:1618)
        at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
        at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056)
        at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)
        at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157)
openhab> java.lang.NullPointerException
        at gnu.io.NRSerialPort.getInputStream(NRSerialPort.java:124)
        at gnu.io.NRSerialPort.disconnect(NRSerialPort.java:151)
        at org.sputnikdev.bluetooth.manager.transport.bluegiga.BluegigaHandler.lambda$closeBGHandler$19(BluegigaHandler.java:703)
        at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1626)
        at java.util.concurrent.CompletableFuture$AsyncRun.exec(CompletableFuture.java:1618)
        at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
        at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056)
        at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)
        at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157)

Currently i have no idea how to solve this problem. a restart of openhab typically solves the problem


(G) #823

New crash, but different error. This one only comes up on syslog.
From that time on, no bluetooth until I restarted the service. Is no one else getting these?

Jan 14 11:04:15 raspberrypi karaf[24764]: ** (process:24764): WARNING **: Error setting property 'Alias' on interface org.bluez.Device1: GDBus.Error:org.freedesktop.DBus.Error.UnknownObject: Method "Set" with signature "ssv" on interface "org.freedesktop.DBus.Properties" doesn't exist
Jan 14 11:04:15 raspberrypi karaf[24764]: (g-dbus-error-quark, 41)

(Christian) #824

Hello and thanks for the binding and documentation.

I get two Xiaomi Bluetooth Temperature sensors which works fine, but only in a range of 5-7m from my raspberry pi 3B with onboard Bluetooth. Is there a recommendation for a Bluetooth stick which could cover the complete house (two level, each 70m2).

Bye,
Christian


(Thomas Bail) #825

Thats an interessting quest but i assume that the answer ist No. I use different raspberry with BT Dngles that are spread over the house and remotely connected using usbip an ser2net/socat


(Christoph) #826

You could try a stick, which is classified as class 1. They should cover a range up to 100m. An external antenna would be a benefit. There are also some sticks, which claim to have a even greater range (also class 1, but with the addition long range).