dustindclark / homebridge-globalcache-itach Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
I have this controlling an old receiver and when I turn on the switch in HomeKit it works great and turns on the receiver, but when I leave the home app and come back the switch resets itself back to off. Is there a setting I add in the config to get the switch to be stateful?
Dustin
Thank you for the quick response and terrific effort. I just realized that the recent version has an error. The plugin technically works. But, in the current version whether you configure 1 or multiple Itach devices the plugin starts successfully but you loss the ability in HomeKit via Siri to address/request an entire room to be turned on/off. With the plugin enabled Siri believes that no devices are located in any room. I verified that if I remove the plugin from the config.json that you are again able to address a room. For instance with the plugin enabled you can't say "Turn off the Lights in Room 2." Siri responds, "There are no devices in Room 2." As soon is the plugin is disabled the ability returns.
I noticed in the code that you made the following change registering each device as a platform instead of an accessory:
homebridge.registerPlatform("homebridge-globalcache-itach", "GlobalCacheItach", ItachPlatform);
//homebridge.registerAccessory("homebridge-globalcache-itach", "GlobalCacheItach", ItachAccessory);
This appears to have caused the issue. In the interim could you reverse the change so that I can continue to use one device successfully. I didn't make it to UPS today but I will be overnighting you the device in the morning for you testing. Thanks for everything, not pressure on getting multiple devices to work take your time and just let me know when you have nailed it. I realize we all have day jobs. ;-)
Thanks in advance,
Daron
Hi,
Do you have any plans to release a version of this that supports the itach irtriport_blaster?
Thank you.
[8/14/2016, 5:18:30 PM] Loading 1 platforms...
[8/14/2016, 5:18:30 PM] [Global Cache Itach] Initializing GlobalCacheItach platform...
[8/14/2016, 5:18:31 PM] [Global Cache Itach] Connected to 192.168.1.78:48584. Sending command: getdevices
endlistdevicesRIPORT_BLASTERbal Cache Itach] DATA: device,0,0 WIFI
[8/14/2016, 5:18:31 PM] [Global Cache Itach] Found 1 irtriport_blaster ports.
[8/14/2016, 5:18:31 PM] [Global Cache Itach] Configuring iTach accessory. Name: Gate - 1, Type: irtriport_blaster at port: 0
/usr/lib/node_modules/homebridge-globalcache-itach/index.js:186
throw new Error("Unsupported device type: " + this.deviceType);
^
Error: Unsupported device type: irtriport_blaster
at new ItachAccessory (/usr/lib/node_modules/homebridge-globalcache-itach/index.js:186:15)
at ItachPlatform. (/usr/lib/node_modules/homebridge-globalcache-itach/index.js:94:46)
at Socket. (/usr/lib/node_modules/homebridge-globalcache-itach/index.js:314:9)
at emitOne (events.js:96:13)
at Socket.emit (events.js:188:7)
at readableAddChunk (_stream_readable.js:177:18)
at Socket.Readable.push (_stream_readable.js:135:10)
at TCP.onread (net.js:542:20)
Hi, I currently have a global cache relay that I use with Roomie Remote (Simple Control Remote) to open/close my garage door. I would like to get ride of Roomie remote and use this relay with Homebridge.. but how do I go about getting the relay code to insert in the plugins programming?
Root cause is that there are multiple switch services for a given device. Ideally, commands other than on/off would be stateless switches, but stateless switches don't appear to work (see last comment here: https://github.com/KhaosT/HAP-NodeJS/issues/134). Unless HAP supports setting state on a StatelessProgrammableSwitch, only On/Off commands can be used.
The plugin works great! I have one issue If i activate a IR device, say the TV, then turn off the device, multiple times, (three to be exact) the device becomes unresponsive and won't let you interact with it. (I noticed this as I was excited trying out siri and my tv haha) any thoughts to what would be causing this? home bridge doesn't crash, I can still activate my other items Ex. hue lights, but not my tv.
Dustin,
I just realized I was updating a closed ticket so I moved my comments to a new ticket.
I try to initialize home bridge with the itach plugin and I get the following error, any ideas?
Thanks in advance
[9/26/2016, 4:31:07 AM] [Global Cache Itach] Initializing GlobalCacheItach platform...
[9/26/2016, 4:31:07 AM] [Global Cache Itach] Connected to 192.168.1.13:38532. Sending command: getdevices
[9/26/2016, 4:31:07 AM] [Global Cache Itach] Connected to 192.168.1.13:38534. Sending command: get_IRL
[9/26/2016, 4:31:07 AM] [Global Cache Itach] Connected to 192.168.1.13:38536. Sending command: getdevices
endlistdevices31:07 AM] [Global Cache Itach] DATA: device,0,0 ETHERNET
[9/26/2016, 4:31:07 AM] [Global Cache Itach] Found 3 ir ports.
[9/26/2016, 4:31:07 AM] [Global Cache Itach] Configuring iTach accessory. Name: Gate - 1, Type: ir at port: 0
/usr/local/lib/node_modules/homebridge-globalcache-itach/index.js:172
for (var i = 0; i < Object.keys(this.commands).length; i++) {
^
TypeError: Cannot convert undefined or null to object
at Function.keys (native)
at new ItachAccessory (/usr/local/lib/node_modules/homebridge-globalcache-itach/index.js:172:36)
at ItachPlatform. (/usr/local/lib/node_modules/homebridge-globalcache-itach/index.js:94:46)
at Socket. (/usr/local/lib/node_modules/homebridge-globalcache-itach/index.js:314:9)
at emitOne (events.js:77:13)
at Socket.emit (events.js:169:7)
at readableAddChunk (_stream_readable.js:146:16)
at Socket.Readable.push (_stream_readable.js:110:10)
at TCP.onread (net.js:523:20)
Hi,
Thanks very much for your great work. I'm having trouble getting homebridge to start once I install the plugin:
[10/7/2018, 8:40:37 PM] Loaded config.json with 0 accessories and 1 platforms.
[10/7/2018, 8:40:37 PM] ---
[10/7/2018, 8:40:37 PM] Loaded plugin: homebridge-globalcache-itach
[10/7/2018, 8:40:37 PM] Registering platform 'homebridge-globalcache-itach.GlobalCacheItach'
[10/7/2018, 8:40:37 PM] ---
[10/7/2018, 8:40:37 PM] Loading 1 platforms...
[10/7/2018, 8:40:37 PM] [Global Cache Itach] Initializing GlobalCacheItach platform...
[10/7/2018, 8:40:37 PM] Loading 0 accessories...
[10/7/2018, 8:40:37 PM] [Global Cache Itach] Connected to 192.168.0.96:51880. Sending command: getdevices
endlistdevices40:37 PM] [Global Cache Itach] DATA: device,0,0 ETHERNET
[10/7/2018, 8:40:37 PM] [Global Cache Itach] Found 3 ir ports.
[10/7/2018, 8:40:37 PM] [Global Cache Itach] Configuring iTach accessory. Name: Gate - 1, Type: ir at port: 0
/usr/lib/node_modules/homebridge-globalcache-itach/index.js:172
for (var i = 0; i < Object.keys(this.commands).length; i++) {
^
TypeError: Cannot convert undefined or null to object
at Function.keys (<anonymous>)
at new ItachAccessory (/usr/lib/node_modules/homebridge-globalcache-itach/index.js:172:36)
at ItachPlatform.<anonymous> (/usr/lib/node_modules/homebridge-globalcache-itach/index.js:94:46)
at Socket.<anonymous> (/usr/lib/node_modules/homebridge-globalcache-itach/index.js:314:9)
at Socket.emit (events.js:182:13)
at addChunk (_stream_readable.js:283:12)
at readableAddChunk (_stream_readable.js:264:11)
at Socket.Readable.push (_stream_readable.js:219:10)
at TCP.onStreamRead [as onread] (internal/stream_base_commons.js:94:17)
This seems to be similar to the issue raised in #7 . I haven't been able to find a solution, including changing itach settings in the web gui for the IP2IR.
Any thoughts appreciated! Thanks again.
Thanks for this! I'm using it to control my NAD C 356 BEE amp using an IP2IR.
It does work, but I'm getting lots of errors in my homebridge log:
[4/23/2022, 10:14:09 AM] [homebridge-globalcache-itach] Characteristic 'On': SET handler returned write response value, though the characteristic doesn't support write response. See https://git.io/JtMGR for more info.
[4/23/2022, 10:14:09 AM] [homebridge-globalcache-itach] Error:
at On.Characteristic.characteristicWarning (/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:2142:105)
at /usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:1756:22
at /usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/src/lib/util/once.ts:10:18
at ItachAccessory. (/usr/local/lib/node_modules/homebridge-globalcache-itach/index.js:216:9)
at /usr/local/lib/node_modules/homebridge-globalcache-itach/index.js:227:13
at ItachAccessory. (/usr/local/lib/node_modules/homebridge-globalcache-itach/index.js:264:21)
at Socket. (/usr/local/lib/node_modules/homebridge-globalcache-itach/index.js:340:9)
at Socket.emit (node:events:526:28)
at addChunk (node:internal/streams/readable:315:12)
at readableAddChunk (node:internal/streams/readable:289:9)
Here's my JSON if that helps:
{
"platform": "GlobalCacheItach",
"name": "Global Cache Itach",
"devices": [
{
"name": "IP2IR",
"host": "10.0.1.6",
"enableLearnLogging": true,
"ports": [
{
"name": "NAD",
"port": "1",
"commands": {
"PowerOn": "1,38000,1,69,343,171,21,64,21,64,21,64,21,22,21,21,22,21,22,21,21,64,21,21,22,21,22,63,22,63,22,63,22,63,22,63,22,21,21,64,21,21,22,63,22,21,22,21,21,64,21,21,22,21,22,21,22,63,22,21,21,64,21,64,21,21,22,63,22,63,22,1488,342,85,22,1488",
"PowerOff": "1,38000,1,69,343,172,21,64,21,64,21,64,21,21,22,21,22,21,21,22,21,65,21,21,22,21,22,63,22,63,22,63,22,63,22,63,22,22,21,21,22,21,22,21,21,64,21,21,22,21,22,63,22,63,22,63,22,63,22,63,22,21,21,64,21,64,21,21,22,21,22,1487,342,85,22,1487",
"DSC": "1,38000,1,69,342,172,22,64,22,64,22,63,22,21,22,21,21,21,22,21,22,63,22,21,21,21,22,64,22,64,22,63,22,64,22,64,22,21,22,63,22,21,22,21,21,65,21,21,22,21,22,22,21,65,21,22,22,64,22,64,22,21,22,64,22,63,22,63,22,21,21,1490,343,85,22,1490",
"AUX": "1,38000,1,69,343,171,21,64,21,64,21,64,21,21,22,21,22,21,22,21,21,64,21,21,22,21,22,63,22,63,22,63,22,63,22,63,22,21,21,64,21,64,21,21,22,63,22,63,22,21,22,21,21,64,21,21,22,21,22,64,22,21,21,22,21,63,22,63,22,21,22,1489,342,86,22,1489",
"VolUp": "1,38000,1,69,343,171,22,63,22,63,22,63,22,21,21,21,22,21,22,21,21,64,21,22,21,21,22,63,22,63,22,63,22,63,22,63,22,21,22,21,21,21,22,21,22,63,22,21,21,21,22,21,22,63,22,63,22,63,22,63,22,21,21,64,21,64,21,64,21,21,22,1488,342,85,21,3656",
"VolDown": "1,38000,1,69,343,171,22,63,22,63,22,63,22,21,21,21,22,21,22,21,21,64,21,21,22,21,22,63,22,63,22,63,22,63,22,63,22,21,21,21,22,21,22,63,22,63,22,21,21,22,21,21,22,63,22,63,22,63,22,21,22,21,21,64,21,64,21,64,21,21,22,1488,342,85,21,3655"
}
},
{
"disable": true
},
{
"disable": true
}
]
}
]
}`
I am interested in using you plugin. Do you have an example config.json file. I currently don't see where I specify the IR Code for the itach module. Thanks in advance.
Hi,
Module works with IOS 10 but as soon as I execute the 1st command none of my devices can update and become unavailalble in the homekit app.
I need to restart homebridge to get updates going again. On/off commands still seem to work even though everything is unavailable
Any ideas?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.