Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. Controllers
  3. Home Assistant
  4. Need help with Hass.io and serial gateway.

Need help with Hass.io and serial gateway.

Scheduled Pinned Locked Moved Home Assistant
4 Posts 4 Posters 370 Views 5 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    alexc
    wrote on last edited by alexc
    #1

    Hi all,

    I have a serial gateway connected to the RaspberryPI running Hass.io.
    I've also built a sample BinarySwitchSleepSensor.
    I can see the logs on the serial gateway - it seems like it receives the messages from the sensor just fine.
    My problem is that I cannot see the sensor in the Home Assistant, no matter what I do...
    Running ls -l /dev/tty* command brings me this:
    0_1572020689657_009e0b97-ebbc-4821-826a-b342be69ce64-image.png

    The configuration.yaml contains the following section:

    mysensors:
      gateways:    
        - device: '/dev/ttyAMA0'          
      optimistic: false
      persistence: true
      retain: true
      version: '2.0'
    

    In one of the attempts I actually saw the sensor (even two, for some reason) though the state never changed.
    I'm unable to see them anymore...

    Some more info:
    After RPI reboot, the "hassio hardware info" command shows:
    0_1572073791399_0ced1a7b-3041-448b-a8bd-e6ef0a1497c7-image.png

    But after reattaching the USB I see
    0_1572073885845_082f4665-b17c-4d54-986f-6777857d6781-image.png
    So, it seems like the gateway is invisible after the boot. Chanding ttyAMA0 to ttyUSB0 in the configuration file just results in error notification on boot...

    Can someone please help me with this? What am I doing wrong?

    Thanks,

    Alex

    monteM 1 Reply Last reply
    0
    • SebexS Offline
      SebexS Offline
      Sebex
      wrote on last edited by
      #2

      @alexc I can't help you but I do have a question. What steps did you take to make the raspberry the serial gateway and run hass.io on the same time. To run hassio you need to flash the raspberry sd card right?

      1 Reply Last reply
      0
      • A alexc

        Hi all,

        I have a serial gateway connected to the RaspberryPI running Hass.io.
        I've also built a sample BinarySwitchSleepSensor.
        I can see the logs on the serial gateway - it seems like it receives the messages from the sensor just fine.
        My problem is that I cannot see the sensor in the Home Assistant, no matter what I do...
        Running ls -l /dev/tty* command brings me this:
        0_1572020689657_009e0b97-ebbc-4821-826a-b342be69ce64-image.png

        The configuration.yaml contains the following section:

        mysensors:
          gateways:    
            - device: '/dev/ttyAMA0'          
          optimistic: false
          persistence: true
          retain: true
          version: '2.0'
        

        In one of the attempts I actually saw the sensor (even two, for some reason) though the state never changed.
        I'm unable to see them anymore...

        Some more info:
        After RPI reboot, the "hassio hardware info" command shows:
        0_1572073791399_0ced1a7b-3041-448b-a8bd-e6ef0a1497c7-image.png

        But after reattaching the USB I see
        0_1572073885845_082f4665-b17c-4d54-986f-6777857d6781-image.png
        So, it seems like the gateway is invisible after the boot. Chanding ttyAMA0 to ttyUSB0 in the configuration file just results in error notification on boot...

        Can someone please help me with this? What am I doing wrong?

        Thanks,

        Alex

        monteM Offline
        monteM Offline
        monte
        wrote on last edited by
        #3

        @alexc I don't know for sure, but it can be permission issues which you probably won't be able to fix as you are running hass.io. I suggest using docker image of the Home Assistant on a plain Raspbian install. This you way you will get full access to all features of your Raspberry.

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mysensors-newbie
          wrote on last edited by
          #4

          Did you solve your problem? I had a similar problem, but using an Ethernet gateway, until I discovered that my sketch was not using the 2.x API, contrary to the gateway. This is also the case for the BinarySwitchSleepSensor you mention. You might want to try with a sketch based on the last one on this page (using the 'initialValueSent' variable): https://www.home-assistant.io/integrations/sensor.mysensors/#mysensors-2x-example-sketch
          After updating to the 2.x API, my sensor showed up in the entities list of Home Asisstant (v0.106.6, HassOS 3.12, on Raspberry Pi 3) and I could create a UI card for it.

          (For some reason the entity is read-only in Hass.)

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          24

          Online

          11.7k

          Users

          11.2k

          Topics

          113.1k

          Posts


          Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • MySensors
          • OpenHardware.io
          • Categories
          • Recent
          • Tags
          • Popular