So, … hier mein Flow, … nicht schön und mit Sicherheit auch nicht perfekt, aber läuft
Der Flow ist auf die Verwendung mit einem Smart getrimmt. Damit funktioniert es erste Sahne.
Die PV-Produktion und der aktuelle Verbrauch kommen über Variablen in den Flow rein. Die Datenquelle ist also beliebig! Bei mir Fronius WR inkl. Fronius Smartmeter.
Modus 2 ist für den börsenabhängigen Strompreis von Awattar ausgelegt. Die Umsetzung erledigt nach Aktivierung der go eCharger selbstständig. Ihr könnt den Modus aber ohne diesen Stromtarif nutzen um das Netz zu entlasten. Der Strom ist immer am günstigsten, wenn am meisten im Netz Verfügbar ist.
[{"id":"2d794b0f.8d3884","type":"tab","label":"600 - go-eCharger","disabled":false,"info":""},{"id":"1fdcd9da.d0c936","type":"mqtt in","z":"2d794b0f.8d3884","name":"go-eCharger - Status","topic":"go-eCharger/XXXXXX/status","qos":"2","datatype":"auto","broker":"a11f5671.f677c","x":120,"y":120,"wires":[["7b2face1.c3df1c"]]},{"id":"7b2face1.c3df1c","type":"json","z":"2d794b0f.8d3884","name":"","pretty":false,"x":110,"y":200,"wires":[["b7a3f534.496bc","f76dff4.1a5af8","1c322cb1.b465cb","fc7720e1.810478","63b772d5.253fb4","6b47695c.ade5c8","688d4a21.edaecc","3853542e.6f1ce4","fe2b07e.95f90f8","e94b41ec.c8ac48"]]},{"id":"b7a3f534.496bc","type":"function","z":"2d794b0f.8d3884","name":"Ladestrom","func":"msg.payload = {\"id\":602,\"value\":Number(msg.payload.amp)};\nreturn msg;","outputs":1,"noerr":0,"x":550,"y":100,"wires":[["19211e3b.1e911a"]]},{"id":"7e40b17e.2fbb5","type":"switch","z":"2d794b0f.8d3884","name":"Knöpfe","property":"payload.attributeId","propertyType":"msg","rules":[{"t":"eq","v":"601","vt":"num"},{"t":"eq","v":"602","vt":"str"},{"t":"eq","v":"603","vt":"str"},{"t":"eq","v":"604","vt":"str"},{"t":"eq","v":"605","vt":"str"}],"checkall":"false","repair":false,"outputs":5,"x":180,"y":720,"wires":[["38f20e84.5d4f72"],["fb66d224.5c4fd8"],["5ee05bd1.a5bbec"],["75243cd3.cee474"],["1f3eed3f.63011b"]],"outputLabels":["Modus","Ladestrom","min. Ladezeit","Abfahrtszeit","Aktivierung"]},{"id":"a489aa39.ac16e8","type":"mqtt out","z":"2d794b0f.8d3884","name":"go-eCharger - Request","topic":"go-eCharger/XXXXXX/cmd/req","qos":"","retain":"","broker":"a11f5671.f677c","x":990,"y":760,"wires":[]},{"id":"fb66d224.5c4fd8","type":"function","z":"2d794b0f.8d3884","name":"Ladestrom","func":"msg.payload = \"amp=\"+msg.payload.targetValue;\nreturn msg;","outputs":1,"noerr":0,"x":530,"y":760,"wires":[["a489aa39.ac16e8"]]},{"id":"f76dff4.1a5af8","type":"function","z":"2d794b0f.8d3884","name":"min. Ladezeit / Strompreis","func":"msg.payload = {\"id\":603,\"value\":Number(msg.payload.aho)};\nreturn msg;","outputs":1,"noerr":0,"x":600,"y":140,"wires":[["34837f35.ac979"]]},{"id":"1c322cb1.b465cb","type":"function","z":"2d794b0f.8d3884","name":"Abfahrt / Strompreis","func":"msg.payload = {\"id\":604,\"value\":Number(msg.payload.afi)};\nreturn msg;","outputs":1,"noerr":0,"x":580,"y":180,"wires":[["382093f7.68ccb4"]]},{"id":"5ee05bd1.a5bbec","type":"function","z":"2d794b0f.8d3884","name":"min. Ladezeit","func":"msg.payload = \"aho=\"+msg.payload.targetValue;\nreturn msg;","outputs":1,"noerr":0,"x":540,"y":800,"wires":[["a489aa39.ac16e8"]]},{"id":"75243cd3.cee474","type":"function","z":"2d794b0f.8d3884","name":"Abfahrtszeit","func":"msg.payload = \"afi=\"+msg.payload.targetValue;\nreturn msg;","outputs":1,"noerr":0,"x":530,"y":840,"wires":[["a489aa39.ac16e8"]]},{"id":"2c4d3f89.e11198","type":"link in","z":"2d794b0f.8d3884","name":"","links":["9497ebf3.a8b0a8"],"x":75,"y":720,"wires":[["7e40b17e.2fbb5"]]},{"id":"9497ebf3.a8b0a8","type":"link out","z":"2d794b0f.8d3884","name":"go-eCharger OUT","links":["2c4d3f89.e11198"],"x":1095,"y":180,"wires":[]},{"id":"fc7720e1.810478","type":"function","z":"2d794b0f.8d3884","name":"akt. Ladevorgang","func":"msg.payload = {\"id\":606,\"value\":Number(msg.payload.dws)*10/3600/1000};\nreturn msg;","outputs":1,"noerr":0,"x":570,"y":220,"wires":[["989f8b98.a38578"]]},{"id":"59b01361.41518c","type":"homeeDevice","z":"2d794b0f.8d3884","virtual-homee":"a34a1077.683ed","name":"go-eCharger","nodeId":"600","profile":"11","icon":"default","attributes":"[{\"id\":601,\"node_id\":600,\"instance\":0,\"minimum\":1,\"maximum\":3,\"current_value\":0,\"target_value\":0,\"last_value\":0,\"unit\":\"Modus\",\"step_value\":1,\"editable\":1,\"type\":2,\"state\":1,\"last_changed\":1573669587,\"changed_by\":1,\"changed_by_id\":0,\"based_on\":1,\"data\":\"\",\"options\":{\"automations\":[\"step\"]}},{\"id\":602,\"node_id\":600,\"instance\":1,\"minimum\":6,\"maximum\":20,\"current_value\":0,\"target_value\":0,\"last_value\":0,\"unit\":\"A\",\"step_value\":1,\"editable\":1,\"type\":2,\"state\":1,\"last_changed\":1573669587,\"changed_by\":1,\"changed_by_id\":0,\"based_on\":1,\"data\":\"\",\"options\":{\"automations\":[\"step\"]}},{\"id\":603,\"node_id\":600,\"instance\":2,\"minimum\":1,\"maximum\":4,\"current_value\":0,\"target_value\":0,\"last_value\":0,\"unit\":\"h\",\"step_value\":1,\"editable\":1,\"type\":2,\"state\":1,\"last_changed\":1573669587,\"changed_by\":1,\"changed_by_id\":0,\"based_on\":1,\"data\":\"\",\"options\":{\"automations\":[\"step\"]}},{\"id\":604,\"node_id\":600,\"instance\":3,\"minimum\":0,\"maximum\":23,\"current_value\":0,\"target_value\":0,\"last_value\":0,\"unit\":\"Uhr\",\"step_value\":1,\"editable\":1,\"type\":2,\"state\":1,\"last_changed\":1573669587,\"changed_by\":1,\"changed_by_id\":0,\"based_on\":1,\"data\":\"\",\"options\":{\"automations\":[\"step\"]}},{\"id\":605,\"node_id\":600,\"instance\":0,\"minimum\":0,\"maximum\":1,\"current_value\":0,\"target_value\":0,\"last_value\":0,\"unit\":\"\",\"step_value\":1,\"editable\":1,\"type\":1,\"state\":1,\"last_changed\":1577388774,\"changed_by\":1,\"changed_by_id\":0,\"based_on\":1,\"data\":\"\"},{\"id\":606,\"node_id\":600,\"instance\":0,\"minimum\":0,\"maximum\":100,\"current_value\":0,\"target_value\":0,\"last_value\":0,\"unit\":\"kWh (Ladevorgang)\",\"step_value\":0.01,\"editable\":0,\"type\":4,\"state\":1,\"last_changed\":1579510989,\"changed_by\":1,\"changed_by_id\":0,\"based_on\":1,\"data\":\"\"},{\"id\":607,\"node_id\":600,\"instance\":0,\"minimum\":0,\"maximum\":25000,\"current_value\":0,\"target_value\":0,\"last_value\":0,\"unit\":\"W\",\"step_value\":1,\"editable\":0,\"type\":3,\"state\":1,\"last_changed\":1579512125,\"changed_by\":1,\"changed_by_id\":0,\"based_on\":1,\"data\":\"\"},{\"id\":608,\"node_id\":600,\"instance\":1,\"minimum\":0,\"maximum\":100000,\"current_value\":0,\"target_value\":0,\"last_value\":0,\"unit\":\"kWh (Gesamt)\",\"step_value\":0.01,\"editable\":0,\"type\":4,\"state\":1,\"last_changed\":1579510989,\"changed_by\":1,\"changed_by_id\":0,\"based_on\":1,\"data\":\"\"}]","x":990,"y":180,"wires":[["9497ebf3.a8b0a8"]]},{"id":"38f20e84.5d4f72","type":"switch","z":"2d794b0f.8d3884","name":"","property":"payload.targetValue","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"str"},{"t":"eq","v":"2","vt":"str"},{"t":"eq","v":"3","vt":"str"}],"checkall":"true","repair":false,"outputs":3,"x":350,"y":680,"wires":[["96b01a6a.22d1d"],["4b91b479.aa892c"],["8529bce9.586698"]],"outputLabels":["Sofort","Strompreis","PV-Überschuss"]},{"id":"96b01a6a.22d1d","type":"function","z":"2d794b0f.8d3884","name":"Sofort","func":"global.set(\"goeModus\",1);\nvar msg1 = { payload:\"amp=20\" };\nvar msg2 = { payload:\"ast=0\" };\nvar msg3 = { payload:\"alw=1\" };\nvar msg4 = { payload:\"stp=0\" };\nreturn [ [ msg1, msg2, msg3, msg4 ]];","outputs":1,"noerr":0,"x":510,"y":640,"wires":[["a489aa39.ac16e8"]]},{"id":"1f3eed3f.63011b","type":"function","z":"2d794b0f.8d3884","name":"Aktivierung","func":"msg.payload = \"alw=\"+msg.payload.targetValue;\nreturn msg;","outputs":1,"noerr":0,"x":530,"y":880,"wires":[["a489aa39.ac16e8"]]},{"id":"63b772d5.253fb4","type":"function","z":"2d794b0f.8d3884","name":"Aktivierung","func":"msg.payload = {\"id\":605,\"value\":Number(msg.payload.alw)};\nreturn msg;","outputs":1,"noerr":0,"x":550,"y":60,"wires":[["e944161a.ea4e"]]},{"id":"6b47695c.ade5c8","type":"function","z":"2d794b0f.8d3884","name":"akt. Ladeleistung","func":"msg.payload = {\"id\":607,\"value\":Number(msg.payload.nrg[11])*10};\nreturn msg;","outputs":1,"noerr":0,"x":570,"y":260,"wires":[["94260a6a.d1ce5"]]},{"id":"688d4a21.edaecc","type":"function","z":"2d794b0f.8d3884","name":"Gesamt","func":"msg.payload = {\"id\":608,\"value\":Number(msg.payload.eto)/10};\nreturn msg;","outputs":1,"noerr":0,"x":540,"y":300,"wires":[["46672353.49e6bc"]]},{"id":"8529bce9.586698","type":"function","z":"2d794b0f.8d3884","name":"Überschuss Start","func":"global.set(\"goeModus\",3);\nvar msg1 = { payload:\"amp=6\" };\nvar msg2 = { payload:\"ast=0\" };\nvar msg3 = { payload:\"alw=0\" };\nvar msg4 = { payload:\"stp=0\" };\nreturn [ [ msg1, msg2, msg3, msg4 ]];","outputs":1,"noerr":0,"x":550,"y":720,"wires":[["a489aa39.ac16e8"]]},{"id":"4b91b479.aa892c","type":"function","z":"2d794b0f.8d3884","name":"Strompreis","func":"global.set(\"goeModus\",2);\nvar msg1 = { payload:\"amp=20\" };\nvar msg2 = { payload:\"ast=2\" };\nvar msg3 = { payload:\"alw=1\" };\nvar msg4 = { payload:\"stp=0\" };\nvar msg5 = { payload:\"azo=1\" };\nreturn [ [ msg1, msg2, msg3, msg4, msg5]];","outputs":1,"noerr":0,"x":530,"y":680,"wires":[["a489aa39.ac16e8"]]},{"id":"e944161a.ea4e","type":"rbe","z":"2d794b0f.8d3884","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":790,"y":60,"wires":[["59b01361.41518c"]]},{"id":"19211e3b.1e911a","type":"rbe","z":"2d794b0f.8d3884","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":790,"y":100,"wires":[["59b01361.41518c"]]},{"id":"34837f35.ac979","type":"rbe","z":"2d794b0f.8d3884","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":790,"y":140,"wires":[["59b01361.41518c"]]},{"id":"382093f7.68ccb4","type":"rbe","z":"2d794b0f.8d3884","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":790,"y":180,"wires":[["59b01361.41518c"]]},{"id":"989f8b98.a38578","type":"rbe","z":"2d794b0f.8d3884","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":790,"y":220,"wires":[["59b01361.41518c"]]},{"id":"94260a6a.d1ce5","type":"rbe","z":"2d794b0f.8d3884","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":790,"y":260,"wires":[["59b01361.41518c"]]},{"id":"46672353.49e6bc","type":"rbe","z":"2d794b0f.8d3884","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":790,"y":300,"wires":[["59b01361.41518c"]]},{"id":"3853542e.6f1ce4","type":"switch","z":"2d794b0f.8d3884","name":"Auto da?","property":"payload.car","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":320,"y":380,"wires":[["96b01a6a.22d1d","eb7de803.77171"]]},{"id":"eb7de803.77171","type":"function","z":"2d794b0f.8d3884","name":"Modus = 1","func":"msg.payload = {\"id\":601,\"value\":1};\nreturn msg;","outputs":1,"noerr":0,"x":550,"y":380,"wires":[["7c7eedac.5d52f4"]]},{"id":"7c7eedac.5d52f4","type":"delay","z":"2d794b0f.8d3884","name":"1msg/10s","pauseType":"rate","timeout":"5","timeoutUnits":"seconds","rate":"1","nbRateUnits":"10","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":true,"x":780,"y":380,"wires":[["59b01361.41518c"]]},{"id":"fe2b07e.95f90f8","type":"switch","z":"2d794b0f.8d3884","name":"Strompreis aktiv?","property":"payload.ast","propertyType":"msg","rules":[{"t":"eq","v":"2","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":340,"wires":[["119a5941.ea2da7"]]},{"id":"119a5941.ea2da7","type":"function","z":"2d794b0f.8d3884","name":"Modus = 2","func":"msg.payload = {\"id\":601,\"value\":2};\nreturn msg;","outputs":1,"noerr":0,"x":550,"y":340,"wires":[["c0db88c0.b34ff8"]]},{"id":"c0db88c0.b34ff8","type":"delay","z":"2d794b0f.8d3884","name":"1msg/10s","pauseType":"rate","timeout":"5","timeoutUnits":"seconds","rate":"1","nbRateUnits":"10","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":true,"x":780,"y":340,"wires":[["59b01361.41518c"]]},{"id":"647fff0e.76b308","type":"function","z":"2d794b0f.8d3884","name":"Start Überschussladung","func":"var aktUeberschuss = global.get(\"aktProduktion\") - global.get(\"aktVerbrauch\");\nvar msgFreigabe;\n\nif (global.get(\"goeModus\") == 3 && Number(msg.payload.car) == 4 && Number(msg.payload.alw) === 0 && aktUeberschuss > 1380) {\n msgFreigabe = { payload:\"alw=1\" };\n}\nreturn msgFreigabe;","outputs":1,"noerr":0,"x":590,"y":460,"wires":[["a489aa39.ac16e8"]]},{"id":"7fa1aab6.1ee32c","type":"function","z":"2d794b0f.8d3884","name":"Stopp Überschussladung","func":"var aktUeberschuss = global.get(\"aktProduktion\") - global.get(\"aktVerbrauch\");\nvar msgFreigabe;\nif (global.get(\"goeModus\") == 3 && Number(msg.payload.car) == 2 && Number(msg.payload.amp) == 6 && aktUeberschuss < -100) {\n msgFreigabe = { payload:\"alw=0\" };\n}\nreturn msgFreigabe;","outputs":1,"noerr":0,"x":590,"y":540,"wires":[["a489aa39.ac16e8"]]},{"id":"e94b41ec.c8ac48","type":"delay","z":"2d794b0f.8d3884","name":"1Msg/30s","pauseType":"rate","timeout":"5","timeoutUnits":"seconds","rate":"1","nbRateUnits":"30","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":true,"x":320,"y":460,"wires":[["647fff0e.76b308","7fa1aab6.1ee32c","4d19015b.b68e9"]]},{"id":"4d19015b.b68e9","type":"function","z":"2d794b0f.8d3884","name":"Regelung Überschussladung","func":"var aktUeberschuss = global.get(\"aktProduktion\") - global.get(\"aktVerbrauch\");\nvar Ladestrom;\nvar msgLadestrom;\nif (global.get(\"goeModus\") == 3 && Number(msg.payload.car) == 2) {\n Ladestrom = (Number(msg.payload.amp) + (aktUeberschuss / 230)).toFixed(0); \n if (Ladestrom > 20)\n Ladestrom = 20;\n else if (Ladestrom < 6)\n Ladestrom = 6;\n msgLadestrom = { payload:\"amp=\"+Ladestrom };\n}\nreturn msgLadestrom;","outputs":1,"noerr":0,"x":600,"y":500,"wires":[["a489aa39.ac16e8"]]},{"id":"a11f5671.f677c","type":"mqtt-broker","z":"","name":"Diskstation MQTT","broker":"10.10.10.10","port":"1883","clientid":"","usetls":false,"compatmode":false,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthRetain":"false","birthPayload":"","closeTopic":"","closeQos":"0","closeRetain":"false","closePayload":"","willTopic":"","willQos":"0","willRetain":"false","willPayload":""},{"id":"a34a1077.683ed","type":"virtualHomee","z":"","name":"1ABC"}]
Nur noch kurz zur Info:
Manche Autos sind etwas zickig beim Laden, … bisher konnte ich es mit zwei Auto testen:
Smart: forfour EQ: Ich muss nach dem Anschließen den Smart kurz anfangen lassen zu laden, dann schalte ich auf Modus 3 und der Ladevorgang wird pausiert. Falls ich dass nicht so mache, schläft der Smart innerhalb kürzester Zeit ein und fängt dann auch nicht mehr an zu laden. Wenn er schon mal geladen hat und pausiert ist, kann der Ladevorgang ohne weiteres auch erst 12 Std. später fortgesetzt werden.
Zoe: Die Zoe geht immer und zwar ausnahmslos immer nach zwanzig Minuten Ladepause schlafen und ist dann durch den go eCharger nicht mehr weckbar. Zur Verwendung mit der Zoe muss also die Ladepause komplett entfernt und der Strom auf 6A heruntergeregelt werden.
Ich hoffe ich kann damit dem ein oder anderen weiterhelfen. Bei Fragen gerne melden!