At home, I’m a happy OH user: raspberry, sensors and small automation, since OH1
Now I need to connect and control my garage door: some times it stays open during the night, and it is not so good…
The real problem is my garage is not directly connected with my LAN
I need to use a GPRS modem connected to the public internet and route my MQTT traffic to the “main” OH server in my home
And I don’t have any static IP on my internet router
I read some topic on this forum to use the OH cloud to sync two instances of openhab, but I want to use a small price contract with my GPRS operator, so I want to limit the traffic only to small MQTT messages
Any suggestion on how to build this network?
If you just have a sensor, using the OH Cloud will use as little data as MQTT as long as you are not streaming sitemaps or stuff like that. The only message traffic that you’d be sending between the two is one HTTP request from the Garage to the main OH instance when the sensor changes.
It’s not like there is a constant stream of data passing between OH and the OH Cloud server. There is a heart beat but MQTT has a heart beat too.
However, if you also have an opener to control, MQTT is going to be most data efficient.
The problem though is you must have an MQTT broker that both your main OH instance and your garage can find. So you need to:
- use CloudMQTT
- rent a virtual private server with a domain name or static IP address that runs your own MQTT Broker
- acquire a dynamic DNS domain and open ports on your network to the Internet so the Garage can reach your MQTT broker running on your home network. (I really do not recommend this approach unless you really know what you are doing, which if it were the case you wouldn’t be here asking the question, it’s really not safe).
Notice how all of these approaches essentially create a static IP/domain name for both your openHAB and garage to reach to talk to the MQTT broker. You can’t get around that requirement.
Rich, thank you for your consideration
the idea to have two OH instances and have Openhab cloud syncing is really excellent and ready to use
also, your project on GitHub seems to be interesting
still to understand how to connect the local system in the garage with a GPRS modem (which modem and which protocol), and if I can stay in the 200 MB monthly traffic of my contract
I’m exploring also two other ideas:
VPN with a PI in the garage and my main PI at home (I never made it but I saw it is plenty of tutorial on that). I could use external services and solve the problem I don’t have a static IP address
LoRa point to point link
The garage is too far from my flat for wifi (two blocks and 8 floors), but I saw some youtube videos by the guy with the Swiss accent with a fantastic distance covered, maybe it can work for me)
in this case, I can skip the GSM interface and don’t pay money to an operator
for sure, I must think of what I’m able to do, mainly considering my competences, and skip the best architecture that I could be not able to implement …
Have you got a line of sight?
I have made an interbuilding LAN bridge link over a couple hundred metres using a pair of scrap routers with WiFi, and cheap chinese panel antenna. The routers do support WDS mode, but for my purposes (and yours) older 2.4Ghz gear will do.
It’s a low-cost experiment.
already made several experiments with a yagi 25 dB directive antenna
unfortunately no way to connect the two sites with standard WIFI
I’m living in a city, the two blocks are made with reinforced concrete, the direct line is passing through all the floors slabs
and on top, plenty of neighbours with their own access points
In Hackspace Magazine (I think, maybe MagPi) there was a good article on LoRa using RPis, IIRC. You can download both as PDF for free on the Raspberry Pi Press website.
In Hackspace Magazine (I think, maybe MagPi) there was a good article on LoRa using RPis, IIRC. You can download both as PDF for free on the Raspberry Pi Press website. The article was mentioned on the cover so you should be able to find it.
I find this discussion really interesting from a technological perspective, but I wonder if it’s an over-complicated solution to the problem of “check that the garage door is closed”.
This is coming from personal experience, as I often get wrapped up in trying to make things work with openHAB…just because I think I can. Then I realize that it’s better to either have a separate system or revert to my pre-OH days and change my behaviour.
For example, there was a discussion long ago about putting a sensor in the mailbox to detect when there’s mail, which I found interesting and contemplated doing. But the simplest solution is to just make a habit of checking the mailbox and accept that sometimes there’s no mail.
In this case, I wonder if you “need” your garage OH system to talk to your house system. If not, you could have a self-contained system that publishes to an IFTTT webhook when the garage door has been open for a period of time, which could trigger a notification on your phone. The upside is that you wouldn’t need the OH cloud and you would only use data whenever your rule posts the webhook. The downside is that you’d have to walk to the garage to close the door, since it’s a one-way system.
The cheapest solution would be to adjust your behaviour such that you always make sure it’s fully closed before walking away, but I assume there’s more to the problem than just this.
And if you’re doing this in part for the joy of home automation, then ignore pretty much everything I just wrote.
@Russ I have a real problem with my garage door, and I need automation to solve it.
sometimes I forget to close, or I push the closing button and it stops because it hits on the bottom
so to prevent this problem I need to be warned
my real problem is not “how to do that”, but “how to connect the garage to my smartphone”
I don’t have wifi or internet in the garage, and the solution to put a GPRS board with a contract presents some disadvantages: to pay per month, to implement some drivers I don’t know
And the legacy SMS seems to me really obsolete
So the idea to use openhab is to solve all these problems seems to be a quick way to solve it
If all you have is a hammer, everything looks like a nail…
@Rich, you tempted me, I ordered 3 TTGO Esp32 LoRa modules on amazon
ESP32 board because I feel more comfortable in developing on embedded systems - remember the hammer…
I will update you soon
This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.