Has anyone used OpenHAB with Lorawan?

Hi Forum,

As I read and learn more about IOT and home automation, I’m trying to determine the best IOT transport method to use to capture and collect my data. z-wave definitely has the options when it comes to the sensors and other devices that I can connect to each other. But Lorawan devices and sensors has the distance! For my use case to monitor our boats in the boathouse I’m wondering if Lorawan would be a better choice for the sensors and gateway hub I use. I’d like to explore all options so I’ve been searching on how to use OpenHAB with Lorawan. I see that Lorawan can connect to a cloud server called the Things Network. I’d rather host my own and use OpenHAB.

Has anyone setup or have experience with using OpenHAB with a Lorawan network of devices? Am I able to do this with OpenHAB or is this just not possible?

Thank you.

2 Likes

Hello

I am no expert compared to many on here, and I do not use LoRa devices (I do use some devices called Moteino, that work on more traditional radio frequencies). If I was starting again (!) I would definitely look at LoRa as even in my relatively small house, I suffer from weak signals and of course battery problems.

I use Zwave for lights and power switching, this has a binding which is very easy to configure given the hugh variety of Zwave devices available. But I found them pricey, so I use Moteinos as well. You mention monitoring - this is what I tend to use Moteinos for - presence, temperature etc. Zwave is more robust and well equipped for controlling electrictal devices etc

I don’t know that there is an out-of-the-box for LoRa and Openhab in terms of a binding. The same is true of Moteinos - no “binding”.
Therefore, many people use a generic transport such as MQTT to pass data to/from OpenHAB. This is slightly trickier to set up than a binding, but only a little, and its a well documented approach.

For example:
In my case, with the Moteinos, they communicate to a “gateway Moteino” which passes information, over USB, through a small Python program onto MQTT. OpenHAB is subscribed to MQTT (more specifically topics) and I have associated key information (states, temperatures, changes) with OpenHAB items (lights, switches, temperatures etc).
All this I adapted this from examples shared on this forum, and the Moteino forums. The members of both I have found to be extremely helpful, patient and knowledgable.

All this is accomplished without any dependency on external systems or cloud solutions, but I did have to a) come with a plan for the information I wanted to send around [schema], b) adapt the python program [gateway], b) configure MQTT [transport] c) configure OpenHAB [control] d) have the means to host all these things somewhere [hosting].

Hope that helps.

Hello @nick_balch, thanks very much for this helpful response. I’ve not heard of Moteino before…so many players in this IOT market that I always come across something new!

Makes sense that MQTT could be the protocol that will allow me to send my data to an OpenHAB server. For your case, what did you use to install MQTT so the data from Moteino could be sent to your OpenHAB? Did you have to change or reformat the data collected before OpenHAB would accept it?

I’m planning on using a Raspberry Pi with the Lorawan addon board to talk to my Lorawan sensors. On the Pi I will install MQTT as well but will need to better understand the format the OpenHAB requires for the data I collect and send to it.

Thanks.

Hi @greavette

I installed Mosquitto, and Paho-mqtt for python - both are available on Raspbian.

I do have to reformat the data, as I send just a simple set of digits from the Moteinos thus my python program reformats this into a set of topics in MQTT.

I think strictly speaking, this could all be accomplished through rules within Openhab, or even with a regex in the item itself. OpenHAB could also probably read direct from the serial port also!

Another avenue to investigate is whether the Lorawan addon board provides some sort of web api interface - REST or similar - you could then have Openhab directly interrogate that API with no recourse to another transport…

Hi

Any new about a new LoRaWan binding ?

I would like to switch my transmitter (RFM69 + teensy) -> receiver (RFM69+teensy) -> server (MQTT + OH) to a LoRa IOT network.

Nick, your network seems to be close to mine. Did you work around with LoraWan ?

Vincent