Gateway for other protocols?



  • I assume I have not found my answer because this is not possible. I'll ask anyway to be sure.

    I want to use both MySensors and commercial sensors in my setup. I constructed an Arduino project a few years ago that decoded 3 different commercial sensors transmitting on 433MHz and sent the data to my HA system via MQTT. It functioned under ideal circumstances but was not reliable primarily due to range issues. I planned to migrate from an UNO + w5100 + superheterodyne 433MHz receiver to an ESP8266 (NodeMCU) + RFM69. At the time, I had no joy in getting the code to work as Arduino on ESP was new and buggy. I have tried recently and not gotten better results.

    So, I was wondering of MySensors gateways can receive both its own traffic as well as 433MHz commercial sensors. Obviously some code might be needed to define the protocol and properly decode. But, I don't want to waste lots of time hacking on the code that will never be capable.

    Any thoughts?

    Tl;Dr - can MS read RF from commercial sensors?



  • @bkenobi I would not look necessarily to MySensors to do all of this. I would look at something like this more from the controller level instead of the gateway level. A MySensors gateway and a 433 MHz receiver would in my eyes be gateway level components to the system. The controller level would be software and/or hardware such as Domoticz, OpenHAB, Vera or something like that. Let your controller be the bridge between sensor types/protocols. If you were previously using MQTT, the logical assumption would be that you had a broker in pace to run it. Did you use any kind of controller software with your other setup? Having a controller in place would be your bridge, in a sense, between your hardware types. So for instance if you were running Domoticz, you would have a MySensors gateway set up to handle your MySensors nodes/hardware, and then a 433 MHz receiver set up to handle all of your 433 nodes/hardware. The Domoticz controller software with LUA scripting would then handle the logic between hardware types.

    In my setup I use MySensors, OneWire, RS485 and Sonoff devices on WiFi as my different types of hardware. My controller is currently a Vera Plus box which integrates all of that together. Previous to that I use Domoticz. My controller can take information from my MySensors devices, translate it, and use the information to control say my Sonoff relays or other things.

    Does that make sense?



  • I have a RPI running a MQTT broker and HomeGenie. HG receives the MQTT messages and converts them for use with X10 primarily. I could have a 433MHz-to-MQTT gateway and a MySensors gateway. I'm currently having a heck of a time finding a solution to receive the 433 on the ESP though. I've yet to find working code that works with the RFM69 to receive commercial RF sensors. Any suggestions (if MySensors won't work) would be very much appreciated.



  • @bkenobi I took a look at the HomeGenie website. From the looks of it you want to look for someone that has made a widget for a 433MHz receiver. Another option if you are up to it, you could switch to something like Domoticz which has support for many types of hardware, including 433 MHz. Domoticz will run just fine on a Raspberry Pi. One of those two solutions is going to be easier than trying to bridge a 433 MHz to MySensors. I say that because I have built a bridge to MySensors, and it took a long time to figure everything out. It was to bridge my RCS TR40 serial thermostat over to MySensors. I had coded an interface for it in c# a few years back for a different automation software package that I used to use called Open Source Automation. Even having the information from my old C# code it took a while because I had to learn MySensors.



  • I've been using HG for several years and have a lot of time setting things up the way I want. At the time I selected HG, Dominicz didn't look like an option but it's definitely matured and I've recently considered it as a switch. HG's author has decided to step back a bit and the future isn't as secure if updates are required.

    That said, I didn't opt to install a RFM69 directly onto the RPI since I wasn't sure it had sufficient power to run HA and do real time processing of 433MHz signals.



  • @bkenobi said in Gateway for other protocols?:

    I've been using HG for several years and have a lot of time setting things up the way I want.

    I can understand that. I did a little more looking and I do see that HG supports RFXCOM which is a 433 MHz transceiver. Have a look to see if RFXCOM supports the hardware you are trying to control. As mentioned, finding something that supports your 433 hardware already is going to be easier than trying to code a bridge to MySensors.



  • I've looked at rfxcom a few times. If there was a way to extend the existing sensor database, I would probably just do that. It can transceive X10 and a lot of other code, so if it were customizable it would be an ideal solution.

    I've found several examples of Arduino code that decode various sensors but I've struggled to locate an ESP compatible version. Maybe it's just that most of my 433 receivers ar 5v and won't work on 3.3v logic. That's where the rfm69 comes in. But I haven't found code that works with it...



  • @bkenobi What kind of hardware are you talking to?



  • I have 3 sensor types that I am currently trying to decode. I have the protocol decoded for all 3. Two are Acurite sensors (5in1 weather station, temperature sensor) and one is a power meter reader (Blueline power meter reader). Both have a WiFi device available, but both are overpriced and, more importantly, upload to a cloud server rather than making a Ata available locally.



  • @bkenobi If you were going to bridge those to MySensors, you would have to code the actions for each of the 3 sensors into the bridge you build. You would first want to map each of the actions to a particular MySensors sensor type and value found here
    Once you have them mapped, you need to code a translator for each function you need in each direction. From MySensors to the device, and from the device to MySensors.

    When I did the one for my thermostat, I was lucky enough to have all of the commands documented from the company which was a HUGE help as I didn't have to decode them like you did.



  • I was able to locate documentation from others who decoded the devices already. In truth, they are very simple as they only send 1 or 2 packets. Your thermostat presumably sends all kinds of info out and each packet could contain very different data.

    I may go back to my old code first and give it one more run since it really just needs ESP8266 and RFM69 compatibility added to it. That should be easier than porting the decode algorithm to either MySensors or another project.

    My original goal was to simply use OpenMQTTGateway with my added protocols and decoders. That didn't work well, so I've made no real progress.


Log in to reply
 

Suggested Topics

  • 4
  • 2
  • 9
  • 2
  • 4
  • 8

10
Online

11.4k
Users

11.1k
Topics

112.7k
Posts