For some devices the /dev/ttyAMA0 device is not detected by udev and is therefore not mapped by Docker. To explicitly set this device for mapping to Home-Assistant, execute the following command using the ssh add-on:
$ curl -d '{"devices": ["ttyAMA0"]}' http://hassio/homeassistant/options
After that, you need to change usb_path to /dev/ttyAMA0 in your configuration.yaml.
zwave:
usb_path: /dev/ttyAMA0
follow those steps and it should start working for you.
I think you’re on the right track - first off, piping your ls command into tail with the -n 1 option is only going to return you one result… so we still don’t know definitively if the Aeotec is recognized on your Pi or not.
Ssh into the Pi and type hassio host hardware. That will return you a list of the hardware attached to the Pi and recognized by Hassio. In the serial section at the top your should see /dev/ttyUSB0 or something similar if the Aeotec is recognized.
Also, the Aeotec is almost certainly going to be recognized as a USB serial device and not AMA, which on the Pi is generally reserved for the hardware UART that hat devices like the Razberry board attach to.
That’s obviously a little confusing to me because I have both ACM0 and AMA0. I have used AMA0 in my config file, but perhaps it should be changed to ACM0?
Did you restart homeassistant? Once you do, either the Zwave entry will show up under the configuration menu or you will have an error entry in your log telling us why it isn’t showing up.
@marthocoo - I did not. I didn’t realize that I had to restart it. My apologies.
I’m a bit nervous because the last time I restarted HA, I ended up having to power down the RPI altogether to get it to come back – I lost the ability to access the front end. We’ll see what happens this time.
I will update shortly – thanks again for all of your help. Frustrating to know that this all might have been solved by a restart…
Probably, but the logs (hassio homeassistant logs when your SSHd on) will tell you more. The first 20 lines of the OZW_Log.txt file (in the same directory as configuration.yaml will also be useful)
I believe this is the section of the logs that is most relevant. Please note that this is AFTER I changed from ACM0 to AMA0, but it should be noted that I got the exact same error (only with ACM0 instead of AMA0) previously…
Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/openzwave/option.py", line 78, in __init__
raise ZWaveException(u"Can't find device %s : %s" % (device, traceback.format_exception(*sys.exc_info())))
openzwave.object.ZWaveException: "Zwave Generic Exception : Can't find device /dev/tty/AMA0 : ['NoneType: None\\n']"
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/homeassistant/setup.py", line 193, in _async_setup_component
component.setup, hass, processed_config)
File "/usr/lib/python3.6/asyncio/futures.py", line 332, in __iter__
yield self # This tells Task to wait for completion.
File "/usr/lib/python3.6/asyncio/tasks.py", line 250, in _wakeup
future.result()
File "/usr/lib/python3.6/asyncio/futures.py", line 245, in result
raise self._exception
File "/usr/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/lib/python3.6/site-packages/homeassistant/components/zwave/__init__.py", line 280, in setup
config_path=config[DOMAIN].get(CONF_CONFIG_PATH))
File "/usr/lib/python3.6/site-packages/openzwave/option.py", line 81, in __init__
raise ZWaveException(u"Error when retrieving device %s : %s" % (device, traceback.format_exception(*sys.exc_info())))
openzwave.object.ZWaveException: 'Zwave Generic Exception : Error when retrieving device /dev/tty/AMA0 : [\'Traceback (most recent call last):\\n\', \' File "/usr/lib/python3.6/site-packages/openzwave/option.py", line 78, in __init__\\n raise ZWaveException(u"Can\\\'t find device %s : %s" % (device, traceback.format_exception(*sys.exc_info())))\\n\', \'openzwave.object.ZWaveException: "Zwave Generic Exception : Can\\\'t find device /dev/tty/AMA0 : [\\\'NoneType: None\\\\\\\\n\\\']"\\n\']'
Thank you, @marthocoo – I think my frustrations were getting the best of me, as I looked over that 100 times. In reality, I just checked back in my Putty logs and I didn’t have the \ in there when I was using ACM0, but I must have added it when I changed it to AMA0.
I now have the Z-Wave menu in my Configuration tab. Now to start actually adding devices…
I’ve spent a lot of time trying to get Aeotec Z-Wave stick active on the vmdk under virtualbox.
I am getting two errors:
Unable to find component usb_path:
zwave:
usb_path: /dev/ttyACM0
error during setup of component zwave
Log Details (ERROR)
Mon Oct 22 2018 17:49:36 GMT-0400 (Eastern Daylight Time)
Error during setup of component zwave
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/openzwave/option.py”, line 78, in init
raise ZWaveException(u"Can’t find device %s : %s" % (device, traceback.format_exception(*sys.exc_info())))
openzwave.object.ZWaveException: “Zwave Generic Exception : Can’t find device /dev/ttyACM0 : [‘NoneType: None\n’]”
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/homeassistant/setup.py”, line 145, in _async_setup_component
hass, processed_config)
File “/usr/local/lib/python3.6/site-packages/homeassistant/components/zwave/init.py”, line 244, in async_setup
config_path=config[DOMAIN].get(CONF_CONFIG_PATH))
File “/usr/local/lib/python3.6/site-packages/openzwave/option.py”, line 81, in init
raise ZWaveException(u"Error when retrieving device %s : %s" % (device, traceback.format_exception(*sys.exc_info())))
openzwave.object.ZWaveException: ‘Zwave Generic Exception : Error when retrieving device /dev/ttyACM0 : [‘Traceback (most recent call last):\n’, ’ File “/usr/local/lib/python3.6/site-packages/openzwave/option.py”, line 78, in init\n raise ZWaveException(u"Can\‘t find device %s : %s" % (device, traceback.format_exception(*sys.exc_info())))\n’, ‘openzwave.object.ZWaveException: “Zwave Generic Exception : Can\'t find device /dev/ttyACM0 : [\‘NoneType: None\\\\n\’]”\n’]’
My host is ubuntu 18 and when I run in terminal: ls -ltr /dev/tty*|tail -n 1 I can see, crw-rw---- 1 root dialout 166, 0 Oct 22 17:41 /dev/ttyACM0
when i ssh root@hassio and run the terminal command: ls -ltr /dev/tty*|tail -n 1 I can only see crw-rw-rw- 1 root root 5, 0 Oct 22 10:36 /dev/tty