With the Ausgrid two-way trial tariff some considerations required:
Quote
There are some considerations to keep in mind when looking to make the most of this tariff.
There is a 26.58 c/kWh (excl. GST) network charge for buying power from the grid between 2-8PM on top of the wholesale price of energy.
We do not expect this to significantly impact most Amber battery customers, as your solar and stored energy should usually cover household usage at these times. Generally, we see batteries optimised by SmartShiftā¢ export power to create value during this period instead.
There is a 2.19 c/kWh (incl. GST)charge for solar exports between 10-2PM. Load-shifting is key to minimising exports during this period, as with any other period with low feed-in tariffs.
There are no differences between seasons or shoulder periods for the Two-way tariff trial.
End quote
However Iāve also noticed that EMHASS does not alway correclty analyse data so Iām trying to build in some ground rules like no discharging between 10am and 2pm and no charging between 2pm and 8pm.
[{"id":"3268c2b16eaa7414","type":"inject","z":"65840aa926d9c567","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":120,"y":2420,"wires":[["16b27b4bf4a2ede5"]]},{"id":"16b27b4bf4a2ede5","type":"time-range-switch","z":"65840aa926d9c567","name":"","lat":"-33.7971621672968","lon":"151.0986226273335","startTime":"010:00","endTime":"14:00","startOffset":0,"endOffset":0,"x":300,"y":2420,"wires":[["fc6d04ecabfbd91a"],["ada71e681fe334bf"]]},{"id":"26ba461bbb0f2d05","type":"api-current-state","z":"65840aa926d9c567","name":"p_batt_forecast","server":"afc27684.cf6ed8","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"sensor.p_batt_forecast","state_type":"num","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"}],"for":"0","forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":560,"y":2520,"wires":[["cab16b27b4a64132","f2a947d71485142f"]]},{"id":"fc6d04ecabfbd91a","type":"api-current-state","z":"65840aa926d9c567","name":"p_batt_forecast","server":"afc27684.cf6ed8","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"sensor.p_batt_forecast","state_type":"num","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"}],"for":"0","forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":560,"y":2400,"wires":[["c481f5db555d72ca"]]},{"id":"cab16b27b4a64132","type":"debug","z":"65840aa926d9c567","name":"debug 1","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":980,"y":2360,"wires":[]},{"id":"c481f5db555d72ca","type":"api-render-template","z":"65840aa926d9c567","name":"","server":"afc27684.cf6ed8","version":0,"template":"{% set grid_feedin = states.sensor.sonnenbatterie_84324_state_grid_inout.state|float(0) %}\n{% set batt_forecast = states.sensor.p_batt_forecast.state|float(0) %}\n{% set pos_feedin = ((grid_feedin + batt_forecast) > 0)|bool %}\n{% set zero = (0)|float(0)|default(0) %}\n{% set rescharge = batt_forecast|float(0) %}\n{% if pos_feedin %}\n{% set rescharge = zero|float(0) %}\n{% else %}\n{% set rescharge = batt_forecast|float(0) %}\n{% endif %}\n{{ rescharge|int() }}","resultsLocation":"payload","resultsLocationType":"msg","templateLocation":"","templateLocationType":"none","x":760,"y":2400,"wires":[["cab16b27b4a64132","ad6df5eba5cd703a"]]},{"id":"ad6df5eba5cd703a","type":"link out","z":"65840aa926d9c567","name":"link out adjusted charge","mode":"link","links":["93beed478696134e"],"x":925,"y":2400,"wires":[]},{"id":"ada71e681fe334bf","type":"time-range-switch","z":"65840aa926d9c567","name":"","lat":"-33.7971621672968","lon":"151.0986226273335","startTime":"014:00","endTime":"20:00","startOffset":0,"endOffset":0,"x":300,"y":2500,"wires":[["6ebfdbd9b9cfa958"],["26ba461bbb0f2d05"]]},{"id":"6ebfdbd9b9cfa958","type":"api-current-state","z":"65840aa926d9c567","name":"p_batt_forecast","server":"afc27684.cf6ed8","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"sensor.p_batt_forecast","state_type":"num","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"}],"for":"0","forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":560,"y":2460,"wires":[["d65ef605e29630d6"]]},{"id":"d65ef605e29630d6","type":"api-render-template","z":"65840aa926d9c567","name":"","server":"afc27684.cf6ed8","version":0,"template":"{% set grid_feedin = states.sensor.sonnenbatterie_84324_state_grid_inout.state|float(0) %}\n{% set batt_forecast = states.sensor.p_batt_forecast.state|float(0) %}\n{% set neg_feedin = ((grid_feedin + batt_forecast) < 0)|bool %}\n{% set zero = (0)|float(0)|default(0) %}\n{% set rescharge = batt_forecast|float(0) %}\n{% if neg_feedin %}\n{% set rescharge = zero|float(0) %}\n{% else %}\n{% set rescharge = batt_forecast|float(0) %}\n{% endif %}\n{{ rescharge|int() }}","resultsLocation":"payload","resultsLocationType":"msg","templateLocation":"","templateLocationType":"none","x":760,"y":2460,"wires":[["cab16b27b4a64132","e141d12a92ab5773"]]},{"id":"1c7d785a53cd2053","type":"comment","z":"65840aa926d9c567","name":"Ausgrid -2.19c on FiT","info":"","x":300,"y":2380,"wires":[]},{"id":"5385a46d2cd4892a","type":"comment","z":"65840aa926d9c567","name":"Ausgrid +26.58c on FiT","info":"","x":300,"y":2560,"wires":[]},{"id":"c71f62cc34968214","type":"comment","z":"65840aa926d9c567","name":"Not ok to discharge AM","info":"","x":760,"y":2360,"wires":[]},{"id":"fed8abdc502539fe","type":"comment","z":"65840aa926d9c567","name":"Not ok to charge PM","info":"","x":770,"y":2520,"wires":[]},{"id":"db2c0a119c510f09","type":"link in","z":"65840aa926d9c567","name":"link in adjusted charge/discharge","links":[],"x":105,"y":2480,"wires":[["16b27b4bf4a2ede5"]]},{"id":"e141d12a92ab5773","type":"link out","z":"65840aa926d9c567","name":"link out adjusted discharge","mode":"link","links":[],"x":925,"y":2460,"wires":[]},{"id":"1583a885818be654","type":"link out","z":"65840aa926d9c567","name":"link out 1","mode":"link","links":[],"x":925,"y":2520,"wires":[]},{"id":"d32ba786df56b857","type":"link out","z":"65840aa926d9c567","name":"link out 2","mode":"link","links":[],"x":925,"y":2580,"wires":[]},{"id":"f2a947d71485142f","type":"switch","z":"65840aa926d9c567","name":"","property":"payload","propertyType":"msg","rules":[{"t":"lt","v":"0","vt":"num"},{"t":"gt","v":"0","vt":"num"}],"checkall":"true","repair":false,"outputs":2,"x":750,"y":2560,"wires":[["1583a885818be654"],["d32ba786df56b857"]]},{"id":"85a5838316958742","type":"comment","z":"65840aa926d9c567","name":"discharge adjusted to 0","info":"","x":1060,"y":2400,"wires":[]},{"id":"70f2963ab704c122","type":"comment","z":"65840aa926d9c567","name":"charge adjusted to 0","info":"","x":1050,"y":2460,"wires":[]},{"id":"39cbb99fb9a73dc3","type":"comment","z":"65840aa926d9c567","name":"charge passed through","info":"","x":1060,"y":2520,"wires":[]},{"id":"a6ad54984bd41b4e","type":"comment","z":"65840aa926d9c567","name":"discharge passed through","info":"","x":1070,"y":2580,"wires":[]},{"id":"afc27684.cf6ed8","type":"server","name":"Home Assistant","version":5,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true,"heartbeat":false,"heartbeatInterval":30,"areaSelector":"friendlyName","deviceSelector":"friendlyName","entitySelector":"friendlyName","statusSeparator":"at: ","statusYear":"hidden","statusMonth":"short","statusDay":"numeric","statusHourCycle":"h23","statusTimeFormat":"h:m","enableGlobalContextStore":true}]
When I test this flow Iāll sit it between the switch and the POST/PUT calls.