I developed a flow on a raspberry pi using version node-red 1.1.2 and node.js ver 14.6.0 which works fine. It takes in can data from a battery and serial data from a victron mppt 150¦70-tr. The battery and serial data are joined using the join node and some logic compares the charge demand current with the actual battery current to control the charging regime of the solar charger i.e. turn on when demand > actual and off when demand < actual. there is also a requirement to turn of if can bus communication is lost. i set up a new raspi 4 and updated node-red to ver 1.2.2 and node.js to 12.19.0 (raspi noobs set up node-red with ver 1.0.6 and node js as 10.21.0 and I thought the older version was causing my problem)
In the battery input flow I convert the payload using a function node with a statement
msg.payload = msg.payload.data;
the output from ver 1.1.2 was an array which went into the join node but now the output is just a number from byte 0 of an array
Not sure how to paste the json flow here but am quite happy to do so if required.
I would appreciate some help please - thanks in advance