Page 38 of 86

Re: homebridge-edomoticz Plugin

Posted: Thursday 22 September 2016 20:13
by Marci
TheRamon wrote: I have kind of lost track of the master branch. :oops: :D
You n’ me both - am delaying the inevitable... master needs throwing in the bin and MQTT-integration becoming master.

Bravo on the auth issue - can’t believe I missed the missing ‘Basic ‘ prefix for so long... have just merged in the SSL cert revocation fixes also, which changes things somewhat regarding the auth anyways, so you might wanna get that pulled!

EDIT: Jeebus but my autism is getting the better of me today... sooo many mistakes / double posts!

Re: homebridge-edomoticz Plugin

Posted: Friday 23 September 2016 9:57
by superczar
Just tried this last night and the npm is working very well for me - for a system with over 50 devices

Just have a couple of questions:
a) Is there any possibility of supporting IP Cameras?
b) I cannot use remote access because the only spare iOS device I have is a gen 3 ipad - Before I plonk the cash for an Apple TV (for which I have no other use except remote access enabling), just wanted to confirm if :

(i) is there any alternate method for remote access
(ii) I don't understand the way the code works, is there any possibility that Apple could kill support for homebridge with an update?

Re: homebridge-edomoticz Plugin

Posted: Friday 23 September 2016 10:20
by Marci
superczar wrote:Just tried this last night and the npm is working very well for me - for a system with over 50 devices

Just have a couple of questions:
a) Is there any possibility of supporting IP Cameras?
Not until https://github.com/nfarina/homebridge supports it, which basically means waiting until https://github.com/KhaosT/HAP-NodeJS/ supports it, which is dependant on a node based rtsp transcoder that functions within HomeKit protocol spec. So that’s 3x pieces of software from 3 unrelated developers that need to be updated / commissioned before this plugin will be able to have access to anything to do with IP cameras over HomeKit. (That’s without any work that may be required on the Domoticz side of things). Watch this space.

TL:DR - yes, but everyone will have to be VERY patient about it.
b) I cannot use remote access because the only spare iOS device I have is a gen 3 ipad - Before I plonk the cash for an Apple TV (for which I have no other use except remote access enabling), just wanted to confirm if :

(i) is there any alternate method for remote access
Nope, not via HomeKit. AppleTV 3rd gen supports remote access for manual switch control, but will ignore automation rules and triggers. AppleTV 4th gen is required for full functionality. As of iOS10, you must have Apple’s Two Factor Authentication enabled on your iCloud account for any of it to work via any method.

All that said, iOS9 devices running their own HomeKit clients (e.g.: Eve) will continue to function fully with AppleTV 2nd generation upwards as the remote access bridge.
(ii) I don't understand the way the code works, is there any possibility that Apple could kill support for homebridge with an update?
Entirely possible... s’what you get for wanting to home bodge your own HomeKit hardware rather than pay for certified products from manufacturers who have paid the relevant licensing and intellectual property fees to Apple. Essentially, HAP-NodeJS is the home automation protocol equivalent of a pirate movie downloaded off bit-torrent.

Re: homebridge-edomoticz Plugin

Posted: Friday 23 September 2016 18:14
by madrian
Thanks for this code, it's a nice to turn on/off my devices via Siri. :) One question: remote connection is not supported? As I know to access HomeKit form remote location you need an AppleTV.

Re: homebridge-edomoticz Plugin

Posted: Friday 23 September 2016 18:30
by Marci
Like I said in the post directly before yours...
AppleTV 3rd gen supports remote access for manual switch control, but will ignore automation rules and triggers. AppleTV 4th gen is required for full functionality. As of iOS10, you must have Apple’s Two Factor Authentication enabled on your iCloud account for any of it to work via any method.

Re: homebridge-edomoticz Plugin

Posted: Friday 23 September 2016 19:21
by madrian
Ahh. Sorry. ;) Thanks!

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 12:44
by Marci
Lots of 'Prepare for release' commits being made by KhaosT to the IP-cam branch of HAP-nodeJS over past 48hrs... once these propagate through to nfarina's Homebridge we can start looking towards IPCam support [IF Domoticz exposes the necessary information via it's own API].

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 19:58
by boudicca
aww sausages.....The bridge is broke, been working for months fine, did some npm stuff for another project HAbridge and not sure whats broken if its even on the homebridge side. Homebridge ran okay....still shows as present on network port 51826, but Homekit on the phone just doesn't see it. Have deleted the homekit profiles from the iphone, readded and tried with EVE to find the homekit (homebridge) just keeps spinning.

Any thoughts, this week i've updated rpi-update to the latest firmware, (for wifi) also done a jessie upgrade, as well as trying to install some button-dash npm stuff and habridge....

Any thoughts. No errors I can see on the pi.

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 20:27
by Marci
You emptied the persist folder at ~/.homebridge, and changed mac-address-style username in config.json?

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 22:42
by boudicca
no.

It still the one from the original docs CC:21:3E:E4:DE:33 and persists has has this in the persists AccessoryInfo.CC213EE4DE33.json and equivelent identifier one.

heres the tail of the log. happily sitting waiting for a connection.....I can telnet from my laptop to the port also...so its listening. Just EVE can't see it

[eDomoticz] Initializing platform accessory 'X10 LightX10a3 - Heyu'...
[eDomoticz] Initializing platform accessory 'energenie r1 Stand Lamp'...
[eDomoticz] Initializing platform accessory 'energenie r2 Desk Lamp'...
Scan this code with your HomeKit App on your iOS device to pair with Homebridge:

┌────────────┐
│ 031-45-154 │
└────────────┘

Homebridge is running on port 51826.

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 22:54
by Marci
That's why. Stop homebridge. Empty persist, change username in config.json, and ideally give your bridge a new name while you're in there. Start homebridge. You should then be able to add your bridge.

This is standard practice and first port of call when anything occurs that results in your bridge not showing up (if no other errors can be found).

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 23:08
by rwijbenga
Great work on this plugin! Love it! :D

But I have 2 questions:

1- I have a lux sensor working in domoticz, but on my homekit it gives an error and does not display a value.... Any idea's ?

2- If I add a new device in Domoticz, how can I update the homekit without deleting the house and ading it again... that is the I have been doing it the last few times. Then I have to ceate all the rooms again and names......

Thnx again!

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 23:11
by Marci
1) if your HomeKit app is iOS10’s Home app, lux isn't an Apple native supported service. Therefore, will display as unsupported. Try it in Eve. If it shows up with an error in Eve, post your JSON output for the device to the GitHub issues page for the plugin as per the first post.
2) Restart homeBridge, give it a few minutes. New devices will show up in whatever room is your default room.

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 23:15
by boudicca
stopped.
emptied
name changed

bridge": {
"name": "Shazbridge",
"username": "CC:21:3E:E4:DE:39"

Still no....just eve whirling round.

A hunch poss......tcp6 0 0 [::]:51826 [::]:* LISTEN

Note tcp6.... but its connecting via telnet so not 100% on that hunch

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 23:17
by Marci
Turn off tcp6 on your Pi. Restart homeBridge, try again. Make sure bonjour protocol is running freely on your network (flush DNS caches then try connecting to your device's .local name in a web browser)

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 23:28
by boudicca
its back not sure if me disabling ipv6 had anything to do with it...but its back....whoopie

edit: lot of reconfiguring to do.............weird

Thanks for the help

Re: homebridge-edomoticz Plugin

Posted: Sunday 25 September 2016 23:33
by Marci
Usually takes a few minutes as everything takes a while to sync to your iCloud instance. This can take longer if you recreate your home profile in HomeKit and use the same home name as previous. You've got identity and credential cacheing taking place within homeBridge (via persist/), and then any cacheing that takes place at Apple's end in iCloud to contend with. If such occurs again, recreate your home with a new name, rename your bridge and username in config.json, empty persist folder. That semi-guarantees all caches will start afresh.

Re: homebridge-edomoticz Plugin

Posted: Monday 26 September 2016 11:17
by rwijbenga
@marci

Lux sensor works in eve! :)

And rebooting my Pi works super for adding or removing things from homekit.

Great work!

Currious about the new updates to come tot his plugin in the future... 8-)

Re: homebridge-edomoticz Plugin

Posted: Monday 26 September 2016 18:15
by Marci
Add a manual switch in Domoticz, with on action set to script:///usr/bin/shutdown%20-r%20now or similar...
Now you can tap that switch via homekit to remote trigger a reboot of the server.

Or better yet, get it to run the proper command to restart homebridge on it’s own rather than the entire Pi (which for me is simply 'forever restart 0’ but depends how you’ve got homebridge running at boot)

Re: homebridge-edomoticz Plugin

Posted: Monday 26 September 2016 22:54
by rwijbenga
Good tip! Works a treat!