node-red-contrib-deconz
Advanced tools
Comparing version 0.6.0 to 0.6.1
@@ -87,14 +87,22 @@ var request = require('request'); | ||
node.sendState = function (device) { | ||
//status | ||
node.status({ | ||
fill: "green", | ||
shape: "dot", | ||
text: (node.config.state in device.state) ? device.state[node.config.state] : "connected" | ||
}); | ||
if (device.state === undefined) { | ||
console.log("CODE: #66"); | ||
console.log(device); | ||
} else { | ||
//status | ||
node.status({ | ||
fill: "green", | ||
shape: "dot", | ||
text: (node.config.state in device.state) ? device.state[node.config.state] : "connected" | ||
}); | ||
//outputs | ||
node.send([ | ||
{payload: (node.config.state in device.state) ? device.state[node.config.state] : device.state, payload_raw: device}, | ||
format_to_homekit(device) | ||
]); | ||
//outputs | ||
node.send([ | ||
{ | ||
payload: (node.config.state in device.state) ? device.state[node.config.state] : device.state, | ||
payload_raw: device | ||
}, | ||
format_to_homekit(device) | ||
]); | ||
} | ||
}; | ||
@@ -657,2 +665,5 @@ | ||
else if (state['buttonevent'] == 1001) characteristic.ProgrammableSwitchEvent = 2; | ||
else if (state['buttonevent'] == 1005) characteristic.ProgrammableSwitchEvent = 3; | ||
else if (state['buttonevent'] == 1006) characteristic.ProgrammableSwitchEvent = 4; | ||
else if (state['buttonevent'] == 1010) characteristic.ProgrammableSwitchEvent = 5; | ||
} | ||
@@ -659,0 +670,0 @@ |
@@ -34,3 +34,3 @@ { | ||
}, | ||
"version": "0.6.0" | ||
"version": "0.6.1" | ||
} |
@@ -57,3 +57,3 @@ RED.nodes.registerType('deconz-output', { | ||
icon: 'icons/node-red-contrib-deconz/icon-color.png', | ||
options: ['on', 'bri', 'hue', 'sat', 'ct', 'xy', 'alert', 'effect', 'colorloopspeed', 'transitiontime', 'json', 'homekit'] | ||
options: ['on', 'bri', 'hue', 'sat', 'ct', 'xy', 'alert', 'effect', 'colorloopspeed', 'transitiontime'] | ||
}; | ||
@@ -60,0 +60,0 @@ $('#node-input-command').typedInput({ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
777390
2468