I currently have OpenHAB running an an RPi 2 with a Aeon Z-wave stick. So far I only use it with Z-wave but I’m ready to start playing with devices through MQTT. Eventually I plan on putting together some things using ESP-8266 chips and I’ve been ordering parts from China over eBay to play around with them.
I have a few DHT-22s (and other sensors). Is there any reason why I shouldn’t connect them to the RPi 2 that I’m already running OpenHAB and mosquito on? My OpenHAB RPi is in my server rack and it would be nice to monitor the temperature and humidity (plus maybe other things). Instead of putting together another device, wouldn’t it make sense to just hook the sensor(s) up the RPi’s GPIOs?
Has anyone done this and if so, can they point to some instructions? I’m not finding what I’m wanting.
I have not done so myself (yet!) but I see no immediate reasons why you should not be able to (or want to) connect the sensors directly to the RPi.
As for instructions on how to do this, maybe this link can help?
DHT Humidity Sensing on Raspberry Pi …
The only reason not to that I can think of is if the raspberry pi is not physically located close enough to where you want to sense.
[quote=“rlkoshak, post:3, topic:7408, full:true”]
The only reason not to that I can think of is if the raspberry pi is not physically located close enough to where you want to sense.[/quote]
For me that’s a non-issue since it’s in my server rack and that’s where I want to measure temp/humidity. i am thinking that I might want to have some distance between the sensor and my equipment, but nothing too much.
I’ll make this my first sensor experiment rather than try the ESP-8266s. i wonder if there is any issue having an MQTT devices on the MQTT broker. I guess I’ll find out soon. With luck I can make simple instructions for others running OpenHAB off a RPi who want to use a sensor.
No problem. I run my broker on the same machine as openHAB and another script that publishes over MQTT. The broker (Mosquitto in my case) is really light weight and it plays well with others.