So after doing some testing/digging etc. I think I found out some things that maybe can help someone else.
I have a Symo Gen 24 8kW so maybe you will need to change the values if you have a smaller/bigger inverter. WChaMax divide by 2 to get your maximum watt that you can charge/discharge, or look it up on the spec of the inverter. (in my case 8250w)
Node-RED code below to import what worked for me:
[{"id":"082d1a6d7f9f4ee6","type":"tab","label":"Charge Controll Fronius Battery","disabled":false,"info":"","env":[]},{"id":"990a82509790982d","type":"group","z":"082d1a6d7f9f4ee6","style":{"stroke":"#3a3a3a","stroke-opacity":"1","fill":"#1e1e1e","fill-opacity":"0.5","label":true,"label-position":"nw","color":"#cccccc"},"nodes":["01b27fd4c6df709e","a14e060aa8b357d3"],"x":1114,"y":99,"w":412,"h":82},{"id":"45acb5295fb1f6dc","type":"group","z":"082d1a6d7f9f4ee6","name":"Charge 100%","style":{"label":true},"nodes":["884f2c943fb25d0a","b83174f039a2d5e6","78bf6418bd324a42","4ddfd89be5bfedf9","fe05816fcd28a90d","20b1eff7b4967a95"],"x":14,"y":19,"w":492,"h":162},{"id":"4f3ffe065555c0fe","type":"group","z":"082d1a6d7f9f4ee6","name":"Discharge 100%","style":{"label":true},"nodes":["90fccb5e6388880a","9891a0a6eb033160","92d5124fc68884d0","c5c98e12a75471fa","8bd4d58fbd889f99","29977cc08b49350b"],"x":14,"y":199,"w":492,"h":162},{"id":"2b3f222be46c2490","type":"group","z":"082d1a6d7f9f4ee6","name":"Normal operation","style":{"label":true},"nodes":["ea00b2d2947c7047","f64bcb1810827035"],"x":554,"y":19,"w":392,"h":82},{"id":"6cefe547798fa70b","type":"group","z":"082d1a6d7f9f4ee6","name":"No charge/discharge","style":{"label":true},"nodes":["56971e07f5b82a9d","301cc5bfd5441a20","5e1aed5ce6c7b5ae","321d182f3a1d142b","7c0bb5afc650da96","159b084e75e7ebe6"],"x":554,"y":199,"w":492,"h":162},{"id":"c40948974576ca28","type":"group","z":"082d1a6d7f9f4ee6","name":"Check Battery info","style":{"label":true},"nodes":["6af939f8557606d0","33f657511e9659a2","9d2b7e0d8afa516b"],"x":14,"y":479,"w":592,"h":82},{"id":"f899bcc02c1725fc","type":"group","z":"082d1a6d7f9f4ee6","name":"Check Battery info RW only","style":{"label":true},"nodes":["bb3812291ebfcfb9","ef1f47997f40e6e5","18f4782d041591d2"],"x":14,"y":379,"w":592,"h":82},{"id":"01b27fd4c6df709e","type":"modbus-response","z":"082d1a6d7f9f4ee6","g":"990a82509790982d","name":"","registerShowMax":20,"x":1410,"y":140,"wires":[]},{"id":"a14e060aa8b357d3","type":"modbus-flex-write","z":"082d1a6d7f9f4ee6","g":"990a82509790982d","name":"Fronius-Storage","showStatusActivities":true,"showErrors":true,"server":"bcc4229c.180ac","emptyMsgOnFail":true,"keepMsgProperties":true,"x":1220,"y":140,"wires":[["01b27fd4c6df709e"],[]]},{"id":"884f2c943fb25d0a","type":"delay","z":"082d1a6d7f9f4ee6","g":"45acb5295fb1f6dc","name":"500ms","pauseType":"delay","timeout":"500","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":290,"y":100,"wires":[["fe05816fcd28a90d"]]},{"id":"b83174f039a2d5e6","type":"delay","z":"082d1a6d7f9f4ee6","g":"45acb5295fb1f6dc","name":"1s","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":270,"y":140,"wires":[["20b1eff7b4967a95"]]},{"id":"78bf6418bd324a42","type":"inject","z":"082d1a6d7f9f4ee6","g":"45acb5295fb1f6dc","name":"Charge 100%","props":[{"p":"outwrte","v":"60933","vt":"num"},{"p":"inwrte","v":"4603","vt":"str"},{"p":"storctl_mod","v":"2","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":"","topic":"","x":130,"y":60,"wires":[["4ddfd89be5bfedf9","884f2c943fb25d0a","b83174f039a2d5e6"]]},{"id":"4ddfd89be5bfedf9","type":"function","z":"082d1a6d7f9f4ee6","g":"45acb5295fb1f6dc","name":"InWRte","func":"msg.payload = { \n 'value': msg.inwrte,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40366,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":420,"y":60,"wires":[["a14e060aa8b357d3"]]},{"id":"fe05816fcd28a90d","type":"function","z":"082d1a6d7f9f4ee6","g":"45acb5295fb1f6dc","name":"OutWRte","func":"msg.payload = { \n 'value': msg.outwrte,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40365,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":420,"y":100,"wires":[["a14e060aa8b357d3"]]},{"id":"20b1eff7b4967a95","type":"function","z":"082d1a6d7f9f4ee6","g":"45acb5295fb1f6dc","name":"StorCtl_Mod","func":"msg.payload = { \n 'value': msg.storctl_mod,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40358,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":410,"y":140,"wires":[["a14e060aa8b357d3"]]},{"id":"90fccb5e6388880a","type":"delay","z":"082d1a6d7f9f4ee6","g":"4f3ffe065555c0fe","name":"500ms","pauseType":"delay","timeout":"500","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":290,"y":280,"wires":[["8bd4d58fbd889f99"]]},{"id":"9891a0a6eb033160","type":"delay","z":"082d1a6d7f9f4ee6","g":"4f3ffe065555c0fe","name":"1s","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":270,"y":320,"wires":[["29977cc08b49350b"]]},{"id":"92d5124fc68884d0","type":"inject","z":"082d1a6d7f9f4ee6","g":"4f3ffe065555c0fe","name":"Discharge 100%","props":[{"p":"outwrte","v":"4603","vt":"num"},{"p":"inwrte","v":"60933","vt":"str"},{"p":"storctl_mod","v":"1","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":"","topic":"","x":140,"y":240,"wires":[["c5c98e12a75471fa","90fccb5e6388880a","9891a0a6eb033160"]]},{"id":"c5c98e12a75471fa","type":"function","z":"082d1a6d7f9f4ee6","g":"4f3ffe065555c0fe","name":"InWRte","func":"msg.payload = { \n 'value': msg.inwrte,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40366,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":420,"y":240,"wires":[["a14e060aa8b357d3"]]},{"id":"8bd4d58fbd889f99","type":"function","z":"082d1a6d7f9f4ee6","g":"4f3ffe065555c0fe","name":"OutWRte","func":"msg.payload = { \n 'value': msg.outwrte,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40365,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":420,"y":280,"wires":[["a14e060aa8b357d3"]]},{"id":"29977cc08b49350b","type":"function","z":"082d1a6d7f9f4ee6","g":"4f3ffe065555c0fe","name":"StorCtl_Mod","func":"msg.payload = { \n 'value': msg.storctl_mod,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40358,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":410,"y":320,"wires":[["a14e060aa8b357d3"]]},{"id":"ea00b2d2947c7047","type":"inject","z":"082d1a6d7f9f4ee6","g":"2b3f222be46c2490","name":"Normal operation","props":[{"p":"storctl_mod","v":"0","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":"","topic":"","x":680,"y":60,"wires":[["f64bcb1810827035"]]},{"id":"f64bcb1810827035","type":"function","z":"082d1a6d7f9f4ee6","g":"2b3f222be46c2490","name":"StorCtl_Mod","func":"msg.payload = { \n 'value': msg.storctl_mod,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40358,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":850,"y":60,"wires":[["a14e060aa8b357d3"]]},{"id":"56971e07f5b82a9d","type":"delay","z":"082d1a6d7f9f4ee6","g":"6cefe547798fa70b","name":"500ms","pauseType":"delay","timeout":"500","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":830,"y":280,"wires":[["7c0bb5afc650da96"]]},{"id":"301cc5bfd5441a20","type":"delay","z":"082d1a6d7f9f4ee6","g":"6cefe547798fa70b","name":"1s","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":810,"y":320,"wires":[["159b084e75e7ebe6"]]},{"id":"5e1aed5ce6c7b5ae","type":"inject","z":"082d1a6d7f9f4ee6","g":"6cefe547798fa70b","name":"No charge/discharge","props":[{"p":"outwrte","v":"0","vt":"num"},{"p":"inwrte","v":"0","vt":"str"},{"p":"storctl_mod","v":"3","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":"","topic":"","x":690,"y":240,"wires":[["321d182f3a1d142b","56971e07f5b82a9d","301cc5bfd5441a20"]]},{"id":"321d182f3a1d142b","type":"function","z":"082d1a6d7f9f4ee6","g":"6cefe547798fa70b","name":"InWRte","func":"msg.payload = { \n 'value': msg.inwrte,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40366,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":960,"y":240,"wires":[["a14e060aa8b357d3"]]},{"id":"7c0bb5afc650da96","type":"function","z":"082d1a6d7f9f4ee6","g":"6cefe547798fa70b","name":"OutWRte","func":"msg.payload = { \n 'value': msg.outwrte,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40365,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":960,"y":280,"wires":[["a14e060aa8b357d3"]]},{"id":"159b084e75e7ebe6","type":"function","z":"082d1a6d7f9f4ee6","g":"6cefe547798fa70b","name":"StorCtl_Mod","func":"msg.payload = { \n 'value': msg.storctl_mod,\n 'fc': 6,\n 'unitid': 1,\n 'address': 40358,\n 'quantity': 1\n} \n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":950,"y":320,"wires":[["a14e060aa8b357d3"]]},{"id":"6af939f8557606d0","type":"modbus-read","z":"082d1a6d7f9f4ee6","g":"c40948974576ca28","name":"Battery info all values","topic":"40354","showStatusActivities":false,"logIOActivities":false,"showErrors":false,"unitid":"1","dataType":"HoldingRegister","adr":"40353","quantity":"26","rate":"10","rateUnit":"m","delayOnStart":false,"startDelayTime":"","server":"bcc4229c.180ac","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":false,"x":160,"y":520,"wires":[["9d2b7e0d8afa516b"],[]]},{"id":"33f657511e9659a2","type":"debug","z":"082d1a6d7f9f4ee6","g":"c40948974576ca28","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":510,"y":520,"wires":[]},{"id":"9d2b7e0d8afa516b","type":"function","z":"082d1a6d7f9f4ee6","g":"c40948974576ca28","name":"RAW to JSON","func":"var data = msg.payload;\nvar raw = {\n 'ID': data[0],\n 'L': data[1],\n 'WChaMax': data[2],\n 'WChaGra': data[3],\n 'WDisChaGra': data[4],\n 'StorCtl_Mod': data[5],\n 'VAChaMax': data[6],\n 'MinRsvPct': data[7],\n 'ChaState': data[8],\n 'StorAval': data[9],\n 'InBatV': data[10],\n 'ChaSt': data[11],\n 'OutWRte': data[12],\n 'InWRte': data[13],\n 'InOutWRte_WinTms': data[14],\n 'InOutWRte_RvrtTms': data[15],\n 'InOutWRte_RmpTms': data[16],\n 'ChaGriSet': data[17],\n 'WChaMax_SF': data[18],\n 'WChaDisChaGra_SF': data[19],\n 'VAChaMax_SF': data[20],\n 'MinRsvPct_SF': data[21],\n 'ChaState_SF': data[22],\n 'StorAval_SF': data[23],\n 'InBatV_SF': data[24],\n 'InOutWRte_SF': data[25],\n}\n\n\nmsg.payload = {\n data : data,\n raw : raw,\n}\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":360,"y":520,"wires":[["33f657511e9659a2"]]},{"id":"bb3812291ebfcfb9","type":"modbus-read","z":"082d1a6d7f9f4ee6","g":"f899bcc02c1725fc","name":"Battery info RW values","topic":"40354","showStatusActivities":false,"logIOActivities":false,"showErrors":false,"unitid":"1","dataType":"HoldingRegister","adr":"40353","quantity":"26","rate":"10","rateUnit":"m","delayOnStart":false,"startDelayTime":"","server":"bcc4229c.180ac","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":false,"x":160,"y":420,"wires":[["18f4782d041591d2"],[]]},{"id":"ef1f47997f40e6e5","type":"debug","z":"082d1a6d7f9f4ee6","g":"f899bcc02c1725fc","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":510,"y":420,"wires":[]},{"id":"18f4782d041591d2","type":"function","z":"082d1a6d7f9f4ee6","g":"f899bcc02c1725fc","name":"RAW to JSON","func":"var data = msg.payload;\nvar raw = {\n 'StorCtl_Mod': data[5],\n 'MinRsvPct': data[7],\n 'OutWRte': data[12],\n 'InWRte': data[13],\n 'InOutWRte_RvrtTms': data[15],\n 'ChaGriSet': data[17],\n}\n\nmsg.payload = {\n data : data,\n raw : raw,\n}\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":360,"y":420,"wires":[["ef1f47997f40e6e5"]]},{"id":"bcc4229c.180ac","type":"modbus-client","name":"Fronius","clienttype":"tcp","bufferCommands":true,"stateLogEnabled":false,"queueLogEnabled":false,"failureLogEnabled":false,"tcpHost":"192.168.5.182","tcpPort":"502","tcpType":"DEFAULT","serialPort":"/dev/ttyUSB","serialType":"RTU-BUFFERD","serialBaudrate":"9600","serialDatabits":"8","serialStopbits":"1","serialParity":"none","serialConnectionDelay":"100","serialAsciiResponseStartDelimiter":"","unit_id":"200","commandDelay":"1","clientTimeout":"1000","reconnectOnTimeout":true,"reconnectTimeout":"2000","parallelUnitIdsAllowed":true}]
Also this helped me understand how the inverter operates:
0 (normal operation)
1 (bit 1 activates charge limit, bit pattern: 01)
2 (activates discharge limit, bit pattern: 10)
3 (activate both limit values, bit pattern: 11)