Setting up Z-PI7 on RaspiOS using zwavejsui

Hello!

I’m trying to setup zwavejsui on Raspi64bit.
After configuring the Addon I endup with the following errors:

Blockquote

2023-02-05T16:11:25.087Z DRIVER   ███████╗ ██╗    ██╗  █████╗  ██╗   ██╗ ███████╗             ██╗ ███████╗
                                  ╚══███╔╝ ██║    ██║ ██╔══██╗ ██║   ██║ ██╔════╝             ██║ ██╔════╝
                                    ███╔╝  ██║ █╗ ██║ ███████║ ██║   ██║ █████╗   █████╗      ██║ ███████╗
                                   ███╔╝   ██║███╗██║ ██╔══██║ ╚██╗ ██╔╝ ██╔══╝   ╚════╝ ██   ██║ ╚════██║
                                  ███████╗ ╚███╔███╔╝ ██║  ██║  ╚████╔╝  ███████╗        ╚█████╔╝ ███████║
                                  ╚══════╝  ╚══╝╚══╝  ╚═╝  ╚═╝   ╚═══╝   ╚══════╝         ╚════╝  ╚══════╝
2023-02-05T16:11:25.089Z DRIVER   version 10.5.5
2023-02-05T16:11:25.091Z DRIVER   
2023-02-05T16:11:25.091Z DRIVER   starting driver...
2023-02-05T16:11:25.127Z DRIVER   opening serial port /dev/zwave
2023-02-05T16:11:25.144Z DRIVER   serial port opened
2023-02-05T16:11:25.146Z SERIAL » 0x15                                                                 (1 bytes)
2023-02-05T16:11:26.157Z DRIVER   loading configuration...
2023-02-05T16:11:26.165Z CONFIG   Synchronizing external config dir /usr/src/app/store/.config-db...
2023-02-05T16:11:29.321Z CONFIG   Using external configuration dir /usr/src/app/store/.config-db
2023-02-05T16:11:29.322Z CONFIG   version 10.5.5
2023-02-05T16:11:37.790Z CONFIG   Device index regenerated
2023-02-05T16:11:37.845Z DRIVER   beginning interview...
2023-02-05T16:11:37.848Z DRIVER   added request handler for AddNodeToNetwork (0x4a)...
                                  1 registered
2023-02-05T16:11:37.848Z DRIVER   added request handler for RemoveNodeFromNetwork (0x4b)...
                                  1 registered
2023-02-05T16:11:37.849Z DRIVER   added request handler for ReplaceFailedNode (0x63)...
                                  1 registered
2023-02-05T16:11:37.850Z CNTRLR   querying controller IDs...
2023-02-05T16:11:38.170Z SERIAL » 0x01030020dc                                                         (5 bytes)
2023-02-05T16:11:38.175Z DRIVER » [REQ] [GetControllerId]
2023-02-05T16:11:39.185Z CNTRLR   Failed to execute controller command after 1/3 attempts. Scheduling next try i
                                  n 100 ms.
2023-02-05T16:11:39.286Z SERIAL » 0x01030020dc                                                         (5 bytes)
2023-02-05T16:11:39.287Z DRIVER » [REQ] [GetControllerId]
2023-02-05T16:11:40.291Z CNTRLR   Failed to execute controller command after 2/3 attempts. Scheduling next try i
                                  n 1100 ms.
2023-02-05T16:11:41.394Z SERIAL » 0x01030020dc                                                         (5 bytes)
2023-02-05T16:11:41.396Z DRIVER » [REQ] [GetControllerId]
2023-02-05T16:11:42.413Z DRIVER   Failed to initialize the driver: ZWaveError: Timeout while waiting for an ACK 
                                  from the controller (ZW0200)
                                      at Driver.sendMessage (/usr/src/app/node_modules/zwave-js/src/lib/driver/D
                                  river.ts:4001:23)
                                      at ZWaveController.identify (/usr/src/app/node_modules/zwave-js/src/lib/co
                                  ntroller/Controller.ts:776:33)
                                      at Driver.initializeControllerAndNodes (/usr/src/app/node_modules/zwave-js
                                  /src/lib/driver/Driver.ts:1265:26)
                                      at Immediate.<anonymous> (/usr/src/app/node_modules/zwave-js/src/lib/drive
                                  r/Driver.ts:1072:16)
2023-02-05T16:11:42.420Z DRIVER   destroying driver instance...
2023-02-05T16:11:42.424Z DRIVER   driver instance destroyed

Can anybody please advise ?

Are you using the HAOS Community Add-on, or running it yourself as a Docker container? If the former, /dev/zwave is not a valid path. If the latter, post your Docker run command or Docker compose configuration.

Hello!

Running it myself in docker using the following compose :slight_smile:

version: '3.0'

services:
  portainer:
    container_name: portainer
    image: portainer/portainer-ce
    restart: always
    ports:
      - "9000:9000/tcp"
    environment:
      - TZ=Europe/London
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - /opt/portainer:/data
  homeassistant:
    container_name: homeassistant
    image: "ghcr.io/home-assistant/home-assistant:stable"
    volumes:
      - /opt/homeassistant/config:/config
      - /etc/localtime:/etc/localtime:ro
    restart: unless-stopped
    privileged: true
    network_mode: host
  zwave-js-ui:
    container_name: zwave-js-ui
    image: zwavejs/zwave-js-ui:latest
    restart: always
    tty: true
    stop_signal: SIGINT
    environment:
      - SESSION_SECRET=*************************
      - ZWAVEJS_EXTERNAL_CONFIG=/usr/src/app/store/.config-db
      # Uncomment if you want logs time and dates to match your timezone instead of UTC
      # Available at https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
      #- TZ=America/New_York
    networks:
      - zwave
    devices:
      # Do not use /dev/ttyUSBX serial devices, as those mappings can change over time.
      # Instead, use the /dev/serial/by-id/X serial device for your Z-Wave stick.
      - '/dev/ttyAMA0:/dev/ttyAMA0'
    volumes:
      - zwave-config:/usr/src/app/store
    ports:
      - '8091:8091' # port for web interface
      - '3000:3000' # port for Z-Wave JS websocket server
networks:
  zwave:
volumes:
  zwave-config:
    name: zwave-config

What controller are you using? /dev/ttyAMA0 is only for Pi HAT/Shield and not USB sticks.

Your controller mapping and config are also conflicting:

'/dev/ttyAMA0:/dev/ttyAMA0'

Means your config in ZUI (inside the container) should be /dev/ttyAMA0. If you want to use /dev/zwave in the ZUI configuration, map it correctly:

'/dev/ttyAMA0:/dev/zwave'

Hi!

I’m using the Z-Pi7 not the usb dongle. I’ve tried with both ‘/dev/ttyAMA0:/dev/ttyAMA0’ and ‘/dev/ttyAMA0:/dev/zwave’ the same result, I’ve ended up with this driver error.

Not sure what I’m doing wrong.
Running on PI4.
More or less the step I’ve following was:
Install Rasp64Lite using the following config

dtoverlay=disable-bt
enable_uart=1

Apt update + upgrade
Install docker
Install docker compose
Install Portainer with compose
Install Homeassistant with compose
Configure home assistant basic.
Install zwavejsui
Using /dev/ttyAMA0:/dev/zwave when is was not working tried also /dev/ttyAMA0:/dev/ttyAMA0
Switching off the MTTQ Server and enabled the ws server.
The compose config is what I’ve shared.

Seems like the port is accessible from the container:

[email protected]:/opt $ docker exec -it 6e5d2e76ad15 stty -F /dev/zwave
speed 115200 baud; line = 0;
intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>; swtch = <undef>; start = ^Q; stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O; min = 1; time = 0;
-brkint -icrnl -imaxbel
-opost -onlcr
-isig -icanon -iexten -echo -echoe -echok -echoctl -echoke