HassOS + Serial Gateway OR Docker + RPI Ethernet Gateway



  • Hi,

    currently I'm using MySensors RPI-Gateway and MyController on the same RPI 2 .
    I connected a RFM69 Modul directly to the GPIO of the Pi.
    This system works fine for many Years.

    Now its time for an upgrade.
    I want to use HA and I want to add ZigBee devices. For that I purchased the SonOff Dongle-P and I grapped a RPI 3 for testing HA parallel to my running setup.

    Now I want to tidy up. Two RPI for a task, which one alone can do is not the best solution.
    The question of all questions is now, how to combine HA, MySensors and Zigbee in the best way?

    Option 1 (I have to build the serial GW, and ICs (328P) are rare at the moment):
    HassOS + MySensors Serial Gateway (RFM69 connected to an ATMEGA328 connected to the UART-pins from the RPI) + ZigBee USB Stick. (I dont want to use a UART<-> USB chip, when a RPI has native UART on the GPIO)

    Option 2 (Favorite, because I dont have to build hardware stuff):
    HA running in Docker + MySensors RPI Gatway (RFM69 connected directly to the GPIO) + ZigBee USB Stick. (I found a tutorial for installing HA in Docker with Supervisor)

    Are there any pitfalls in the Options above?
    Can I use the UART Port "/dev/ttyAMA0" in HassOS?
    Are there any limitations in Option2, when HA running in Docker?

    I hope someone can give some tips.

    Thanks!
    Sebastian



  • I had a similar conundrum, though it was Z-Wave instead of Zigbee.

    I have a concern that an RPI is not sufficiently robust. This may be unfounded because there are a lot of amazing things that people do with it. Be that as it may, I found a refurbished PC on Amazon for under $100, well under the current price of an RPi! (I bought the $10, 2 year warrantee, too) On this I installed Virtualbox and installed Home Assistant OS on it. I allocated a USB port for the virtual machine and plugged in a Z-Wave dongle.

    The downside of the computer is that the video is VGA, so one needs a VGA monitor (and mouse and keyboard) to set it up. The computer is run headless and I remote into it with VNC, thus the VNC server process is also running on it. The free version of RealVNC allows five server licenses, and unlimited viewers.

    I like the concept of using MQTT and chose that over serial. Also because because the computer is located in the garage and the gateway needs to be on the other side of the house near my sensors and actuators which are in the back yard. So, I run the gateway on my RPi (the one I bought for $35). My MQTT broker runs as a separate process on this computer, "next" to Virtualbox.

    Note that the gateway can run on an Arduino Nano which could be plugged into this computer which would be, not only a cost effective solution, but IMHO, more robust. (I just had a thought, run HAOS on the RPi and plug the Nano into the RPi ... would this work?)

    So when I'm working out in my yard, I VNC into this computer with my phone, pull up Firefox to bring up the HA interface and view and control my devices in the yard. (Think HA has an app, but I haven't tried it ... I don't like cloud based apps.)

    Just some thoughts for you.

    Good luck on your project!

    OSD


  • Mod

    @OldSurferDude the HA app is local, no cloud involved. (With the exception of app notifications which go through firebase)



  • Thanks @mfalkvidd! I just automatically made the assumption the any app on a phone is cloud based. A personal myth busted, for which I express my appreciation!

    OSD



  • @se-O-matic said in HassOS + Serial Gateway OR Docker + RPI Ethernet Gateway:

    Can I use the UART Port "/dev/ttyAMA0" in HassOS?

    Yes.

    @se-O-matic said in HassOS + Serial Gateway OR Docker + RPI Ethernet Gateway:

    Are there any limitations in Option2, when HA running in Docker?

    Not that I can think of. Supervisor might be unhappy about "unsupported" setup, but it will work. They invented very strict guidelines for supervisor setup, apparently to lift any "responsibility" in terms of support for what people may come up with in their setups. But everything usually works anyway.



  • Thanks for the answers. 🙂

    I want to keep the raspberry pi as central. This should fit all my needs in my rental apartment.
    For HA, I have chosen a SD-card with application class A2.

    For a clean setup, i will try to run HA in docker. So can i use the same Raspberry as gateway and for the controller.
    So I dont have to use a "rare" mega328p for a serial gateway.

    I report my results, when I find some time to work on it.


Log in to reply
 

Suggested Topics

  • 2
  • 10
  • 5
  • 6
  • 22
  • 10
  • 4
  • 38

121
Online

10.7k
Users

10.9k
Topics

111.8k
Posts