[APP][Pro] Modbus - Connect every Modbus devices

Ronny,
I have Modbus installed and it is connected to my Fronius Primo Inverter. Next step I was going to try and read the registers I need to eventually write to reduce output power (40365).
Here is my first attempt. I have written the Homey Script as per your example:

// Calculate Scale Factor
let json = JSON.parse(args[0]);
let value = Number(json.value);
let exp. = Number(json.exp);
return parseInt(value * Math.pow(10, exp));

Here is the Flow:

And here is the error message I get when I test the Homeyscript:
Screenshot 2024-03-18 at 4.40.09 pm
Could this be because of the test data I entered. I entered -2 and 10000.