Open JSweep opened 7 years ago
Hi
did you get it running
i am totally new in programing but i want to connect my NIKO NHC with my Apple HomeKit
i found only this threat on internet. but i don't know how to get it working even i don't know how to start :(
Hello, I have the same issue :
MacBook-Air-de-Antoine:~ antoine$ nhc-homekit /usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/HomeControlClient.js:90 locations.data.forEach(function(location) { ^
TypeError: locations.data.forEach is not a function at JsonSocket.onMessage (/usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/HomeControlClient.js:90:20) at emitTwo (events.js:106:13) at JsonSocket.emit (events.js:191:7) at JsonSocket.onData (/usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/JsonSocket.js:42:12) at emitOne (events.js:96:13) at Socket.emit (events.js:188:7) at readableAddChunk (_stream_readable.js:176:18) at Socket.Readable.push (_stream_readable.js:134:10) at TCP.onread (net.js:547:20) MacBook-Air-de-Antoine:~ antoine$
I'm having the same issue. It would be nice if I could try this bridge
Hi, it works fine on my MacMini and MacBook. Is the NHC controller in reach of your computer? Be sure you are on the same network.
Hello, Yes all is on the same network. What are the versions of yours softwares : OSX, npm, niko, ... ?
Thanks.
Bien à vous,
Antoine Cesbron
Le 21 oct. 2017 à 10:41, Jan Stieperaere notifications@github.com a écrit :
Hi, it works fine on my MacMini and MacBook. Is the NHC controller in reach of your computer? Be sure you are on the same network.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.
I’m trying it on High Sierra with and version v6.11.4 of Node.
On these versions the error occurs.
On 21 Oct 2017, at 18:09, Tonio1180 notifications@github.com wrote:
Hello, Yes all is on the same network. What are the versions of yours softwares : OSX, npm, niko, ... ?
Thanks.
Bien à vous,
Antoine Cesbron
Le 21 oct. 2017 à 10:41, Jan Stieperaere notifications@github.com a écrit :
Hi, it works fine on my MacMini and MacBook. Is the NHC controller in reach of your computer? Be sure you are on the same network.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kevinbungeneers/nhc-homekit/issues/2#issuecomment-338413219, or mute the thread https://github.com/notifications/unsubscribe-auth/AA2Fb0Go63jHeCQrbtB3bp7zd0iZYFwpks5suhdFgaJpZM4OSCct.
Hi, I'm using:
node 6.11.3 npm 3.10.10 NHC Controller API 1.19 Mac OS 10.11.6 ( on MacMini ) and 10.12.6 ( on MacBook Pro )
I first tested it on my MacBook, but it is now running on my MacMini who is on all the time.
Node v6.11.4 nom 3.10.10 Connected Controller softwareversie: 1.3.2.38 Programming Software version: 1.16 Mac OS 10.13.1
--> Not working
sudo npm install -g nhc-homekit /usr/local/bin/nhc-homekit -> /usr/local/lib/node_modules/nhc-homekit/bin/nhc-homekit /usr/local/lib └── nhc-homekit@0.0.2
nhc-homekit /usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/HomeControlClient.js:90 locations.data.forEach(function(location) { ^
TypeError: locations.data.forEach is not a function at JsonSocket.onMessage (/usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/HomeControlClient.js:90:20) at emitTwo (events.js:106:13) at JsonSocket.emit (events.js:191:7) at JsonSocket.onData (/usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/JsonSocket.js:42:12) at emitOne (events.js:96:13) at Socket.emit (events.js:188:7) at readableAddChunk (_stream_readable.js:176:18) at Socket.Readable.push (_stream_readable.js:134:10) at TCP.onread (net.js:547:20)
Any update on this?
Guys did you solve the issue with
TypeError: locations.data.forEach is not a function ?????
thanks
Dont have this error but others.
Wouldn’t it be good to start a Facebook chat of Skype chat for the nhc. Because looks like a lot of belgium Guys want to modify it. Maybe we can help each other better this way
Friend of mine help mi to push me little bit further they know something about coding and past some extra line to code to find out something
HomeControlClient.prototype.listLocations = function(callback) { var json = { cmd: 'listlocations' }; var onMessage = (locations, socket) => { var parsedLocations = []; if(locations != null){ if(locations.data!=null){ console.log("locations.data exist"); console.log("data="+JSON.stringify(locations.data,null,2)); locations.data.forEach( (location )=> { console.log("loc="+location.toString()); }); } else{console.log("locations.data is null!");} }else{console.log("locations is null!");} locations.data.forEach(function(location) { parsedLocations[location.id] = new Location(location); });
we find out there is a problem with object "data"
WARNING Please fix your application to use the native API of Avahi! WARNING For more information see http://0pointer.de/avahi-compat?s=libdns_sd&e=node&f=DNSServiceRegister locations.data exist data={ "error": 105 } /usr/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/HomeControlClient.js:94 locations.data.forEach( (location )=> { ^
TypeError: locations.data.forEach is not a function
it seems there is a problem that the program can not contact a niko controller or what. in Object "DATA" is nothing or data have an error 105 and we don't know what does it mean. in code there is something with room list can we somehow check the communication with NIKO controller ? did you know somebody how to check communication ?
thanks
Guys,
Can anyone confirm if they have locations defined in their NHC installation? That's probably the first step in order to fix this.
When writing this application I kinda assumed that everyone who had such an installation, had locations defined for all the actions programmed. I'll need some info/help before I can even try to fix this since I don't have access to an NHC installation anymore.
Yes, I have locations defined in my NHC and I see the error.
On 2 Feb 2018, at 09:43, Kevin Bungeneers notifications@github.com wrote:
Guys,
Can anyone confirm if they have locations defined in their NHC installation? That's probably the first step in order to fix this.
When writing this application I kinda assumed that everyone who had such an installation, had locations defined for all the actions programmed. I'll need some info/help before I can even try to fix this since I don't have access to an NHC installation anymore.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kevinbungeneers/nhc-homekit/issues/2#issuecomment-362522351, or mute the thread https://github.com/notifications/unsubscribe-auth/AA2Fb7lg2PiFJdCP7eK_8T_jrK4StCM-ks5tQsrGgaJpZM4OSCct.
Hi,
As I said before, im running on:
node 6.11.3 npm 3.10.10 NHC Controller API 1.19 Mac OS 10.11.6 ( on MacMini ) or 10.12.6 ( on MacBook Pro )
and do NOT have this error, everything works fine.
I think it is best to first try if the HomeControlClient works. https://github.com/kevinbungeneers/nhc-client
Try to list location there, and maybe try to turn on/off a light manually. If that all works fine, the NHC-Homekit should work as well.
Kind regards,
Jan
I don't seem to be able to get this running.
This is the error I keep getting.
MacBook-Pro-van-Joris:lib jorisv$ nhc-homekit /usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/HomeControlClient.js:90 locations.data.forEach(function(location) { ^
TypeError: locations.data.forEach is not a function at JsonSocket.onMessage (/usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/HomeControlClient.js:90:20) at emitTwo (events.js:106:13) at JsonSocket.emit (events.js:191:7) at JsonSocket.onData (/usr/local/lib/node_modules/nhc-homekit/node_modules/nhc-client/lib/JsonSocket.js:42:12) at emitOne (events.js:96:13) at Socket.emit (events.js:188:7) at readableAddChunk (_stream_readable.js:176:18) at Socket.Readable.push (_stream_readable.js:134:10) at TCP.onread (net.js:547:20)