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. unable to open USB port

unable to open USB port

Scheduled Pinned Locked Moved Home Assistant
23 Posts 4 Posters 7.9k Views 4 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.
  • chillimanC
    chillimanC
    chilliman
    wrote on last edited by
    #4

    martinhjelmare
    i had to check the info from the gateway and sensor on a different m/c for some reason the install on Debain 8.5 i was unable to access the desktop .
    for the gateway :-
    0;0;3;0;9;gateway started, id=0, parent=0, distance=0
    0;0;3;0;14;Gateway startup complete.

    for the sensor( motion sensor)
    send: 3-3-0-0 s=255,c=0,t=17,pt=0,l=5,sg=0,st=ok:1.5.1
    send: 3-3-0-0 s=255,c=3,t=6,pt=1,l=1,sg=0,st=ok:0
    sensor started, id=3, parent=0, distance=1
    send: 3-3-0-0 s=255,c=3,t=11,pt=0,l=13,sg=0,st=ok:Motion Sensor
    send: 3-3-0-0 s=255,c=3,t=12,pt=0,l=3,sg=0,st=ok:1.0
    send: 3-3-0-0 s=1,c=0,t=1,pt=0,l=0,sg=0,st=ok:
    0
    send: 3-3-0-0 s=1,c=1,t=16,pt=0,l=1,sg=0,st=ok:0
    1
    send: 3-3-0-0 s=1,c=1,t=16,pt=0,l=1,sg=0,st=ok:1
    0
    send: 3-3-0-0 s=1,c=1,t=16,pt=0,l=1,sg=0,st=ok:0

    add both:-
    0;0;3;0;9;gateway started, id=0, parent=0, distance=0
    0;0;3;0;14;Gateway startup complete.
    0;0;3;0;9;read: 3-3-0 s=1,c=1,t=16,pt=0,l=1,sg=0:0
    3;1;1;0;16;0
    0;0;3;0;9;read: 3-3-0 s=1,c=1,t=16,pt=0,l=1,sg=0:1
    3;1;1;0;16;1
    0;0;3;0;9;read: 3-3-0 s=1,c=1,t=16,pt=0,l=1,sg=0:0
    3;1;1;0;16;0

    hope you make some sense of this numbers
    if you need any info please let me know so i can get it for you , do you know why i can not open the debian desk ?
    chilliman

    1 Reply Last reply
    0
    • martinhjelmareM
      martinhjelmareM
      martinhjelmare
      Plugin Developer
      wrote on last edited by
      #5

      The serial output looks good. Now you should check the permission and ownership information of the usb device on the computer. But of course you need access to that first. Have you had access to the desktop before? How did you install Debian?

      1 Reply Last reply
      0
      • chillimanC
        chillimanC
        chilliman
        wrote on last edited by
        #6

        hi.
        i was not able to access the desktop from the start i reload the OS three time make sure i select the correct option (the one i through i needed), as it boots up it ask me for my password screen clears and comes up with Opp's where was a problem and goes back to the sign in screen

        chilliman

        1 Reply Last reply
        0
        • martinhjelmareM
          martinhjelmareM
          martinhjelmare
          Plugin Developer
          wrote on last edited by
          #7

          If it's a fresh install and you don't mind wiping the disk or partition , it might be easiest to just reinstall the complete OS, if you don't know what's wrong. Otherwise try googling the error message.

          I'm using Ubuntu myself which is another distribution but based on Debian. If you don't have a specific reason for choosing Debian, I would recommend Ubuntu. My installs have gone without hiccups for probably more than 90% of times over multiple different systems for more than 10 years that I've been using Ubuntu.

          1 Reply Last reply
          0
          • chillimanC
            chillimanC
            chilliman
            wrote on last edited by
            #8

            martinhjelmare
            what version of ubuntu do you i should i use 14.04 ,15.10 or 16.04LTS i am more that happy to reinstall the OS i am just trying to get Home Assistant and MySensors working correctly

            thanks for you help
            chilliman

            1 Reply Last reply
            0
            • D
              D
              drock1985
              wrote on last edited by
              #9

              @chilliman

              Go with the latest LTS build of Ubuntu. LTS stands for Long Term Support and guarantees security updates to that version for 5 years(?); and can be easily updated to the latest if you wish.

              Also depending on what you comfort level is with Linux in general. there are several other flavours/distributions of Ubuntu, including a Server edition that is completely text based and uses the least system resources.

              My Projects
              2 Door Chime Sensor
              Washing Machine Monitor

              1 Reply Last reply
              1
              • chillimanC
                chillimanC
                chilliman
                wrote on last edited by chilliman
                #10

                Martin.
                i have purchased a raspberry pi 3 running Debian Jessie loaded Home Assistant which working great i have add MySensors Gateway with a motion sensor node there is no error as regards to not opening the usb port (it says found and has open it) what i am getting error :-

                16-07-17 16:46:03 mysensors.mysensors: File does not exist or is not readable: path/mysensors.json
                16-07-17 16:46:03 mysensors.mysensors: Trying backup file: path/mysensors.json.bak
                16-07-17 16:46:03 mysensors.mysensors: File does not exist or is not readable: path/mysensors.json.bak
                16-07-17 16:46:03 mysensors.mysensors: Failed to load sensors from file: path/mysensors.json

                what do i have to do to get this working correctly any ideas

                chilliman

                1 Reply Last reply
                0
                • D
                  D
                  drock1985
                  wrote on last edited by
                  #11

                  The error says it. You have persistence turned on, but the file location is invalid or you do not have read/write access to it.

                  What user are you using to turn on hass and what does the MySensors entry of configuration.yaml look like?

                  My Projects
                  2 Door Chime Sensor
                  Washing Machine Monitor

                  1 Reply Last reply
                  0
                  • chillimanC
                    chillimanC
                    chilliman
                    wrote on last edited by
                    #12

                    drock1985
                    do you have to have the persistence turned on , i turn on hass with pi (user)

                    mysensors:
                    gateways:
                    - device: '/dev/ttyUSB0'
                    persistence_file: 'path/mysensors2.json'
                    baud_rate: 115200

                    if i turn the persistence off i get a different error

                    16-07-17 21:42:41 mysensors.mysensors: File does not exist or is not readable: /home/pi/.homeassistant/mysensors1.pickle
                    16-07-17 21:42:41 mysensors.mysensors: Trying backup file: /home/pi/.homeassistant/mysensors1.pickle.bak
                    16-07-17 21:42:41 mysensors.mysensors: File does not exist or is not readable: /home/pi/.homeassistant/mysensors1.pickle.bak
                    16-07-17 21:42:41 mysensors.mysensors: Failed to load sensors from file: /home/pi/.homeassistant/mysensors1.pickle

                    any ideas?

                    chilliman

                    1 Reply Last reply
                    0
                    • D
                      D
                      drock1985
                      wrote on last edited by
                      #13

                      Your path to the persistence file is wrong. You need to choose a directory that your user (in this case pi) has access to. I would recommend using /home/pi/.homeassistant so that your configuration.yaml flie would look like this:

                      mysensors:
                        gateways:
                          - device: '/dev/ttyUSB0'
                            persistence_file: 'home/pi/.homeassistant'
                            baud_rate: 115200
                        debug: false
                        persistence: true
                      

                      The entry in your configuration.yaml file is a direct copy/paste of the example; you have to change it to meet your setup. The one I posted above should work fine for your install, and you can enable debug and launch hass manually from a terminal if you need to debug any MySensors related issues.

                      My Projects
                      2 Door Chime Sensor
                      Washing Machine Monitor

                      1 Reply Last reply
                      0
                      • chillimanC
                        chillimanC
                        chilliman
                        wrote on last edited by
                        #14

                        drock1985.
                        i cut and paste the example you posted but a get a error

                        16-07-17 23:07:10 mysensors.mysensors: File does not exist or is not readable: home/pi/.homeassistant
                        16-07-17 23:07:10 mysensors.mysensors: Trying backup file: home/pi/.homeassistant.bak
                        16-07-17 23:07:10 mysensors.mysensors: File does not exist or is not readable: home/pi/.homeassistant.bak
                        16-07-17 23:07:10 mysensors.mysensors: Failed to load sensors from file: home/pi/.homeassistant

                        not sure what is going on hopefully you can help me
                        chilliman

                        D 1 Reply Last reply
                        0
                        • chillimanC chilliman

                          drock1985.
                          i cut and paste the example you posted but a get a error

                          16-07-17 23:07:10 mysensors.mysensors: File does not exist or is not readable: home/pi/.homeassistant
                          16-07-17 23:07:10 mysensors.mysensors: Trying backup file: home/pi/.homeassistant.bak
                          16-07-17 23:07:10 mysensors.mysensors: File does not exist or is not readable: home/pi/.homeassistant.bak
                          16-07-17 23:07:10 mysensors.mysensors: Failed to load sensors from file: home/pi/.homeassistant

                          not sure what is going on hopefully you can help me
                          chilliman

                          D
                          D
                          drock1985
                          wrote on last edited by drock1985
                          #15

                          @chilliman said:

                          mysensors:
                          gateways:
                          - device: '/dev/ttyUSB0'
                          persistence_file: 'home/pi/.homeassistant'
                          baud_rate: 115200
                          debug: false
                          persistence: true

                          My bad, forgot to add the file at the end of the directory.

                          mysensors:
                            gateways:
                              - device: '/dev/ttyUSB0'
                                persistence_file: 'home/pi/.homeassistant/mysensors.json'
                                baud_rate: 115200
                            debug: false
                            persistence: true
                          

                          My Projects
                          2 Door Chime Sensor
                          Washing Machine Monitor

                          1 Reply Last reply
                          0
                          • chillimanC
                            chillimanC
                            chilliman
                            wrote on last edited by
                            #16

                            drock1985
                            i just changed the conf file to with the latest and i get this error massage
                            16-07-17 23:16:27 mysensors.mysensors: File does not exist or is not readable: home/pi/.homeassistant/mysensors.json
                            16-07-17 23:16:27 mysensors.mysensors: Trying backup file: home/pi/.homeassistant/mysensors.json.bak
                            16-07-17 23:16:27 mysensors.mysensors: File does not exist or is not readable: home/pi/.homeassistant/mysensors.json.bak
                            16-07-17 23:16:27 mysensors.mysensors: Failed to load sensors from file: home/pi/.homeassistant/mysensors.json

                            chilliman

                            1 Reply Last reply
                            0
                            • chillimanC
                              chillimanC
                              chilliman
                              wrote on last edited by
                              #17

                              Drock1985
                              please find attached HA start up file
                              0_1468799007226_HA-startup.txt

                              thanks
                              chilliman

                              martinhjelmareM 1 Reply Last reply
                              0
                              • chillimanC chilliman

                                Drock1985
                                please find attached HA start up file
                                0_1468799007226_HA-startup.txt

                                thanks
                                chilliman

                                martinhjelmareM
                                martinhjelmareM
                                martinhjelmare
                                Plugin Developer
                                wrote on last edited by martinhjelmare
                                #18

                                @chilliman

                                The first time you start home assistant, the persistence file will not have been created, so you will get the warning message even if you have set the correct path. Only after a sensor has reported a value will the persistence file be written. You should always include a sending of initial value in your setup/presentation function for a node, so once you have started the node, it will be added as a device to home assistant and the persistence file will be populated.

                                1 Reply Last reply
                                0
                                • chillimanC
                                  chillimanC
                                  chilliman
                                  wrote on last edited by
                                  #19

                                  martin.
                                  i am sorry i having a newbie moment i just need to understand what is happening so the way it is setup is good.
                                  if so i have few more question , i have the gateway and all have a node with a motion sensor attached so how do i get the motion sensor to show up on HA .
                                  sorry for not understanding its a very steep learning curve.

                                  chilliman

                                  D 1 Reply Last reply
                                  0
                                  • chillimanC chilliman

                                    martin.
                                    i am sorry i having a newbie moment i just need to understand what is happening so the way it is setup is good.
                                    if so i have few more question , i have the gateway and all have a node with a motion sensor attached so how do i get the motion sensor to show up on HA .
                                    sorry for not understanding its a very steep learning curve.

                                    chilliman

                                    D
                                    D
                                    drock1985
                                    wrote on last edited by
                                    #20

                                    @chilliman

                                    Not sure what else to tell you. Like Martin said, for a node to appear at all in HA; it must do two things. 1) send the full presentation on the node start. Easiest way to do that is to start HA, and after HA is fully started put power to your motion sensor. 2) It must send a valid sensor status. In the case of a motion sensor, I believe it is either 1 or 0 (1 being motion detected, 0 being none).

                                    The only thing I can see is maybe the / needs to be in front of home. Can't see it causing this many issues though.

                                    mysensors:
                                      gateways:
                                        - device: '/dev/ttyUSB0'
                                          persistence_file: '/home/pi/.homeassistant/mysensors.json'
                                          baud_rate: 115200
                                      debug: false
                                      persistence: true
                                    

                                    Other than that i'm not sure what else to suggest. If everything is configured right, it should see it. You may also want to check out the debug part of MySensors config and HA to better determine your issue. @martinhjelmare help me with that issue some time ago.

                                    My Projects
                                    2 Door Chime Sensor
                                    Washing Machine Monitor

                                    SebexS 1 Reply Last reply
                                    1
                                    • chillimanC
                                      chillimanC
                                      chilliman
                                      wrote on last edited by
                                      #21

                                      Drock1985 & Martin.
                                      thanks guys i have it working just needed to do the full presentation and where it was.
                                      just a newbie mistake.
                                      thanks again
                                      chilliman.

                                      D 1 Reply Last reply
                                      1
                                      • chillimanC chilliman

                                        Drock1985 & Martin.
                                        thanks guys i have it working just needed to do the full presentation and where it was.
                                        just a newbie mistake.
                                        thanks again
                                        chilliman.

                                        D
                                        D
                                        drock1985
                                        wrote on last edited by
                                        #22

                                        @chilliman

                                        No problem; just glad to hear you got it working. Everyone is new sometime.

                                        FYI I made quite a few mistakes in the configuration.yaml file - took me a while to realize spaces were important ;)

                                        Let us know if you have any other problems.

                                        My Projects
                                        2 Door Chime Sensor
                                        Washing Machine Monitor

                                        1 Reply Last reply
                                        0
                                        • D drock1985

                                          @chilliman

                                          Not sure what else to tell you. Like Martin said, for a node to appear at all in HA; it must do two things. 1) send the full presentation on the node start. Easiest way to do that is to start HA, and after HA is fully started put power to your motion sensor. 2) It must send a valid sensor status. In the case of a motion sensor, I believe it is either 1 or 0 (1 being motion detected, 0 being none).

                                          The only thing I can see is maybe the / needs to be in front of home. Can't see it causing this many issues though.

                                          mysensors:
                                            gateways:
                                              - device: '/dev/ttyUSB0'
                                                persistence_file: '/home/pi/.homeassistant/mysensors.json'
                                                baud_rate: 115200
                                            debug: false
                                            persistence: true
                                          

                                          Other than that i'm not sure what else to suggest. If everything is configured right, it should see it. You may also want to check out the debug part of MySensors config and HA to better determine your issue. @martinhjelmare help me with that issue some time ago.

                                          SebexS
                                          SebexS
                                          Sebex
                                          wrote on last edited by
                                          #23
                                          This post is deleted!
                                          1 Reply Last reply
                                          0

                                          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                                          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                                          With your input, this post could be even better 💗

                                          Register Login
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          13

                                          Online

                                          12.4k

                                          Users

                                          11.2k

                                          Topics

                                          113.5k

                                          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