hestia wrote: ↑Wednesday 01 December 2021 13:50
port and address are those for the mqtt broker, not the ws server
1883 and localhost for me
I thought I understood, but there is still a missing gap
If I run this Docker image (https://github.com/zwave-js/zwavejs2mqtt) on the RPI would I need to also install the broker separately?
So do I need anything else beside Domoticz and zwavejs2mqtt.
You do need a mosquitto broker indeed. Also, if you run that on the same system as the zwavejs2mqtt docker, do not use localhost in the docker container as localhost IS the docker container, not the host machine! Put in the hostname or IP for the host machine!
So both domoticz and zwavejs need the hostname/IP and port (default 1883) of the mqtt broker.
Docker in Truenas scale, close to latest beta
DASHTICZ 🙃
RFXCOM, zwavejs2mqtt, zigbee2mqtt,
P1 meter & solar panel
Google home, Wifi Cams motion detection
Geofence iCloud, Bluetooth & Wifi ping
Harmony hub, Nest, lots more :-)
version: '3.7'
services:
zwavejs2mqtt:
container_name: zwavejs2mqtt
image: zwavejs/zwavejs2mqtt:latest
restart: always
tty: true
stop_signal: SIGINT
environment:
- SESSION_SECRET=mysupersecretkey
- 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=Europe/Amsterdam
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/serial/by-id/usb-0658_0200-if00:/dev/zwave'
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
Now it works with my test wall plug
So far so good, will start some testing and see how it goes.
Thanks for the help and patience, it's a lot to process if this is the first time dipping your toes in Docker, MQTT and zwavejs2mqtt
That's understandable but once you get used to the docker approach, you don't go back!
I have been on zwavejs2mqtt and domoticz autodiscovery for nearly a month now and am very happy with the stability and flexibility.
My zwave stick is the aeotec gen5 which, on a pi4, suffers from the reboot problem (the old gen5 didn't follow the usb specs very well and the pi4 is more strict than the 3). That causes me to have to use a usb hub which then triggers the occasional disconnect. Now I can simply write a udev rule to restart the container on a connect. Works like a champ.
Sent from my SM-G980F using Tapatalk
Docker in Truenas scale, close to latest beta
DASHTICZ 🙃
RFXCOM, zwavejs2mqtt, zigbee2mqtt,
P1 meter & solar panel
Google home, Wifi Cams motion detection
Geofence iCloud, Bluetooth & Wifi ping
Harmony hub, Nest, lots more :-)
Not sure if I should continue all my questions here or if I should start a new thread.
It appears all devices from the discovered node are added automatically to the Domoticz dashboard.
Is there a way to disable that?
Other thing I see is that I can switch the wall plug on and off from Domoticz but changing the state on the plug physically is not reflected in Domoticz. It stays as off.
I do see it flip over in zwavejs2mqtt
There was a discussion regarding automatic addition of devices on Slack and this behaviour is by design indeed.
In terms of states not being updated correctly, this can be a bug in domoticz not handling the response message correctly. Best to go onto slack (pm me your email address and I will send you an invitation) and provide the autodiscovery topic/message as well as the response message. If you install mqtt explorer, you can easily find them.
Docker in Truenas scale, close to latest beta
DASHTICZ 🙃
RFXCOM, zwavejs2mqtt, zigbee2mqtt,
P1 meter & solar panel
Google home, Wifi Cams motion detection
Geofence iCloud, Bluetooth & Wifi ping
Harmony hub, Nest, lots more :-)
i am running domoticz in docker(indeed very pleased) but still use the native zwave devices.
my setup is very stable.
the only problem i have had is that power consumption devices were not stable.
as a result you could se the power go off/on while in reality the device was constant on.
i solved this by using compute on every power/energy device
the problem with zwave is that it generates a lot of devices which apparently doe the same(but in reality do not)
question regarding moving to MQTT
do you replace the old devices with the new devices once you are convinced everything is stable. that way you keep the hisory of those devices
It's doable but a bit tricky since you cannot have your controller connected to both ozw and zwavejs at the same time.
What you can do is to disable ozw, start jwavejs, user autodiscovery such that it creates devices. Once you have those, you can switch the ozw history over but you would need to reenable ozw for that.
As said, it's doable but takes a bit of fiddling and switching backwards and forwards...
Sent from my SM-G980F using Tapatalk
Docker in Truenas scale, close to latest beta
DASHTICZ 🙃
RFXCOM, zwavejs2mqtt, zigbee2mqtt,
P1 meter & solar panel
Google home, Wifi Cams motion detection
Geofence iCloud, Bluetooth & Wifi ping
Harmony hub, Nest, lots more :-)
heggink wrote: ↑Thursday 02 December 2021 10:19
It's doable but a bit tricky since you cannot have your controller connected to both ozw and zwavejs at the same time.
What you can do is to disable ozw, start jwavejs, user autodiscovery such that it creates devices. Once you have those, you can switch the ozw history over but you would need to reenable ozw for that.
As said, it's doable but takes a bit of fiddling and switching backwards and forwards...
Sent from my SM-G980F using Tapatalk
I have managed to do this by changing the USB device for OZW to something that won't work but without disabling the OZW hardware device, this way the devices stay in the device list. Then you can start/install zwavejs2mqtt (best to name the devices there before connecting to MQTT) and let the devices populate in Domoticz, Once they are all there you can "replace" which can save a LOT of time. Some devices won't replace though, I noticed a few RGB devices are presented slightly differently but simple switches etc are fine.
Intel NUC with Ubuntu Server VM (Proxmox),mosquitto(docker),RFXtrx433E,zwavejsUI (docker),Zigbee2mqtt(docker),SMA Hub (docker),Harmony Hub plugin, Kodi plugin,Homebridge(docker)+Google Home,APC UPS,SMA Modbus,Mitsubishi MQTT, Broadlink,Dombus
heggink wrote: ↑Thursday 02 December 2021 10:19
It's doable but a bit tricky since you cannot have your controller connected to both ozw and zwavejs at the same time.
What you can do is to disable ozw, start jwavejs, user autodiscovery such that it creates devices. Once you have those, you can switch the ozw history over but you would need to reenable ozw for that.
As said, it's doable but takes a bit of fiddling and switching backwards and forwards...
Sent from my SM-G980F using Tapatalk
I have managed to do this by changing the USB device for OZW to something that won't work but without disabling the OZW hardware device, this way the devices stay in the device list. Then you can start/install zwavejs2mqtt (best to name the devices there before connecting to MQTT) and let the devices populate in Domoticz, Once they are all there you can "replace" which can save a LOT of time. Some devices won't replace though, I noticed a few RGB devices are presented slightly differently but simple switches etc are fine.
Excellent idea, that can save a lot of time when switching
Agreed! Great suggestion! Should be in a kind of transition wiki...
Sent from my SM-G980F using Tapatalk
Docker in Truenas scale, close to latest beta
DASHTICZ 🙃
RFXCOM, zwavejs2mqtt, zigbee2mqtt,
P1 meter & solar panel
Google home, Wifi Cams motion detection
Geofence iCloud, Bluetooth & Wifi ping
Harmony hub, Nest, lots more :-)
Edit: But reading it it is already there. Disabling the OCW hardware (instead of delete) should also have the old devices visible to be replaced. After that you can remove the OZW hardware, resulting in removing all old left over devices.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
With the new stable version, I'm planning to migrate from ozw to zwavejs2mqtt. I've about 50 zwave used devices (and 130 not used).
I've juste read the "tip and trick" to disable ozw hardware, to get the old devices visible, and then replace one by one.
It will be long, but not impossible ^^. But I'm wondering what will happen with scripts.
I have a lot of script (lua/blockly/dzVents). With the replace method, we have a new device, with a new name and a new id.
So If I do nothing more, they will be broken.
If after replacing the device, I rename the new device with the old name, will it be enough for the script to work ?
With ID, I'm sure not. The ID is still diffrent
With named device and dzEvents/lua, I think it will be ok. Is it correct ?
With named device and blockly, no idea...
Ragdag wrote: ↑Wednesday 01 December 2021 14:38
Thanks, figured that part out as well and created a docker-compose for Mosquitto
So far so good, will start some testing and see how it goes.
Thanks for the help and patience, it's a lot to process if this is the first time dipping your toes in Docker, MQTT and zwavejs2mqtt
Thank you for your post.
I am running the same in Docker, but I could not get mosquitto:latest to work, I'm still om 1.6
Could you show you mosquitto.conf file too, please?
Ragdag wrote: ↑Wednesday 01 December 2021 14:38
Thanks, figured that part out as well and created a docker-compose for Mosquitto
So far so good, will start some testing and see how it goes.
Thanks for the help and patience, it's a lot to process if this is the first time dipping your toes in Docker, MQTT and zwavejs2mqtt
Thank you for your post.
I am running the same in Docker, but I could not get mosquitto:latest to work, I'm still om 1.6
Could you show you mosquitto.conf file too, please?
Installing Mosquitto
The recommended way to install Mosquitto is by using Docker (Docker Compose).
For this to work you need to:
- Install both Docker Engine and Docker Compose.
- Install Mosquitto using docker (compose) (https://github.com/vvatelot/mosquitto-docker-compose)
Legacy installation method:
It is highly recommended that if you are using Debian or Rasbian that you use the additional Mosquitto repositories. This will ensure you get the latest stable version of Mosquitto as determined by the project itself, rather than an outdated version via the Debian or Raspbian repositories.
Rather than re-iterating the install procedure here, the guide given a thttps://randomnerdtutorials.com/how-to-install-mosquitto-broker-on-raspberry-pi/ is simple and easy to follow, and we encourage you to give their process a shot.
Warning: from Mosquitto v2.0.x you need extra configuration, else no connection is made with Domoticz see also viewtopic.php?f=28&t=35706
To fix this edit the /etc/mosquitto/mosquitto.conf file and add:
listener 1883
allow_anonymous true
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Thanks for your reply. I am now on lastest mosquitto 2.0 on Docker.
I had an incorrect location on config file. I was on "./mosquitto/conf" but should have been "./mosquitto/config"
My error
Guys, if you disable the OZW device, to see devices again you must go to settings -> System tab -> Hardware/Devices and uncheck the "Hide Disbaled Hardware Senosors".