In the planning stage of a project. We have two pumping stations located far away from each other and we want to monitor water-levels, water-flow etc. at the two stations. Both have internet access but are too far away from each other for any wired or WiFi connection. My first thought is to install a Raspberry Pi with Home Assistant at one of the stations but I am uncertain what the best solution is for the second station. Another Pi/HA but how should these two instances communicate? I have very little experience of this type of communication an would be very grateful for any suggestions
what exactly is the distance between the locations and is there a clear line of sight between them, or not?
You would put your HA somewhere close by where you can manage it.
Then set up 2 site-to-site vpns. Each location should have a different subnet eg:
home: 192.168.1.X
Pump location1: 192.168.2.X
Now just set up a esph. Device on those pump locations and connect them to esphome and to home assistant.
The total solution is going to be quite complex and too much to put in a post. But that should give you an idea
No these are several kilometers apart and no line of sight
So you are thinking that the sensors in the pump stations are connected to an ESP32 dev board which is in turn connected to its local router. VPN tunnel from there to one instance of Home Assistance which is also connected to the internet via its own router with vpn (one to each station). With this connection all the sensors can be included in Home Assistant using ESPHome on that unit?
Of course! aslong as HA can communicate to the esphome device all sensors should be available.
My solution is to use Tuya devices. Once they are in the Tuya App, they will show up in HA even when at different locations and can be used in HA Automations.
That is also one way of solving the problem!
another option is to use tailscale. there is an add-on for home assistant and it basically joins 2 remote networks. you just need something to run it on at the pump end, just a pi or a router capable of running it.
I use it regularly for getting to the web portals of devices on my home network while I’m away… HA is always running, i turn on tailscale on my phone and its like I’m connected to my home Wi-Fi.
meaning: depend on the willingness and availability of tuya. VPN would be better solution
Which is in fact a VPN. Excellent choice!
Also: loraWAN could be a solution depending on in what country you are. This requires a gateway as well.
Is it possible to run Tailscale directly on a router? Plan was to use an ESP32 dev board to host the sensors. and that board would reach the internet via a router. Perhaps better to put an Pi Zero or similar between to esp32 and the router?
Not every router supports tailscale. Most routers however support other VPN’s / openVPN. I dont know your (remote) network, but you can run a tailscale on a Pi
Teltonika routers support Zerotier, an another way to create a network, similar to Tailscale.
I did not say that it is the best solution… Just another way, and btw it works for me.
I have been looking at Tailscale and this certainly seems like a great alternative for my project - Thanks to all who have taken the time to give me advice. Big thumbs up!