node-red-contrib-power-saver 3.3.2 → 3.4.2
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/.firebase/hosting.ZG9jcy8udnVlcHJlc3MvZGlzdA.cache +94 -0
- package/.firebaserc +5 -0
- package/.github/workflows/firebase-hosting-merge.yml +20 -0
- package/.github/workflows/firebase-hosting-pull-request.yml +17 -0
- package/README.md +1 -1
- package/docs/.vuepress/components/BestSaveVerificator.vue +3 -3
- package/docs/.vuepress/config.js +15 -1
- package/docs/.vuepress/dist/404.html +23 -5
- package/docs/.vuepress/dist/assets/css/896.styles.21a80cb6.css +1 -0
- package/docs/.vuepress/dist/assets/css/styles.1c48cbd0.css +10 -0
- package/docs/.vuepress/dist/assets/img/heat-capacitor-temperatureVsPrice.6e74905b.png +0 -0
- package/docs/.vuepress/dist/assets/img/node-ps-strategy-heat-capacitor-cascade-control.2e75ed9e.png +0 -0
- package/docs/.vuepress/dist/assets/img/node-ps-strategy-heat-capacitor-simple-flow-example.29d9bf59.png +0 -0
- package/docs/.vuepress/dist/assets/img/oven-setpoint-calculation.5bda0eec.png +0 -0
- package/docs/.vuepress/dist/assets/img/overshoot-time.b3b5d70e.png +0 -0
- package/docs/.vuepress/dist/assets/js/229.5c5378fa.js +1 -0
- package/docs/.vuepress/dist/assets/js/331.872104cd.js +1 -0
- package/docs/.vuepress/dist/assets/js/405.f4edd94d.js +2 -0
- package/docs/.vuepress/dist/assets/js/{619.8ba1b1f6.js.LICENSE.txt → 405.f4edd94d.js.LICENSE.txt} +0 -0
- package/docs/.vuepress/dist/assets/js/490.1e639e05.js +1 -0
- package/docs/.vuepress/dist/assets/js/{491.17a98f38.js → 491.bd938119.js} +1 -1
- package/docs/.vuepress/dist/assets/js/555.d8963d84.js +1 -0
- package/docs/.vuepress/dist/assets/js/{811.6a3392d5.js → 811.5f659592.js} +0 -0
- package/docs/.vuepress/dist/assets/js/app.dfdee6f9.js +1 -0
- package/docs/.vuepress/dist/assets/js/runtime~app.f6ac32d7.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-0607240a.0193a377.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-08683c60.52e94cb6.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-0aca7ba6.cac5d4b9.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-0b5e3c8c.18561f6e.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-1ad821fa.6697a349.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-1b3a0ab8.c6c4e19b.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-1e2b191e.07b8ab21.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-29504124.00be7399.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-30acb564.28af12af.js +1 -0
- package/docs/.vuepress/dist/assets/js/{v-3706649a.d7f73384.js → v-3706649a.c76d575b.js} +1 -1
- package/docs/.vuepress/dist/assets/js/v-4637f9e4.d334c29a.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-4c28314d.8cbb0f9d.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-510ed0d4.c04bc2e4.js +1 -0
- package/docs/.vuepress/dist/assets/js/{v-5954bcb2.937005d0.js → v-5954bcb2.dff3fc67.js} +1 -1
- package/docs/.vuepress/dist/assets/js/v-5db8da3a.e5e6d7a6.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-61f728ca.81968036.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-677dfaed.c159b0f4.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-7446a652.8fc2c591.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-7c87f26e.8ed52391.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-84304104.f3f07ed3.js +1 -0
- package/docs/.vuepress/dist/assets/js/{v-8daa1a0e.c63afc2b.js → v-8daa1a0e.ed84ca09.js} +1 -1
- package/docs/.vuepress/dist/assets/js/{v-b4a42144.733e4e7c.js → v-b4a42144.9a2a0c9f.js} +1 -1
- package/docs/.vuepress/dist/assets/js/v-e8c55052.b7d52fc6.js +1 -0
- package/docs/.vuepress/dist/assets/js/v-fffb8e28.d09ab959.js +1 -0
- package/docs/.vuepress/dist/changelog/index.html +23 -5
- package/docs/.vuepress/dist/contribute/index.html +23 -5
- package/docs/.vuepress/dist/examples/example-cascade-temperature-control.html +304 -0
- package/docs/.vuepress/dist/examples/example-heat-capacitor.html +247 -0
- package/docs/.vuepress/dist/examples/example-next-schedule-entity.html +27 -9
- package/docs/.vuepress/dist/examples/example-nordpool-current-state.html +24 -6
- package/docs/.vuepress/dist/examples/example-nordpool-events-state.html +24 -6
- package/docs/.vuepress/dist/examples/example-tibber-mqtt.html +24 -6
- package/docs/.vuepress/dist/examples/index.html +23 -5
- package/docs/.vuepress/dist/faq/best-save-viewer.html +23 -5
- package/docs/.vuepress/dist/faq/index.html +23 -5
- package/docs/.vuepress/dist/guide/index.html +24 -6
- package/docs/.vuepress/dist/index.html +23 -5
- package/docs/.vuepress/dist/nodes/index.html +23 -5
- package/docs/.vuepress/dist/nodes/old-power-saver-doc.html +25 -7
- package/docs/.vuepress/dist/nodes/power-saver.html +23 -5
- package/docs/.vuepress/dist/nodes/ps-elvia-add-tariff.html +23 -5
- package/docs/.vuepress/dist/nodes/ps-general-add-tariff.html +23 -5
- package/docs/.vuepress/dist/nodes/ps-receive-price.html +26 -8
- package/docs/.vuepress/dist/nodes/ps-strategy-best-save.html +32 -9
- package/docs/.vuepress/dist/nodes/ps-strategy-heat-capacitor.html +260 -0
- package/docs/.vuepress/dist/nodes/ps-strategy-lowest-price.html +30 -7
- package/docs/.vuepress/dist/nodes/strategy-input.html +24 -6
- package/docs/README.md +1 -1
- package/docs/changelog/README.md +14 -0
- package/docs/contribute/README.md +8 -0
- package/docs/examples/README.md +8 -2
- package/docs/examples/example-cascade-temperature-control.md +346 -0
- package/docs/examples/example-heat-capacitor.md +271 -0
- package/docs/images/heat-capacitor-temperatureVsPrice.png +0 -0
- package/docs/images/node-ps-strategy-heat-capacitor-cascade-control.png +0 -0
- package/docs/images/node-ps-strategy-heat-capacitor-simple-flow-example.png +0 -0
- package/docs/images/node-ps-strategy-heat-capacitor.png +0 -0
- package/docs/images/oven-setpoint-calculation.png +0 -0
- package/docs/images/overshoot-time.png +0 -0
- package/docs/images/temperature-manipulation-config.png +0 -0
- package/docs/nodes/README.md +7 -1
- package/docs/nodes/ps-strategy-heat-capacitor.md +346 -0
- package/examples/add-general-tariff.json +103 -0
- package/examples/best-save-for-water-heater.json +140 -0
- package/examples/elvia-add-tariff.json +99 -0
- package/examples/elvia-get-tariff-types.json +58 -0
- package/examples/elvia-get-tariff.json +60 -0
- package/examples/heat-capacitor-for-room-heating.json +186 -0
- package/examples/lowest-price-for-heating-cables.json +159 -0
- package/firebase.json +6 -0
- package/package.json +17 -9
- package/public/404.html +33 -0
- package/public/index.html +89 -0
- package/src/elvia/elvia-tariff.js +2 -1
- package/src/handle-input.js +6 -3
- package/src/strategy-heat-capacitor-functions.js +246 -0
- package/src/strategy-heat-capacitor.html +85 -0
- package/src/strategy-heat-capacitor.js +125 -0
- package/test/data/converted-prices.json +1 -1
- package/test/data/multiple-trades.json +53 -0
- package/test/data/tibber-decreasing-24h.json +101 -0
- package/test/data/tibber-decreasing2-24h.json +101 -0
- package/test/strategy-heat-capacitor-node.test.js +183 -0
- package/test/strategy-heat-capacitor.test.js +103 -0
- package/test/strategy-lowest-price-functions.test.js +1 -1
- package/test/utils.test.js +0 -2
- package/docs/.vuepress/dist/.nojekyll +0 -0
- package/docs/.vuepress/dist/assets/css/563.styles.99f4a8aa.css +0 -1
- package/docs/.vuepress/dist/assets/css/styles.031dcf27.css +0 -9
- package/docs/.vuepress/dist/assets/js/262.cf2c57d2.js +0 -1
- package/docs/.vuepress/dist/assets/js/293.08ea5200.js +0 -1
- package/docs/.vuepress/dist/assets/js/331.15ee3c51.js +0 -1
- package/docs/.vuepress/dist/assets/js/619.8ba1b1f6.js +0 -2
- package/docs/.vuepress/dist/assets/js/app.b705176c.js +0 -1
- package/docs/.vuepress/dist/assets/js/runtime~app.47f4f812.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-0607240a.a57c2199.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-08683c60.ccafdcab.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-0aca7ba6.25903946.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-0b5e3c8c.a6a015b4.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-1ad821fa.5978386f.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-1e2b191e.88dc5555.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-29504124.4aca27d5.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-30acb564.529a3c16.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-4637f9e4.703b1d96.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-510ed0d4.7b142a81.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-5db8da3a.3de3588d.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-61f728ca.21d432fe.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-677dfaed.44a653b9.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-7446a652.74b21d0b.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-7c87f26e.ee5be992.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-e8c55052.ab0a79ec.js +0 -1
- package/docs/.vuepress/dist/assets/js/v-fffb8e28.525be02a.js +0 -1
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id": "a621e21fe99857ef",
|
|
4
|
+
"type": "inject",
|
|
5
|
+
"z": "7b33d8ec8339db62",
|
|
6
|
+
"name": "House",
|
|
7
|
+
"props": [
|
|
8
|
+
{
|
|
9
|
+
"p": "payload"
|
|
10
|
+
}
|
|
11
|
+
],
|
|
12
|
+
"repeat": "",
|
|
13
|
+
"crontab": "",
|
|
14
|
+
"once": false,
|
|
15
|
+
"onceDelay": 0.1,
|
|
16
|
+
"topic": "",
|
|
17
|
+
"payload": "{viewer{home(id:\"12345678-abcd-4df4-ba6d-654321a987ab\"){currentSubscription{priceInfo{today{totalenergytaxstartsAt}tomorrow{totalenergytaxstartsAt}}}}}}",
|
|
18
|
+
"payloadType": "str",
|
|
19
|
+
"x": 70,
|
|
20
|
+
"y": 100,
|
|
21
|
+
"wires": [["2b55670453ea3277"]]
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"id": "2b55670453ea3277",
|
|
25
|
+
"type": "tibber-query",
|
|
26
|
+
"z": "7b33d8ec8339db62",
|
|
27
|
+
"name": "Get prices",
|
|
28
|
+
"active": true,
|
|
29
|
+
"apiEndpointRef": "0b8e6a120837e93c",
|
|
30
|
+
"x": 210,
|
|
31
|
+
"y": 100,
|
|
32
|
+
"wires": [["7eeb5593b6da21f1"]]
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"id": "7eeb5593b6da21f1",
|
|
36
|
+
"type": "ps-receive-price",
|
|
37
|
+
"z": "7b33d8ec8339db62",
|
|
38
|
+
"name": "Price Receiver",
|
|
39
|
+
"x": 380,
|
|
40
|
+
"y": 100,
|
|
41
|
+
"wires": [["5482ec46805cd9fd"]]
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"id": "c65dfd3ad3f7b10d",
|
|
45
|
+
"type": "ps-strategy-lowest-price",
|
|
46
|
+
"z": "7b33d8ec8339db62",
|
|
47
|
+
"name": "Lowest Price",
|
|
48
|
+
"fromTime": "00",
|
|
49
|
+
"toTime": "00",
|
|
50
|
+
"hoursOn": "12",
|
|
51
|
+
"doNotSplit": "false",
|
|
52
|
+
"sendCurrentValueWhenRescheduling": "true",
|
|
53
|
+
"outputIfNoSchedule": "true",
|
|
54
|
+
"outputOutsidePeriod": "false",
|
|
55
|
+
"x": 750,
|
|
56
|
+
"y": 100,
|
|
57
|
+
"wires": [[], [], ["9eb381b935ec987c"]]
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"id": "5482ec46805cd9fd",
|
|
61
|
+
"type": "ps-elvia-add-tariff",
|
|
62
|
+
"z": "7b33d8ec8339db62",
|
|
63
|
+
"name": "Add Elvia Grid Tariff",
|
|
64
|
+
"elviaConfig": "45c5580013db88b3",
|
|
65
|
+
"tariffKey": "private_tou_rush1",
|
|
66
|
+
"range": "today",
|
|
67
|
+
"x": 570,
|
|
68
|
+
"y": 100,
|
|
69
|
+
"wires": [["c65dfd3ad3f7b10d"]]
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
"id": "9eb381b935ec987c",
|
|
73
|
+
"type": "debug",
|
|
74
|
+
"z": "7b33d8ec8339db62",
|
|
75
|
+
"name": "",
|
|
76
|
+
"active": true,
|
|
77
|
+
"tosidebar": true,
|
|
78
|
+
"console": false,
|
|
79
|
+
"tostatus": false,
|
|
80
|
+
"complete": "false",
|
|
81
|
+
"statusVal": "",
|
|
82
|
+
"statusType": "auto",
|
|
83
|
+
"x": 960,
|
|
84
|
+
"y": 120,
|
|
85
|
+
"wires": []
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
"id": "0b8e6a120837e93c",
|
|
89
|
+
"type": "tibber-api-endpoint",
|
|
90
|
+
"feedUrl": "wss://api.tibber.com/v1-beta/gql/subscriptions",
|
|
91
|
+
"queryUrl": "https://api.tibber.com/v1-beta/gql",
|
|
92
|
+
"name": "Tibber prices"
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
"id": "45c5580013db88b3",
|
|
96
|
+
"type": "ps-elvia-config",
|
|
97
|
+
"name": "Elvia Config"
|
|
98
|
+
}
|
|
99
|
+
]
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id": "4168826b961c92d8",
|
|
4
|
+
"type": "ps-elvia-tariff-types",
|
|
5
|
+
"z": "7b33d8ec8339db62",
|
|
6
|
+
"name": "Elvia Tariff Types",
|
|
7
|
+
"elviaConfig": "45c5580013db88b3",
|
|
8
|
+
"x": 280,
|
|
9
|
+
"y": 320,
|
|
10
|
+
"wires": [["9c125f23de65a5b7"]]
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
"id": "9c125f23de65a5b7",
|
|
14
|
+
"type": "debug",
|
|
15
|
+
"z": "7b33d8ec8339db62",
|
|
16
|
+
"name": "",
|
|
17
|
+
"active": true,
|
|
18
|
+
"tosidebar": true,
|
|
19
|
+
"console": false,
|
|
20
|
+
"tostatus": false,
|
|
21
|
+
"complete": "false",
|
|
22
|
+
"statusVal": "",
|
|
23
|
+
"statusType": "auto",
|
|
24
|
+
"x": 470,
|
|
25
|
+
"y": 320,
|
|
26
|
+
"wires": []
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"id": "9b1a2d7f9a96214c",
|
|
30
|
+
"type": "inject",
|
|
31
|
+
"z": "7b33d8ec8339db62",
|
|
32
|
+
"name": "",
|
|
33
|
+
"props": [
|
|
34
|
+
{
|
|
35
|
+
"p": "payload"
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"p": "topic",
|
|
39
|
+
"vt": "str"
|
|
40
|
+
}
|
|
41
|
+
],
|
|
42
|
+
"repeat": "",
|
|
43
|
+
"crontab": "",
|
|
44
|
+
"once": false,
|
|
45
|
+
"onceDelay": 0.1,
|
|
46
|
+
"topic": "",
|
|
47
|
+
"payload": "",
|
|
48
|
+
"payloadType": "date",
|
|
49
|
+
"x": 110,
|
|
50
|
+
"y": 320,
|
|
51
|
+
"wires": [["4168826b961c92d8"]]
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"id": "45c5580013db88b3",
|
|
55
|
+
"type": "ps-elvia-config",
|
|
56
|
+
"name": "Elvia Config"
|
|
57
|
+
}
|
|
58
|
+
]
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id": "77f2f8de4c2153e7",
|
|
4
|
+
"type": "ps-elvia-tariff",
|
|
5
|
+
"z": "7b33d8ec8339db62",
|
|
6
|
+
"name": "Elvia Tariff",
|
|
7
|
+
"elviaConfig": "45c5580013db88b3",
|
|
8
|
+
"tariffKey": "private_tou_daynight2",
|
|
9
|
+
"range": "today",
|
|
10
|
+
"x": 290,
|
|
11
|
+
"y": 440,
|
|
12
|
+
"wires": [["cd59d4855edd052c"]]
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"id": "551da2a5de1259dc",
|
|
16
|
+
"type": "inject",
|
|
17
|
+
"z": "7b33d8ec8339db62",
|
|
18
|
+
"name": "",
|
|
19
|
+
"props": [
|
|
20
|
+
{
|
|
21
|
+
"p": "payload"
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"p": "topic",
|
|
25
|
+
"vt": "str"
|
|
26
|
+
}
|
|
27
|
+
],
|
|
28
|
+
"repeat": "",
|
|
29
|
+
"crontab": "",
|
|
30
|
+
"once": false,
|
|
31
|
+
"onceDelay": 0.1,
|
|
32
|
+
"topic": "",
|
|
33
|
+
"payload": "",
|
|
34
|
+
"payloadType": "date",
|
|
35
|
+
"x": 120,
|
|
36
|
+
"y": 440,
|
|
37
|
+
"wires": [["77f2f8de4c2153e7"]]
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"id": "cd59d4855edd052c",
|
|
41
|
+
"type": "debug",
|
|
42
|
+
"z": "7b33d8ec8339db62",
|
|
43
|
+
"name": "",
|
|
44
|
+
"active": true,
|
|
45
|
+
"tosidebar": true,
|
|
46
|
+
"console": false,
|
|
47
|
+
"tostatus": false,
|
|
48
|
+
"complete": "false",
|
|
49
|
+
"statusVal": "",
|
|
50
|
+
"statusType": "auto",
|
|
51
|
+
"x": 450,
|
|
52
|
+
"y": 440,
|
|
53
|
+
"wires": []
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"id": "45c5580013db88b3",
|
|
57
|
+
"type": "ps-elvia-config",
|
|
58
|
+
"name": "Elvia Config"
|
|
59
|
+
}
|
|
60
|
+
]
|
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id": "135c4e7649611314",
|
|
4
|
+
"type": "tab",
|
|
5
|
+
"label": "PowerSaver",
|
|
6
|
+
"disabled": false,
|
|
7
|
+
"info": "",
|
|
8
|
+
"env": []
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"id": "cf5908a52e0aee5e",
|
|
12
|
+
"type": "ps-receive-price",
|
|
13
|
+
"z": "135c4e7649611314",
|
|
14
|
+
"name": "Price Receiver",
|
|
15
|
+
"x": 400,
|
|
16
|
+
"y": 320,
|
|
17
|
+
"wires": [["b7b85590b7d28ba6"]]
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"id": "b08bc12bf8734c5a",
|
|
21
|
+
"type": "tibber-query",
|
|
22
|
+
"z": "135c4e7649611314",
|
|
23
|
+
"name": "",
|
|
24
|
+
"active": true,
|
|
25
|
+
"apiEndpointRef": "9ea07b03b88cb526",
|
|
26
|
+
"x": 230,
|
|
27
|
+
"y": 320,
|
|
28
|
+
"wires": [["cf5908a52e0aee5e"]]
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"id": "d0d4dd31efe67e85",
|
|
32
|
+
"type": "inject",
|
|
33
|
+
"z": "135c4e7649611314",
|
|
34
|
+
"name": "",
|
|
35
|
+
"props": [
|
|
36
|
+
{
|
|
37
|
+
"p": "payload"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"p": "topic",
|
|
41
|
+
"vt": "str"
|
|
42
|
+
}
|
|
43
|
+
],
|
|
44
|
+
"repeat": "60",
|
|
45
|
+
"crontab": "",
|
|
46
|
+
"once": true,
|
|
47
|
+
"onceDelay": "1",
|
|
48
|
+
"topic": "",
|
|
49
|
+
"payload": "{viewer{homes{currentSubscription{priceInfo{today{totalstartsAt}tomorrow{totalstartsAt}}}}}}",
|
|
50
|
+
"payloadType": "str",
|
|
51
|
+
"x": 90,
|
|
52
|
+
"y": 320,
|
|
53
|
+
"wires": [["b08bc12bf8734c5a"]]
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"id": "4831f393a0066565",
|
|
57
|
+
"type": "api-call-service",
|
|
58
|
+
"z": "135c4e7649611314",
|
|
59
|
+
"name": "Set temperature",
|
|
60
|
+
"server": "e2dd69fb.8f70a8",
|
|
61
|
+
"version": 3,
|
|
62
|
+
"debugenabled": false,
|
|
63
|
+
"service_domain": "climate",
|
|
64
|
+
"service": "set_temperature",
|
|
65
|
+
"entityId": "climate.my_climate",
|
|
66
|
+
"data": "{\"entity_id\":\"climate.my_climate\",\"temperature\":\"{{adj_setpoint}}\"}",
|
|
67
|
+
"dataType": "json",
|
|
68
|
+
"mergecontext": "",
|
|
69
|
+
"mustacheAltTags": false,
|
|
70
|
+
"outputProperties": [],
|
|
71
|
+
"queue": "none",
|
|
72
|
+
"x": 980,
|
|
73
|
+
"y": 320,
|
|
74
|
+
"wires": [[]]
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
"id": "027f4267d969e1b8",
|
|
78
|
+
"type": "server-state-changed",
|
|
79
|
+
"z": "135c4e7649611314",
|
|
80
|
+
"name": "Setpoint",
|
|
81
|
+
"server": "e2dd69fb.8f70a8",
|
|
82
|
+
"version": 3,
|
|
83
|
+
"exposeToHomeAssistant": false,
|
|
84
|
+
"haConfig": [
|
|
85
|
+
{
|
|
86
|
+
"property": "name",
|
|
87
|
+
"value": ""
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
"property": "icon",
|
|
91
|
+
"value": ""
|
|
92
|
+
}
|
|
93
|
+
],
|
|
94
|
+
"entityidfilter": "input_number.setpoint",
|
|
95
|
+
"entityidfiltertype": "exact",
|
|
96
|
+
"outputinitially": true,
|
|
97
|
+
"state_type": "num",
|
|
98
|
+
"haltifstate": "",
|
|
99
|
+
"halt_if_type": "str",
|
|
100
|
+
"halt_if_compare": "is",
|
|
101
|
+
"outputs": 1,
|
|
102
|
+
"output_only_on_state_change": false,
|
|
103
|
+
"for": 0,
|
|
104
|
+
"forType": "num",
|
|
105
|
+
"forUnits": "minutes",
|
|
106
|
+
"ignorePrevStateNull": false,
|
|
107
|
+
"ignorePrevStateUnknown": false,
|
|
108
|
+
"ignorePrevStateUnavailable": false,
|
|
109
|
+
"ignoreCurrentStateUnknown": true,
|
|
110
|
+
"ignoreCurrentStateUnavailable": true,
|
|
111
|
+
"outputProperties": [
|
|
112
|
+
{
|
|
113
|
+
"property": "payload.config.setpoint",
|
|
114
|
+
"propertyType": "msg",
|
|
115
|
+
"value": "",
|
|
116
|
+
"valueType": "entityState"
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"property": "data",
|
|
120
|
+
"propertyType": "msg",
|
|
121
|
+
"value": "",
|
|
122
|
+
"valueType": "eventData"
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
"property": "topic",
|
|
126
|
+
"propertyType": "msg",
|
|
127
|
+
"value": "",
|
|
128
|
+
"valueType": "triggerId"
|
|
129
|
+
}
|
|
130
|
+
],
|
|
131
|
+
"x": 420,
|
|
132
|
+
"y": 360,
|
|
133
|
+
"wires": [["b7b85590b7d28ba6"]]
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
"id": "b7b85590b7d28ba6",
|
|
137
|
+
"type": "ps-strategy-heat-capacitor",
|
|
138
|
+
"z": "135c4e7649611314",
|
|
139
|
+
"name": "Heat capacitor",
|
|
140
|
+
"timeHeat1C": "70",
|
|
141
|
+
"timeCool1C": 50,
|
|
142
|
+
"maxTempAdjustment": "1",
|
|
143
|
+
"boostTempHeat": "2",
|
|
144
|
+
"boostTempCool": "2",
|
|
145
|
+
"minSavings": 0.08,
|
|
146
|
+
"setpoint": 23,
|
|
147
|
+
"x": 600,
|
|
148
|
+
"y": 320,
|
|
149
|
+
"wires": [["2b7cbdef3203a482"], [], []]
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
"id": "2b7cbdef3203a482",
|
|
153
|
+
"type": "function",
|
|
154
|
+
"z": "135c4e7649611314",
|
|
155
|
+
"name": "Adjust setpoint",
|
|
156
|
+
"func": "//In case the climate entity can only handle integers\n//Calculate rounded setpoint for the climate entity and return the msg\nmsg.adj_setpoint=Math.round(msg.payload);\nreturn msg\n",
|
|
157
|
+
"outputs": 1,
|
|
158
|
+
"noerr": 0,
|
|
159
|
+
"initialize": "",
|
|
160
|
+
"finalize": "",
|
|
161
|
+
"libs": [],
|
|
162
|
+
"x": 800,
|
|
163
|
+
"y": 320,
|
|
164
|
+
"wires": [["4831f393a0066565"]]
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
"id": "9ea07b03b88cb526",
|
|
168
|
+
"type": "tibber-api-endpoint",
|
|
169
|
+
"feedUrl": "wss://api.tibber.com/v1-beta/gql/subscriptions",
|
|
170
|
+
"queryUrl": "https://api.tibber.com/v1-beta/gql",
|
|
171
|
+
"name": "Tibber"
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
"id": "e2dd69fb.8f70a8",
|
|
175
|
+
"type": "server",
|
|
176
|
+
"name": "Home Assistant",
|
|
177
|
+
"version": 2,
|
|
178
|
+
"addon": false,
|
|
179
|
+
"rejectUnauthorizedCerts": true,
|
|
180
|
+
"ha_boolean": "y|yes|true|on|home|open",
|
|
181
|
+
"connectionDelay": false,
|
|
182
|
+
"cacheJson": true,
|
|
183
|
+
"heartbeat": false,
|
|
184
|
+
"heartbeatInterval": 30
|
|
185
|
+
}
|
|
186
|
+
]
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id": "4f11b5ae.4cc22c",
|
|
4
|
+
"type": "inject",
|
|
5
|
+
"z": "d938c47f.3398f8",
|
|
6
|
+
"name": "Refresh",
|
|
7
|
+
"props": [
|
|
8
|
+
{
|
|
9
|
+
"p": "payload"
|
|
10
|
+
}
|
|
11
|
+
],
|
|
12
|
+
"repeat": "3600",
|
|
13
|
+
"crontab": "",
|
|
14
|
+
"once": true,
|
|
15
|
+
"onceDelay": "1",
|
|
16
|
+
"topic": "",
|
|
17
|
+
"payload": "{viewer{homes{currentSubscription{priceInfo{today{totalstartsAt}tomorrow{totalstartsAt}}}}}}",
|
|
18
|
+
"payloadType": "str",
|
|
19
|
+
"x": 120,
|
|
20
|
+
"y": 40,
|
|
21
|
+
"wires": [["ab2d599a.077738"]]
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"id": "ab2d599a.077738",
|
|
25
|
+
"type": "tibber-query",
|
|
26
|
+
"z": "d938c47f.3398f8",
|
|
27
|
+
"name": "Get Tibber prices",
|
|
28
|
+
"active": true,
|
|
29
|
+
"apiEndpointRef": "b70ec5d0.6f8f08",
|
|
30
|
+
"x": 310,
|
|
31
|
+
"y": 40,
|
|
32
|
+
"wires": [["0ef929fde193cf4d"]]
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"id": "0ef929fde193cf4d",
|
|
36
|
+
"type": "ps-receive-price",
|
|
37
|
+
"z": "d938c47f.3398f8",
|
|
38
|
+
"name": "Price Receiver",
|
|
39
|
+
"x": 140,
|
|
40
|
+
"y": 100,
|
|
41
|
+
"wires": [["5b6be1568744c6cf", "391ac08890e0dd40"]]
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"id": "391ac08890e0dd40",
|
|
45
|
+
"type": "ps-strategy-lowest-price",
|
|
46
|
+
"z": "d938c47f.3398f8",
|
|
47
|
+
"name": "Lowest Price",
|
|
48
|
+
"fromTime": "00",
|
|
49
|
+
"toTime": "00",
|
|
50
|
+
"hoursOn": "12",
|
|
51
|
+
"doNotSplit": false,
|
|
52
|
+
"sendCurrentValueWhenRescheduling": true,
|
|
53
|
+
"outputIfNoSchedule": "true",
|
|
54
|
+
"outputOutsidePeriod": "true",
|
|
55
|
+
"x": 410,
|
|
56
|
+
"y": 400,
|
|
57
|
+
"wires": [["32f17ab2.927cf6"], ["526a6e89600f0f19"], ["ed7202ff.b5725"]]
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"id": "32f17ab2.927cf6",
|
|
61
|
+
"type": "api-call-service",
|
|
62
|
+
"z": "d938c47f.3398f8",
|
|
63
|
+
"name": "Turn up",
|
|
64
|
+
"server": "ec4a12a1.b2be9",
|
|
65
|
+
"version": 3,
|
|
66
|
+
"debugenabled": true,
|
|
67
|
+
"service_domain": "climate",
|
|
68
|
+
"service": "set_temperature",
|
|
69
|
+
"entityId": "climate.varme_gulv_kjellerstue",
|
|
70
|
+
"data": "{\"temperature\":27}",
|
|
71
|
+
"dataType": "json",
|
|
72
|
+
"mergecontext": "",
|
|
73
|
+
"mustacheAltTags": false,
|
|
74
|
+
"outputProperties": [],
|
|
75
|
+
"queue": "last",
|
|
76
|
+
"x": 700,
|
|
77
|
+
"y": 340,
|
|
78
|
+
"wires": [[]]
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"id": "526a6e89600f0f19",
|
|
82
|
+
"type": "api-call-service",
|
|
83
|
+
"z": "d938c47f.3398f8",
|
|
84
|
+
"name": "Turn down",
|
|
85
|
+
"server": "ec4a12a1.b2be9",
|
|
86
|
+
"version": 3,
|
|
87
|
+
"debugenabled": true,
|
|
88
|
+
"service_domain": "climate",
|
|
89
|
+
"service": "set_temperature",
|
|
90
|
+
"entityId": "climate.varme_gulv_kjellerstue",
|
|
91
|
+
"data": "{\"temperature\":25}",
|
|
92
|
+
"dataType": "json",
|
|
93
|
+
"mergecontext": "",
|
|
94
|
+
"mustacheAltTags": false,
|
|
95
|
+
"outputProperties": [],
|
|
96
|
+
"queue": "last",
|
|
97
|
+
"x": 710,
|
|
98
|
+
"y": 400,
|
|
99
|
+
"wires": [[]]
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"id": "ed7202ff.b5725",
|
|
103
|
+
"type": "debug",
|
|
104
|
+
"z": "d938c47f.3398f8",
|
|
105
|
+
"name": "Lowest Price Schedule",
|
|
106
|
+
"active": true,
|
|
107
|
+
"tosidebar": true,
|
|
108
|
+
"console": false,
|
|
109
|
+
"tostatus": false,
|
|
110
|
+
"complete": "payload",
|
|
111
|
+
"targetType": "msg",
|
|
112
|
+
"statusVal": "",
|
|
113
|
+
"statusType": "auto",
|
|
114
|
+
"x": 750,
|
|
115
|
+
"y": 460,
|
|
116
|
+
"wires": []
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"id": "82c86d92b7c9292c",
|
|
120
|
+
"type": "inject",
|
|
121
|
+
"z": "d938c47f.3398f8",
|
|
122
|
+
"name": "Send schedule",
|
|
123
|
+
"props": [
|
|
124
|
+
{
|
|
125
|
+
"p": "payload"
|
|
126
|
+
}
|
|
127
|
+
],
|
|
128
|
+
"repeat": "",
|
|
129
|
+
"crontab": "",
|
|
130
|
+
"once": false,
|
|
131
|
+
"onceDelay": 0.1,
|
|
132
|
+
"topic": "",
|
|
133
|
+
"payload": "{\"commands\":{\"sendSchedule\":true}}",
|
|
134
|
+
"payloadType": "json",
|
|
135
|
+
"x": 140,
|
|
136
|
+
"y": 260,
|
|
137
|
+
"wires": [["5b6be1568744c6cf", "391ac08890e0dd40"]]
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
"id": "b70ec5d0.6f8f08",
|
|
141
|
+
"type": "tibber-api-endpoint",
|
|
142
|
+
"feedUrl": "wss://api.tibber.com/v1-beta/gql/subscriptions",
|
|
143
|
+
"queryUrl": "https://api.tibber.com/v1-beta/gql",
|
|
144
|
+
"name": "Tibber API"
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
"id": "ec4a12a1.b2be9",
|
|
148
|
+
"type": "server",
|
|
149
|
+
"name": "Home Assistant",
|
|
150
|
+
"version": 2,
|
|
151
|
+
"addon": true,
|
|
152
|
+
"rejectUnauthorizedCerts": true,
|
|
153
|
+
"ha_boolean": "y|yes|true|on|home|open",
|
|
154
|
+
"connectionDelay": true,
|
|
155
|
+
"cacheJson": true,
|
|
156
|
+
"heartbeat": false,
|
|
157
|
+
"heartbeatInterval": 30
|
|
158
|
+
}
|
|
159
|
+
]
|
package/firebase.json
ADDED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "node-red-contrib-power-saver",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.4.2",
|
|
4
4
|
"description": "A module for Node-RED that you can use to turn on and off a switch based on power prices",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -25,12 +25,17 @@
|
|
|
25
25
|
"ps-receive-price": "src/receive-price.js",
|
|
26
26
|
"ps-strategy-best-save": "src/strategy-best-save.js",
|
|
27
27
|
"ps-strategy-lowest-price": "src/strategy-lowest-price.js",
|
|
28
|
+
"ps-strategy-heat-capacitor": "src/strategy-heat-capacitor.js",
|
|
28
29
|
"ps-elvia-config": "src/elvia/elvia-config.js",
|
|
29
30
|
"ps-elvia-tariff-types": "src/elvia/elvia-tariff-types.js",
|
|
30
31
|
"ps-elvia-tariff": "src/elvia/elvia-tariff.js",
|
|
31
32
|
"ps-elvia-add-tariff": "src/elvia/elvia-add-tariff.js",
|
|
32
33
|
"ps-general-add-tariff": "src/general-add-tariff.js"
|
|
33
|
-
}
|
|
34
|
+
},
|
|
35
|
+
"version": ">=2.2.0"
|
|
36
|
+
},
|
|
37
|
+
"engines": {
|
|
38
|
+
"node": ">=14.0.0"
|
|
34
39
|
},
|
|
35
40
|
"prettier": {
|
|
36
41
|
"printWidth": 120
|
|
@@ -40,19 +45,22 @@
|
|
|
40
45
|
"url": "https://github.com/ottopaulsen/node-red-contrib-power-saver.git"
|
|
41
46
|
},
|
|
42
47
|
"devDependencies": {
|
|
48
|
+
"@vuepress/bundler-webpack": "^2.0.0-alpha.1",
|
|
43
49
|
"@vuepress/plugin-register-components": "^2.0.0-beta.33",
|
|
44
50
|
"@vuepress/utils": "^2.0.0-beta.27",
|
|
45
|
-
"expect": "^27.
|
|
46
|
-
"mocha": "^
|
|
47
|
-
"node-red": "^
|
|
51
|
+
"expect": "^27.5.1",
|
|
52
|
+
"mocha": "^9.2.0",
|
|
53
|
+
"node-red": "^2.2.0",
|
|
48
54
|
"node-red-node-test-helper": "^0.2.7",
|
|
49
55
|
"patch-vue-directive-ssr": "^0.0.1",
|
|
50
|
-
"vuepress": "^2.0.0-beta.
|
|
56
|
+
"vuepress": "^2.0.0-beta.35",
|
|
57
|
+
"vuepress-webpack": "^2.0.0-beta.35"
|
|
51
58
|
},
|
|
52
59
|
"dependencies": {
|
|
53
|
-
"
|
|
60
|
+
"@vitejs/plugin-vue": "^2.2.0",
|
|
61
|
+
"floating-vue": "^2.0.0-beta.6",
|
|
54
62
|
"lodash.clonedeep": "^4.5.0",
|
|
55
|
-
"luxon": "^
|
|
56
|
-
"node-fetch": "^2.6.
|
|
63
|
+
"luxon": "^2.3.0",
|
|
64
|
+
"node-fetch": "^2.6.7"
|
|
57
65
|
}
|
|
58
66
|
}
|
package/public/404.html
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8">
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
6
|
+
<title>Page Not Found</title>
|
|
7
|
+
|
|
8
|
+
<style media="screen">
|
|
9
|
+
body { background: #ECEFF1; color: rgba(0,0,0,0.87); font-family: Roboto, Helvetica, Arial, sans-serif; margin: 0; padding: 0; }
|
|
10
|
+
#message { background: white; max-width: 360px; margin: 100px auto 16px; padding: 32px 24px 16px; border-radius: 3px; }
|
|
11
|
+
#message h3 { color: #888; font-weight: normal; font-size: 16px; margin: 16px 0 12px; }
|
|
12
|
+
#message h2 { color: #ffa100; font-weight: bold; font-size: 16px; margin: 0 0 8px; }
|
|
13
|
+
#message h1 { font-size: 22px; font-weight: 300; color: rgba(0,0,0,0.6); margin: 0 0 16px;}
|
|
14
|
+
#message p { line-height: 140%; margin: 16px 0 24px; font-size: 14px; }
|
|
15
|
+
#message a { display: block; text-align: center; background: #039be5; text-transform: uppercase; text-decoration: none; color: white; padding: 16px; border-radius: 4px; }
|
|
16
|
+
#message, #message a { box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24); }
|
|
17
|
+
#load { color: rgba(0,0,0,0.4); text-align: center; font-size: 13px; }
|
|
18
|
+
@media (max-width: 600px) {
|
|
19
|
+
body, #message { margin-top: 0; background: white; box-shadow: none; }
|
|
20
|
+
body { border-top: 16px solid #ffa100; }
|
|
21
|
+
}
|
|
22
|
+
</style>
|
|
23
|
+
</head>
|
|
24
|
+
<body>
|
|
25
|
+
<div id="message">
|
|
26
|
+
<h2>404</h2>
|
|
27
|
+
<h1>Page Not Found</h1>
|
|
28
|
+
<p>The specified file was not found on this website. Please check the URL for mistakes and try again.</p>
|
|
29
|
+
<h3>Why am I seeing this?</h3>
|
|
30
|
+
<p>This page was generated by the Firebase Command-Line Interface. To modify it, edit the <code>404.html</code> file in your project's configured <code>public</code> directory.</p>
|
|
31
|
+
</div>
|
|
32
|
+
</body>
|
|
33
|
+
</html>
|