DIYHUE with HA and Z2MQTT

Hi,

I try to add my Hue Lights to DIYHUE with HA und Z2MQTT.

Im using HA OS on an Raspee4 with Z2MQTT. I already added some Light and a Switch to Z2MQTT. I also added MQTT to DIYHUE but the Light wont get added.

WLED Lights are registered without any problem.

Homeassistant is “true” in the config file from Z2MQTT.

The Logs from DIYHUE looks like this:
2024-07-17 20:36:08,820 - lights.protocols.mqtt - INFO - MQTT discovery called
2024-07-17 20:36:09,098 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:09] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:09,175 - services.stateFetch - INFO - start lights sync
2024-07-17 20:36:10,135 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:10] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:11,180 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:11] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:12,230 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:12] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
[Errno -2] Name does not resolve
2024-07-17 20:36:13,284 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:13] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:14,336 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:14] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:14,556 - lights.protocols.native_multi - INFO - 192.168.178.59:80 is Hue Gradient Strip Küche
2024-07-17 20:36:14,557 - lights.protocols.native_multi - INFO - Detected light : Hue Gradient Strip Küche
2024-07-17 20:36:14,558 - lights.protocols.native_multi - INFO - Hue Gradient Strip Küche
2024-07-17 20:36:14,677 - lights.protocols.native_multi - INFO - 192.168.178.60:80 is Hue Gradient TV Strip Links
2024-07-17 20:36:14,678 - lights.protocols.native_multi - INFO - Detected light : Hue Gradient TV Strip Links
2024-07-17 20:36:14,679 - lights.protocols.native_multi - INFO - Hue Gradient TV Strip Links
2024-07-17 20:36:14,781 - lights.protocols.native_multi - INFO - 192.168.178.69:80 is DiyHue Gradient Lightstip
2024-07-17 20:36:14,782 - lights.protocols.native_multi - INFO - Detected light : DiyHue Gradient Lightstip
2024-07-17 20:36:14,783 - lights.protocols.native_multi - INFO - DiyHue Gradient Lightstip
2024-07-17 20:36:14,880 - lights.protocols.native_multi - INFO - 192.168.178.101:80 is DiyHue Gradient Lightstip
2024-07-17 20:36:14,881 - lights.protocols.native_multi - INFO - Detected light : DiyHue Gradient Lightstip
2024-07-17 20:36:14,882 - lights.protocols.native_multi - INFO - DiyHue Gradient Lightstip
2024-07-17 20:36:15,189 - lights.protocols.wled - INFO - discovery started
2024-07-17 20:36:15,375 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:15] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:16,429 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:16] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:17,210 - lights.protocols.wled - INFO - Nothing found using mDNS, trying device_ips method…
2024-07-17 20:36:17,475 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:17] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:18,511 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:18] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:18,562 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:18] “GET /api/hueessee43b711ef96c4d83add7020f0 HTTP/1.1” 200 -
2024-07-17 20:36:19,552 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:19] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:20,364 - services.stateFetch - INFO - start lights sync
2024-07-17 20:36:20,599 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:20] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:21,640 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:21] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:22,674 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:22] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:23,721 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:23] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:24,767 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:24] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:25,818 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:25] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:26,872 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:26] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:27,948 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:27] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:28,612 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:28] “GET /api/hueessee43b711ef96c4d83add7020f0 HTTP/1.1” 200 -
2024-07-17 20:36:28,996 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:28] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:30,044 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:30] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:31,094 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:31] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:31,487 - services.stateFetch - INFO - start lights sync
2024-07-17 20:36:32,151 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:32] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:33,209 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:33] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:33,542 - lights.discover - INFO -
2024-07-17 20:36:33,543 - lights.protocols.elgato - INFO - mDNS discovery for _elgo._tcp.local. started
2024-07-17 20:36:34,259 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:34] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:35,305 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:35] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:35,564 - lights.protocols.elgato - INFO - Nothing found using mDNS, trying to find lights by IP
2024-07-17 20:36:35,566 - lights.discover - INFO - Update IP for light Hue Gradient Strip Küche 1
2024-07-17 20:36:35,567 - lights.discover - INFO - Update IP for light Hue Gradient TV Strip Links 1
2024-07-17 20:36:35,568 - lights.discover - INFO - Update IP for light DiyHue Gradient Lightstip 1
2024-07-17 20:36:35,569 - lights.discover - INFO - Update IP for light DiyHue Gradient Lightstip 1
2024-07-17 20:36:36,362 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:36] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
scan for light
2024-07-17 20:36:36,410 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:36] “POST /api/hueessee43b711ef96c4d83add7020f0/sensors HTTP/1.1” 200 -
2024-07-17 20:36:36,491 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:36] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:37,587 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:37] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:38,638 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:38] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:38,669 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:38] “GET /api/hueessee43b711ef96c4d83add7020f0 HTTP/1.1” 200 -
2024-07-17 20:36:39,689 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:39] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:40,789 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:36:40] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:36:41,340 - lights.discover - INFO - [
“192.168.178.1:80”,
“192.168.178.2:80”,
“192.168.178.3:80”,
“192.168.178.41:80”,
“192.168.178.59:80”,
“192.168.178.60:80”,
“192.168.178.69:80”,
“192.168.178.82:80”,
“192.168.178.88:80”,
“192.168.178.101:80”
]
2024-07-17 20:38:34,984 - lights.protocols.mqtt - INFO - MQTT discovery called
[Errno -2] Name does not resolve
2024-07-17 20:38:40,802 - lights.protocols.native_multi - INFO - 192.168.178.60:80 is Hue Gradient TV Strip Links
2024-07-17 20:38:40,803 - lights.protocols.native_multi - INFO - Detected light : Hue Gradient TV Strip Links
2024-07-17 20:38:40,804 - lights.protocols.native_multi - INFO - Hue Gradient TV Strip Links
2024-07-17 20:38:40,825 - lights.protocols.native_multi - INFO - 192.168.178.69:80 is DiyHue Gradient Lightstip
2024-07-17 20:38:40,826 - lights.protocols.native_multi - INFO - Detected light : DiyHue Gradient Lightstip
2024-07-17 20:38:40,827 - lights.protocols.native_multi - INFO - DiyHue Gradient Lightstip
2024-07-17 20:38:43,855 - lights.protocols.native_multi - INFO - ip 192.168.178.88:80 is unknown device: HTTPConnectionPool(host=‘192.168.178.88’, port=80): Read timed out. (read timeout=3)
2024-07-17 20:38:43,875 - lights.protocols.native_multi - INFO - 192.168.178.101:80 is DiyHue Gradient Lightstip
2024-07-17 20:38:43,876 - lights.protocols.native_multi - INFO - Detected light : DiyHue Gradient Lightstip
2024-07-17 20:38:43,877 - lights.protocols.native_multi - INFO - DiyHue Gradient Lightstip
2024-07-17 20:38:47,150 - lights.protocols.wled - INFO - discovery started
2024-07-17 20:38:49,169 - lights.protocols.wled - INFO - Nothing found using mDNS, trying device_ips method…
2024-07-17 20:38:56,030 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:38:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/groups/0 HTTP/1.1” 200 -
2024-07-17 20:38:56,034 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:38:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/config/swupdate2 HTTP/1.1” 200 -
2024-07-17 20:38:56,096 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:38:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/groups/0 HTTP/1.1” 200 -
2024-07-17 20:38:56,092 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:38:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/config/swupdate2 HTTP/1.1” 200 -
2024-07-17 20:38:57,924 - services.stateFetch - INFO - start lights sync
2024-07-17 20:39:00,494 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:39:00] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:39:01,121 - services.stateFetch - WARNING - Hue Gradient TV Strip Rechts 1 is unreachable: HTTPConnectionPool(host=‘192.168.178.58’, port=80): Max retries exceeded with url: /state (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7f87e12f40>, ‘Connection to 192.168.178.58 timed out. (connect timeout=3)’))
2024-07-17 20:39:01,591 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:39:01] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:39:05,494 - werkzeug - INFO - 192.168.178.29 - - [17/Jul/2024 20:39:05] “GET /api/hueessee43b711ef96c4d83add7020f0/sensors/new HTTP/1.1” 200 -
2024-07-17 20:39:20,774 - lights.discover - INFO -
2024-07-17 20:39:20,775 - lights.protocols.elgato - INFO - mDNS discovery for _elgo._tcp.local. started
2024-07-17 20:39:22,799 - lights.protocols.elgato - INFO - Nothing found using mDNS, trying to find lights by IP
2024-07-17 20:39:22,800 - lights.discover - INFO - Update IP for light Hue Gradient TV Strip Links 1
2024-07-17 20:39:22,801 - lights.discover - INFO - Update IP for light DiyHue Gradient Lightstip 1
2024-07-17 20:39:22,802 - lights.discover - INFO - Update IP for light DiyHue Gradient Lightstip 1
2024-07-17 20:39:56,036 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:39:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/config/swupdate2 HTTP/1.1” 200 -
2024-07-17 20:39:56,042 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:39:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/groups/0 HTTP/1.1” 200 -
2024-07-17 20:39:56,094 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:39:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/config/swupdate2 HTTP/1.1” 200 -
2024-07-17 20:39:56,105 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:39:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/groups/0 HTTP/1.1” 200 -
2024-07-17 20:39:57,213 - services.stateFetch - INFO - start lights sync
2024-07-17 20:40:00,315 - services.stateFetch - WARNING - Hue Gradient TV Strip Rechts 1 is unreachable: HTTPConnectionPool(host=‘192.168.178.58’, port=80): Max retries exceeded with url: /state (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7f87e12eb0>, ‘Connection to 192.168.178.58 timed out. (connect timeout=3)’))
2024-07-17 20:40:56,038 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:40:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/groups/0 HTTP/1.1” 200 -
2024-07-17 20:40:56,032 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:40:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/config/swupdate2 HTTP/1.1” 200 -
2024-07-17 20:40:56,093 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:40:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/config/swupdate2 HTTP/1.1” 200 -
2024-07-17 20:40:56,098 - werkzeug - INFO - 192.168.178.45 - - [17/Jul/2024 20:40:56] “GET /api/aba8fe0243b711ef96c4d83add7020f0/groups/0 HTTP/1.1” 200 -
2024-07-17 20:40:57,405 - services.stateFetch - INFO - start lights sync
2024-07-17 20:41:00,500 - services.stateFetch - WARNING - Hue Gradient TV Strip Rechts 1 is unreachable: HTTPConnectionPool(host=‘192.168.178.58’, port=80): Max retries exceeded with url: /state (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7f87e50d00>, ‘Connection to 192.168.178.58 timed out. (connect timeout=3)’))

Hi, i see a few thing that are not good.
If you want to add lights via MQTT this is not working because of this:

Diyhue can not connect to MQTT this is possible by wrong credentials.

If you want to add stuff from HA you need to enable this via the webui addons>HA.
i dont see HA in the logs to start adding lights.(this should come after MQTT and deconz)