Raspberry PI multiple sensor network idea help

Thread Starter

zazas321

Joined Nov 29, 2015
936
Hey. I have some programming and hardware experience and I have been thinking about this idea for a while now! I would like to make a project for my house where I have multiple temperature sensors in different rooms in the house and maybe one temperature outside which would be able to send data to microcontroller. I could use raspberry pi with a display to show all temperature readings. However, my main concern is what is the best way to power up individual sensors in different rooms and what would be the most efficient way to send sensor data over the air to the microcontroller. Thank you for all the replies in advance..
 

dl324

Joined Mar 30, 2015
16,846
Since most RPi's have BT, that would seem like a logical choice. There are probably many libraries that have done the heavy lifting and will make interface easier for you. Could also use WiFi, but do you want to take the bandwidth hit?

Powering seems obvious. Batteries are the usual method.
 

Thread Starter

zazas321

Joined Nov 29, 2015
936
Batteries could be a way to go but I would not want a hassle to replace batteries every few months or even sooner... If I used a sensor such as DHT22 I would need to have some sort of BLE chip connected to every sensor so it is actually able to transfer data to the microcontroller. Would that be the most efficient way? 1583621666773.png
 

ErnieM

Joined Apr 24, 2011
8,377
You could use any one of a number of inexpensive "smart" computers such as the WeMos mini or anything based on the ESP8266 or similar. The D1 Mini has a mini USB connector for programming you can use with a cheap phone charger to power your temperature sensors. They cost 2-3 bucks each, especially in multiples with slow free shipping from China. Well supported with free libraries too.

I used a few to make some things that used an IR remote control to work with Alexa by putting an IR LED on them.

They connect via WiFi but the info/bandwith is as small as you want.
 

Thread Starter

zazas321

Joined Nov 29, 2015
936
Yeah thanks. I also was thinking about making and Xbee network as I used these devices before. But each xbee device costs like 15-20£ so thats probably not so good.. I had a quick look at that D1 mini and it seems perfectly reasonable for what I am trying to do..

What about the power consumption of the raspberry PI? Ideally, I would like that device to be running 24/7 so I can come and look at the screen and see the temperatures.
 

dl324

Joined Mar 30, 2015
16,846
Batteries could be a way to go but I would not want a hassle to replace batteries every few months or even sooner...
So you think requiring a power adapter and outlet to be nearby to be more convenient? If my remote temperature sensor required a hardwired power source, I wouldn't have it. I don't consider replacing batteries to be inconvenient enough that I'd want have to deal with a power adapter outside; haven't seen any that were rated for wet conditions.
 

Thread Starter

zazas321

Joined Nov 29, 2015
936
It depends on how often I would need to replace the batteries.. Every few months is okay but shorter than that would be pain.
 

ErnieM

Joined Apr 24, 2011
8,377
It depends on how often I would need to replace the batteries.. Every few months is okay but shorter than that would be pain.
I quite Agree. But it should not take too much extra circuitry to turn the remote sensor package on for a short time to make a report then back off. How often do you really need to sense the temperature anyway?
 

LesJones

Joined Jan 8, 2017
4,174
I have done a similar thing using HC-12 modules rather than Bluetooth modules. I think Bluetooth is only suitable for very short range links but the HC-12 works over a greater range depending on conditions and the antenna used. Each remote sensor is controlled by a PIC12F1840. The way it works is that the HC-12 connected to the Raspberry Pi send out an address of one of the sensors. The sensor then responds with a text string giving temperature and humidity from an DHT22 sensor. (I also have some remote sensor for monitoring battery charging using INA219s) As I have a relatively small number of remote sensors I use a very simple addressing system. It is the # character followed by a single character. Each remote sensor checks any character it receives. It then waits for a limited amount of time for the next character. If that character is that sensor's address it transmits it's data.
I mostly use the system with an HC-12 connected to my PC running a terminal emulator program (Teraterm.) to request readings.
I have used it with the Raspberry Pi to monitor battery charging every few minuets an recording the data to a file. This file can then be fed into a spreadsheet program which can produce a graph. For your application the Raspberry Pi could send out the address of each station in sequence and display the results or write them to a file. You have to make sure that you do not send the # character in the data from the sensors as it could be seen one of the other sensors as it's address.

Les.
 
Top