Open vkolotov opened 6 years ago
Hi @druciak, I’m happy to help you. Could you please share OH logs so I can understand what’s happening there. Also could you please let me know:
@druciak:
Regarding my previous post, I was changing the station thing and got the error, but when I tried one more time I succeeded. Moreover when I changed adapter for this thing to preferred one, it shows as ONLINE. :slight_smile:
Unfortunately when I linked some generic channels (Model, HW revision, Manufacturer, Battery level, RSSI) I only got valid data for RSSI.
Here are the details about my setup:
I am running Sept. snapshot of 2.2, but I am going to update to some 2.3 snapshot soon on Debian Stretch with generic bluetooth transport using Bluez 5.43-2+deb9u1
@druciak:
BTW: currently I am using a Python script to get data from Bluez and push it using MQTT to OH. I cannot find the source, but interesting info you can find also here.
From what I can see, we could try to add support for your device through custom GATT spec files.
Hi @druciak, looks like it is definitely possible to add support for your device. Could you please try to add GATT files form this commit? https://github.com/sputnikdev/bluetooth-gatt-parser/commit/175b10eb1e497f896ef2663bbb4ba0872f0cc2ad
Create a folder on your file system that is accessible by “openhab” user, something like that: /home/pi/.bluetooth_smart That folder should contain two subfolders:
These two folders should contain your xml files from the commit above, e.g. “characteristic” folder contains XML file for characteristics and “service” contains XML files for your services. Make sure that file permissions are set correctly so that “openhab” user can read them.
Specify gatt extension folder here:
Let me know how it goes.
Update: You will have to remove the thing and add back again.
Update #2: The following channels will be available (if it is working properly):
Indoor temperature:
Base temp Base max temp Base min temp Outdoor temperature:
Sensor 1 temp Sensor 1 max temp Sensor 1 min temp That’s what I could decode from the python script on the article you mentioned earlier. However, from what I can see, there are some other channels that could be potentially added. Unfortunately I do not nave that device, so it is not possible for me to work further. However, if you have some experience in software engineering, you could try to add more by looking what characteristics the device has and what they represent. Most likely humidity readings and extra outdoor sensors could be added.
Hi Vlad, attached logs from the 1.1 version of the binding. I set log level to debug, then install the bindings and then added things. bt.zip
Hey @vkolotov I've just given another try for this binding, but it still does not work with the RAR station properly. How can we make a progress on this?
Hey @druciak, there was no any work done in regards this device. However... I believe we should try something. Some features have been implemented since we tried to add support for this device. I'm hoping that your device advertise something without establishing connection to it.
Could you please do an experiment?
Here you go: Seems something is advertised, what next? :)
Oh very good, I'll have a look in the evening. It is a good sign, most likely we don't have to be connected to the device to get some data from it.
Add all of these channels please. And see what data they get. Please post IDs and values here. I'll try to recognise what's that. Also pls let me knwo whats temperature and humidity around your device so I'll try to match it with the readings.
If you can get several samples for each channel, that would be good.
What profile should I use when linking? Default?
Might be a coincidence, but something has appeared when I change to "connected": Will add more items tomorrow.
This is what I catch till now.
What profile should I use when linking? Default?
when I change to "connected":
Not sure I understand this, what is "profile"?
An option when linking channel to item.
None of these values have changed since yesterday. also no new channels have been added. Seems strange, since the ones with value are imo static data (device description), while temperature and humidity is not there.
Right. Looks like you accidentally enabled "ConnectionControl". Anyway, looks like it does not advertise anything as you say that the channels do not change. However, I can clearly see that the channels that were created have some meaningful data. Can you please now enable "ConnectinoControl" (make sure "Connected" channel getting changed to "enabled") and observe if the channels get some updates?
I did it already - no changes at all.
@druciak: