Multiple Bluetooth Project - UBC Engineering Student

Hello everybody,
I am new to the Arduino forum. I have read many forums and have not found anything (so far) that covers the project i am about to dig into.
I am a mechanical engineering student at UBC and have been given a project that is heavy in electronics, which unfortunately is my weakest engineering skill.

The project description summary:
We want to do multiple soil analysis' in a farmers field using "Probes". These Probes will have a handful of sensors (moisture, temperature, NPK, etc.), they will have a power supply, a microcontroller (I am assuming an Arduino Uno R3, although i can use anything available on the internet), and it will have a DSD TECH HM-10 Bluetooth module.
There will be 5 Probes.
I want each of the probes, using their Bluetooth in slave mode, to send soil data to a central unit. This central unit will be shared amongst the 5 probes. This central unit needs to have a microcontroller (I am assuming an Arduino Mega), it will have its own power supply, and I am assuming it will have 5 (master) Bluetooth modules as specified above.
The central unit will use a MKR GSM 1400 to send the collected probe data into the cloud.

The problem:
I am having trouble finding a method for the Arduino mega to accept the Bluetooth data from 5 probes. I am troubled because, to my understanding, i can only get the Arduino Mega to have a total of 4 RX/TX pins (0+1, 19+18, 17+16, 15+14).

Summary:
Receiving the the soil data and sending it to the "central unit" via bluetooth is not a problem. I just do not have a solution to how i can make the "Central Unit" accept all this data. It would be a huge bonus if i could upgrade to a single (Master) bluetooth module that could communicate with 5+ probes, but i am not aware of a bluetooth module that can do that. Perhaps my solution is just using a good serial.listen code and scheduled probe data?

As of now, i do not actually have the electronics. As noted, i am assuming i will use Arduino Uno, Mega, and MKR GSM 1400, bluetooth module etc... I am open to completely new ideas.

Any help is appreciated. I look forward to reading the responses!
Thank you

Must you use Bluetooth? The rf24 radios may be a better fit. Up to 6 rf24 slaves can talk to one master. And the rf24 range is usually more than Bluetooth. Robin2’s simple rf24 tutorial was a big help for me learning the rf24 radios.

Bluetooth in inherently point-to-point so you'll have a pair per node, not ideal for a hub-and-spoke topology. Are you limited to Bluetooth? There are other RF modules that can simplify things for communication.

If you must use Bluetooth, then there are not enough hardware serial ports on the Mega. You can certainly get a multiplexer such as these that will breakout 4 UARTs per MEGA serial port. You can get two which will give you 8 UART ports.

https://www.mouser.com/datasheet/2/272/uart-mux-click-schematic-1863756.pdf

groundFungus:
Must you use Bluetooth. The rf24 radios may be a better fit. Up to 6 rf24 slaves can talk to one master. And the rf24 range is usually more than Bluetooth. Robin2's simple rf24 tutorial was a big help for me learning the rf24 radios.

Oh wow, how did i not know about RF?! I am definitely able to switch to RF instead of bluetooth. I will refer to that tutorial in the morning, as my current time zone, it is late. Thank you so much!
I have a feeling this may have solved my issue, but if anyone else has suggestions or even more links/forums to suggest i read on RF or anything else, please do share! Thanks again!

The UNO is not really a good choice for something like this, use a Nano or Pro Mini instead - same processor, but much smaller board. The Pro Mini is also much better suited for battery operation.

I'm not familiar with the MKR GSM 1400, but I would at least try doing all the processing on that board and eliminate the Mega, particularly since you will not be needing the multiple serial ports with the RF module.

Hey everyone, so I have achieved a lot in the past while but now i am at a roadblock again.

I have a Transmitter (called Probe) that is an arduino nano and nrf24L01. If has a DHT11 that i have coded that works and transmits to the receiver properly. The transmitter also has 3 wire temperature sensors and 3 soil moisture sensors that are not coded in.
I did use the test code provided by circuit.io and all the sensors work and will give values to the serial monitor but now with my new code to send this data over to the receiver i do not know how to do it.

Can anyone help me add to my code or modify my code so i can send the 3 soil and 3 temperature sensor data with the DHT11 data?

Ill try to attach the code below:

CentralUnitTrial1.ino (680 Bytes)

ProbeTrail1.ino (1.03 KB)

heres a pic

I guess you are on your way, and have plenty of money, but I submit something from the ESP8266 family would be a far better choice. It's a dirt cheap all-in-one chip that can talk directly to your phone, or any other device with WiFi.

Nick_Pyner:
I guess you are on your way, and have plenty of money, but I submit something from the ESP8266 family would be a far better choice. It's a dirt cheap all-in-one chip that can talk directly to your phone, or any other device with WiFi.

I dont have wifi where this device will be used. My current setup will not be changing as i know it can be done but im having trouble doing it

Anybody able to help me out with this?

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