Closed icepicknz closed 8 years ago
I think the accessory should be just "Daikin" as this is what is in homebridge.registerAccessory ?
Also I think i know why it won't find my accessory, it would appear i'm not even loading the plugin due to the below
[10/16/2016, 1:30:16 AM] ====================
[10/16/2016, 1:30:16 AM] ERROR LOADING PLUGIN homebridge-daikin:
[10/16/2016, 1:30:16 AM] SyntaxError: missing ) after argument list
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:373:25)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Plugin.load (/usr/local/lib/node_modules/homebridge/lib/plugin.js:65:22)
at Server.
Yes, apologies, Accessory should just be Daikin. I'll push that to the readme now. You can also set the name to whatever you want, I just used "Daikin Demo" as a placeholder
For the error you're getting in your log, I'm doing a little digging on my own install. I pushed a copy to NPM but didn't change the readme to show that as I was wanting to test it a little more myself before showing it to the world that it was installable, but manually loading it without having it on NPM doesn't tell me as much as installing it from NPM would
Bear with me, I'll let you know over the next 2-3 days how I go
Ok, I've got it pretty much tacked down, but it's gonna take a LOT more refactoring so I'm gonna leave it for tonight and come back to it tomorrow. New commit coming soon!
Ah, nevermind. Not so much needing refactoring as... the right braces. It should install fine now Run
npm uninstall -g homebridge-daikin
followed by
npm install -g homebridge-daikin
as administrator now and the plugin should load properly. Let me know how you do ^_^
Thanks that worked, now it loads; however when i tried doing anything with it, i get errors like this
[10/17/2016, 10:07:39 PM] [Bedroom Aircon] getCurrentTemperature from: http://192.168.44.81/aircon/get_sensor_info [10/17/2016, 10:07:39 PM] [Bedroom Aircon] response success undefined:1 {"ret":"OK,htemp":"18.0,hhum":"-,otemp":"14.0,err":"0,cmpfreq":"0"} ^
SyntaxError: Unexpected token :
at Object.parse (native)
at Object.
I'm aware of that issue, I'm working on a fix :-/ Something is going wonky when translating from commands the Daikin systems recognise, to JSON for homebridge to read. Keep an eye on Issue #8 , I'll be updating it with the results of each attempt to resolve the problem, and once it is working the way it should I'll post that there as well
I know the page says not working with NPM yet however it did install but isn't working.
Received error "Error: The requested accessory 'Daikin Air Conditioner' was not registered by any plugin."
Config as follows: "accessory": "Daikin Air Conditioner", "name": "Daikin Demo", "apiroute": "http://192.168.44.81"
Do you have any installation steps to make this work?
Many thanks