node-red-contrib-power-saver 3.2.2 → 3.3.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.
Files changed (105) hide show
  1. package/CHANGELOG.md +1 -1
  2. package/README.md +1 -1
  3. package/docs/.vuepress/clientAppEnhance.js +5 -0
  4. package/docs/.vuepress/components/BestSaveVerificator.vue +306 -0
  5. package/docs/.vuepress/components/DonateButtons.vue +87 -0
  6. package/docs/.vuepress/config.js +29 -5
  7. package/docs/.vuepress/dist/.nojekyll +0 -0
  8. package/docs/.vuepress/dist/404.html +5 -5
  9. package/docs/.vuepress/dist/assets/css/563.styles.99f4a8aa.css +1 -0
  10. package/docs/.vuepress/dist/assets/css/835.styles.c5afb22b.css +1 -0
  11. package/docs/.vuepress/dist/assets/css/{styles.e835bef6.css → styles.031dcf27.css} +2 -1
  12. package/docs/.vuepress/dist/assets/img/best-save-config.79a2f39a.png +0 -0
  13. package/docs/.vuepress/dist/assets/img/copy-payload-best-save.b9192985.png +0 -0
  14. package/docs/.vuepress/dist/assets/js/262.cf2c57d2.js +1 -0
  15. package/docs/.vuepress/dist/assets/js/{293.5e967839.js → 293.08ea5200.js} +0 -0
  16. package/docs/.vuepress/dist/assets/js/331.15ee3c51.js +1 -0
  17. package/docs/.vuepress/dist/assets/js/{491.c183eba3.js → 491.17a98f38.js} +0 -0
  18. package/docs/.vuepress/dist/assets/js/619.8ba1b1f6.js +2 -0
  19. package/docs/.vuepress/dist/assets/js/{812.79dad458.js.LICENSE.txt → 619.8ba1b1f6.js.LICENSE.txt} +0 -0
  20. package/docs/.vuepress/dist/assets/js/811.6a3392d5.js +1 -0
  21. package/docs/.vuepress/dist/assets/js/app.b705176c.js +1 -0
  22. package/docs/.vuepress/dist/assets/js/runtime~app.47f4f812.js +1 -0
  23. package/docs/.vuepress/dist/assets/js/{v-0607240a.661e1808.js → v-0607240a.a57c2199.js} +0 -0
  24. package/docs/.vuepress/dist/assets/js/{v-08683c60.a6b9cf5b.js → v-08683c60.ccafdcab.js} +0 -0
  25. package/docs/.vuepress/dist/assets/js/{v-0aca7ba6.b42fad7f.js → v-0aca7ba6.25903946.js} +0 -0
  26. package/docs/.vuepress/dist/assets/js/v-0b5e3c8c.a6a015b4.js +1 -0
  27. package/docs/.vuepress/dist/assets/js/{v-1ad821fa.6e2194d0.js → v-1ad821fa.5978386f.js} +0 -0
  28. package/docs/.vuepress/dist/assets/js/{v-1e2b191e.98cc227b.js → v-1e2b191e.88dc5555.js} +0 -0
  29. package/docs/.vuepress/dist/assets/js/v-29504124.4aca27d5.js +1 -0
  30. package/docs/.vuepress/dist/assets/js/{v-30acb564.f2fcd69f.js → v-30acb564.529a3c16.js} +0 -0
  31. package/docs/.vuepress/dist/assets/js/v-4637f9e4.703b1d96.js +1 -0
  32. package/docs/.vuepress/dist/assets/js/v-510ed0d4.7b142a81.js +1 -0
  33. package/docs/.vuepress/dist/assets/js/{v-5954bcb2.182daf70.js → v-5954bcb2.937005d0.js} +0 -0
  34. package/docs/.vuepress/dist/assets/js/{v-5db8da3a.f2de6cb9.js → v-5db8da3a.3de3588d.js} +1 -1
  35. package/docs/.vuepress/dist/assets/js/{v-61f728ca.6fdbbb92.js → v-61f728ca.21d432fe.js} +1 -1
  36. package/docs/.vuepress/dist/assets/js/{v-677dfaed.0013f083.js → v-677dfaed.44a653b9.js} +0 -0
  37. package/docs/.vuepress/dist/assets/js/v-7446a652.74b21d0b.js +1 -0
  38. package/docs/.vuepress/dist/assets/js/v-7c87f26e.ee5be992.js +1 -0
  39. package/docs/.vuepress/dist/assets/js/{v-8daa1a0e.dde202c9.js → v-8daa1a0e.c63afc2b.js} +1 -1
  40. package/docs/.vuepress/dist/assets/js/{v-b4a42144.9e5f9728.js → v-b4a42144.733e4e7c.js} +0 -0
  41. package/docs/.vuepress/dist/assets/js/{v-e8c55052.8384b053.js → v-e8c55052.ab0a79ec.js} +0 -0
  42. package/docs/.vuepress/dist/assets/js/v-fffb8e28.525be02a.js +1 -0
  43. package/docs/.vuepress/dist/changelog/index.html +5 -5
  44. package/docs/.vuepress/dist/contribute/index.html +5 -5
  45. package/docs/.vuepress/dist/examples/example-next-schedule-entity.html +6 -6
  46. package/docs/.vuepress/dist/examples/example-nordpool-current-state.html +6 -7
  47. package/docs/.vuepress/dist/examples/example-nordpool-events-state.html +6 -6
  48. package/docs/.vuepress/dist/examples/example-tibber-mqtt.html +6 -7
  49. package/docs/.vuepress/dist/examples/index.html +5 -5
  50. package/docs/.vuepress/dist/faq/best-save-viewer.html +15 -0
  51. package/docs/.vuepress/dist/faq/index.html +5 -5
  52. package/docs/.vuepress/dist/guide/index.html +6 -6
  53. package/docs/.vuepress/dist/index.html +5 -5
  54. package/docs/.vuepress/dist/nodes/index.html +5 -5
  55. package/docs/.vuepress/dist/nodes/old-power-saver-doc.html +7 -7
  56. package/docs/.vuepress/dist/nodes/power-saver.html +5 -5
  57. package/docs/.vuepress/dist/nodes/ps-elvia-add-tariff.html +5 -5
  58. package/docs/.vuepress/dist/nodes/ps-general-add-tariff.html +5 -5
  59. package/docs/.vuepress/dist/nodes/ps-receive-price.html +8 -8
  60. package/docs/.vuepress/dist/nodes/ps-strategy-best-save.html +22 -8
  61. package/docs/.vuepress/dist/nodes/ps-strategy-lowest-price.html +17 -7
  62. package/docs/.vuepress/dist/nodes/strategy-input.html +5 -5
  63. package/docs/README.md +4 -1
  64. package/docs/changelog/README.md +23 -0
  65. package/docs/contribute/README.md +3 -3
  66. package/docs/examples/example-nordpool-current-state.md +0 -1
  67. package/docs/examples/example-tibber-mqtt.md +0 -1
  68. package/docs/faq/README.md +28 -1
  69. package/docs/faq/best-save-viewer.md +61 -0
  70. package/docs/images/best-save-config.png +0 -0
  71. package/docs/images/copy-payload-best-save.png +0 -0
  72. package/docs/nodes/ps-strategy-best-save.md +95 -8
  73. package/docs/nodes/ps-strategy-lowest-price.md +57 -0
  74. package/package.json +7 -3
  75. package/src/general-add-tariff-functions.js +0 -1
  76. package/src/general-add-tariff.js +2 -4
  77. package/src/handle-input.js +31 -9
  78. package/src/strategy-best-save.html +0 -21
  79. package/src/strategy-best-save.js +8 -11
  80. package/test/commands-input.test.js +47 -0
  81. package/test/data/best-save-result.json +1 -2
  82. package/test/data/current-undefined-prices.json +197 -0
  83. package/test/data/current-undefined-result.json +208 -0
  84. package/test/data/lowest-price-result-missing-end.json +2 -1
  85. package/test/data/reconfigResult.js +56 -294
  86. package/test/data/reconfigResult_old2.js +75 -0
  87. package/test/data/tibber-result-end-0-24h.json +1 -0
  88. package/test/data/tibber-result-end-0.json +1 -0
  89. package/test/send-config-input.test.js +3 -37
  90. package/test/strategy-best-save-test-utils.js +2 -1
  91. package/test/strategy-best-save.test.js +14 -8
  92. package/test/test-utils.js +1 -7
  93. package/test/utils.test.js +0 -33
  94. package/docs/.vuepress/dist/assets/img/best-save-config.93fa3c21.png +0 -0
  95. package/docs/.vuepress/dist/assets/js/812.79dad458.js +0 -2
  96. package/docs/.vuepress/dist/assets/js/app.46f7644a.js +0 -1
  97. package/docs/.vuepress/dist/assets/js/runtime~app.714a526c.js +0 -1
  98. package/docs/.vuepress/dist/assets/js/v-0b5e3c8c.3b37457f.js +0 -1
  99. package/docs/.vuepress/dist/assets/js/v-4637f9e4.b320f5e8.js +0 -1
  100. package/docs/.vuepress/dist/assets/js/v-510ed0d4.9d35e3e3.js +0 -1
  101. package/docs/.vuepress/dist/assets/js/v-7446a652.d05e2648.js +0 -1
  102. package/docs/.vuepress/dist/assets/js/v-7c87f26e.1127dcf5.js +0 -1
  103. package/docs/.vuepress/dist/assets/js/v-fffb8e28.3406fd88.js +0 -1
  104. package/test/data/adjustedResult.js +0 -302
  105. package/test/data/adjustedResult_old.js +0 -154
@@ -4,12 +4,12 @@
4
4
  <meta charset="utf-8">
5
5
  <meta name="viewport" content="width=device-width,initial-scale=1">
6
6
  <meta name="generator" content="VuePress 2.0.0-beta.27">
7
- <link rel="icon" href="/euro.png"><title>ps-general-add-tariff | Power Saver</title><meta name="description" content="A Node-RED note to save money on hourly changing power prices">
8
- <link rel="preload" href="/node-red-contrib-power-saver/assets/js/runtime~app.714a526c.js" as="script"><link rel="preload" href="/node-red-contrib-power-saver/assets/css/styles.e835bef6.css" as="style"><link rel="preload" href="/node-red-contrib-power-saver/assets/js/812.79dad458.js" as="script"><link rel="preload" href="/node-red-contrib-power-saver/assets/js/app.46f7644a.js" as="script">
9
- <link rel="stylesheet" href="/node-red-contrib-power-saver/assets/css/styles.e835bef6.css">
7
+ <link rel="shortcut icon" type="image/x-icon" href="euro.png"><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-9857859182772006" crossorigin="anonymous"></script><title>ps-general-add-tariff | Power Saver</title><meta name="description" content="A Node-RED note to save money on hourly changing power prices">
8
+ <link rel="preload" href="/assets/js/runtime~app.47f4f812.js" as="script"><link rel="preload" href="/assets/css/styles.031dcf27.css" as="style"><link rel="preload" href="/assets/js/619.8ba1b1f6.js" as="script"><link rel="preload" href="/assets/js/app.b705176c.js" as="script">
9
+ <link rel="stylesheet" href="/assets/css/styles.031dcf27.css">
10
10
  </head>
11
11
  <body>
12
- <div id="app"><!--[--><div class="theme-container"><!--[--><header class="navbar"><div class="toggle-sidebar-button" title="toggle sidebar" aria-expanded="false" role="button" tabindex="0"><div class="icon" aria-hidden="true"><span></span><span></span><span></span></div></div><span><a href="/node-red-contrib-power-saver/" class=""><!----><span class="site-name">Power Saver</span></a></span><div class="navbar-links-wrapper" style=""><!--[--><!--]--><nav class="navbar-links can-hide"><!--[--><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><button class="toggle-dark-button" title="toggle dark mode"><svg style="" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M16 12.005a4 4 0 1 1-4 4a4.005 4.005 0 0 1 4-4m0-2a6 6 0 1 0 6 6a6 6 0 0 0-6-6z" fill="currentColor"></path><path d="M5.394 6.813l1.414-1.415l3.506 3.506L8.9 10.318z" fill="currentColor"></path><path d="M2 15.005h5v2H2z" fill="currentColor"></path><path d="M5.394 25.197L8.9 21.691l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 25.005h2v5h-2z" fill="currentColor"></path><path d="M21.687 23.106l1.414-1.415l3.506 3.506l-1.414 1.414z" fill="currentColor"></path><path d="M25 15.005h5v2h-5z" fill="currentColor"></path><path d="M21.687 8.904l3.506-3.506l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 2.005h2v5h-2z" fill="currentColor"></path></svg><svg style="display:none;" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M13.502 5.414a15.075 15.075 0 0 0 11.594 18.194a11.113 11.113 0 0 1-7.975 3.39c-.138 0-.278.005-.418 0a11.094 11.094 0 0 1-3.2-21.584M14.98 3a1.002 1.002 0 0 0-.175.016a13.096 13.096 0 0 0 1.825 25.981c.164.006.328 0 .49 0a13.072 13.072 0 0 0 10.703-5.555a1.01 1.01 0 0 0-.783-1.565A13.08 13.08 0 0 1 15.89 4.38A1.015 1.015 0 0 0 14.98 3z" fill="currentColor"></path></svg></button><!----></div></header><!--]--><div class="sidebar-mask"></div><!--[--><aside class="sidebar"><nav class="navbar-links"><!--[--><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><ul class="sidebar-links"><!--[--><!--[--><p class="sidebar-heading sidebar-item active">Nodes</p><ul class=""><li><!--[--><a href="/node-red-contrib-power-saver/nodes/power-saver.md" class="nav-link sidebar-item" aria-label="Power Saver"><!--[--><!--]--> Power Saver <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><p class="sidebar-item">Strategy nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html" class="nav-link sidebar-item" aria-label="ps-strategy-best-save"><!--[--><!--]--> ps-strategy-best-save <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-strategy-lowest-price.html" class="nav-link sidebar-item" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item">Utility nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-receive-price.html" class="nav-link sidebar-item" aria-label="ps-receive-price"><!--[--><!--]--> ps-receive-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item active">Grid tariff nodes</p><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html" class="router-link-active router-link-exact-active nav-link router-link-active sidebar-item active" aria-label="ps-general-add-tariff"><!--[--><!--]--> ps-general-add-tariff <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html#description" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Description"><!--[--><!--]--> Description <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html#configuration" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Configuration"><!--[--><!--]--> Configuration <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html#add-and-delete-periods" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Add and delete periods"><!--[--><!--]--> Add and delete periods <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html#from-time-and-value" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="From time and Value"><!--[--><!--]--> From time and Value <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html#valid-from-date" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Valid from date"><!--[--><!--]--> Valid from date <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html#valid-to-date" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Valid to date"><!--[--><!--]--> Valid to date <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html#input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Input"><!--[--><!--]--> Input <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html#output" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output"><!--[--><!--]--> Output <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-elvia-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-elvia-add-tariff"><!--[--><!--]--> ps-elvia-add-tariff <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li></ul><!--]--><!--[--><p class="sidebar-heading sidebar-item">Data format</p><ul class=""><li><!--[--><a href="/node-red-contrib-power-saver/nodes/strategy-input.html" class="nav-link sidebar-item" aria-label="Strategy input format"><!--[--><!--]--> Strategy input format <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--><!--]--></ul><!--[--><!--]--></aside><!--]--><!--[--><main class="page"><!--[--><!--]--><div class="theme-default-content"><!--[--><h1 id="ps-general-add-tariff" tabindex="-1"><a class="header-anchor" href="#ps-general-add-tariff" aria-hidden="true">#</a> ps-general-add-tariff</h1><p><img src="/node-red-contrib-power-saver/assets/img/node-ps-general-add-tariff.a3cf6f06.png" alt="ps-general-add-tariff"></p><p>Node to add a value, for example a variable grid tariff, to the price before it is used to calculate savings in the strategy nodes.</p><h2 id="description" tabindex="-1"><a class="header-anchor" href="#description" aria-hidden="true">#</a> Description</h2><p>This node is useful if there is an addition to the electricity price that varies over the day, as it might be for the grid tariff.</p><p>If there is one price for example from 22:00 to 06:00 every day, and another price from 06:00 to 22:00, this is the right node to use. It can be used for more than two periods, as long as the time it changes is the same every day.</p><p>Here is how this node is normally used:</p><p><img src="/node-red-contrib-power-saver/assets/img/add-tariff-flow.eb700d4f.png" alt="general flow"></p><div class="custom-container tip"><p class="custom-container-title">Changes during the year</p><p>If there is one price now, and another price from a specific date, you can use two nodes after each other. Set the <code>Valid to date</code> of the node with the current prices to the last date the current prices are valid. Set the <code>Valid from date</code> of the node with the upcoming prices to the first date those prices are valid.</p></div><h2 id="configuration" tabindex="-1"><a class="header-anchor" href="#configuration" aria-hidden="true">#</a> Configuration</h2><h3 id="add-and-delete-periods" tabindex="-1"><a class="header-anchor" href="#add-and-delete-periods" aria-hidden="true">#</a> Add and delete periods</h3><p>You can have from 1 to 24 periods during the day, with different values to add for each hour. Click the <code>Add period</code> button to add more periods. Click the <code>X</code> button to delete a period.</p><h3 id="from-time-and-value" tabindex="-1"><a class="header-anchor" href="#from-time-and-value" aria-hidden="true">#</a> From time and Value</h3><p>For each period, select the time of the day the value is valid from, and enter the value.</p><h3 id="valid-from-date" tabindex="-1"><a class="header-anchor" href="#valid-from-date" aria-hidden="true">#</a> Valid from date</h3><p>Fill in the first date the config is valid.</p><p>If this is empty, the config is valid from the dawn of time.</p><h3 id="valid-to-date" tabindex="-1"><a class="header-anchor" href="#valid-to-date" aria-hidden="true">#</a> Valid to date</h3><p>Fill in the last date the config is valid.</p><p>If this is empty, the config is valid until forever.</p><h2 id="input" tabindex="-1"><a class="header-anchor" href="#input" aria-hidden="true">#</a> Input</h2><p>The input is the <a href="/node-red-contrib-power-saver/nodes/strategy-input.html" class="">common strategy input format</a></p><h2 id="output" tabindex="-1"><a class="header-anchor" href="#output" aria-hidden="true">#</a> Output</h2><p>The output is the <a href="/node-red-contrib-power-saver/nodes/strategy-input.html" class="">common strategy input format</a></p><p>If there is a config property in the input payload, it is passed on to the output payload.</p><!--]--></div><footer class="page-meta"><!----><div class="meta-item last-updated"><span class="meta-item-label">Last Updated: </span><span class="meta-item-info">1/7/2022, 9:09:31 PM</span></div><!----></footer><nav class="page-nav"><p class="inner"><!----><span class="next"><a href="/node-red-contrib-power-saver/nodes/ps-elvia-add-tariff.html" class="nav-link" aria-label="ps-elvia-add-tariff"><!--[--><!--]--> ps-elvia-add-tariff <!--[--><!--]--></a> → </span></p></nav><!--[--><!--]--></main><!--]--></div><!----><!--]--></div>
13
- <script src="/node-red-contrib-power-saver/assets/js/runtime~app.714a526c.js" defer></script><script src="/node-red-contrib-power-saver/assets/js/812.79dad458.js" defer></script><script src="/node-red-contrib-power-saver/assets/js/app.46f7644a.js" defer></script>
12
+ <div id="app"><!--[--><div class="theme-container"><!--[--><header class="navbar"><div class="toggle-sidebar-button" title="toggle sidebar" aria-expanded="false" role="button" tabindex="0"><div class="icon" aria-hidden="true"><span></span><span></span><span></span></div></div><span><a href="/" class=""><!----><span class="site-name">Power Saver</span></a></span><div class="navbar-links-wrapper" style=""><!--[--><!--]--><nav class="navbar-links can-hide"><!--[--><div class="navbar-links-item"><a href="/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/faq/" class="nav-link" aria-label="FAQ"><!--[--><!--]--> FAQ <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><button class="toggle-dark-button" title="toggle dark mode"><svg style="" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M16 12.005a4 4 0 1 1-4 4a4.005 4.005 0 0 1 4-4m0-2a6 6 0 1 0 6 6a6 6 0 0 0-6-6z" fill="currentColor"></path><path d="M5.394 6.813l1.414-1.415l3.506 3.506L8.9 10.318z" fill="currentColor"></path><path d="M2 15.005h5v2H2z" fill="currentColor"></path><path d="M5.394 25.197L8.9 21.691l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 25.005h2v5h-2z" fill="currentColor"></path><path d="M21.687 23.106l1.414-1.415l3.506 3.506l-1.414 1.414z" fill="currentColor"></path><path d="M25 15.005h5v2h-5z" fill="currentColor"></path><path d="M21.687 8.904l3.506-3.506l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 2.005h2v5h-2z" fill="currentColor"></path></svg><svg style="display:none;" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M13.502 5.414a15.075 15.075 0 0 0 11.594 18.194a11.113 11.113 0 0 1-7.975 3.39c-.138 0-.278.005-.418 0a11.094 11.094 0 0 1-3.2-21.584M14.98 3a1.002 1.002 0 0 0-.175.016a13.096 13.096 0 0 0 1.825 25.981c.164.006.328 0 .49 0a13.072 13.072 0 0 0 10.703-5.555a1.01 1.01 0 0 0-.783-1.565A13.08 13.08 0 0 1 15.89 4.38A1.015 1.015 0 0 0 14.98 3z" fill="currentColor"></path></svg></button><!----></div></header><!--]--><div class="sidebar-mask"></div><!--[--><aside class="sidebar"><nav class="navbar-links"><!--[--><div class="navbar-links-item"><a href="/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/faq/" class="nav-link" aria-label="FAQ"><!--[--><!--]--> FAQ <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><ul class="sidebar-links"><!--[--><!--[--><p class="sidebar-heading sidebar-item active">Nodes</p><ul class=""><li><!--[--><a href="/nodes/power-saver.md" class="nav-link sidebar-item" aria-label="Power Saver"><!--[--><!--]--> Power Saver <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><p class="sidebar-item">Strategy nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/nodes/ps-strategy-best-save.html" class="nav-link sidebar-item" aria-label="ps-strategy-best-save"><!--[--><!--]--> ps-strategy-best-save <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a href="/nodes/ps-strategy-lowest-price.html" class="nav-link sidebar-item" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item">Utility nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/nodes/ps-receive-price.html" class="nav-link sidebar-item" aria-label="ps-receive-price"><!--[--><!--]--> ps-receive-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item active">Grid tariff nodes</p><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html" class="router-link-active router-link-exact-active nav-link router-link-active sidebar-item active" aria-label="ps-general-add-tariff"><!--[--><!--]--> ps-general-add-tariff <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html#description" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Description"><!--[--><!--]--> Description <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html#configuration" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Configuration"><!--[--><!--]--> Configuration <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html#add-and-delete-periods" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Add and delete periods"><!--[--><!--]--> Add and delete periods <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html#from-time-and-value" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="From time and Value"><!--[--><!--]--> From time and Value <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html#valid-from-date" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Valid from date"><!--[--><!--]--> Valid from date <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html#valid-to-date" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Valid to date"><!--[--><!--]--> Valid to date <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html#input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Input"><!--[--><!--]--> Input <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-general-add-tariff.html#output" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output"><!--[--><!--]--> Output <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a href="/nodes/ps-elvia-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-elvia-add-tariff"><!--[--><!--]--> ps-elvia-add-tariff <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li></ul><!--]--><!--[--><p class="sidebar-heading sidebar-item">Data format</p><ul class=""><li><!--[--><a href="/nodes/strategy-input.html" class="nav-link sidebar-item" aria-label="Strategy input format"><!--[--><!--]--> Strategy input format <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--><!--]--></ul><!--[--><!--]--></aside><!--]--><!--[--><main class="page"><!--[--><!--]--><div class="theme-default-content"><!--[--><h1 id="ps-general-add-tariff" tabindex="-1"><a class="header-anchor" href="#ps-general-add-tariff" aria-hidden="true">#</a> ps-general-add-tariff</h1><p><img src="/assets/img/node-ps-general-add-tariff.a3cf6f06.png" alt="ps-general-add-tariff"></p><p>Node to add a value, for example a variable grid tariff, to the price before it is used to calculate savings in the strategy nodes.</p><h2 id="description" tabindex="-1"><a class="header-anchor" href="#description" aria-hidden="true">#</a> Description</h2><p>This node is useful if there is an addition to the electricity price that varies over the day, as it might be for the grid tariff.</p><p>If there is one price for example from 22:00 to 06:00 every day, and another price from 06:00 to 22:00, this is the right node to use. It can be used for more than two periods, as long as the time it changes is the same every day.</p><p>Here is how this node is normally used:</p><p><img src="/assets/img/add-tariff-flow.eb700d4f.png" alt="general flow"></p><div class="custom-container tip"><p class="custom-container-title">Changes during the year</p><p>If there is one price now, and another price from a specific date, you can use two nodes after each other. Set the <code>Valid to date</code> of the node with the current prices to the last date the current prices are valid. Set the <code>Valid from date</code> of the node with the upcoming prices to the first date those prices are valid.</p></div><h2 id="configuration" tabindex="-1"><a class="header-anchor" href="#configuration" aria-hidden="true">#</a> Configuration</h2><h3 id="add-and-delete-periods" tabindex="-1"><a class="header-anchor" href="#add-and-delete-periods" aria-hidden="true">#</a> Add and delete periods</h3><p>You can have from 1 to 24 periods during the day, with different values to add for each hour. Click the <code>Add period</code> button to add more periods. Click the <code>X</code> button to delete a period.</p><h3 id="from-time-and-value" tabindex="-1"><a class="header-anchor" href="#from-time-and-value" aria-hidden="true">#</a> From time and Value</h3><p>For each period, select the time of the day the value is valid from, and enter the value.</p><h3 id="valid-from-date" tabindex="-1"><a class="header-anchor" href="#valid-from-date" aria-hidden="true">#</a> Valid from date</h3><p>Fill in the first date the config is valid.</p><p>If this is empty, the config is valid from the dawn of time.</p><h3 id="valid-to-date" tabindex="-1"><a class="header-anchor" href="#valid-to-date" aria-hidden="true">#</a> Valid to date</h3><p>Fill in the last date the config is valid.</p><p>If this is empty, the config is valid until forever.</p><h2 id="input" tabindex="-1"><a class="header-anchor" href="#input" aria-hidden="true">#</a> Input</h2><p>The input is the <a href="/nodes/strategy-input.html" class="">common strategy input format</a></p><h2 id="output" tabindex="-1"><a class="header-anchor" href="#output" aria-hidden="true">#</a> Output</h2><p>The output is the <a href="/nodes/strategy-input.html" class="">common strategy input format</a></p><p>If there is a config property in the input payload, it is passed on to the output payload.</p><!--]--></div><footer class="page-meta"><!----><div class="meta-item last-updated"><span class="meta-item-label">Last Updated: </span><span class="meta-item-info">1/7/2022, 9:09:31 PM</span></div><!----></footer><nav class="page-nav"><p class="inner"><!----><span class="next"><a href="/nodes/ps-elvia-add-tariff.html" class="nav-link" aria-label="ps-elvia-add-tariff"><!--[--><!--]--> ps-elvia-add-tariff <!--[--><!--]--></a> → </span></p></nav><!--[--><!--]--></main><!--]--></div><!----><!--]--></div>
13
+ <script src="/assets/js/runtime~app.47f4f812.js" defer></script><script src="/assets/js/619.8ba1b1f6.js" defer></script><script src="/assets/js/app.b705176c.js" defer></script>
14
14
  </body>
15
15
  </html>
@@ -4,12 +4,12 @@
4
4
  <meta charset="utf-8">
5
5
  <meta name="viewport" content="width=device-width,initial-scale=1">
6
6
  <meta name="generator" content="VuePress 2.0.0-beta.27">
7
- <link rel="icon" href="/euro.png"><title>ps-receive-price | Power Saver</title><meta name="description" content="A Node-RED note to save money on hourly changing power prices">
8
- <link rel="preload" href="/node-red-contrib-power-saver/assets/js/runtime~app.714a526c.js" as="script"><link rel="preload" href="/node-red-contrib-power-saver/assets/css/styles.e835bef6.css" as="style"><link rel="preload" href="/node-red-contrib-power-saver/assets/js/812.79dad458.js" as="script"><link rel="preload" href="/node-red-contrib-power-saver/assets/js/app.46f7644a.js" as="script">
9
- <link rel="stylesheet" href="/node-red-contrib-power-saver/assets/css/styles.e835bef6.css">
7
+ <link rel="shortcut icon" type="image/x-icon" href="euro.png"><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-9857859182772006" crossorigin="anonymous"></script><title>ps-receive-price | Power Saver</title><meta name="description" content="A Node-RED note to save money on hourly changing power prices">
8
+ <link rel="preload" href="/assets/js/runtime~app.47f4f812.js" as="script"><link rel="preload" href="/assets/css/styles.031dcf27.css" as="style"><link rel="preload" href="/assets/js/619.8ba1b1f6.js" as="script"><link rel="preload" href="/assets/js/app.b705176c.js" as="script">
9
+ <link rel="stylesheet" href="/assets/css/styles.031dcf27.css">
10
10
  </head>
11
11
  <body>
12
- <div id="app"><!--[--><div class="theme-container"><!--[--><header class="navbar"><div class="toggle-sidebar-button" title="toggle sidebar" aria-expanded="false" role="button" tabindex="0"><div class="icon" aria-hidden="true"><span></span><span></span><span></span></div></div><span><a href="/node-red-contrib-power-saver/" class=""><!----><span class="site-name">Power Saver</span></a></span><div class="navbar-links-wrapper" style=""><!--[--><!--]--><nav class="navbar-links can-hide"><!--[--><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><button class="toggle-dark-button" title="toggle dark mode"><svg style="" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M16 12.005a4 4 0 1 1-4 4a4.005 4.005 0 0 1 4-4m0-2a6 6 0 1 0 6 6a6 6 0 0 0-6-6z" fill="currentColor"></path><path d="M5.394 6.813l1.414-1.415l3.506 3.506L8.9 10.318z" fill="currentColor"></path><path d="M2 15.005h5v2H2z" fill="currentColor"></path><path d="M5.394 25.197L8.9 21.691l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 25.005h2v5h-2z" fill="currentColor"></path><path d="M21.687 23.106l1.414-1.415l3.506 3.506l-1.414 1.414z" fill="currentColor"></path><path d="M25 15.005h5v2h-5z" fill="currentColor"></path><path d="M21.687 8.904l3.506-3.506l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 2.005h2v5h-2z" fill="currentColor"></path></svg><svg style="display:none;" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M13.502 5.414a15.075 15.075 0 0 0 11.594 18.194a11.113 11.113 0 0 1-7.975 3.39c-.138 0-.278.005-.418 0a11.094 11.094 0 0 1-3.2-21.584M14.98 3a1.002 1.002 0 0 0-.175.016a13.096 13.096 0 0 0 1.825 25.981c.164.006.328 0 .49 0a13.072 13.072 0 0 0 10.703-5.555a1.01 1.01 0 0 0-.783-1.565A13.08 13.08 0 0 1 15.89 4.38A1.015 1.015 0 0 0 14.98 3z" fill="currentColor"></path></svg></button><!----></div></header><!--]--><div class="sidebar-mask"></div><!--[--><aside class="sidebar"><nav class="navbar-links"><!--[--><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><ul class="sidebar-links"><!--[--><!--[--><p class="sidebar-heading sidebar-item active">Nodes</p><ul class=""><li><!--[--><a href="/node-red-contrib-power-saver/nodes/power-saver.md" class="nav-link sidebar-item" aria-label="Power Saver"><!--[--><!--]--> Power Saver <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><p class="sidebar-item">Strategy nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html" class="nav-link sidebar-item" aria-label="ps-strategy-best-save"><!--[--><!--]--> ps-strategy-best-save <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-strategy-lowest-price.html" class="nav-link sidebar-item" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item active">Utility nodes</p><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-receive-price.html" class="router-link-active router-link-exact-active nav-link router-link-active sidebar-item active" aria-label="ps-receive-price"><!--[--><!--]--> ps-receive-price <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-receive-price.html#description" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Description"><!--[--><!--]--> Description <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-receive-price.html#configuration" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Configuration"><!--[--><!--]--> Configuration <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-receive-price.html#input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Input"><!--[--><!--]--> Input <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-receive-price.html#tibber-input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Tibber input"><!--[--><!--]--> Tibber input <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-receive-price.html#nord-pool-input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Nord Pool input"><!--[--><!--]--> Nord Pool input <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-receive-price.html#other-input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Other input"><!--[--><!--]--> Other input <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-receive-price.html#output" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output"><!--[--><!--]--> Output <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item">Grid tariff nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-general-add-tariff"><!--[--><!--]--> ps-general-add-tariff <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-elvia-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-elvia-add-tariff"><!--[--><!--]--> ps-elvia-add-tariff <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li></ul><!--]--><!--[--><p class="sidebar-heading sidebar-item">Data format</p><ul class=""><li><!--[--><a href="/node-red-contrib-power-saver/nodes/strategy-input.html" class="nav-link sidebar-item" aria-label="Strategy input format"><!--[--><!--]--> Strategy input format <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--><!--]--></ul><!--[--><!--]--></aside><!--]--><!--[--><main class="page"><!--[--><!--]--><div class="theme-default-content"><!--[--><h1 id="ps-receive-price" tabindex="-1"><a class="header-anchor" href="#ps-receive-price" aria-hidden="true">#</a> ps-receive-price</h1><p><img src="/node-red-contrib-power-saver/assets/img/node-ps-receive-price.76eaa418.png" alt="ps-receive-price"></p><h2 id="description" tabindex="-1"><a class="header-anchor" href="#description" aria-hidden="true">#</a> Description</h2><p>The <code>ps-receive-price</code> node is used to convert prices from Tibber or Nord Pool to the format used by the strategy nodes. It takes its input directly from the output of the following nodes (see details below):</p><ul><li><code>tibber-query</code> node from Tibber (<code>node-red-contrib-tibber-api</code>)</li><li><code>current state</code> node in Home Assistant</li><li><code>events: state</code> node in Home Assistant</li></ul><p>Output can be sent directly to the strategy nodes (for example <code>strategy-best-save</code> or <code>strategy-lowest-price</code>), or it can be sent via another node to add grid tariff or other additional costs before the calculation is done.</p><div class="custom-container warning"><p class="custom-container-title">Note</p><p>In version 2 of <code>node-red-contrib-power-saver</code>, prices were received directly by the Power Saver node. This made it hard to add grid tariff before the calculation was done. That is why this is now a separate node.</p></div><h2 id="configuration" tabindex="-1"><a class="header-anchor" href="#configuration" aria-hidden="true">#</a> Configuration</h2><p>There is no configuration except from node name.</p><h2 id="input" tabindex="-1"><a class="header-anchor" href="#input" aria-hidden="true">#</a> Input</h2><h3 id="tibber-input" tabindex="-1"><a class="header-anchor" href="#tibber-input" aria-hidden="true">#</a> Tibber input</h3><p>If you are a Tibber customer, you can use the <code>tibber-query</code> node from the <a href="https://flows.nodered.org/node/node-red-contrib-tibber-api" target="_blank" rel="noopener noreferrer"><code>node-red-contrib-tibber-api</code><span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>. Set it up with the following query:</p><div class="language-gql ext-gql line-numbers-mode"><pre class="language-gql"><code>{
12
+ <div id="app"><!--[--><div class="theme-container"><!--[--><header class="navbar"><div class="toggle-sidebar-button" title="toggle sidebar" aria-expanded="false" role="button" tabindex="0"><div class="icon" aria-hidden="true"><span></span><span></span><span></span></div></div><span><a href="/" class=""><!----><span class="site-name">Power Saver</span></a></span><div class="navbar-links-wrapper" style=""><!--[--><!--]--><nav class="navbar-links can-hide"><!--[--><div class="navbar-links-item"><a href="/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/faq/" class="nav-link" aria-label="FAQ"><!--[--><!--]--> FAQ <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><button class="toggle-dark-button" title="toggle dark mode"><svg style="" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M16 12.005a4 4 0 1 1-4 4a4.005 4.005 0 0 1 4-4m0-2a6 6 0 1 0 6 6a6 6 0 0 0-6-6z" fill="currentColor"></path><path d="M5.394 6.813l1.414-1.415l3.506 3.506L8.9 10.318z" fill="currentColor"></path><path d="M2 15.005h5v2H2z" fill="currentColor"></path><path d="M5.394 25.197L8.9 21.691l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 25.005h2v5h-2z" fill="currentColor"></path><path d="M21.687 23.106l1.414-1.415l3.506 3.506l-1.414 1.414z" fill="currentColor"></path><path d="M25 15.005h5v2h-5z" fill="currentColor"></path><path d="M21.687 8.904l3.506-3.506l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 2.005h2v5h-2z" fill="currentColor"></path></svg><svg style="display:none;" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M13.502 5.414a15.075 15.075 0 0 0 11.594 18.194a11.113 11.113 0 0 1-7.975 3.39c-.138 0-.278.005-.418 0a11.094 11.094 0 0 1-3.2-21.584M14.98 3a1.002 1.002 0 0 0-.175.016a13.096 13.096 0 0 0 1.825 25.981c.164.006.328 0 .49 0a13.072 13.072 0 0 0 10.703-5.555a1.01 1.01 0 0 0-.783-1.565A13.08 13.08 0 0 1 15.89 4.38A1.015 1.015 0 0 0 14.98 3z" fill="currentColor"></path></svg></button><!----></div></header><!--]--><div class="sidebar-mask"></div><!--[--><aside class="sidebar"><nav class="navbar-links"><!--[--><div class="navbar-links-item"><a href="/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/faq/" class="nav-link" aria-label="FAQ"><!--[--><!--]--> FAQ <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><ul class="sidebar-links"><!--[--><!--[--><p class="sidebar-heading sidebar-item active">Nodes</p><ul class=""><li><!--[--><a href="/nodes/power-saver.md" class="nav-link sidebar-item" aria-label="Power Saver"><!--[--><!--]--> Power Saver <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><p class="sidebar-item">Strategy nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/nodes/ps-strategy-best-save.html" class="nav-link sidebar-item" aria-label="ps-strategy-best-save"><!--[--><!--]--> ps-strategy-best-save <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a href="/nodes/ps-strategy-lowest-price.html" class="nav-link sidebar-item" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item active">Utility nodes</p><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-receive-price.html" class="router-link-active router-link-exact-active nav-link router-link-active sidebar-item active" aria-label="ps-receive-price"><!--[--><!--]--> ps-receive-price <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-receive-price.html#description" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Description"><!--[--><!--]--> Description <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-receive-price.html#configuration" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Configuration"><!--[--><!--]--> Configuration <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-receive-price.html#input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Input"><!--[--><!--]--> Input <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-receive-price.html#tibber-input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Tibber input"><!--[--><!--]--> Tibber input <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-receive-price.html#nord-pool-input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Nord Pool input"><!--[--><!--]--> Nord Pool input <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-receive-price.html#other-input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Other input"><!--[--><!--]--> Other input <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-receive-price.html#output" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output"><!--[--><!--]--> Output <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item">Grid tariff nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/nodes/ps-general-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-general-add-tariff"><!--[--><!--]--> ps-general-add-tariff <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a href="/nodes/ps-elvia-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-elvia-add-tariff"><!--[--><!--]--> ps-elvia-add-tariff <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li></ul><!--]--><!--[--><p class="sidebar-heading sidebar-item">Data format</p><ul class=""><li><!--[--><a href="/nodes/strategy-input.html" class="nav-link sidebar-item" aria-label="Strategy input format"><!--[--><!--]--> Strategy input format <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--><!--]--></ul><!--[--><!--]--></aside><!--]--><!--[--><main class="page"><!--[--><!--]--><div class="theme-default-content"><!--[--><h1 id="ps-receive-price" tabindex="-1"><a class="header-anchor" href="#ps-receive-price" aria-hidden="true">#</a> ps-receive-price</h1><p><img src="/assets/img/node-ps-receive-price.76eaa418.png" alt="ps-receive-price"></p><h2 id="description" tabindex="-1"><a class="header-anchor" href="#description" aria-hidden="true">#</a> Description</h2><p>The <code>ps-receive-price</code> node is used to convert prices from Tibber or Nord Pool to the format used by the strategy nodes. It takes its input directly from the output of the following nodes (see details below):</p><ul><li><code>tibber-query</code> node from Tibber (<code>node-red-contrib-tibber-api</code>)</li><li><code>current state</code> node in Home Assistant</li><li><code>events: state</code> node in Home Assistant</li></ul><p>Output can be sent directly to the strategy nodes (for example <code>strategy-best-save</code> or <code>strategy-lowest-price</code>), or it can be sent via another node to add grid tariff or other additional costs before the calculation is done.</p><div class="custom-container warning"><p class="custom-container-title">Note</p><p>In version 2 of <code>node-red-contrib-power-saver</code>, prices were received directly by the Power Saver node. This made it hard to add grid tariff before the calculation was done. That is why this is now a separate node.</p></div><h2 id="configuration" tabindex="-1"><a class="header-anchor" href="#configuration" aria-hidden="true">#</a> Configuration</h2><p>There is no configuration except from node name.</p><h2 id="input" tabindex="-1"><a class="header-anchor" href="#input" aria-hidden="true">#</a> Input</h2><h3 id="tibber-input" tabindex="-1"><a class="header-anchor" href="#tibber-input" aria-hidden="true">#</a> Tibber input</h3><p>If you are a Tibber customer, you can use the <code>tibber-query</code> node from the <a href="https://flows.nodered.org/node/node-red-contrib-tibber-api" target="_blank" rel="noopener noreferrer"><code>node-red-contrib-tibber-api</code><span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>. Set it up with the following query:</p><div class="language-gql ext-gql line-numbers-mode"><pre class="language-gql"><code>{
13
13
  viewer {
14
14
  homes {
15
15
  currentSubscription {
@@ -27,7 +27,7 @@
27
27
  }
28
28
  }
29
29
  }
30
- </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br><span class="line-number">15</span><br><span class="line-number">16</span><br><span class="line-number">17</span><br><span class="line-number">18</span><br></div></div><p>Send the result from the <code>tibber-query</code> node with the query above directly to the <code>ps-receive-price</code> node. Make sure it is refreshed when new prices are ready. Prices for the next day are normally ready at 13:00, but refreshing every hour can be a good idea.</p><p><a href="/node-red-contrib-power-saver/examples/example-tibber-mqtt.html" class="">See example with Tibber, a switch and MQTT</a></p><div class="custom-container danger"><p class="custom-container-title">Warning</p><p>The query above returns an array with all houses you have in your Tibber account. It will work only if the house you want is the first house in the array, for example if you have only one house. If that is not the case, you must use the query below.</p></div><p><strong>Tibber query for a specific house</strong></p><p>If the above query does not give you the house you want as the first in the result array, you can use the following method. In this method you need run one query in order to find the id of the house you want the prices for first, and then use the id in the real query.</p><p>Go to the <a href="https://developer.tibber.com/" target="_blank" rel="noopener noreferrer">Tibber Developer pages<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>, sign in, and go to the <a href="https://developer.tibber.com/explorer" target="_blank" rel="noopener noreferrer">API Explorer<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>. Load your personal token, then run the following query:</p><div class="language-gql ext-gql line-numbers-mode"><pre class="language-gql"><code>{
30
+ </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br><span class="line-number">15</span><br><span class="line-number">16</span><br><span class="line-number">17</span><br><span class="line-number">18</span><br></div></div><p>Send the result from the <code>tibber-query</code> node with the query above directly to the <code>ps-receive-price</code> node. Make sure it is refreshed when new prices are ready. Prices for the next day are normally ready at 13:00, but refreshing every hour can be a good idea.</p><p><a href="/examples/example-tibber-mqtt.html" class="">See example with Tibber, a switch and MQTT</a></p><div class="custom-container danger"><p class="custom-container-title">Warning</p><p>The query above returns an array with all houses you have in your Tibber account. It will work only if the house you want is the first house in the array, for example if you have only one house. If that is not the case, you must use the query below.</p></div><p><strong>Tibber query for a specific house</strong></p><p>If the above query does not give you the house you want as the first in the result array, you can use the following method. In this method you need run one query in order to find the id of the house you want the prices for first, and then use the id in the real query.</p><p>Go to the <a href="https://developer.tibber.com/" target="_blank" rel="noopener noreferrer">Tibber Developer pages<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>, sign in, and go to the <a href="https://developer.tibber.com/explorer" target="_blank" rel="noopener noreferrer">API Explorer<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>. Load your personal token, then run the following query:</p><div class="language-gql ext-gql line-numbers-mode"><pre class="language-gql"><code>{
31
31
  viewer {
32
32
  homes {
33
33
  id
@@ -62,7 +62,7 @@
62
62
  }
63
63
  }
64
64
  }
65
- </code></pre><div class="highlight-lines"><br><br><div class="highlight-line"> </div><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br></div><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br><span class="line-number">15</span><br><span class="line-number">16</span><br><span class="line-number">17</span><br><span class="line-number">18</span><br></div></div><p>This is the query you shall put in the <code>tibber-query</code> node.</p><h3 id="nord-pool-input" tabindex="-1"><a class="header-anchor" href="#nord-pool-input" aria-hidden="true">#</a> Nord Pool input</h3><p>This is especially designed to work for Home Assistant (HA), and the <a href="https://github.com/custom-components/nordpool" target="_blank" rel="noopener noreferrer">Nord Pool custom component<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>. The Nord Pool component provides a <em>sensor</em> that gives price per hour for today and tomorrow (after 13:00). Send the output from this sensor directly to the <code>ps-receive-price</code> node. Make sure this is done whenever the node is updated, as well as when the system starts up.</p><p>Data can be sent from both the <code>current state</code> node or the <code>events: state</code> node.</p><div class="custom-container tip"><p class="custom-container-title">Output properties</p><p>When using the <code>current state</code> node, configure the output properties to set <code>msg.payload</code> to <code>entity</code>.</p></div><p><a href="/node-red-contrib-power-saver/examples/example-nordpool-current-state.html" class="">See example with Nord Pool and <code>current state</code> node</a></p><p><a href="/node-red-contrib-power-saver/examples/example-nordpool-events-state.html" class="">See example with Nord Pool and <code>events: state</code> node</a></p><h3 id="other-input" tabindex="-1"><a class="header-anchor" href="#other-input" aria-hidden="true">#</a> Other input</h3><p>If you cannot use any of the two above (Tibber or Nord Pool), create the input to the node with the payload containing JSON like this:</p><div class="language-json ext-json line-numbers-mode"><pre class="language-json"><code><span class="token punctuation">{</span>
65
+ </code></pre><div class="highlight-lines"><br><br><div class="highlight-line"> </div><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br></div><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br><span class="line-number">15</span><br><span class="line-number">16</span><br><span class="line-number">17</span><br><span class="line-number">18</span><br></div></div><p>This is the query you shall put in the <code>tibber-query</code> node.</p><h3 id="nord-pool-input" tabindex="-1"><a class="header-anchor" href="#nord-pool-input" aria-hidden="true">#</a> Nord Pool input</h3><p>This is especially designed to work for Home Assistant (HA), and the <a href="https://github.com/custom-components/nordpool" target="_blank" rel="noopener noreferrer">Nord Pool custom component<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>. The Nord Pool component provides a <em>sensor</em> that gives price per hour for today and tomorrow (after 13:00). Send the output from this sensor directly to the <code>ps-receive-price</code> node. Make sure this is done whenever the node is updated, as well as when the system starts up.</p><p>Data can be sent from both the <code>current state</code> node or the <code>events: state</code> node.</p><div class="custom-container tip"><p class="custom-container-title">Output properties</p><p>When using the <code>current state</code> node, configure the output properties to set <code>msg.payload</code> to <code>entity</code>.</p></div><p><a href="/examples/example-nordpool-current-state.html" class="">See example with Nord Pool and <code>current state</code> node</a></p><p><a href="/examples/example-nordpool-events-state.html" class="">See example with Nord Pool and <code>events: state</code> node</a></p><h3 id="other-input" tabindex="-1"><a class="header-anchor" href="#other-input" aria-hidden="true">#</a> Other input</h3><p>If you cannot use any of the two above (Tibber or Nord Pool), create the input to the node with the payload containing JSON like this:</p><div class="language-json ext-json line-numbers-mode"><pre class="language-json"><code><span class="token punctuation">{</span>
66
66
  <span class="token property">&quot;today&quot;</span><span class="token operator">:</span> <span class="token punctuation">[</span>
67
67
  <span class="token punctuation">{</span> <span class="token property">&quot;value&quot;</span><span class="token operator">:</span> <span class="token number">1</span><span class="token punctuation">,</span> <span class="token property">&quot;start&quot;</span><span class="token operator">:</span> <span class="token string">&quot;2021-06-21T00:00:00+02:00&quot;</span> <span class="token punctuation">}</span><span class="token punctuation">,</span>
68
68
  <span class="token punctuation">{</span> <span class="token property">&quot;value&quot;</span><span class="token operator">:</span> <span class="token number">2</span><span class="token punctuation">,</span> <span class="token property">&quot;start&quot;</span><span class="token operator">:</span> <span class="token string">&quot;2021-06-21T01:00:00+02:00&quot;</span> <span class="token punctuation">}</span>
@@ -74,7 +74,7 @@
74
74
  <span class="token comment">//...</span>
75
75
  <span class="token punctuation">]</span>
76
76
  <span class="token punctuation">}</span>
77
- </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br></div></div><h2 id="output" tabindex="-1"><a class="header-anchor" href="#output" aria-hidden="true">#</a> Output</h2><p>The output is the <a href="/node-red-contrib-power-saver/nodes/strategy-input.html" class="">common strategy input format</a>, so it can be sent directly to the strategy nodes, or via any <code>ps-xxx-add-tariff</code> node.</p><!--]--></div><footer class="page-meta"><!----><div class="meta-item last-updated"><span class="meta-item-label">Last Updated: </span><span class="meta-item-info">12/20/2021, 10:10:18 PM</span></div><!----></footer><nav class="page-nav"><p class="inner"><span class="prev"> ← <a href="/node-red-contrib-power-saver/nodes/ps-strategy-lowest-price.html" class="nav-link" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a></span><!----></p></nav><!--[--><!--]--></main><!--]--></div><!----><!--]--></div>
78
- <script src="/node-red-contrib-power-saver/assets/js/runtime~app.714a526c.js" defer></script><script src="/node-red-contrib-power-saver/assets/js/812.79dad458.js" defer></script><script src="/node-red-contrib-power-saver/assets/js/app.46f7644a.js" defer></script>
77
+ </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br></div></div><h2 id="output" tabindex="-1"><a class="header-anchor" href="#output" aria-hidden="true">#</a> Output</h2><p>The output is the <a href="/nodes/strategy-input.html" class="">common strategy input format</a>, so it can be sent directly to the strategy nodes, or via any <code>ps-xxx-add-tariff</code> node.</p><!--]--></div><footer class="page-meta"><!----><div class="meta-item last-updated"><span class="meta-item-label">Last Updated: </span><span class="meta-item-info">12/20/2021, 10:10:18 PM</span></div><!----></footer><nav class="page-nav"><p class="inner"><span class="prev"> ← <a href="/nodes/ps-strategy-lowest-price.html" class="nav-link" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a></span><!----></p></nav><!--[--><!--]--></main><!--]--></div><!----><!--]--></div>
78
+ <script src="/assets/js/runtime~app.47f4f812.js" defer></script><script src="/assets/js/619.8ba1b1f6.js" defer></script><script src="/assets/js/app.b705176c.js" defer></script>
79
79
  </body>
80
80
  </html>
@@ -4,22 +4,31 @@
4
4
  <meta charset="utf-8">
5
5
  <meta name="viewport" content="width=device-width,initial-scale=1">
6
6
  <meta name="generator" content="VuePress 2.0.0-beta.27">
7
- <link rel="icon" href="/euro.png"><title>ps-strategy-best-save | Power Saver</title><meta name="description" content="A Node-RED note to save money on hourly changing power prices">
8
- <link rel="preload" href="/node-red-contrib-power-saver/assets/js/runtime~app.714a526c.js" as="script"><link rel="preload" href="/node-red-contrib-power-saver/assets/css/styles.e835bef6.css" as="style"><link rel="preload" href="/node-red-contrib-power-saver/assets/js/812.79dad458.js" as="script"><link rel="preload" href="/node-red-contrib-power-saver/assets/js/app.46f7644a.js" as="script">
9
- <link rel="stylesheet" href="/node-red-contrib-power-saver/assets/css/styles.e835bef6.css">
7
+ <link rel="shortcut icon" type="image/x-icon" href="euro.png"><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-9857859182772006" crossorigin="anonymous"></script><title>ps-strategy-best-save | Power Saver</title><meta name="description" content="A Node-RED note to save money on hourly changing power prices">
8
+ <link rel="preload" href="/assets/js/runtime~app.47f4f812.js" as="script"><link rel="preload" href="/assets/css/styles.031dcf27.css" as="style"><link rel="preload" href="/assets/js/619.8ba1b1f6.js" as="script"><link rel="preload" href="/assets/js/app.b705176c.js" as="script">
9
+ <link rel="stylesheet" href="/assets/css/styles.031dcf27.css">
10
10
  </head>
11
11
  <body>
12
- <div id="app"><!--[--><div class="theme-container"><!--[--><header class="navbar"><div class="toggle-sidebar-button" title="toggle sidebar" aria-expanded="false" role="button" tabindex="0"><div class="icon" aria-hidden="true"><span></span><span></span><span></span></div></div><span><a href="/node-red-contrib-power-saver/" class=""><!----><span class="site-name">Power Saver</span></a></span><div class="navbar-links-wrapper" style=""><!--[--><!--]--><nav class="navbar-links can-hide"><!--[--><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><button class="toggle-dark-button" title="toggle dark mode"><svg style="" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M16 12.005a4 4 0 1 1-4 4a4.005 4.005 0 0 1 4-4m0-2a6 6 0 1 0 6 6a6 6 0 0 0-6-6z" fill="currentColor"></path><path d="M5.394 6.813l1.414-1.415l3.506 3.506L8.9 10.318z" fill="currentColor"></path><path d="M2 15.005h5v2H2z" fill="currentColor"></path><path d="M5.394 25.197L8.9 21.691l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 25.005h2v5h-2z" fill="currentColor"></path><path d="M21.687 23.106l1.414-1.415l3.506 3.506l-1.414 1.414z" fill="currentColor"></path><path d="M25 15.005h5v2h-5z" fill="currentColor"></path><path d="M21.687 8.904l3.506-3.506l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 2.005h2v5h-2z" fill="currentColor"></path></svg><svg style="display:none;" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M13.502 5.414a15.075 15.075 0 0 0 11.594 18.194a11.113 11.113 0 0 1-7.975 3.39c-.138 0-.278.005-.418 0a11.094 11.094 0 0 1-3.2-21.584M14.98 3a1.002 1.002 0 0 0-.175.016a13.096 13.096 0 0 0 1.825 25.981c.164.006.328 0 .49 0a13.072 13.072 0 0 0 10.703-5.555a1.01 1.01 0 0 0-.783-1.565A13.08 13.08 0 0 1 15.89 4.38A1.015 1.015 0 0 0 14.98 3z" fill="currentColor"></path></svg></button><!----></div></header><!--]--><div class="sidebar-mask"></div><!--[--><aside class="sidebar"><nav class="navbar-links"><!--[--><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/node-red-contrib-power-saver/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><ul class="sidebar-links"><!--[--><!--[--><p class="sidebar-heading sidebar-item active">Nodes</p><ul class=""><li><!--[--><a href="/node-red-contrib-power-saver/nodes/power-saver.md" class="nav-link sidebar-item" aria-label="Power Saver"><!--[--><!--]--> Power Saver <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><p class="sidebar-item active">Strategy nodes</p><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html" class="router-link-active router-link-exact-active nav-link router-link-active sidebar-item active" aria-label="ps-strategy-best-save"><!--[--><!--]--> ps-strategy-best-save <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#description" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Description"><!--[--><!--]--> Description <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#configuration" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Configuration"><!--[--><!--]--> Configuration <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#dynamic-config" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Dynamic config"><!--[--><!--]--> Dynamic config <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Input"><!--[--><!--]--> Input <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#output" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output"><!--[--><!--]--> Output <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#output-1" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output 1"><!--[--><!--]--> Output 1 <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#output-2" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output 2"><!--[--><!--]--> Output 2 <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#output-3" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output 3"><!--[--><!--]--> Output 3 <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#algorithm" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Algorithm"><!--[--><!--]--> Algorithm <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/node-red-contrib-power-saver/nodes/ps-strategy-best-save.html#integration-with-magicmirror" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Integration with MagicMirror"><!--[--><!--]--> Integration with MagicMirror <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-strategy-lowest-price.html" class="nav-link sidebar-item" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item">Utility nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-receive-price.html" class="nav-link sidebar-item" aria-label="ps-receive-price"><!--[--><!--]--> ps-receive-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item">Grid tariff nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-general-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-general-add-tariff"><!--[--><!--]--> ps-general-add-tariff <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a href="/node-red-contrib-power-saver/nodes/ps-elvia-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-elvia-add-tariff"><!--[--><!--]--> ps-elvia-add-tariff <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li></ul><!--]--><!--[--><p class="sidebar-heading sidebar-item">Data format</p><ul class=""><li><!--[--><a href="/node-red-contrib-power-saver/nodes/strategy-input.html" class="nav-link sidebar-item" aria-label="Strategy input format"><!--[--><!--]--> Strategy input format <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--><!--]--></ul><!--[--><!--]--></aside><!--]--><!--[--><main class="page"><!--[--><!--]--><div class="theme-default-content"><!--[--><h1 id="ps-strategy-best-save" tabindex="-1"><a class="header-anchor" href="#ps-strategy-best-save" aria-hidden="true">#</a> ps-strategy-best-save</h1><p><img src="/node-red-contrib-power-saver/assets/img/node-ps-strategy-best-save.392292d5.png" alt="ps-strategy-best-save"></p><p>Strategy node to postpone power consumption until the price is lower.</p><h2 id="description" tabindex="-1"><a class="header-anchor" href="#description" aria-hidden="true">#</a> Description</h2><p>This strategy turns off the hours where the price difference is largest compared to the next hour that is on. The idea is that the power you are not using when the switch is turned off, will be used immediately when the switch is turned on. This would fit well for turning off a water heater or another thermostat controlled heater.</p><p>The picture at the bottom of the page, under <a href="#integration-with-magicmirror">Integration with MagicMirror</a>, illustrates this by the purple strokes, taking the price from the top of the price curve to the level of the first hour after the save-period.</p><h2 id="configuration" tabindex="-1"><a class="header-anchor" href="#configuration" aria-hidden="true">#</a> Configuration</h2><p><img src="/node-red-contrib-power-saver/assets/img/best-save-config.93fa3c21.png" alt="Best Save Config"></p><table><thead><tr><th>Value</th><th>Description</th></tr></thead><tbody><tr><td>Max per sequence</td><td>Maximum number of hours to turn off in a sequence.</td></tr><tr><td>Min recover</td><td>Minimum hours to turn on immediately after a period when turned off the maximum number of hours that is allowed to be turned off</td></tr><tr><td>Min saving</td><td>Minimum amount to save per kWh in order to bother turning it off. It is recommended to have some amount here, e.g. 2 cents / 2 øre. No point in saving 0.001, is it?</td></tr><tr><td>Schedule for</td><td>Select to schedule for the whole data set or only from the current hour.</td></tr><tr><td>Send when rescheduling</td><td>Check this to make sure on or off output is sent immediately after rescheduling</td></tr><tr><td>If no schedule, send</td><td>What to do if there is no valid schedule any more (turn on or off).</td></tr></tbody></table><div class="custom-container warning"><p class="custom-container-title">Min recover</p><p>NB! The <code>Min recover</code> only has effect if the previous save-period is of length <code>Max per sequence</code>. If the save-period is shorter, the following on-period may be as short as one hour.</p></div><div class="custom-container tip"><p class="custom-container-title">Legionella</p><p>Many people ask if there is a danger that legionella bacteria will grow and become dangerous when the temperature of the water heater is lowered. As long as the water is heated to at least 65 °C every day, or at least every week, the risk of infection is not considered significant, according to the norwegian <a href="https://www.fhi.no/nettpub/legionellaveilederen/" target="_blank" rel="noopener noreferrer">FHI<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>.</p></div><h3 id="dynamic-config" tabindex="-1"><a class="header-anchor" href="#dynamic-config" aria-hidden="true">#</a> Dynamic config</h3><p>It is possible to change config dynamically by sending a config message to the node. The config messages has a payload with a config object like this example:</p><div class="language-json ext-json line-numbers-mode"><pre class="language-json"><code><span class="token property">&quot;payload&quot;</span><span class="token operator">:</span> <span class="token punctuation">{</span>
12
+ <div id="app"><!--[--><div class="theme-container"><!--[--><header class="navbar"><div class="toggle-sidebar-button" title="toggle sidebar" aria-expanded="false" role="button" tabindex="0"><div class="icon" aria-hidden="true"><span></span><span></span><span></span></div></div><span><a href="/" class=""><!----><span class="site-name">Power Saver</span></a></span><div class="navbar-links-wrapper" style=""><!--[--><!--]--><nav class="navbar-links can-hide"><!--[--><div class="navbar-links-item"><a href="/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/faq/" class="nav-link" aria-label="FAQ"><!--[--><!--]--> FAQ <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><button class="toggle-dark-button" title="toggle dark mode"><svg style="" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M16 12.005a4 4 0 1 1-4 4a4.005 4.005 0 0 1 4-4m0-2a6 6 0 1 0 6 6a6 6 0 0 0-6-6z" fill="currentColor"></path><path d="M5.394 6.813l1.414-1.415l3.506 3.506L8.9 10.318z" fill="currentColor"></path><path d="M2 15.005h5v2H2z" fill="currentColor"></path><path d="M5.394 25.197L8.9 21.691l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 25.005h2v5h-2z" fill="currentColor"></path><path d="M21.687 23.106l1.414-1.415l3.506 3.506l-1.414 1.414z" fill="currentColor"></path><path d="M25 15.005h5v2h-5z" fill="currentColor"></path><path d="M21.687 8.904l3.506-3.506l1.414 1.415l-3.506 3.505z" fill="currentColor"></path><path d="M15 2.005h2v5h-2z" fill="currentColor"></path></svg><svg style="display:none;" class="icon" focusable="false" viewBox="0 0 32 32"><path d="M13.502 5.414a15.075 15.075 0 0 0 11.594 18.194a11.113 11.113 0 0 1-7.975 3.39c-.138 0-.278.005-.418 0a11.094 11.094 0 0 1-3.2-21.584M14.98 3a1.002 1.002 0 0 0-.175.016a13.096 13.096 0 0 0 1.825 25.981c.164.006.328 0 .49 0a13.072 13.072 0 0 0 10.703-5.555a1.01 1.01 0 0 0-.783-1.565A13.08 13.08 0 0 1 15.89 4.38A1.015 1.015 0 0 0 14.98 3z" fill="currentColor"></path></svg></button><!----></div></header><!--]--><div class="sidebar-mask"></div><!--[--><aside class="sidebar"><nav class="navbar-links"><!--[--><div class="navbar-links-item"><a href="/guide/" class="nav-link" aria-label="Guide"><!--[--><!--]--> Guide <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/nodes/" class="nav-link router-link-active" aria-label="Nodes"><!--[--><!--]--> Nodes <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/examples/" class="nav-link" aria-label="Examples"><!--[--><!--]--> Examples <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/faq/" class="nav-link" aria-label="FAQ"><!--[--><!--]--> FAQ <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/contribute/" class="nav-link" aria-label="Contribute"><!--[--><!--]--> Contribute <!--[--><!--]--></a></div><div class="navbar-links-item"><a href="/changelog/" class="nav-link" aria-label="Changes"><!--[--><!--]--> Changes <!--[--><!--]--></a></div><div class="navbar-links-item"><a class="nav-link external" href="https://github.com/ottopaulsen/node-red-contrib-power-saver" rel="noopener noreferrer" target="_blank" aria-label="GitHub"><!--[--><!--]--> GitHub <span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span><!--[--><!--]--></a></div><!--]--></nav><!--[--><!--]--><ul class="sidebar-links"><!--[--><!--[--><p class="sidebar-heading sidebar-item active">Nodes</p><ul class=""><li><!--[--><a href="/nodes/power-saver.md" class="nav-link sidebar-item" aria-label="Power Saver"><!--[--><!--]--> Power Saver <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><p class="sidebar-item active">Strategy nodes</p><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html" class="router-link-active router-link-exact-active nav-link router-link-active sidebar-item active" aria-label="ps-strategy-best-save"><!--[--><!--]--> ps-strategy-best-save <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#description" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Description"><!--[--><!--]--> Description <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#configuration" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Configuration"><!--[--><!--]--> Configuration <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#dynamic-config" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Dynamic config"><!--[--><!--]--> Dynamic config <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#dynamic-commands" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Dynamic commands"><!--[--><!--]--> Dynamic commands <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#input" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Input"><!--[--><!--]--> Input <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#output" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output"><!--[--><!--]--> Output <!--[--><!--]--></a><ul class="sidebar-sub-items"><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#output-1" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output 1"><!--[--><!--]--> Output 1 <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#output-2" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output 2"><!--[--><!--]--> Output 2 <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#output-3" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Output 3"><!--[--><!--]--> Output 3 <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#data-saved-in-context" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Data saved in context"><!--[--><!--]--> Data saved in context <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#algorithm" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Algorithm"><!--[--><!--]--> Algorithm <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#data-used-for-calculation" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Data used for calculation"><!--[--><!--]--> Data used for calculation <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#restarts" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Restarts"><!--[--><!--]--> Restarts <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#integration-with-magicmirror" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Integration with MagicMirror"><!--[--><!--]--> Integration with MagicMirror <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a aria-current="page" href="/nodes/ps-strategy-best-save.html#viewer" class="router-link-active router-link-exact-active nav-link sidebar-item" aria-label="Viewer"><!--[--><!--]--> Viewer <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><a href="/nodes/ps-strategy-lowest-price.html" class="nav-link sidebar-item" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item">Utility nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/nodes/ps-receive-price.html" class="nav-link sidebar-item" aria-label="ps-receive-price"><!--[--><!--]--> ps-receive-price <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li><li><!--[--><p class="sidebar-item">Grid tariff nodes</p><ul class="sidebar-sub-items"><li><!--[--><a href="/nodes/ps-general-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-general-add-tariff"><!--[--><!--]--> ps-general-add-tariff <!--[--><!--]--></a><!----><!--]--></li><li><!--[--><a href="/nodes/ps-elvia-add-tariff.html" class="nav-link sidebar-item" aria-label="ps-elvia-add-tariff"><!--[--><!--]--> ps-elvia-add-tariff <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--></li></ul><!--]--><!--[--><p class="sidebar-heading sidebar-item">Data format</p><ul class=""><li><!--[--><a href="/nodes/strategy-input.html" class="nav-link sidebar-item" aria-label="Strategy input format"><!--[--><!--]--> Strategy input format <!--[--><!--]--></a><!----><!--]--></li></ul><!--]--><!--]--></ul><!--[--><!--]--></aside><!--]--><!--[--><main class="page"><!--[--><!--]--><div class="theme-default-content"><!--[--><h1 id="ps-strategy-best-save" tabindex="-1"><a class="header-anchor" href="#ps-strategy-best-save" aria-hidden="true">#</a> ps-strategy-best-save</h1><p><img src="/assets/img/node-ps-strategy-best-save.392292d5.png" alt="ps-strategy-best-save"></p><p>Strategy node to postpone power consumption until the price is lower.</p><h2 id="description" tabindex="-1"><a class="header-anchor" href="#description" aria-hidden="true">#</a> Description</h2><p>This strategy turns off the hours where the price difference is largest compared to the next hour that is on. The idea is that the power you are not using when the switch is turned off, will be used immediately when the switch is turned on. This would fit well for turning off a water heater or another thermostat controlled heater.</p><p>The picture at the bottom of the page, under <a href="#integration-with-magicmirror">Integration with MagicMirror</a>, illustrates this by the purple strokes, taking the price from the top of the price curve to the level of the first hour after the save-period.</p><h2 id="configuration" tabindex="-1"><a class="header-anchor" href="#configuration" aria-hidden="true">#</a> Configuration</h2><p><img src="/assets/img/best-save-config.79a2f39a.png" alt="Best Save Config"></p><table><thead><tr><th>Value</th><th>Description</th></tr></thead><tbody><tr><td>Max per sequence</td><td>Maximum number of hours to turn off in a sequence.</td></tr><tr><td>Min recover</td><td>Minimum hours to turn on immediately after a period when turned off the maximum number of hours that is allowed to be turned off</td></tr><tr><td>Min saving</td><td>Minimum amount to save per kWh in order to bother turning it off. It is recommended to have some amount here, e.g. 2 cents / 2 øre. No point in saving 0.001, is it?</td></tr><tr><td>Send when rescheduling</td><td>Check this to make sure on or off output is sent immediately after rescheduling</td></tr><tr><td>If no schedule, send</td><td>What to do if there is no valid schedule any more (turn on or off).</td></tr></tbody></table><div class="custom-container warning"><p class="custom-container-title">Min recover</p><p>NB! The <code>Min recover</code> only has effect if the previous save-period is of length <code>Max per sequence</code>. If the save-period is shorter, the following on-period may be as short as one hour.</p></div><h3 id="dynamic-config" tabindex="-1"><a class="header-anchor" href="#dynamic-config" aria-hidden="true">#</a> Dynamic config</h3><p>It is possible to change config dynamically by sending a config message to the node. The config messages has a payload with a config object like this example:</p><div class="language-json ext-json line-numbers-mode"><pre class="language-json"><code><span class="token property">&quot;payload&quot;</span><span class="token operator">:</span> <span class="token punctuation">{</span>
13
13
  <span class="token property">&quot;config&quot;</span><span class="token operator">:</span> <span class="token punctuation">{</span>
14
14
  <span class="token property">&quot;maxHoursToSaveInSequence&quot;</span><span class="token operator">:</span> <span class="token number">4</span><span class="token punctuation">,</span>
15
15
  <span class="token property">&quot;minHoursOnAfterMaxSequenceSaved&quot;</span><span class="token operator">:</span> <span class="token number">2</span><span class="token punctuation">,</span>
16
16
  <span class="token property">&quot;minSaving&quot;</span><span class="token operator">:</span> <span class="token number">0.02</span><span class="token punctuation">,</span>
17
17
  <span class="token property">&quot;sendCurrentValueWhenRescheduling&quot;</span><span class="token operator">:</span> <span class="token boolean">true</span><span class="token punctuation">,</span>
18
18
  <span class="token property">&quot;outputIfNoSchedule&quot;</span><span class="token operator">:</span> <span class="token boolean">true</span><span class="token punctuation">,</span>
19
- <span class="token property">&quot;scheduleOnlyFromCurrentTime&quot;</span><span class="token operator">:</span> <span class="token boolean">false</span>
20
19
  <span class="token punctuation">}</span>
21
20
  <span class="token punctuation">}</span>
22
- </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br></div></div><p>All the variables in the config object are optional. You can send only those you want to change.</p><p>The config sent like this will be valid until a new config is sent the same way, or until the flow is restarted. On a restart, the original config set up in the node will be used.</p><p>When a config is sent like this, and without price data, the schedule will be replanned based on the last previously received price data. If no price data has been received, no scheduling is done.</p><p>However, you can send config and price data in the same message. Then both will be used .</p><h2 id="input" tabindex="-1"><a class="header-anchor" href="#input" aria-hidden="true">#</a> Input</h2><p>The input is the <a href="/node-red-contrib-power-saver/nodes/strategy-input.html" class="">common strategy input format</a></p><h2 id="output" tabindex="-1"><a class="header-anchor" href="#output" aria-hidden="true">#</a> Output</h2><p>There are three outputs. You use only those you need for your purpose.</p><h3 id="output-1" tabindex="-1"><a class="header-anchor" href="#output-1" aria-hidden="true">#</a> Output 1</h3><p>A payload with the word <code>true</code> is sent to output 1 whenever the power / switch shall be turned on.</p><h3 id="output-2" tabindex="-1"><a class="header-anchor" href="#output-2" aria-hidden="true">#</a> Output 2</h3><p>A payload with the word <code>false</code> is sent to output 2 whenever the power / switch shall be turned off.</p><h3 id="output-3" tabindex="-1"><a class="header-anchor" href="#output-3" aria-hidden="true">#</a> Output 3</h3><p>When a valid input is received, and the schedule is recalculated, the resulting schedule, as well as some other information, is sent to output 3. You can use this to see the plan and verify that it meets your expectations. You can also use it to display the schedule in any way you like.</p><p>Example of output:</p><div class="language-json ext-json line-numbers-mode"><pre class="language-json"><code><span class="token punctuation">{</span>
21
+ </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br></div></div><p>All the variables in the config object are optional. You can send only those you want to change.</p><p>The config sent like this will be valid until a new config is sent the same way, or until the flow is restarted. On a restart, the original config set up in the node will be used.</p><p>When a config is sent like this, and without price data, the schedule will be replanned based on the last previously received price data. If no price data has been received, no scheduling is done.</p><p>However, you can send config and price data in the same message. Then both will be used.</p><h3 id="dynamic-commands" tabindex="-1"><a class="header-anchor" href="#dynamic-commands" aria-hidden="true">#</a> Dynamic commands</h3><p>You can dynamically send some commands to the node via its input, by using a <code>commands</code> object in the payload as described below.</p><p>Commands can be sent together with config and/or price data, but the exact behavior is not defined.</p><h4 id="sendschedule" tabindex="-1"><a class="header-anchor" href="#sendschedule" aria-hidden="true">#</a> sendSchedule</h4><p>You can get the schedule sent to output 3 any time by sending a message like this to the node:</p><div class="language-json ext-json line-numbers-mode"><pre class="language-json"><code><span class="token property">&quot;payload&quot;</span><span class="token operator">:</span> <span class="token punctuation">{</span>
22
+ <span class="token property">&quot;commands&quot;</span><span class="token operator">:</span> <span class="token punctuation">{</span>
23
+ <span class="token property">&quot;sendSchedule&quot;</span><span class="token operator">:</span> <span class="token boolean">true</span><span class="token punctuation">,</span>
24
+ <span class="token punctuation">}</span>
25
+ <span class="token punctuation">}</span>
26
+ </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><p>When you do this, the current schedule is actually recalculated based on the last received data, and then sent to output 3 the same way as when it was originally planned.</p><h4 id="reset" tabindex="-1"><a class="header-anchor" href="#reset" aria-hidden="true">#</a> reset</h4><p>You can reset data the node has saved in context by sending this message:</p><div class="language-json ext-json line-numbers-mode"><pre class="language-json"><code><span class="token property">&quot;payload&quot;</span><span class="token operator">:</span> <span class="token punctuation">{</span>
27
+ <span class="token property">&quot;commands&quot;</span><span class="token operator">:</span> <span class="token punctuation">{</span>
28
+ <span class="token property">&quot;reset&quot;</span><span class="token operator">:</span> <span class="token boolean">true</span><span class="token punctuation">,</span>
29
+ <span class="token punctuation">}</span>
30
+ <span class="token punctuation">}</span>
31
+ </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><p>When you do this, all historical data the node has saved is deleted, including the current schedule, so the result will be that the node shows status &quot;No price data&quot;. When new price data is received, a schedule is calculated without considering any history.</p><p>The nodes config is not deleted, as the node depends on it to work.</p><div class="custom-container warning"><p class="custom-container-title">WARNING</p><p>This operation cannot be undone.</p><p>However, it is normally not a big loss, as you can just feed the node with new price data and start from scratch.</p></div><h2 id="input" tabindex="-1"><a class="header-anchor" href="#input" aria-hidden="true">#</a> Input</h2><p>The input is the <a href="/nodes/strategy-input.html" class="">common strategy input format</a>.</p><p>In addition to the prices sent as input, the node is using the schedule for the day before it receives data for, so that it can calculate the schedule in the beginning of the day according to the configured rules. This requires of course that the node was run the day before.</p><h2 id="output" tabindex="-1"><a class="header-anchor" href="#output" aria-hidden="true">#</a> Output</h2><p>There are three outputs. You use only those you need for your purpose.</p><h3 id="output-1" tabindex="-1"><a class="header-anchor" href="#output-1" aria-hidden="true">#</a> Output 1</h3><p>A payload with the word <code>true</code> is sent to output 1 whenever the power / switch shall be turned on.</p><h3 id="output-2" tabindex="-1"><a class="header-anchor" href="#output-2" aria-hidden="true">#</a> Output 2</h3><p>A payload with the word <code>false</code> is sent to output 2 whenever the power / switch shall be turned off.</p><h3 id="output-3" tabindex="-1"><a class="header-anchor" href="#output-3" aria-hidden="true">#</a> Output 3</h3><p>When a valid input is received, and the schedule is recalculated, the resulting schedule, as well as some other information, is sent to output 3. You can use this to see the plan and verify that it meets your expectations. You can also use it to display the schedule in any way you like.</p><p>Example of output:</p><div class="language-json ext-json line-numbers-mode"><pre class="language-json"><code><span class="token punctuation">{</span>
23
32
  <span class="token property">&quot;schedule&quot;</span><span class="token operator">:</span> <span class="token punctuation">[</span>
24
33
  <span class="token punctuation">{</span>
25
34
  <span class="token property">&quot;time&quot;</span><span class="token operator">:</span> <span class="token string">&quot;2021-09-30T00:00:00.000+02:00&quot;</span><span class="token punctuation">,</span>
@@ -61,7 +70,12 @@
61
70
  <span class="token property">&quot;time&quot;</span><span class="token operator">:</span> <span class="token string">&quot;2021-09-30T23:45:12.123+02:00&quot;</span><span class="token punctuation">,</span>
62
71
  <span class="token property">&quot;version&quot;</span><span class="token operator">:</span> <span class="token string">&quot;3.1.2&quot;</span>
63
72
  <span class="token punctuation">}</span>
64
- </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br><span class="line-number">15</span><br><span class="line-number">16</span><br><span class="line-number">17</span><br><span class="line-number">18</span><br><span class="line-number">19</span><br><span class="line-number">20</span><br><span class="line-number">21</span><br><span class="line-number">22</span><br><span class="line-number">23</span><br><span class="line-number">24</span><br><span class="line-number">25</span><br><span class="line-number">26</span><br><span class="line-number">27</span><br><span class="line-number">28</span><br><span class="line-number">29</span><br><span class="line-number">30</span><br><span class="line-number">31</span><br><span class="line-number">32</span><br><span class="line-number">33</span><br><span class="line-number">34</span><br><span class="line-number">35</span><br><span class="line-number">36</span><br><span class="line-number">37</span><br><span class="line-number">38</span><br><span class="line-number">39</span><br><span class="line-number">40</span><br><span class="line-number">41</span><br><span class="line-number">42</span><br></div></div><p>The <code>schedule</code> array shows every time the switch is turned on or off. The <code>hours</code> array shows values per hour containing the price (received as input), whether that hour is on or off, the start time of the hour and the amount per kWh that is saved on hours that are turned off, compared to the next hour that is on.</p><h2 id="algorithm" tabindex="-1"><a class="header-anchor" href="#algorithm" aria-hidden="true">#</a> Algorithm</h2><p>The calculation that decides what hours to turn off works as follows:</p><ol><li>A matrix (x * y) is created where x is the number of hours we have price information for, and y is the configured maximum number of hours to turn off in a sequence.</li><li>The matrix is filled with how much you save by turning off hour x for y hours.</li><li>The matrix is processed calculating all possibilities for turning off a number of hours in a sequence and by that saving money. In this process all non-saving sequences are discarded. Also, if the average saving per hour is less than what you have configured as minimum amount to save per kWh, the sequence is discarded.</li><li>The remaining sequences are sorted by how much that is saved, in descending order.</li><li>Next, a table with one value per hour is created, with all hours in state &quot;on&quot;.</li><li>Then the saving sequences is applied one by one, turning off the hours in each sequence, discarding sequences that lead to any violation of the rules set by the config.</li><li>When all sequences are processed, the resulting table shows a pretty good savings plan, that in most cases would be the optimal plan.</li></ol><p>I say &quot;in most cases&quot;, because there is a chance that a group of two or more sequences combined can give a better plan than a single sequence preceeding those two, but where the selection of the one sequence causes the group to be discarded. If anyone encounters this situation, I would be happy to receive the price data set, and try to improve the algorithm even further.</p><h2 id="integration-with-magicmirror" tabindex="-1"><a class="header-anchor" href="#integration-with-magicmirror" aria-hidden="true">#</a> Integration with MagicMirror</h2><p>Are you using <a href="https://magicmirror.builders/" target="_blank" rel="noopener noreferrer">MagicMirror<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>? Are you also using <a href="https://tibber.com/" target="_blank" rel="noopener noreferrer">Tibber<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>? If so, there is a module for MM called <a href="https://github.com/ottopaulsen/MMM-Tibber" target="_blank" rel="noopener noreferrer">MMM-Tibber<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>, that easily can be used to show savings from this node.</p><p><img src="https://github.com/ottopaulsen/MMM-Tibber/blob/master/doc/MMM-Tibber-screenshot-savings-graph.png?raw=true" alt="Show savings in MMM-Tibber"></p><p>The purple lines show savings per kWh.</p><p>Read more about this in the <a href="https://github.com/ottopaulsen/MMM-Tibber#show-savings" target="_blank" rel="noopener noreferrer">MMM-Tibber documentation<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>.</p><!--]--></div><footer class="page-meta"><!----><div class="meta-item last-updated"><span class="meta-item-label">Last Updated: </span><span class="meta-item-info">1/7/2022, 9:09:31 PM</span></div><!----></footer><nav class="page-nav"><p class="inner"><!----><span class="next"><a href="/node-red-contrib-power-saver/nodes/ps-strategy-lowest-price.html" class="nav-link" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a></span></p></nav><!--[--><!--]--></main><!--]--></div><!----><!--]--></div>
65
- <script src="/node-red-contrib-power-saver/assets/js/runtime~app.714a526c.js" defer></script><script src="/node-red-contrib-power-saver/assets/js/812.79dad458.js" defer></script><script src="/node-red-contrib-power-saver/assets/js/app.46f7644a.js" defer></script>
73
+ </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br><span class="line-number">15</span><br><span class="line-number">16</span><br><span class="line-number">17</span><br><span class="line-number">18</span><br><span class="line-number">19</span><br><span class="line-number">20</span><br><span class="line-number">21</span><br><span class="line-number">22</span><br><span class="line-number">23</span><br><span class="line-number">24</span><br><span class="line-number">25</span><br><span class="line-number">26</span><br><span class="line-number">27</span><br><span class="line-number">28</span><br><span class="line-number">29</span><br><span class="line-number">30</span><br><span class="line-number">31</span><br><span class="line-number">32</span><br><span class="line-number">33</span><br><span class="line-number">34</span><br><span class="line-number">35</span><br><span class="line-number">36</span><br><span class="line-number">37</span><br><span class="line-number">38</span><br><span class="line-number">39</span><br><span class="line-number">40</span><br><span class="line-number">41</span><br><span class="line-number">42</span><br></div></div><p>The <code>schedule</code> array shows every time the switch is turned on or off. The <code>hours</code> array shows values per hour containing the price (received as input), whether that hour is on or off, the start time of the hour and the amount per kWh that is saved on hours that are turned off, compared to the next hour that is on.</p><h3 id="data-saved-in-context" tabindex="-1"><a class="header-anchor" href="#data-saved-in-context" aria-hidden="true">#</a> Data saved in context</h3><p>The node saves some data in the nodes context, so that it can be used on restarts and also taken into consideration when calculating the schedule over midnight.</p><p>You can see the saved data if you select the node in Node-RED, and view &quot;Context data&quot;, and refresh the Node context.</p><h2 id="algorithm" tabindex="-1"><a class="header-anchor" href="#algorithm" aria-hidden="true">#</a> Algorithm</h2><p>The calculation that decides what hours to turn off works as follows:</p><ol><li>A matrix (x * y) is created where x is the number of hours we have price information for, and y is the configured maximum number of hours to turn off in a sequence.</li><li>The matrix is filled with how much you save by turning off hour x for y hours.</li><li>The matrix is processed calculating all possibilities for turning off a number of hours in a sequence and by that saving money. In this process all non-saving sequences are discarded. Also, if the average saving per hour is less than what you have configured as minimum amount to save per kWh, the sequence is discarded.</li><li>The remaining sequences are sorted by how much that is saved, in descending order.</li><li>Next, a table with one value per hour is created, with all hours in state &quot;on&quot;.</li><li>Then the saving sequences is applied one by one, turning off the hours in each sequence, discarding sequences that lead to any violation of the rules set by the config.</li><li>When all sequences are processed, the resulting table shows a pretty good savings plan, that in most cases would be the optimal plan.</li></ol><p>I say &quot;in most cases&quot;, because there is a chance that a group of two or more sequences combined can give a better plan than a single sequence preceeding those two, but where the selection of the one sequence causes the group to be discarded. If anyone encounters this situation, I would be happy to receive the price data set, and try to improve the algorithm even further.</p><h2 id="data-used-for-calculation" tabindex="-1"><a class="header-anchor" href="#data-used-for-calculation" aria-hidden="true">#</a> Data used for calculation</h2><p>Normally data is received for one or two whole days, and all this data is used to do the calculation. In addition, if the node has run before, so there is historical data, the last period on or off before the period data is received for, is considered in the calculation, so that the rules in the configuration are followed also between days.</p><h2 id="restarts" tabindex="-1"><a class="header-anchor" href="#restarts" aria-hidden="true">#</a> Restarts</h2><p>The node saves data in the nodes context, so if Node-RED is configured to save context between restarts, the node will replan with the last received data when it restarts.</p><div class="custom-container warning"><p class="custom-container-title">WARNING</p><p>In Home Assistant, Node-RED is by default configured to save context between restarts. However, if you run Node-RED another way, this may not be the case by default. If context is only stored in memory, it is lost between restarts, and even between re-deployments. This can be changed in the <code>settings.js</code> file for Node-RED like this:</p><div class="language-javascript ext-js line-numbers-mode"><pre class="language-javascript"><code>contextStorage<span class="token operator">:</span> <span class="token punctuation">{</span>
74
+ <span class="token keyword">default</span><span class="token operator">:</span> <span class="token punctuation">{</span>
75
+ module<span class="token operator">:</span> <span class="token string">&quot;localfilesystem&quot;</span>
76
+ <span class="token punctuation">}</span>
77
+ <span class="token punctuation">}</span>
78
+ </code></pre><div class="line-numbers"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><p>Please read the <a href="https://nodered.org/docs/user-guide/context" target="_blank" rel="noopener noreferrer">Node-RED documentation<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a> for more details about this.</p></div><h2 id="integration-with-magicmirror" tabindex="-1"><a class="header-anchor" href="#integration-with-magicmirror" aria-hidden="true">#</a> Integration with MagicMirror</h2><p>Are you using <a href="https://magicmirror.builders/" target="_blank" rel="noopener noreferrer">MagicMirror<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>? Are you also using <a href="https://tibber.com/" target="_blank" rel="noopener noreferrer">Tibber<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>? If so, there is a module for MM called <a href="https://github.com/ottopaulsen/MMM-Tibber" target="_blank" rel="noopener noreferrer">MMM-Tibber<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>, that easily can be used to show savings from this node.</p><p><img src="https://github.com/ottopaulsen/MMM-Tibber/blob/master/doc/MMM-Tibber-screenshot-savings-graph.png?raw=true" alt="Show savings in MMM-Tibber"></p><p>The purple lines show savings per kWh.</p><p>Read more about this in the <a href="https://github.com/ottopaulsen/MMM-Tibber#show-savings" target="_blank" rel="noopener noreferrer">MMM-Tibber documentation<span><svg class="icon outbound" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewbox="0 0 100 100" width="15" height="15"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path><polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg><!--[--><span class="sr-only">open in new window</span><!--]--></span></a>.</p><h2 id="viewer" tabindex="-1"><a class="header-anchor" href="#viewer" aria-hidden="true">#</a> Viewer</h2><p>If you like to analyze the data output by the node, take a look at the <a href="/faq/best-save-viewer.html" class="">Best Save Viewer</a>.</p><!--]--></div><footer class="page-meta"><!----><div class="meta-item last-updated"><span class="meta-item-label">Last Updated: </span><span class="meta-item-info">1/18/2022, 8:52:35 PM</span></div><!----></footer><nav class="page-nav"><p class="inner"><!----><span class="next"><a href="/nodes/ps-strategy-lowest-price.html" class="nav-link" aria-label="ps-strategy-lowest-price"><!--[--><!--]--> ps-strategy-lowest-price <!--[--><!--]--></a> → </span></p></nav><!--[--><!--]--></main><!--]--></div><!----><!--]--></div>
79
+ <script src="/assets/js/runtime~app.47f4f812.js" defer></script><script src="/assets/js/619.8ba1b1f6.js" defer></script><script src="/assets/js/app.b705176c.js" defer></script>
66
80
  </body>
67
81
  </html>