First of all, my arduino sketch tells the arduino to serialprint my results.
Then its two ways, either connect TX/RX from the arduino to the ras-pi or via USB.
I choosed USB.
Then I take the signal from arduino who is separated in 3 lines:
Waste 0-90
Diesel 0-255
Water 0-255
Then I separate those 3 into singel lines and then again separate the value from the text.
And finally the 0-255 is converted to the size of the tank. So f.ex the diesel tank is 90liter, so then 255 equal 90. And 0 equal 0.
This number is then transferred to Freeboard where I have my statusscreen of the boat.
The Node-red setup:
And the Freeboard:
(The temperatures and the 230v system comes from Domoticz via Z-wave and RFXCom, the 12v system are not integrated yet. Just text to show my plans..)
Also its possible to download a Arduino-node into node-red, but this is only working when I install it, and next reboot its gone again..
Then its two ways, either connect TX/RX from the arduino to the ras-pi or via USB.
I choosed USB.
Then I take the signal from arduino who is separated in 3 lines:
Waste 0-90
Diesel 0-255
Water 0-255
Then I separate those 3 into singel lines and then again separate the value from the text.
And finally the 0-255 is converted to the size of the tank. So f.ex the diesel tank is 90liter, so then 255 equal 90. And 0 equal 0.
This number is then transferred to Freeboard where I have my statusscreen of the boat.
The Node-red setup:
And the Freeboard:
(The temperatures and the 230v system comes from Domoticz via Z-wave and RFXCom, the 12v system are not integrated yet. Just text to show my plans..)
Also its possible to download a Arduino-node into node-red, but this is only working when I install it, and next reboot its gone again..