node slave arduino's sending data to a center arduino

Hello all.

I have a project in mind that will require multiple i2C Time-Of-Flight ranging sensor and be located all over a room. The sensors data will be computed and the Arduino will perform an action based on the data altogether.

I have since discovered the limitation of the wire length of an I2C bus and found that alternatives and other solutions will require some more work (and money).

Plan A, since I got multiple stock of an Atmega328P-PU "parts kit" laying around I was thinking of using those, and having the TOF sensors on each and just doing TX from that to a central Arduino. I need to send data one (or better 2x) per second.

I am afraid my only other (readily available) alternatives are ESP-01S and that might be slowish via WiFi and TCP/IP

The "nodes" will just take the raw sensor data and serial it directly to the central Arduino and nothing else. Distance between the nodes to the center Arduino is no more than 20 feet.

Anyone here with that experience or confirmation that three (3) or more arduinos can Serial to a single arduino? can this be done via SoftwareSerial? or AltSoftSerial? or any other library? (if so, any limitation?)

Anyone else have any suggestion (that hopefully) I have something cost effective?

The RF24l01 radios can have up to 6 slaves communicating with one master. Robin2 has a good introductory tutorial for those radios.

Thanks. I will make your suggestion as plan B as I was saving up my nRF24's for a next project.

In this project, there are 3 nodes and 1 master Arduino, the farthest node is just 20 feet away, the closest is less than a feet - so a wired solution preferred.

Then a serial solution. Use a Mega for the center as it has 3 extra hardware serial ports.

Or RS485. RS485 is made for longer distance and multi-drop.

Thanks for the fast response, luckily I found a sale item (Used like New) for a good price of an (original) Arduino Mega 2560 R3 which has four (4) serial ports. Thanks for the suggestion!

I have since discovered the limitation of the wire length of an I2C bus

Distance between the nodes to the center Arduino is no more than 20 feet.

I have I2C working reliably over about 25m to 30m, which is a lot more than 20 feet. I2C might not be designed for long cables, but it can be made to work.

last night, I did a quick test using a push button on a bare ATMega328 and the internal LED of an Arduino Uno over serial and I didnt like the speed of it, a bit of a lag even at 115200 baud with wire length of only 0.5 ft -- It's not as fluid as I hoped. My Arduino Mega 2560 R3 will arrive shortly, so I will give it another shot at that real soon on its secondary TX/RX ports

I have a (phase 2) project of an air quality sensor (MQ-135) running on a bare ATMega328 doing TX to (an already done) build using Arduino Nano IoT 33 which has a couple of other sensors that does MQTT and InfluxDB, so taking raw data over serial once every few seconds is okay for that extended project.

but the other project (a garage car park assist) comes with three (3) VL53L0X, one on the ceiling, other on the side and the other one on the wall facing the front of the car. hence the need to get this sorted out. I don't have enough VL53L0X's to experiment on as I dont want to wire it on a breadboard pins as it will be difficult to deal when it goes to its enclosure.

so I have a decision to make, but really thanks to all the suggestions here.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.