HA<=(MQTT)=>Lora (Gateway)

Hi,
I have tested some devices, like sonoff, to do automation in a residential environment. The sonoff devices are based in wifi technology, the range of this technology is very limited, is 2.4 Ghz (lower penetration) and in big homes is a problem to do coverage in some distant divisions. And if we need send sensor data or control some devices located in outdoor, (Garden sensors, gate control etc) is a biggest problem.

I think is not only my problem, but this problem is commun to most people that have a big house, and garden.

To solve this problem, iam trying developing a sensor network based in Lora techonoly to get a big coverage, in indoor and outdoor to.

My project idea, is develop a Gateway, based in MQTT techology to connect the devices to the HA and bridging the MQTT packets to the correspondent Lora Node.

The adress of node is represented in the command_topic, for example:

command_topic: “B9AD/0015/d/led” -> “d” for downlink
state_topic: “B9AD/0015/u/led” -> “u” for uplink

The B9AD… is like a network address, unic for each gateway.

Here: B9AD0000 is the gateway address.

Here: B9AD0015 is a Lora Node address (0015).

If the adress topic corresponds to the gateway B9AD0000, the topic is destined to or originated by the gateway, this give us possiblity, to control and receive some stats of the Gateway.

For example:
The Gateway can be equiped with a internal battery, when the Home Power goes down, the gateway can inform the Home Power stat, publishing for example in the topic: “B9AD/0000/u/pwr”

If the topic have a adress B9ADXXXX (XXXX!=0000) the packet is destined to a Lora Node XXXX.

For example: B9AD0015
When gateway receive the topic with B9AD0015 Addr, the gateway redirects the packet to the Lora Node (0015), and vice versa, when some sensor need to send data to the broker.

This way we can connect Lora Nodes to the HA and control it transparently way.

This video is a simple demonstartion of te current developing.
You can see in the video, controling (Led) and receiving (Button state) in the HA, using a Lora Node.

Video Link

Is a good way to increase the range of ours devices, do a big coverage for the home indoor and outdoor.

3 Likes

Very interesting! Keep us posted.

Thanks for the share, would you be kind enough to share with us some schemas of setup ? and how you made it work ? :wink:

I’ll soon share the schematic of the gateway.
Right now I still have a functional prototype.

Any update on this interesting topic? I was unable to open the linked video.

Hi!
Yes I have a functional Gateway working for tests only.

Some test videos. Mqtt to Lora in HA.
Video 1: [https://youtu.be/NYsO36SNZhg]
Video 2: [https://youtu.be/y7FuTc5PSeM ]

Can you share Firmware from ESP
and which module you use for LORA ?

1 Like

Hi, any updates on your project? I’m thinking about writing a LoRa gateway.

Hi,

For your info Openmqttgateway supports Lora

1 Like