node-red-contrib-huemagic 2.8.2 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +229 -0
- package/README.md +806 -729
- package/examples/Hue Bridge.json +189 -35
- package/examples/Hue Brightness.json +124 -14
- package/examples/Hue Buttons.json +88 -0
- package/examples/Hue Group.json +575 -63
- package/examples/Hue Light.json +805 -58
- package/examples/Hue Magic.json +69 -24
- package/examples/Hue Motion.json +110 -42
- package/examples/Hue Rules.json +105 -37
- package/examples/Hue Scene.json +145 -28
- package/examples/Hue Temperature.json +124 -14
- package/huemagic/animations/001-sunny.json +22 -22
- package/huemagic/animations/002-cloudy.json +46 -46
- package/huemagic/animations/003-nightsky.json +20 -20
- package/huemagic/animations/004-sunrise.json +54 -54
- package/huemagic/animations/005-sunset.json +46 -46
- package/huemagic/animations/006-fireplace.json +74 -74
- package/huemagic/animations/007-spring.json +31 -31
- package/huemagic/animations/008-autmn.json +23 -23
- package/huemagic/animations/009-winter.json +23 -23
- package/huemagic/animations/010-dirtyfog.json +23 -23
- package/huemagic/animations/011-lgbt.json +49 -50
- package/huemagic/animations/012-rasta.json +28 -29
- package/huemagic/animations/013-strobo.json +30 -31
- package/huemagic/animations/014-randomrainbow.json +30 -31
- package/huemagic/animations/015-sos.json +158 -159
- package/huemagic/animations/016-milkyway.json +83 -0
- package/huemagic/animations/017-beach.json +40 -0
- package/huemagic/animations/018-forest.json +43 -0
- package/huemagic/animations/019-christmas.json +30 -0
- package/huemagic/animations/020-superhero.json +56 -0
- package/huemagic/animations/021-neoncity.json +52 -0
- package/huemagic/animations/previews/001-sunny.gif +0 -0
- package/huemagic/animations/previews/002-cloudy.gif +0 -0
- package/huemagic/animations/previews/003-nightsky.gif +0 -0
- package/huemagic/animations/previews/004-sunrise.gif +0 -0
- package/huemagic/animations/previews/005-sunset.gif +0 -0
- package/huemagic/animations/previews/006-fireplace.gif +0 -0
- package/huemagic/animations/previews/007-spring.gif +0 -0
- package/huemagic/animations/previews/008-autmn.gif +0 -0
- package/huemagic/animations/previews/009-winter.gif +0 -0
- package/huemagic/animations/previews/010-dirtyfog.gif +0 -0
- package/huemagic/animations/previews/011-lgbt.gif +0 -0
- package/huemagic/animations/previews/012-rasta.gif +0 -0
- package/huemagic/animations/previews/013-strobo.gif +0 -0
- package/huemagic/animations/previews/014-randomrainbow.gif +0 -0
- package/huemagic/animations/previews/015-sos.gif +0 -0
- package/huemagic/animations/previews/016-milkyway.gif +0 -0
- package/huemagic/animations/previews/017-beach.gif +0 -0
- package/huemagic/animations/previews/018-forest.gif +0 -0
- package/huemagic/animations/previews/019-christmas.gif +0 -0
- package/huemagic/animations/previews/020-superhero.gif +0 -0
- package/huemagic/animations/previews/021-neoncity.gif +0 -0
- package/huemagic/hue-bridge-config.html +105 -61
- package/huemagic/hue-bridge-config.js +629 -319
- package/huemagic/hue-bridge.html +41 -21
- package/huemagic/hue-bridge.js +191 -398
- package/huemagic/hue-brightness.html +130 -49
- package/huemagic/hue-brightness.js +131 -35
- package/huemagic/hue-buttons.html +197 -0
- package/huemagic/hue-buttons.js +152 -0
- package/huemagic/hue-group.html +137 -60
- package/huemagic/hue-group.js +394 -367
- package/huemagic/hue-light.html +133 -59
- package/huemagic/hue-light.js +551 -336
- package/huemagic/hue-magic.html +91 -237
- package/huemagic/hue-magic.js +57 -27
- package/huemagic/hue-motion.html +128 -50
- package/huemagic/hue-motion.js +116 -87
- package/huemagic/hue-rules.html +121 -50
- package/huemagic/hue-rules.js +84 -64
- package/huemagic/hue-scene.html +96 -115
- package/huemagic/hue-scene.js +65 -96
- package/huemagic/hue-temperature.html +130 -49
- package/huemagic/hue-temperature.js +136 -32
- package/huemagic/icons/hue-bridge.png +0 -0
- package/huemagic/icons/hue-bridge.svg +3 -0
- package/huemagic/icons/hue-brightness.png +0 -0
- package/huemagic/icons/hue-brightness.svg +11 -0
- package/huemagic/icons/hue-buttons.png +0 -0
- package/huemagic/icons/hue-buttons.svg +4 -0
- package/huemagic/icons/hue-group.png +0 -0
- package/huemagic/icons/hue-group.svg +12 -0
- package/huemagic/icons/hue-light.png +0 -0
- package/huemagic/icons/hue-light.svg +3 -0
- package/huemagic/icons/hue-magic.png +0 -0
- package/huemagic/icons/hue-magic.svg +3 -0
- package/huemagic/icons/hue-motion.png +0 -0
- package/huemagic/icons/hue-motion.svg +9 -0
- package/huemagic/icons/hue-rules.png +0 -0
- package/huemagic/icons/hue-rules.svg +4 -0
- package/huemagic/icons/hue-scene.png +0 -0
- package/huemagic/icons/hue-scene.svg +5 -0
- package/huemagic/icons/hue-temperature.png +0 -0
- package/huemagic/icons/hue-temperature.svg +7 -0
- package/huemagic/locales/de/hue-bridge-config.html +17 -12
- package/huemagic/locales/de/hue-bridge-config.json +7 -5
- package/huemagic/locales/de/hue-bridge.html +64 -145
- package/huemagic/locales/de/hue-bridge.json +6 -17
- package/huemagic/locales/de/hue-brightness.html +52 -38
- package/huemagic/locales/de/hue-brightness.json +7 -2
- package/huemagic/locales/de/hue-buttons.html +58 -0
- package/huemagic/locales/de/hue-buttons.json +28 -0
- package/huemagic/locales/de/hue-group.html +46 -122
- package/huemagic/locales/de/hue-group.json +4 -2
- package/huemagic/locales/de/hue-light.html +68 -116
- package/huemagic/locales/de/hue-light.json +5 -2
- package/huemagic/locales/de/hue-magic.html +65 -57
- package/huemagic/locales/de/hue-magic.json +2 -1
- package/huemagic/locales/de/hue-motion.html +48 -44
- package/huemagic/locales/de/hue-motion.json +6 -3
- package/huemagic/locales/de/hue-rules.html +68 -73
- package/huemagic/locales/de/hue-rules.json +5 -2
- package/huemagic/locales/de/hue-scene.html +23 -32
- package/huemagic/locales/de/hue-scene.json +5 -2
- package/huemagic/locales/de/hue-temperature.html +53 -36
- package/huemagic/locales/de/hue-temperature.json +7 -2
- package/huemagic/locales/en-US/hue-bridge-config.html +17 -12
- package/huemagic/locales/en-US/hue-bridge-config.json +5 -3
- package/huemagic/locales/en-US/hue-bridge.html +64 -145
- package/huemagic/locales/en-US/hue-bridge.json +5 -16
- package/huemagic/locales/en-US/hue-brightness.html +52 -38
- package/huemagic/locales/en-US/hue-brightness.json +10 -3
- package/huemagic/locales/en-US/hue-buttons.html +58 -0
- package/huemagic/locales/en-US/hue-buttons.json +34 -0
- package/huemagic/locales/en-US/hue-group.html +46 -122
- package/huemagic/locales/en-US/hue-group.json +7 -3
- package/huemagic/locales/en-US/hue-light.html +68 -116
- package/huemagic/locales/en-US/hue-light.json +8 -3
- package/huemagic/locales/en-US/hue-magic.html +65 -57
- package/huemagic/locales/en-US/hue-magic.json +3 -1
- package/huemagic/locales/en-US/hue-motion.html +48 -44
- package/huemagic/locales/en-US/hue-motion.json +9 -4
- package/huemagic/locales/en-US/hue-rules.html +68 -73
- package/huemagic/locales/en-US/hue-rules.json +5 -2
- package/huemagic/locales/en-US/hue-scene.html +23 -32
- package/huemagic/locales/en-US/hue-scene.json +5 -2
- package/huemagic/locales/en-US/hue-temperature.html +53 -36
- package/huemagic/locales/en-US/hue-temperature.json +10 -3
- package/huemagic/utils/api.js +290 -0
- package/huemagic/utils/color.js +382 -0
- package/{utils → huemagic/utils}/merge.js +9 -6
- package/huemagic/utils/messages.js +447 -0
- package/package.json +12 -12
- package/examples/Hue Switch.json +0 -40
- package/examples/Hue Tap.json +0 -40
- package/huemagic/assets/anime.js +0 -8
- package/huemagic/hue-switch.html +0 -119
- package/huemagic/hue-switch.js +0 -113
- package/huemagic/hue-tap.html +0 -119
- package/huemagic/hue-tap.js +0 -74
- package/huemagic/icons/hue-button.png +0 -0
- package/huemagic/icons/hue-switch.png +0 -0
- package/huemagic/icons/hue-tap.png +0 -0
- package/huemagic/locales/de/hue-switch.html +0 -50
- package/huemagic/locales/de/hue-switch.json +0 -31
- package/huemagic/locales/de/hue-tap.html +0 -41
- package/huemagic/locales/de/hue-tap.json +0 -23
- package/huemagic/locales/en-US/hue-switch.html +0 -50
- package/huemagic/locales/en-US/hue-switch.json +0 -31
- package/huemagic/locales/en-US/hue-tap.html +0 -41
- package/huemagic/locales/en-US/hue-tap.json +0 -23
- package/utils/messages.js +0 -571
- package/utils/rgb.js +0 -188
|
@@ -1,27 +1,34 @@
|
|
|
1
1
|
<script type="text/x-red" data-template-name="hue-temperature">
|
|
2
2
|
<div class="form-row">
|
|
3
3
|
<label for="node-input-name"><i class="fa fa-tag"></i> <span data-i18n="hue-temperature.config.name"></span></label>
|
|
4
|
-
<input type="text" id="node-input-name" data-i18n="[placeholder]hue-temperature.config.input-name">
|
|
4
|
+
<input type="text" id="node-input-name" data-i18n="[placeholder]hue-temperature.config.input-name" style="width: calc(100% - 105px)">
|
|
5
5
|
</div>
|
|
6
6
|
<div class="form-row">
|
|
7
7
|
<label for="node-input-bridge"><i class="fa fa-server"></i> Bridge</label>
|
|
8
|
-
<input type="text" id="node-input-bridge">
|
|
8
|
+
<input type="text" id="node-input-bridge" style="width: calc(100% - 105px)">
|
|
9
9
|
</div>
|
|
10
10
|
<div class="form-row">
|
|
11
11
|
<label for="node-input-sensorid"><i class="fa fa-thermometer-three-quarters"></i> <span data-i18n="hue-temperature.config.sensor"></span></label>
|
|
12
|
-
<div style="display: inline-
|
|
13
|
-
<div style="
|
|
14
|
-
<input type="text" id="node-input-sensorid" placeholder="
|
|
12
|
+
<div style="display: inline-flex; width: calc(100% - 105px)">
|
|
13
|
+
<div id="input-select-toggle" style="flex-grow: 1;">
|
|
14
|
+
<input type="text" id="node-input-sensorid" placeholder="00000000-0000-0000-0000-000000000000" style="width: 100%"/>
|
|
15
15
|
</div>
|
|
16
|
-
<
|
|
16
|
+
<button id="node-config-input-scan-temp-sensors" type="button" class="red-ui-button" style="margin-left: 10px;">
|
|
17
17
|
<i class="fa fa-search"></i>
|
|
18
|
-
</
|
|
18
|
+
</button>
|
|
19
|
+
</div>
|
|
20
|
+
</div>
|
|
21
|
+
<div class="form-row" style="margin-top: 30px">
|
|
22
|
+
<div style="display: inline-flex; width: calc(100% - 105px)">
|
|
23
|
+
<input type="checkbox" id="node-input-skipevents" style="flex: 15px;">
|
|
24
|
+
<span data-i18n="hue-temperature.config.skipevents-node" style="width: 100%; margin-left: 10px;"></span>
|
|
19
25
|
</div>
|
|
20
26
|
</div>
|
|
21
27
|
<div class="form-row">
|
|
22
|
-
<
|
|
23
|
-
|
|
24
|
-
|
|
28
|
+
<div style="display: inline-flex; width: calc(100% - 105px)">
|
|
29
|
+
<input type="checkbox" id="node-input-initevents" style="flex: 15px;">
|
|
30
|
+
<span data-i18n="hue-temperature.config.sendinitevents-node" style="width: 100%; margin-left: 10px;"></span>
|
|
31
|
+
</div>
|
|
25
32
|
</div>
|
|
26
33
|
</script>
|
|
27
34
|
|
|
@@ -30,87 +37,161 @@
|
|
|
30
37
|
category: 'HueMagic',
|
|
31
38
|
color: '#1abc9c',
|
|
32
39
|
defaults: {
|
|
33
|
-
name: {value:""},
|
|
34
|
-
bridge: {type: "hue-bridge", required: true},
|
|
35
|
-
sensorid: {value:"", required:
|
|
36
|
-
skipevents: {value: false}
|
|
40
|
+
name: { value:"" },
|
|
41
|
+
bridge: { type: "hue-bridge", required: true },
|
|
42
|
+
sensorid: { value:"", required: false },
|
|
43
|
+
skipevents: { value: false },
|
|
44
|
+
initevents: { value: false }
|
|
37
45
|
},
|
|
38
|
-
inputs:
|
|
46
|
+
inputs: 1,
|
|
39
47
|
outputs: 1,
|
|
40
|
-
|
|
41
|
-
return this._("hue-temperature.node.output");
|
|
42
|
-
},
|
|
43
|
-
align: 'right',
|
|
48
|
+
align: 'left',
|
|
44
49
|
icon: "hue-temperature.png",
|
|
50
|
+
label: function() {
|
|
51
|
+
return this.name || this._("hue-temperature.node.title");
|
|
52
|
+
},
|
|
45
53
|
paletteLabel: function() {
|
|
46
54
|
return this._("hue-temperature.node.title");
|
|
47
55
|
},
|
|
48
|
-
|
|
49
|
-
return this.
|
|
56
|
+
inputLabels: function() {
|
|
57
|
+
return this._("hue-temperature.node.input");
|
|
58
|
+
},
|
|
59
|
+
outputLabels: function() {
|
|
60
|
+
return this._("hue-temperature.node.output");
|
|
50
61
|
},
|
|
51
62
|
oneditprepare: function()
|
|
52
63
|
{
|
|
53
|
-
|
|
64
|
+
const scope = this;
|
|
65
|
+
let options = [];
|
|
54
66
|
|
|
55
|
-
function
|
|
67
|
+
function manualInput()
|
|
56
68
|
{
|
|
69
|
+
// GET CURRENT SELECTED VALUE
|
|
57
70
|
var current = $('#node-input-sensorid').val();
|
|
58
|
-
|
|
59
|
-
|
|
71
|
+
|
|
72
|
+
// REMOVE SELECT FIELD
|
|
73
|
+
$('#input-select-toggle').empty();
|
|
74
|
+
|
|
75
|
+
// CREATE NEW INPUT FIELD
|
|
76
|
+
$('#input-select-toggle').append('<input type="text" id="node-input-sensorid" placeholder="00000000-0000-0000-0000-000000000000" style="width: 100%" value="'+current+'" />');
|
|
77
|
+
|
|
78
|
+
// CHANGE BUTTON ICON
|
|
79
|
+
var button = $("#node-config-input-scan-temp-sensors");
|
|
80
|
+
var buttonIcon = button.find("i");
|
|
81
|
+
buttonIcon.removeClass("fa-pencil");
|
|
82
|
+
buttonIcon.addClass("fa-search");
|
|
60
83
|
}
|
|
61
84
|
|
|
62
|
-
function
|
|
85
|
+
function searchAndSelect()
|
|
63
86
|
{
|
|
87
|
+
// GET CURRENT BRIDGE CONFIGURATION
|
|
88
|
+
var bridgeConfig = RED.nodes.node($('#node-input-bridge option:selected').val());
|
|
89
|
+
if(!bridgeConfig) { return false; }
|
|
90
|
+
|
|
91
|
+
// GET CURRENT SELECTED VALUE
|
|
64
92
|
var current = $('#node-input-sensorid').val();
|
|
65
|
-
$('#node-input-sensorid').replaceWith('<select id="node-input-sensorid" style="width: 100%"></select>');
|
|
66
|
-
$('#node-input-sensorid').append('<option selected="selected" value="null">'+scope._("hue-temperature.config.searching")+'</option>');
|
|
67
93
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
.done( function(data) {
|
|
71
|
-
var temperatureSensors = JSON.parse(data);
|
|
94
|
+
// TRIGGER SEARCHING NOTIFICATION
|
|
95
|
+
var notification = RED.notify(scope._("hue-temperature.config.searching"), { type: "compact", modal: true, fixed: true });
|
|
72
96
|
|
|
73
|
-
|
|
97
|
+
// GET THE SENSORS
|
|
98
|
+
$.get('hue/ressources', { bridge: bridgeConfig.bridge, key: bridgeConfig.key, type: "temperature" })
|
|
99
|
+
.done( function(data) {
|
|
100
|
+
var allRessources = JSON.parse(data);
|
|
101
|
+
if(allRessources.length <= 0)
|
|
74
102
|
{
|
|
75
|
-
|
|
103
|
+
notification.close();
|
|
104
|
+
RED.notify(scope._("hue-temperature.config.none-found"), { type: "error" });
|
|
105
|
+
return false;
|
|
76
106
|
}
|
|
77
107
|
|
|
78
|
-
//
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
// SET TEMPERATURE SENSORS AS OPTIONS
|
|
82
|
-
temperatureSensors.forEach(function(sensor)
|
|
108
|
+
// SET OPTIONS
|
|
109
|
+
allRessources.forEach(function(ressource)
|
|
83
110
|
{
|
|
84
|
-
|
|
111
|
+
if(ressource.model)
|
|
112
|
+
{
|
|
113
|
+
options[ressource.id] = { value: ressource.id, label: ressource.name + " ("+ressource.model+")" };
|
|
114
|
+
}
|
|
115
|
+
else
|
|
116
|
+
{
|
|
117
|
+
options[ressource.id] = { value: ressource.id, label: ressource.name };
|
|
118
|
+
}
|
|
85
119
|
});
|
|
86
120
|
|
|
87
121
|
// SELECT CURRENT VALUE
|
|
88
|
-
$(
|
|
122
|
+
$("#node-input-sensorid").typedInput({
|
|
123
|
+
types: [
|
|
124
|
+
{
|
|
125
|
+
value: current,
|
|
126
|
+
options: Object.values(options)
|
|
127
|
+
}
|
|
128
|
+
]
|
|
129
|
+
});
|
|
130
|
+
|
|
131
|
+
// CHANGE BUTTON ICON
|
|
132
|
+
var button = $("#node-config-input-scan-temp-sensors");
|
|
133
|
+
var buttonIcon = button.find("i");
|
|
134
|
+
buttonIcon.removeClass("fa-search");
|
|
135
|
+
buttonIcon.addClass("fa-pencil");
|
|
136
|
+
|
|
137
|
+
// CLOSE SEARCH NOTIFICATION
|
|
138
|
+
notification.close();
|
|
89
139
|
})
|
|
90
140
|
.fail(function()
|
|
91
141
|
{
|
|
142
|
+
notification.close();
|
|
92
143
|
RED.notify(scope._("hue-temperature.config.unknown-error"), "error");
|
|
93
144
|
});
|
|
94
145
|
}
|
|
95
146
|
|
|
96
|
-
|
|
147
|
+
// CHANGED SENSOR ID? -> REPLACE NAME (IF POSSIBLE)
|
|
148
|
+
$(document).on('change', '#node-input-sensorid', function(e)
|
|
97
149
|
{
|
|
98
|
-
|
|
99
|
-
|
|
150
|
+
let currentSelectedOptionID = $(e.currentTarget).val();
|
|
151
|
+
let currentSelectedOptionValue = (currentSelectedOptionID.length > 0 && options[currentSelectedOptionID]) ? options[currentSelectedOptionID].label : false;
|
|
152
|
+
|
|
153
|
+
if(currentSelectedOptionValue !== false)
|
|
100
154
|
{
|
|
101
|
-
$('#node-input-name').val(
|
|
155
|
+
$('#node-input-name').val(currentSelectedOptionValue.split(" (")[0]);
|
|
102
156
|
}
|
|
103
157
|
});
|
|
104
158
|
|
|
159
|
+
// TOGGLE SELECT/INPUT FIELD
|
|
105
160
|
$('#node-config-input-scan-temp-sensors').click(function()
|
|
106
161
|
{
|
|
107
|
-
if($('#
|
|
162
|
+
if($('#input-select-toggle').find(".red-ui-typedInput-container").length > 0)
|
|
108
163
|
{
|
|
109
|
-
|
|
110
|
-
}
|
|
111
|
-
|
|
164
|
+
manualInput();
|
|
165
|
+
}
|
|
166
|
+
else
|
|
167
|
+
{
|
|
168
|
+
searchAndSelect();
|
|
112
169
|
}
|
|
113
170
|
});
|
|
171
|
+
},
|
|
172
|
+
button: {
|
|
173
|
+
enabled: function() {
|
|
174
|
+
return (this.sensorid && this.sensorid.length > 1)
|
|
175
|
+
},
|
|
176
|
+
visible: function() {
|
|
177
|
+
return (this.sensorid && this.sensorid.length > 1)
|
|
178
|
+
},
|
|
179
|
+
onclick: function()
|
|
180
|
+
{
|
|
181
|
+
const node = this;
|
|
182
|
+
if(node.bridge)
|
|
183
|
+
{
|
|
184
|
+
$.ajax({
|
|
185
|
+
url: "inject/" + node.id,
|
|
186
|
+
type: "POST",
|
|
187
|
+
data: JSON.stringify({ __user_inject_props__: "status"}),
|
|
188
|
+
contentType: "application/json; charset=utf-8",
|
|
189
|
+
success: function (resp) {
|
|
190
|
+
RED.notify(node.name + ": " + node._("hue-temperature.node.statusmsg"), { type: "success", id: "status", timeout: 2000 });
|
|
191
|
+
}
|
|
192
|
+
});
|
|
193
|
+
}
|
|
194
|
+
}
|
|
114
195
|
}
|
|
115
196
|
});
|
|
116
197
|
</script>
|
|
@@ -6,26 +6,27 @@ module.exports = function(RED)
|
|
|
6
6
|
{
|
|
7
7
|
RED.nodes.createNode(this, config);
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
let { HueTemperatureMessage } = require('../utils/messages');
|
|
12
|
-
let moment = require('moment');
|
|
9
|
+
const scope = this;
|
|
10
|
+
const bridge = RED.nodes.getNode(config.bridge);
|
|
13
11
|
|
|
14
|
-
// SAVE LAST
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
//
|
|
18
|
-
// MEMORY
|
|
19
|
-
this.temperature = -1000;
|
|
12
|
+
// SAVE LAST COMMAND
|
|
13
|
+
this.lastCommand = null;
|
|
20
14
|
|
|
21
15
|
//
|
|
22
16
|
// CHECK CONFIG
|
|
23
|
-
if(
|
|
17
|
+
if(bridge == null)
|
|
24
18
|
{
|
|
25
19
|
this.status({fill: "red", shape: "ring", text: "hue-temperature.node.not-configured"});
|
|
26
20
|
return false;
|
|
27
21
|
}
|
|
28
22
|
|
|
23
|
+
//
|
|
24
|
+
// UNIVERSAL MODE?
|
|
25
|
+
if(!config.sensorid)
|
|
26
|
+
{
|
|
27
|
+
this.status({fill: "grey", shape: "dot", text: "hue-temperature.node.universal"});
|
|
28
|
+
}
|
|
29
|
+
|
|
29
30
|
//
|
|
30
31
|
// UPDATE STATE
|
|
31
32
|
if(typeof bridge.disableupdates != 'undefined'||bridge.disableupdates == false)
|
|
@@ -34,38 +35,141 @@ module.exports = function(RED)
|
|
|
34
35
|
}
|
|
35
36
|
|
|
36
37
|
//
|
|
37
|
-
//
|
|
38
|
-
bridge.
|
|
38
|
+
// SUBSCRIBE TO UPDATES FROM THE BRIDGE
|
|
39
|
+
bridge.subscribe("temperature", config.sensorid, function(info)
|
|
39
40
|
{
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
}
|
|
45
|
-
else if(scope.temperature != sensor.state.temperature)
|
|
41
|
+
let currentState = bridge.get("temperature", info.id);
|
|
42
|
+
|
|
43
|
+
// RESSOURCE FOUND?
|
|
44
|
+
if(currentState !== false)
|
|
46
45
|
{
|
|
47
|
-
//
|
|
48
|
-
|
|
49
|
-
|
|
46
|
+
// SEND MESSAGE
|
|
47
|
+
if(!config.skipevents && (config.initevents || info.suppressMessage == false))
|
|
48
|
+
{
|
|
49
|
+
// SET LAST COMMAND
|
|
50
|
+
if(scope.lastCommand !== null)
|
|
51
|
+
{
|
|
52
|
+
currentState.command = scope.lastCommand;
|
|
53
|
+
}
|
|
50
54
|
|
|
51
|
-
|
|
52
|
-
|
|
55
|
+
// SEND STATE
|
|
56
|
+
scope.send(currentState);
|
|
53
57
|
|
|
54
|
-
|
|
55
|
-
|
|
58
|
+
// RESET LAST COMMAND
|
|
59
|
+
scope.lastCommand = null;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
// NOT IN UNIVERAL MODE? -> CHANGE UI STATES
|
|
63
|
+
if(config.sensorid)
|
|
64
|
+
{
|
|
65
|
+
if(currentState.payload.reachable == false)
|
|
66
|
+
{
|
|
67
|
+
scope.status({fill: "red", shape: "ring", text: "hue-temperature.node.not-reachable"});
|
|
68
|
+
}
|
|
69
|
+
else if(currentState.payload.active == false)
|
|
70
|
+
{
|
|
71
|
+
scope.status({fill: "red", shape: "ring", text: "hue-temperature.node.deactivated"});
|
|
72
|
+
}
|
|
73
|
+
else
|
|
74
|
+
{
|
|
75
|
+
var color = "yellow";
|
|
76
|
+
|
|
77
|
+
if(currentState.payload.celsius < 21)
|
|
78
|
+
{
|
|
79
|
+
color = "blue";
|
|
80
|
+
}
|
|
81
|
+
else if(currentState.payload.celsius < 26)
|
|
82
|
+
{
|
|
83
|
+
color = "yellow";
|
|
84
|
+
}
|
|
85
|
+
else
|
|
86
|
+
{
|
|
87
|
+
color = "red";
|
|
88
|
+
}
|
|
56
89
|
|
|
57
|
-
|
|
58
|
-
|
|
90
|
+
scope.status({fill: color, shape: "dot", text: currentState.payload.celsius+" °C / "+currentState.payload.fahrenheit+" °F"});
|
|
91
|
+
}
|
|
92
|
+
}
|
|
59
93
|
}
|
|
60
94
|
});
|
|
61
95
|
|
|
62
96
|
//
|
|
63
|
-
//
|
|
64
|
-
this.on('
|
|
97
|
+
// ON COMMAND
|
|
98
|
+
this.on('input', function(msg, send, done)
|
|
65
99
|
{
|
|
66
|
-
|
|
100
|
+
// REDEFINE SEND AND DONE IF NOT AVAILABLE
|
|
101
|
+
send = send || function() { scope.send.apply(scope,arguments); }
|
|
102
|
+
done = done || function() { scope.done.apply(scope,arguments); }
|
|
103
|
+
|
|
104
|
+
// SAVE LAST COMMAND
|
|
105
|
+
scope.lastCommand = msg;
|
|
106
|
+
|
|
107
|
+
// CREATE PATCH
|
|
108
|
+
let patchObject = {};
|
|
109
|
+
|
|
110
|
+
// DEFINE SENSOR ID & CURRENT STATE
|
|
111
|
+
const tempSensorID = (msg.topic != null) ? msg.topic : config.sensorid;
|
|
112
|
+
let currentState = bridge.get("temperature", tempSensorID);
|
|
113
|
+
|
|
114
|
+
// GET CURRENT STATE
|
|
115
|
+
if( (typeof msg.payload != 'undefined' && typeof msg.payload.status != 'undefined') || (typeof msg.__user_inject_props__ != 'undefined' && msg.__user_inject_props__ == "status") )
|
|
116
|
+
{
|
|
117
|
+
// SET LAST COMMAND
|
|
118
|
+
if(scope.lastCommand !== null)
|
|
119
|
+
{
|
|
120
|
+
currentState.command = scope.lastCommand;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
// SEND STATE
|
|
124
|
+
scope.send(currentState);
|
|
125
|
+
|
|
126
|
+
// RESET LAST COMMAND
|
|
127
|
+
scope.lastCommand = null;
|
|
128
|
+
|
|
129
|
+
if(done) { done(); }
|
|
130
|
+
return true;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
// TURN ON / OFF
|
|
134
|
+
if((msg.payload === true || msg.payload === false) && (msg.payload !== currentState.payload.active))
|
|
135
|
+
{
|
|
136
|
+
// PREPARE PATCH
|
|
137
|
+
patchObject.enabled = msg.payload;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
//
|
|
141
|
+
// SHOULD PATCH?
|
|
142
|
+
if(Object.values(patchObject).length > 0)
|
|
143
|
+
{
|
|
144
|
+
// CHANGE NODE UI STATE
|
|
145
|
+
if(config.sensorid)
|
|
146
|
+
{
|
|
147
|
+
scope.status({fill: "grey", shape: "ring", text: "hue-temperature.node.command"});
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
// PATCH!
|
|
151
|
+
bridge.patch("temperature", tempSensorID, patchObject)
|
|
152
|
+
.then(function() { if(done) { done(); }})
|
|
153
|
+
.catch(function(errors) { scope.error(errors); });
|
|
154
|
+
}
|
|
155
|
+
else
|
|
156
|
+
{
|
|
157
|
+
// SET LAST COMMAND
|
|
158
|
+
if(scope.lastCommand !== null)
|
|
159
|
+
{
|
|
160
|
+
currentState.command = scope.lastCommand;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
// SEND STATE
|
|
164
|
+
scope.send(currentState);
|
|
165
|
+
|
|
166
|
+
// RESET LAST COMMAND
|
|
167
|
+
scope.lastCommand = null;
|
|
168
|
+
|
|
169
|
+
if(done) { done(); }
|
|
170
|
+
}
|
|
67
171
|
});
|
|
68
172
|
}
|
|
69
173
|
|
|
70
174
|
RED.nodes.registerType("hue-temperature", HueTemperature);
|
|
71
|
-
}
|
|
175
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M2 21.7222C2 16.3528 6.35279 12 11.7222 12H27.2778C32.6472 12 37 16.3528 37 21.7222V37.2778C37 42.6472 32.6472 47 27.2778 47H11.7222C6.35279 47 2 42.6472 2 37.2778V21.7222ZM19.5 37.2778C23.7955 37.2778 27.2778 33.7955 27.2778 29.5C27.2778 25.2045 23.7955 21.7222 19.5 21.7222C15.2045 21.7222 11.7222 25.2045 11.7222 29.5C11.7222 33.7955 15.2045 37.2778 19.5 37.2778ZM19.5 39.2222C24.8694 39.2222 29.2222 34.8694 29.2222 29.5C29.2222 24.1306 24.8694 19.7778 19.5 19.7778C14.1306 19.7778 9.77778 24.1306 9.77778 29.5C9.77778 34.8694 14.1306 39.2222 19.5 39.2222ZM14.1528 16.8611C14.9582 16.8611 15.6111 16.2082 15.6111 15.4028C15.6111 14.5974 14.9582 13.9444 14.1528 13.9444C13.3474 13.9444 12.6944 14.5974 12.6944 15.4028C12.6944 16.2082 13.3474 16.8611 14.1528 16.8611ZM20.8611 15.4028C20.8611 16.2082 20.2082 16.8611 19.4028 16.8611C18.5974 16.8611 17.9444 16.2082 17.9444 15.4028C17.9444 14.5974 18.5974 13.9444 19.4028 13.9444C20.2082 13.9444 20.8611 14.5974 20.8611 15.4028ZM24.8472 16.8611C25.6526 16.8611 26.3056 16.2082 26.3056 15.4028C26.3056 14.5974 25.6526 13.9444 24.8472 13.9444C24.0418 13.9444 23.3889 14.5974 23.3889 15.4028C23.3889 16.2082 24.0418 16.8611 24.8472 16.8611Z" fill="white"/>
|
|
3
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M19.5363 21.5125C15.1069 21.5125 11.5125 25.1068 11.5125 29.5363C11.5125 33.9658 15.1069 37.5965 19.5363 37.5965C24.0021 37.5965 27.5965 33.9658 27.5965 29.5363C27.5965 25.1068 23.9658 21.5125 19.5363 21.5125ZM25.6359 29.5726C25.6359 32.6587 23.167 35.3091 20.0809 35.5996V23.5093C23.167 23.7998 25.6359 26.4502 25.6359 29.5726Z" fill="white"/>
|
|
3
|
+
<path d="M20.5166 40.2468H18.556V46.9999H20.5166V40.2468Z" fill="white"/>
|
|
4
|
+
<path d="M20.5166 12H18.556V18.7531H20.5166V12Z" fill="white"/>
|
|
5
|
+
<path d="M8.75311 28.5562H2V30.5167H8.75311V28.5562Z" fill="white"/>
|
|
6
|
+
<path d="M37 28.5562H30.2469V30.5167H37V28.5562Z" fill="white"/>
|
|
7
|
+
<path d="M12.57 37.7817L11.1837 36.3954L6.40857 41.1705L7.7949 42.5568L12.57 37.7817Z" fill="white"/>
|
|
8
|
+
<path d="M26.4501 21.2405L27.8366 22.6266L32.6111 17.8508L31.2246 16.4647L26.4501 21.2405Z" fill="white"/>
|
|
9
|
+
<path d="M6.46442 17.8216L11.2396 22.5967L12.6259 21.2104L7.85075 16.4352L6.46442 17.8216Z" fill="white"/>
|
|
10
|
+
<path d="M32.6072 41.1853L27.8321 36.4102L26.4457 37.7965L31.2209 42.5716L32.6072 41.1853Z" fill="white"/>
|
|
11
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M4 13C3.44772 13 3 13.4477 3 14V46C3 46.5523 3.44772 47 4 47H36C36.5523 47 37 46.5523 37 46V14C37 13.4477 36.5523 13 36 13H4ZM20 38.5C24.6944 38.5 28.5 34.6944 28.5 30C28.5 25.3056 24.6944 21.5 20 21.5C15.3056 21.5 11.5 25.3056 11.5 30C11.5 34.6944 15.3056 38.5 20 38.5Z" fill="white"/>
|
|
3
|
+
<circle cx="20" cy="30" r="5.1" fill="white"/>
|
|
4
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<g clip-path="url(#clip0_34_10)">
|
|
3
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M26.052 47.0449L30.3639 46.698C30.3639 47.9254 29.3978 48.9998 28.2075 49.0956C27.0197 49.1921 26.052 48.2708 26.052 47.0449ZM23.8586 45.7562V44.816C23.8586 44.4786 24.1367 44.1795 24.4815 44.1521L31.7769 43.5321C32.12 43.5023 32.4005 43.7534 32.4005 44.0916V45.0311C32.4005 45.3677 32.12 45.6675 31.7769 45.695L24.4815 46.3142C24.1367 46.344 23.8586 46.0937 23.8586 45.7562ZM23.8562 42.4263V40.8982C23.8562 40.56 24.1367 40.2618 24.4807 40.2335L31.936 40.1896C32.2808 40.1613 32.5589 40.4117 32.5589 40.7483V41.6901C32.5589 42.0268 32.2808 42.3242 31.936 42.3533L24.4807 42.9858C24.1367 43.0149 23.8562 42.7645 23.8562 42.4263ZM22.424 36.9758L22.3935 36.8784C22.3886 36.7215 22.383 36.5637 22.3758 36.4068L22.3476 36.3095C22.3348 35.8927 22.3155 35.4768 22.289 35.0624C21.9466 31.0583 20.8688 27.095 19.2566 23.1089H37.1529C35.5407 27.095 34.4629 31.0583 34.1213 35.0624C34.0948 35.4768 34.0755 35.8927 34.0626 36.3095L34.0345 36.4068C34.0273 36.5637 34.0216 36.7215 34.0168 36.8784L33.9863 36.9758C33.6391 38.295 32.5251 39.2031 31.2576 39.2031C31.2223 39.2031 31.1733 39.2031 31.1355 39.2007H25.2748C25.237 39.2031 25.188 39.2031 25.1526 39.2031C23.8852 39.2031 22.7712 38.295 22.424 36.9758ZM16.7248 17.6137C16.507 17.1907 16.3857 16.6923 16.4146 16.2191L16.413 16.2152C16.3133 13.5131 18.9399 11.7096 22.8243 10.7223C24.2259 10.3613 26.1814 10.136 28.1489 10.1282H28.2606C30.2281 10.136 32.1835 10.3613 33.586 10.7223C37.4704 11.7096 40.0969 13.5131 39.9973 16.2152L39.9957 16.2191C40.0246 16.6923 39.9032 17.1907 39.6854 17.6137C39.1011 18.754 38.5522 19.8897 38.0442 21.0221H18.3652C17.8573 19.8897 17.3083 18.754 16.7248 17.6137Z" fill="white"/>
|
|
4
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.44929 23.4584L7.88634 23.2849C7.88634 23.8986 7.34033 24.4358 6.66759 24.4837C5.99621 24.532 5.44929 24.0713 5.44929 23.4584ZM4.20964 22.814V22.3439C4.20964 22.1752 4.36682 22.0257 4.56169 22.0119L8.68491 21.7019C8.87887 21.687 9.0374 21.8126 9.0374 21.9817V22.4514C9.0374 22.6198 8.87887 22.7697 8.68491 22.7834L4.56169 23.093C4.36682 23.1079 4.20964 22.9828 4.20964 22.814ZM4.20828 21.1491V20.385C4.20828 20.2159 4.36682 20.0668 4.56123 20.0527L8.77485 20.0307C8.96972 20.0166 9.12689 20.1417 9.12689 20.3101V20.781C9.12689 20.9493 8.96972 21.098 8.77485 21.1126L4.56123 21.4288C4.36682 21.4434 4.20828 21.3182 4.20828 21.1491ZM3.39881 18.4238L3.38155 18.3751C3.37882 18.2967 3.37564 18.2178 3.37155 18.1393L3.35566 18.0906C3.34839 17.8823 3.33749 17.6743 3.3225 17.4671C3.12899 15.4651 2.51984 13.4834 1.60861 11.4904H11.7234C10.8122 13.4834 10.203 15.4651 10.01 17.4671C9.99496 17.6743 9.98406 17.8823 9.97679 18.0906L9.96089 18.1393C9.9568 18.2178 9.95362 18.2967 9.9509 18.3751L9.93364 18.4238C9.7374 19.0834 9.10781 19.5374 8.39146 19.5374C8.37147 19.5374 8.34377 19.5374 8.32242 19.5363H5.01003C4.98868 19.5374 4.96097 19.5374 4.94099 19.5374C4.22463 19.5374 3.59504 19.0834 3.39881 18.4238ZM0.177729 8.74276C0.0546275 8.53126 -0.013964 8.28208 0.002389 8.04546C-0.0539379 6.69441 1.42964 5.7907 3.62503 5.29705C4.41724 5.11655 5.52243 5.00393 6.63443 5H6.69757C7.80957 5.00393 8.91476 5.11655 9.70742 5.29705C11.9028 5.7907 13.3873 6.69245 13.331 8.0435C13.3473 8.28012 13.2778 8.53126 13.1547 8.74276C12.8245 9.31293 12.5142 9.88074 12.2271 10.447H1.10485C0.817766 9.88074 0.507514 9.31293 0.177729 8.74276Z" fill="white" fill-opacity="0.8"/>
|
|
5
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M10.5779 54.1192L13.0151 53.9275C13.0151 54.6058 12.469 55.1996 11.7962 55.2525C11.1248 55.3059 10.5779 54.7967 10.5779 54.1192ZM9.33815 53.4071V52.8875C9.33815 52.701 9.49533 52.5357 9.69022 52.5206L13.8137 52.1779C14.0076 52.1615 14.1662 52.3002 14.1662 52.4872V53.0063C14.1662 53.1924 14.0076 53.3581 13.8137 53.3732L9.69022 53.7154C9.49533 53.7319 9.33815 53.5936 9.33815 53.4071ZM9.33679 51.5668V50.7224C9.33679 50.5355 9.49533 50.3707 9.68976 50.355L13.9036 50.3308C14.0985 50.3151 14.2557 50.4535 14.2557 50.6396V51.16C14.2557 51.3461 14.0985 51.5105 13.9036 51.5265L9.68976 51.8761C9.49533 51.8921 9.33679 51.7538 9.33679 51.5668ZM8.52727 48.5547L8.51001 48.5009C8.50729 48.4142 8.50411 48.327 8.50002 48.2403L8.48412 48.1865C8.47685 47.9562 8.46595 47.7263 8.45096 47.4973C8.25743 45.2845 7.64825 43.0943 6.73698 40.8915H16.8523C15.941 43.0943 15.3319 45.2845 15.1388 47.4973C15.1238 47.7263 15.1129 47.9562 15.1056 48.1865L15.0897 48.2403C15.0856 48.327 15.0825 48.4142 15.0797 48.5009L15.0625 48.5547C14.8662 49.2838 14.2366 49.7856 13.5202 49.7856C13.5002 49.7856 13.4725 49.7856 13.4512 49.7843H10.1386C10.1172 49.7856 10.0895 49.7856 10.0695 49.7856C9.35315 49.7856 8.72352 49.2838 8.52727 48.5547ZM5.30601 37.8546C5.1829 37.6209 5.11431 37.3454 5.13066 37.0839L5.12975 37.0817C5.07342 35.5885 6.55799 34.5918 8.7535 34.0462C9.54576 33.8467 10.651 33.7222 11.7631 33.7179H11.8262C12.9383 33.7222 14.0435 33.8467 14.8362 34.0462C17.0317 34.5918 18.5163 35.5885 18.46 37.0817L18.4591 37.0839C18.4754 37.3454 18.4068 37.6209 18.2837 37.8546C17.9535 38.4848 17.6432 39.1124 17.3561 39.7382H6.23319C5.94609 39.1124 5.63582 38.4848 5.30601 37.8546Z" fill="white" fill-opacity="0.6"/>
|
|
6
|
+
</g>
|
|
7
|
+
<defs>
|
|
8
|
+
<clipPath id="clip0_34_10">
|
|
9
|
+
<rect width="40" height="60" fill="white"/>
|
|
10
|
+
</clipPath>
|
|
11
|
+
</defs>
|
|
12
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M17.0792 53.2547L22.9284 52.7918C22.9284 54.4295 21.6179 55.863 20.0033 55.9907C18.3919 56.1195 17.0792 54.8902 17.0792 53.2547ZM14.1039 51.5353V50.2809C14.1039 49.8306 14.4811 49.4317 14.9488 49.395L24.8451 48.5678C25.3107 48.528 25.6912 48.8631 25.6912 49.3144V50.5678C25.6912 51.017 25.3107 51.417 24.8451 51.4536L14.9488 52.2798C14.4811 52.3196 14.1039 51.9856 14.1039 51.5353ZM14.1006 47.0925V45.0537C14.1006 44.6024 14.4811 44.2045 14.9477 44.1669L25.061 44.1082C25.5287 44.0705 25.9059 44.4045 25.9059 44.8538V46.1103C25.9059 46.5595 25.5287 46.9563 25.061 46.9951L14.9477 47.839C14.4811 47.8778 14.1006 47.5438 14.1006 47.0925ZM12.1578 39.8203L12.1163 39.6905C12.1098 39.4811 12.1022 39.2706 12.0924 39.0612L12.0542 38.9313C12.0367 38.3753 12.0106 37.8204 11.9746 37.2675C11.5102 31.9252 10.0481 26.6373 7.86106 21.3191H32.1379C29.9508 26.6373 28.4888 31.9252 28.0254 37.2675C27.9894 37.8204 27.9633 38.3753 27.9458 38.9313L27.9076 39.0612C27.8978 39.2706 27.8902 39.4811 27.8837 39.6905L27.8422 39.8203C27.3712 41.5805 25.8601 42.792 24.1408 42.792C24.0928 42.792 24.0263 42.792 23.9751 42.7889H16.0249C15.9737 42.792 15.9072 42.792 15.8592 42.792C14.1399 42.792 12.6288 41.5805 12.1578 39.8203ZM4.42674 13.9873C4.13128 13.4229 3.96665 12.758 4.0059 12.1266L4.00372 12.1213C3.86853 8.51615 7.43149 6.10991 12.7007 4.79265C14.6021 4.31099 17.2547 4.01047 19.9237 4H20.0752C22.7442 4.01047 25.3968 4.31099 27.2993 4.79265C32.5685 6.10991 36.1315 8.51615 35.9963 12.1213L35.9941 12.1266C36.0333 12.758 35.8687 13.4229 35.5733 13.9873C34.7806 15.5087 34.036 17.0239 33.347 18.5348H6.65196C5.96292 17.0239 5.21827 15.5087 4.42674 13.9873Z" fill="white"/>
|
|
3
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M22.2875 25.462C21.9625 25.1374 21.475 25.1374 21.15 25.462L1.73125 44.8606C0.75625 45.8345 0.75625 47.2955 1.73125 48.2695C2.70625 49.2435 4.16875 49.2435 5.14375 48.2695L24.5625 28.871C24.8875 28.5463 24.8875 28.0593 24.5625 27.7347C24.5625 27.7347 22.2875 25.462 22.2875 25.462ZM27.975 25.462L30.575 22.8647C31.0625 22.3777 31.0625 21.6472 30.575 21.1603L28.8688 19.4558C28.3813 18.9688 27.65 18.9688 27.1625 19.4558L24.5625 22.0531C24.2375 22.3777 24.2375 22.8647 24.5625 23.1894L26.8375 25.462C27.1625 25.7867 27.65 25.7867 27.975 25.462ZM7.825 17.8325C10.9125 18.8065 13.35 21.1602 14.325 24.3257C14.4875 24.8127 15.1375 24.8127 15.3 24.3257C16.275 21.2414 18.6312 18.8065 21.8 17.8325C22.2875 17.6701 22.2875 17.0208 21.8 16.8585C18.7125 15.8845 16.275 13.5307 15.3 10.3652C15.1375 9.87825 14.4875 9.87825 14.325 10.3652C13.35 13.4495 10.9938 15.8845 7.825 16.8585C7.41875 17.0208 7.41875 17.6701 7.825 17.8325ZM39.675 33.1727C36.9125 32.2799 34.8 30.1696 33.9063 27.41C33.7438 27.0042 33.175 27.0042 33.0125 27.41C32.1188 30.1696 30.0063 32.2799 27.2438 33.1727C26.8375 33.3351 26.8375 33.9032 27.2438 34.0656C30.0063 34.9584 32.1188 37.0687 33.0125 39.8283C33.175 40.2341 33.7438 40.2341 33.9063 39.8283C34.8 37.0687 36.9125 34.9584 39.675 34.0656C40.0813 33.9032 40.0813 33.2539 39.675 33.1727ZM30.4938 15.2352C32.6063 15.8845 34.15 17.4266 34.8 19.5369C34.8813 19.8616 35.3688 19.8616 35.45 19.5369C36.1 17.4266 37.6438 15.8845 39.7563 15.2352C40.0813 15.154 40.0813 14.667 39.7563 14.5858C37.6438 13.9365 36.1 12.3944 35.45 10.2841C35.3688 9.95942 34.8813 9.95942 34.8 10.2841C34.15 12.3944 32.6063 13.9365 30.4938 14.5858C30.1688 14.667 30.1688 15.154 30.4938 15.2352Z" fill="white"/>
|
|
3
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M26.1239 29.5001C26.1239 32.7311 23.5047 35.35 20.274 35.35C17.0431 35.35 14.4242 32.7311 14.4242 29.5001C14.4242 26.2695 17.0431 23.6503 20.274 23.6503C23.5047 23.6503 26.1239 26.2695 26.1239 29.5001Z" fill="white"/>
|
|
3
|
+
<path d="M20.2741 42.1499C16.9168 42.1583 13.6953 40.8264 11.3243 38.4502C11.0226 38.1144 10.9148 37.647 11.0397 37.2132C11.1642 36.779 11.5032 36.44 11.9371 36.3154C12.3713 36.1906 12.8386 36.2983 13.1744 36.6C15.0518 38.4931 17.6079 39.5583 20.2743 39.5583C22.9406 39.5583 25.4963 38.4931 27.3741 36.6C27.71 36.2983 28.1773 36.1906 28.6111 36.3154C29.045 36.4399 29.3844 36.7789 29.5089 37.2132C29.6334 37.6471 29.526 38.1144 29.2239 38.4502C26.8527 40.8263 23.6311 42.1583 20.2741 42.1499H20.2741Z" fill="white"/>
|
|
4
|
+
<path d="M12.2742 22.8004C11.9321 22.7959 11.607 22.6515 11.3744 22.4004C11.1341 22.1524 10.9999 21.8207 10.9999 21.4755C10.9999 21.1302 11.1341 20.7985 11.3744 20.5506C13.7425 18.1856 16.9522 16.8572 20.2993 16.8572C23.646 16.8572 26.8558 18.1856 29.2238 20.5506C29.5259 20.8864 29.6333 21.3538 29.5088 21.7876C29.3843 22.2215 29.0449 22.5608 28.611 22.6854C28.1771 22.8099 27.7098 22.7024 27.374 22.4004C25.4858 20.5269 22.9339 19.4757 20.2742 19.4757C17.6141 19.4757 15.0622 20.5268 13.1743 22.4004C12.9494 22.662 12.6191 22.8088 12.2742 22.8004L12.2742 22.8004Z" fill="white"/>
|
|
5
|
+
<path d="M20.274 47.2498C17.9422 47.2564 15.6324 46.8002 13.478 45.9077C11.3237 45.0149 9.36822 43.7039 7.72415 42.0501C7.45699 41.8098 7.30005 41.4701 7.29063 41.1105C7.28087 40.7513 7.41967 40.4036 7.67393 40.1493C7.92783 39.8954 8.27555 39.7566 8.6348 39.7664C8.99437 39.7758 9.33407 39.9327 9.57433 40.1999C11.4486 42.0849 13.7877 43.4413 16.355 44.1318C18.9219 44.822 21.6258 44.822 24.1931 44.1318C26.76 43.4413 29.0992 42.0849 30.9738 40.1999C31.2141 39.9327 31.5538 39.7758 31.913 39.7664C32.2726 39.7566 32.62 39.8954 32.8743 40.1493C33.1285 40.4036 33.267 40.7513 33.2575 41.1105C33.2481 41.4701 33.0912 41.8098 32.8237 42.0501C31.18 43.7039 29.2241 45.0149 27.0701 45.9077C24.9158 46.8002 22.606 47.2564 20.2741 47.2498H20.274Z" fill="white"/>
|
|
6
|
+
<path d="M31.8738 19.2004C31.5316 19.1959 31.2066 19.0515 30.974 18.8004C28.1242 15.9664 24.2683 14.3756 20.2492 14.3756C16.2301 14.3756 12.3745 15.9663 9.52447 18.8004C9.28417 19.0679 8.94447 19.2249 8.5852 19.2343C8.22593 19.2437 7.87825 19.1052 7.62397 18.851C7.36969 18.5967 7.23127 18.2494 7.24068 17.8897C7.25044 17.5305 7.40739 17.1908 7.67454 16.9505C11.0101 13.6358 15.5218 11.7755 20.2243 11.7755C24.927 11.7755 29.4383 13.6358 32.774 16.9505C33.0139 17.1985 33.1482 17.5301 33.1482 17.8754C33.1482 18.2206 33.0139 18.5523 32.774 18.8003C32.5473 19.0597 32.218 19.2059 31.8738 19.2003L31.8738 19.2004Z" fill="white"/>
|
|
7
|
+
<path d="M20.274 51.9997C17.3189 52.0053 14.3925 51.4246 11.6634 50.2918C8.93439 49.1589 6.45677 47.4964 4.37423 45.4C4.07255 45.0641 3.96478 44.5968 4.08929 44.163C4.21414 43.7288 4.55314 43.3898 4.98703 43.2652C5.42125 43.1404 5.88862 43.2481 6.22442 43.5502C8.06411 45.4042 10.253 46.8756 12.6644 47.8794C15.0757 48.8834 17.6618 49.4003 20.274 49.3999C22.8876 49.4115 25.4772 48.9002 27.8904 47.8953C30.3031 46.8905 32.4905 45.4132 34.3237 43.5501C34.6596 43.248 35.1269 43.1403 35.5607 43.2651C35.9946 43.3896 36.3339 43.7286 36.4585 44.1629C36.583 44.5968 36.4756 45.0641 36.1735 45.3999C34.098 47.5054 31.6218 49.1742 28.8914 50.3077C26.1605 51.4412 23.2306 52.0164 20.2741 51.9996L20.274 51.9997Z" fill="white"/>
|
|
8
|
+
<path d="M5.27438 15.8505C4.93225 15.846 4.60684 15.7016 4.37422 15.4505C4.13427 15.2025 4 14.8709 4 14.5256C4 14.1803 4.13427 13.8487 4.37422 13.6007C7.16229 10.804 10.6384 8.79199 14.4526 7.768C18.2668 6.744 22.2827 6.744 26.0961 7.768C29.9095 8.79199 33.3859 10.804 36.1735 13.6007C36.4755 13.9366 36.583 14.4039 36.4584 14.8377C36.3339 15.2716 35.9946 15.611 35.5607 15.7355C35.1268 15.86 34.6595 15.7526 34.3237 15.4506C32.4836 13.5965 30.2951 12.1251 27.8837 11.121C25.4724 10.1173 22.8859 9.60042 20.2741 9.60078C17.6605 9.58892 15.0705 10.1006 12.6577 11.1054C10.2447 12.1098 8.05721 13.5876 6.2244 15.4506C5.96666 15.6948 5.62905 15.8367 5.27433 15.8507L5.27438 15.8505Z" fill="white"/>
|
|
9
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M27.0595 25.71L21.1022 30.9227L21.1022 20.9999L29.4285 20.9999L29.4285 4L10 4L10 20.9999L18.3267 20.9999L18.3267 30.923L12.3689 25.71L10.4067 27.427L19.7142 35.5713L29.0219 27.427L27.0595 25.71Z" fill="white"/>
|
|
3
|
+
<path d="M29.4285 35.5715L10 35.5715L10 55L29.4285 55L29.4285 35.5715Z" fill="white"/>
|
|
4
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<rect x="3" y="11" width="15.2105" height="38" fill="white"/>
|
|
3
|
+
<rect x="18.2105" y="11" width="18.7895" height="38" fill="white" fill-opacity="0.5"/>
|
|
4
|
+
<rect x="11.9474" y="11" width="16.1053" height="38" fill="white" fill-opacity="0.5"/>
|
|
5
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<svg width="40" height="60" viewBox="0 0 40 60" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M14.9583 54.7837C22.0765 56.1648 28.2385 50.7465 28.2385 43.8407C28.2385 40.2285 26.4324 36.935 23.6701 34.9164V10.587C23.6701 6.97478 20.8016 4 17.0831 4C13.4709 4 10.4961 6.97478 10.4961 10.587V34.9164C7.2026 37.36 5.29024 41.5034 6.24642 46.1781C7.09636 50.4277 10.6023 53.9337 14.9583 54.7837ZM11.8772 36.935L12.8334 36.1913V10.6932C12.8334 8.35592 14.7458 6.54981 16.9769 6.54981C19.3142 6.54981 21.2265 8.46216 21.2265 10.6932V36.1913L22.1827 36.935C24.4138 38.5286 25.6887 41.1847 25.6887 43.947C25.6887 46.2843 24.7325 48.5154 23.1389 50.109C21.439 51.7026 19.3142 52.6588 16.9769 52.6588C12.6209 52.6588 9.2212 49.5778 8.4775 45.7531C7.94629 42.2471 9.2212 38.8474 11.8772 36.935Z" fill="white"/>
|
|
3
|
+
<path d="M17.0831 50.109C18.783 50.109 20.3766 49.4715 21.5453 48.3029C22.7139 47.1342 23.3514 45.5406 23.3514 43.8407C23.3514 39.591 19.7391 38.2099 18.783 37.3599V19.405H15.277V37.3599C14.5333 38.2099 9.85864 39.9097 10.9211 45.1156C11.4523 47.8779 13.8958 50.109 17.0831 50.109Z" fill="white"/>
|
|
4
|
+
<path d="M32.4882 11.2246H26.4324V13.6682H32.4882C33.1257 13.6682 33.6569 13.137 33.6569 12.4995C33.7631 11.7558 33.2319 11.2246 32.4882 11.2246Z" fill="white"/>
|
|
5
|
+
<path d="M31.3196 18.8741C31.3196 18.2367 30.7883 17.7054 30.1509 17.7054H26.5387V20.149H30.1509C30.7883 20.0428 31.3196 19.5116 31.3196 18.8741Z" fill="white"/>
|
|
6
|
+
<path d="M33.7631 25.2486C33.7631 24.6112 33.2319 24.08 32.5945 24.08H26.5387V26.5235H32.5945C33.2319 26.5235 33.7631 25.8861 33.7631 25.2486Z" fill="white"/>
|
|
7
|
+
</svg>
|
|
@@ -1,18 +1,23 @@
|
|
|
1
|
-
<script type="text/
|
|
2
|
-
|
|
1
|
+
<script type="text/markdown" data-help-name="hue-bridge">
|
|
2
|
+
Stellt eine Verbindung mit einer Philips Hue Bridge her.
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
<p>Geben Sie den Namen der Hue Bridge manuell ein oder behalten Sie den Standardgerätenamen bei</p>
|
|
4
|
+
### Name
|
|
6
5
|
|
|
7
|
-
|
|
8
|
-
<p>Geben Sie die Hue Bridge-IP-Adresse manuell ein oder drücken Sie den Button, um alle lokal verfügbaren Bridges abzurufen (statische IP-Konfiguration auf der Hue Bridge empfohlen). Optional können Sie anstelle des Standardports (80) einen alternativen Port für die Bridge definieren, indem Sie diesen mit einem Doppelpunkt anfügen</p>
|
|
6
|
+
Sie können hier entweder einen alternativen, internen Namen für die Bridge vergeben oder den Standardnamen beibehalten.
|
|
9
7
|
|
|
10
|
-
|
|
11
|
-
<p>Geben Sie den Hue Bridge API-Schlüssel manuell ein oder drücken Sie den Button, um einen neuen Schlüssel zu erstellen</p>
|
|
8
|
+
### Bridge IP & Port
|
|
12
9
|
|
|
13
|
-
|
|
14
|
-
<p>Intervall, in dem aktive Nodes auf Änderungen abgefragt werden (mindestens 500ms / empfohlen wird ein Wert zwischen 1000ms und 5000ms)</p>
|
|
10
|
+
Geben Sie die Hue Bridge-IP-Adresse manuell ein oder drücken Sie den Button, um alle lokal verfügbaren Bridges abzurufen (statische IP-Konfiguration auf der Hue Bridge empfohlen). Optional können Sie auch einen alternativen Port für die Bridge definieren, indem Sie diesen mit einem Doppelpunkt an die IP-Adresse anfügen.
|
|
15
11
|
|
|
16
|
-
|
|
17
|
-
|
|
12
|
+
### API-Schlüssel
|
|
13
|
+
|
|
14
|
+
Geben Sie den Hue Bridge API-Schlüssel manuell ein oder drücken Sie den Button, um einen neuen Schlüssel zu erstellen. Wenn Sie einen neuen Schlüssel erstellen möchten, müssen Sie innerhalb des Zeitfensters von 20 Sekunden den physischen Button der Bridge betätigen, um den Prozess abzuschließen.
|
|
15
|
+
|
|
16
|
+
### Automatische Firmware-Updates
|
|
17
|
+
|
|
18
|
+
HueMagic prüft periodisch nach verfügbaren Philips Hue Firmware Updates und installiert sie automatisch, wenn sie verfügbar sind. Sie können dieses Verhalten deaktivieren, indem Sie die entsprechende Checkbox anklicken.
|
|
19
|
+
|
|
20
|
+
### Mitteilungen deaktivieren
|
|
21
|
+
|
|
22
|
+
Wenn Sie diese Einstellung aktivieren, erhalten alle Nodes hinter dieser Bridge keine automatischen Statusmeldungen mehr.
|
|
18
23
|
</script>
|