superjunky / Domoticz-Brel-Plugin

A Python plugin for Domoticz to controll Brel Home Hub
MIT License
3 stars 3 forks source link

Help needed #1

Closed Caroga closed 3 years ago

Caroga commented 3 years ago

Hi there! I'm trying to find information about the brel home router and how to interface with it. I was wondering, besides reading your code, how I could do some stuff with this. Where and how did you manage to get this to work, I cannot seem to find any documentation on the api of the device.

Any references or help would be very much appreciated. Thank you in advance.

Caroga commented 3 years ago

Ow wow, I feel like such an idiot. It's after posting this message that I saw the pdf files in your repository. I will take a look at this. Also, retrieving the key: does this only work in the iphone app or also android ?

superjunky commented 3 years ago

Yeah exactly, the docs :) For this plugin I made use of the UDP interface since it doesn't require internet. The Restful API is fairly new, I never tested it. (While writing it comes to mind I did not even add it to the repo. Will do that right away.)

As for the key; I only was able to test it on ios, but I'm certain it works the same for Android. I recall their app was originally designed for Android.

Caroga commented 3 years ago

Thank you for your quick response! I currently am unable to generate a API key on the android app. Using the Brel Home app I tried pressing quickly 5 times on the Version number on the settings page but this did not result in an key being displayed. I will install the app on my iPhone, see if this helps I will check the JSON document right away.

superjunky commented 3 years ago

If you haven't done so, make sure you have the bridge setup with your app before retrieving the key. I remember having some issues setting up the bridge because it needed a WIFI network dedicated for 2.4G. When you combine it with a 5G network, the hub fails to connect.

Caroga commented 3 years ago

I've connected succesfully with the Brel device using the brel app. I can control my devices too. The wifi is 2.4ghz indeed. I do see that the app differs from the documentation (connector app) where I am using the Brel Home https://play.google.com/store/apps/details?id=com.id3.icurtain.brel&hl=nl&gl=US Which app are you using?

superjunky commented 3 years ago

The Brel app. I couldn't get the connector app to work. Instead of tapping 5 times, perhaps try tapping the version number like a maniac ;)

At first I used a rather hard-coded script for sending commands to the Hub. I have added it to the docs folder in the repo. Maybe it's helpfull

Caroga commented 3 years ago

I will take a lookt at the script, thank you very much! In the meantime I've bashed the version number like a maniac on steroids but still am unable to get a key from the app. For the sake if science I've posted a screenshot from the app where I'm poking the version number at: image

I assume, since I could not find any other location displaying the version number, this is the right place. Right?

superjunky commented 3 years ago

Yes thats where I got it from. Check my screen. Well... I would fire-off an email to Brel. I know for a fact the tech-person is on Android, he should be able to help you out. And if you do, please share the answer here. You got me curious

Schermafbeelding 2021-02-14 om 19 52 15
Caroga commented 3 years ago

I see you are running version 1.1.5(3) where I have 1.1.0.0125. Maybe this could be a reason as to why it's not working. I'll try it with my iPhone too if that's possible. Anyway I'll be contacting support yeah, maybe the tech-person over that could assist me with this. I thank you very much for your time and help so far!

Caroga commented 3 years ago

Okay I got the key from the iPhone, hooray! Still be contacting support though. I will try (to modify) your scripts to see if I can get some stuff from the hub. I'm not a python developer but I think I'll manage. 🎉

Caroga commented 3 years ago

Hey! I completely forgot closing this ticket, thanks for your help! I have succeeded creating a connection via python with the device. I have however not had the privilege to continue and finish the work. Hopefully some day soon. Thank you for your help, much appreciated!