ottopaulsen / node-red-contrib-power-saver

A Node-RED node to saver money by turning off when the power is most expensive
Other
71 stars 17 forks source link

Turning off when cheap #84

Closed niklasgisselman closed 1 year ago

niklasgisselman commented 1 year ago

Hi!

First, thanks a lot for your effort on this. Really great job!!

During some nights the Best saver disables the output for some cheap hous. See the code below at 20220911 02:00 as an example.

My settings are 8 hours max per sequence 4 hours min recover and min save 0,01€.

I'm controlling a water heater and ventilation fan with one plug, and would like the plug to turn on during the cheapest hours and start the heating, then let it run the ventilation as long as it's cheap. Also heat water once during daytime.

Attribut
Schedule
- time: '2022-09-10T00:00:00.000+02:00'
value: false
countHours: 6
- time: '2022-09-10T06:00:00.000+02:00'
value: true
countHours: 9
- time: '2022-09-10T15:00:00.000+02:00'
value: false
countHours: 8
- time: '2022-09-10T23:00:00.000+02:00'
value: true
countHours: 4
- time: '2022-09-11T03:00:00.000+02:00'
value: false
countHours: 1
- time: '2022-09-11T04:00:00.000+02:00'
value: true
countHours: 3
- time: '2022-09-11T07:00:00.000+02:00'
value: false
countHours: 7
- time: '2022-09-11T14:00:00.000+02:00'
value: true
countHours: 3
- time: '2022-09-11T17:00:00.000+02:00'
value: false
countHours: 6
- time: '2022-09-11T23:00:00.000+02:00'
value: true
countHours: 1
Hours
- price: 1.2851
onOff: '0'
start: '2022-09-10T00:00:00.000+02:00'
saving: 0.0763
- price: 1.2748
onOff: '0'
start: '2022-09-10T01:00:00.000+02:00'
saving: 0.066
- price: 1.2867
onOff: '0'
start: '2022-09-10T02:00:00.000+02:00'
saving: 0.0779
- price: 1.3141
onOff: '0'
start: '2022-09-10T03:00:00.000+02:00'
saving: 0.1053
- price: 1.3383
onOff: '0'
start: '2022-09-10T04:00:00.000+02:00'
saving: 0.1295
- price: 1.3874
onOff: '0'
start: '2022-09-10T05:00:00.000+02:00'
saving: 0.1786
- price: 1.2088
onOff: '1'
start: '2022-09-10T06:00:00.000+02:00'
saving: null
- price: 1.4152
onOff: '1'
start: '2022-09-10T07:00:00.000+02:00'
saving: null
- price: 2.6117
onOff: '1'
start: '2022-09-10T08:00:00.000+02:00'
saving: null
- price: 3.2653
onOff: '1'
start: '2022-09-10T09:00:00.000+02:00'
saving: null
- price: 3.5252
onOff: '1'
start: '2022-09-10T10:00:00.000+02:00'
saving: null
- price: 3.6865
onOff: '1'
start: '2022-09-10T11:00:00.000+02:00'
saving: null
- price: 3.796
onOff: '1'
start: '2022-09-10T12:00:00.000+02:00'
saving: null
- price: 3.7967
onOff: '1'
start: '2022-09-10T13:00:00.000+02:00'
saving: null
- price: 3.7967
onOff: '1'
start: '2022-09-10T14:00:00.000+02:00'
saving: null
- price: 4.0556
onOff: '0'
start: '2022-09-10T15:00:00.000+02:00'
saving: 1.2556
- price: 3.9302
onOff: '0'
start: '2022-09-10T16:00:00.000+02:00'
saving: 1.1302
- price: 4.5522
onOff: '0'
start: '2022-09-10T17:00:00.000+02:00'
saving: 1.7522
- price: 4.7272
onOff: '0'
start: '2022-09-10T18:00:00.000+02:00'
saving: 1.9272
- price: 4.727
onOff: '0'
start: '2022-09-10T19:00:00.000+02:00'
saving: 1.927
- price: 4.8493
onOff: '0'
start: '2022-09-10T20:00:00.000+02:00'
saving: 2.0493
- price: 4.4987
onOff: '0'
start: '2022-09-10T21:00:00.000+02:00'
saving: 1.6987
- price: 3.861
onOff: '0'
start: '2022-09-10T22:00:00.000+02:00'
saving: 1.061
- price: 2.8
onOff: '1'
start: '2022-09-10T23:00:00.000+02:00'
saving: null
- price: 5.295
onOff: '1'
start: '2022-09-11T00:00:00.000+02:00'
saving: null
- price: 3.5624
onOff: '1'
start: '2022-09-11T01:00:00.000+02:00'
saving: null
- price: 3.4342
onOff: '1'
start: '2022-09-11T02:00:00.000+02:00'
saving: null
- price: 3.3565
onOff: '0'
start: '2022-09-11T03:00:00.000+02:00'
saving: 0.107
- price: 3.2495
onOff: '1'
start: '2022-09-11T04:00:00.000+02:00'
saving: null
- price: 3.2561
onOff: '1'
start: '2022-09-11T05:00:00.000+02:00'
saving: null
- price: 3.4296
onOff: '1'
start: '2022-09-11T06:00:00.000+02:00'
saving: null
- price: 4.2516
onOff: '0'
start: '2022-09-11T07:00:00.000+02:00'
saving: 0.8059
- price: 5.3291
onOff: '0'
start: '2022-09-11T08:00:00.000+02:00'
saving: 1.8834
- price: 5.3291
onOff: '0'
start: '2022-09-11T09:00:00.000+02:00'
saving: 1.8834
- price: 5.1511
onOff: '0'
start: '2022-09-11T10:00:00.000+02:00'
saving: 1.7054
- price: 5.0405
onOff: '0'
start: '2022-09-11T11:00:00.000+02:00'
saving: 1.5948
- price: 4.7786
onOff: '0'
start: '2022-09-11T12:00:00.000+02:00'
saving: 1.3329
- price: 3.9292
onOff: '0'
start: '2022-09-11T13:00:00.000+02:00'
saving: 0.4835
- price: 3.4457
onOff: '1'
start: '2022-09-11T14:00:00.000+02:00'
saving: null
- price: 3.9554
onOff: '1'
start: '2022-09-11T15:00:00.000+02:00'
saving: null
- price: 4.5577
onOff: '1'
start: '2022-09-11T16:00:00.000+02:00'
saving: null
- price: 5.4876
onOff: '0'
start: '2022-09-11T17:00:00.000+02:00'
saving: 0.1863
- price: 6.233
onOff: '0'
start: '2022-09-11T18:00:00.000+02:00'
saving: 0.9317
- price: 6.6856
onOff: '0'
start: '2022-09-11T19:00:00.000+02:00'
saving: 1.3843
- price: 6.8352
onOff: '0'
start: '2022-09-11T20:00:00.000+02:00'
saving: 1.5339
- price: 6.4112
onOff: '0'
start: '2022-09-11T21:00:00.000+02:00'
saving: 1.1099
- price: 5.9711
onOff: '0'
start: '2022-09-11T22:00:00.000+02:00'
saving: 0.6698
- price: 5.3013
onOff: '1'
start: '2022-09-11T23:00:00.000+02:00'
saving: null
Control
payload.hours[0].onOff
Current
payload.current
ottopaulsen commented 1 year ago

For me being able to look at your result, I need the complete output on output 3 from the Best Save node. However, from what you write, maybe you should consider the Lowest Price node instead.