I want to build a systems monitor panel for my boat. I am having a hard time deciding if the Arduino is up to the task.
To break it down, I would like a system that includes the following:
- 8 inch 4:3 capacitive touch display panel with USB input
There aren't many 8 inch and 4:3 AR plus USB input really limits the possibilities. HDMI means RPi.
It should have the capacity to do the following:
Read DC volts from 4 batteries
Read battery charge/discharge current from 3 current shunts
Read AC volts
Read AC Amps from a current transformer.
Read levels in 5 tanks with a through the bottom up piezo sensor similar to the one mentioned here in an article on liquid level sensing
Read engine rpms digitally
Run the fuel tank readings through a 2nd order polynomial to account for tank geometry.
Display readings on two pages of virtual instruments and use the touch screen to toggle between them.
That adds up to 17 analog inputs. With the proper interface on each one, none of them are dynamic but the 3 DC currents need DI inputs so, unless I use LM324s to float them, that makes 20 analog inputs.
Does this project sound like a good candidate for an Arduino Mega? Any advice is appreciated.
The Mega has some capacity regarding memory and the number of I/Os. If Your proj is supposed to handle pictures checking the Raspberry is most likely needed.
You can use the Mega for sensor polling, but would probably want an RPi to drive the user interface. You can communicate between the Mega and RPi (for reporting sensor data) via the compatible libraries: pySerialTransfer and SerialTransfer.h.
pySerialTransfer is pip-installable and cross-platform compatible. SerialTransfer.h runs on the Arduino platform and can be installed through the Arduino IDE’s Libraries Manager.
Example Python Script:
from time import sleep
from pySerialTransfer import pySerialTransfer as txfer
if __name__ == '__main__':
link = txfer.SerialTransfer('COM13')
sleep(2) # allow some time for the Arduino to completely reset
link.txBuff = 'h'
link.txBuff = 'i'
link.txBuff = '\n'
while not link.available():
if link.status < 0:
response = ''
for index in range(link.bytesRead):
response += chr(link.rxBuff[index])
Example Arduino Sketch:
myTransfer.txBuff = 'h';
myTransfer.txBuff = 'i';
myTransfer.txBuff = '\n';
for(byte i = 0; i < myTransfer.bytesRead; i++)
else if(myTransfer.status < 0)