Split data stream

I want to split the data stream I receive into different variables. The values are separated by a comma.

Enclosed a copy of the data stream

50,57,51,54,0,1,2,2013,2024,32,40561,0,587,0,0,61536,4000,8675,0,1392,45600,3485,52935

Enclosed the node with which I want to read a PV memory via Modbus TCP

[{"id":"a415dce4.a57f","type":"tab","label":"Flow 2","disabled":false,"info":""},{"id":"f3d27682.364cb8","type":"modbustcp-read","z":"a415dce4.a57f","name":"PV-Speicher alle Werte","topic":"pv-speicher","dataType":"InputRegister","adr":"1059","quantity":"23","rate":"1","rateUnit":"s","server":"aa8af165.8798e","ieeeType":"off","ieeeBE":true,"x":130,"y":120,"wires":[["a4e2a17d.d81f2"]]},{"id":"a4e2a17d.d81f2","type":"json","z":"a415dce4.a57f","name":"","property":"payload","action":"","pretty":false,"x":130,"y":220,"wires":[["846aa32f.9c4a4"]]},{"id":"846aa32f.9c4a4","type":"change","z":"a415dce4.a57f","name":"","rules":[{"t":"change","p":"payload","pt":"msg","from":"[","fromt":"str","to":"","tot":"str"},{"t":"change","p":"payload","pt":"msg","from":"]","fromt":"str","to":"","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":340,"y":220,"wires":[["826a8ee7.982ef"]]},{"id":"826a8ee7.982ef","type":"debug","z":"a415dce4.a57f","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":660,"y":160,"wires":[]},{"id":"aa8af165.8798e","type":"modbustcp-server","name":"PV-Speicher","host":"192.168.178.11","port":"502","unit_id":"1","reconnecttimeout":"60"}]

Please see this post for how to format a flow so that it can be imported. How to share code or flow json

Please post a screenshot of the output from the modbus node in a debug node so we can see exactly what we are dealing with.

Look at the buffer-parser node. It is ideal for taking a buffer and turning it into a nice key/value object.

or if it is really just a string then maybe the CSV node

I suspect as the OP mentions Modbus TCP and "values are separated by a comma" is more so an array data items that need coercing into nice values.

I could be wrong - it happens :smiley:

Indeed - but when they include more than just bytes it looks less like a buffer. so ... who knows... (well hopefully OP :wink:

I am now getting values. How can i convert the value to sint16 now?

did you look at this?

This recent post might help