Just got OmnIoT working today, still getting the hang of it, but noticed my BLE device is disconnecting from a RPi with raspbian stretch, bluez version 5.43, on regular 10 minute intervals! This from the SysLog.log:
01/12/19 22:03:25 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has connected successfully.
01/12/19 22:13:34 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has disconnected. <-- 10 minutes 9 seconds
01/12/19 22:13:52 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has connected successfully.
01/12/19 22:23:58 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has disconnected. <-- 10 minutes 6 seconds
01/12/19 22:24:16 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has connected successfully.
01/12/19 22:34:25 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has disconnected. <-- 10 minutes 9 seconds
01/12/19 22:34:42 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has connected successfully.
01/12/19 22:44:49 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has disconnected. <-- 10 minutes 7 seconds
01/12/19 22:45:07 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has connected successfully.
01/12/19 22:55:15 - BLE COMMSMGR: Ble Sensor Type=Atmosphere Project, Id=00:60:37:0A:AF:EF, has disconnected. <-- 10 minutes 8 seconds
CES was fun but also a grind. Always happy to go but then happy to get back too... regarding the disconnect, the 10 minute one was definitely our issue. We have some watchdog code that monitors each BLE connection and in the lead up to CES there was a flurry of new features/sensor support added and that code got tweaked. Needed to move one line of code back where it had been basically. The shorter period disconnects I think may be the device unfortunately. I noticed that on the sensor I have sometimes if I moved it at all it would disconnect sometimes. I usually had it plugged in so I thought it might have had a power connect issue or even a bad cable. Last night after making that code change I used a raspberry pi ac adapter to power it and left it sitting on a separate desk and it ran for the hour I tested it with no disconnects...
CES - I'm totally jealous :) This is likely not an OmnIoT thing - get the same ocassional ble disconnect with gatttool. Will try the updated file shortly.
So I believe the issue should be resolved (some overzealous connection watchdog code). I've uploaded just an updated tar-omniotsh.tar.gz file for the time being and there is a link below. I'll update the full install package once I've done some more testing but I'm pretty confident this should address what you are seeing. To install you only need to
(1) Stop the omniotshd daemon
(2) Extract the "omniotshd" executable file and replace the copy in /usr/local/bin/
(3) Restart the omniotshd daemon
Here's the link... any additional questions let me know, Thx!
https://drive.google.com/uc?export=download&id=1lsz9cOFYg-Gofq2LxCHsk_-zd4RC3uhN
Hi, Sorry you are having issues... I don't believe I've seen anything like this before but will be able to try it out tonight (currently traveling back from CES) and let you know if I can reproduce it. In the meantime if possible if you can send your config file to info@omniot.com that would help. If needed, you can just dummy out any private values (i.e. your server ip addresses, etc.). Also, I believe you are connecting with the NXP sensor (via the auto-connect), correct? And only enabling the light sensor for notifications?
I'll follow up tonight and let you know what I find... thx!
Ah the 10 minutes might be a red herring - recently happens more often:
01/12/19 23:05:47 - connected successfully.
01/12/19 23:15:55 - disconnected. <-- 10 minutes 8 seconds
01/12/19 23:16:13 - connected successfully.
01/12/19 23:19:54 - disconnected. <-- 3 minutes 41 seconds
01/12/19 23:20:08 - connected successfully.
01/12/19 23:21:04 - disconnected. <-- 56 seconds