logo elektroda
logo elektroda
X
logo elektroda

AVATTO Tuya ZigBee3.0 thermostat integration ZigBee3.0 actuator smart thermostat TRV with home assis

hkielp745 4554 53
Best answers

Can I integrate an AVATTO Tuya ZigBee 3.0 TRV thermostat with Home Assistant using ZHA instead of Zigbee2MQTT?

It appears to not work properly with ZHA yet: ZHA can detect the thermostat, but if you don’t get temperature adjustment and other controls/configuration entities, then there is no working ZHA support from this thread [#21274148] The suggested workaround is to use Zigbee2MQTT instead, preferably on a second coordinator so ZHA and Z2M don’t fight over the same one [#21274134][#21274148]
Generated by the language model.
ADVERTISEMENT
This content has been translated flag-pl » flag-en View the original version here
  • #1 21265809
    hkielp745
    Level 2  
    Hello, is it possible to integrate AVATTO Tuya ZigBee3.0? Smart actuator, TRV thermostat with home assistant, using ZHA and not zigbee2mqtt?
  • ADVERTISEMENT
  • #2 21274134
    Anonymous
    Level 1  
  • #3 21274137
    hkielp745
    Level 2  
    I have a Home Assis os and a Sonoff dongle 3+. The zha detects the thermostat but there is no way to adjust the temperature and other functions and the zigbee2mqqt so average it wants to work.
  • ADVERTISEMENT
  • #4 21274148
    Anonymous
    Level 1  
  • #5 21274153
    hkielp745
    Level 2  
    So should I uninstall zha first and then install zigbee2mqtt?
  • #6 21274172
    Anonymous
    Level 1  
  • #7 21274184
    hkielp745
    Level 2  
    3. create a new user in HA - MQTT User
    But this is to create a new user in HA?
  • #8 21274194
    Anonymous
    Level 1  
  • #9 21274203
    hkielp745
    Level 2  
    Take something in the logs:
    [2024-10-23 17:30:50] info: z2m: Logging to console, file (filename: log.log)
    [2024-10-23 17:30:50] info: z2m: Starting Zigbee2MQTT version 1.40.2 (commit #unknown)
    [2024-10-23 17:30:50] info: z2m: Starting zigbee-herdsman (2.1.3)
    [2024-10-23 17:30:52] error: zh:zstack:znp: Failed to determine if path is valid: 'Error: ENOENT: no such file or directory, lstat '/dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20231220134520-if00 adapter: ezsp''
    [2024-10-23 17:30:52] info: zh:zstack:znp: Opening SerialPort with {"path":"/dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20231220134520-if00 adapter: ezsp'', "baudRate":115200, "rtscts":false, "autoOpen":false}
    [2024-10-23 17:30:52] error: z2m: Error while starting zigbee-herdsman
    [2024-10-23 17:30:52] error: z2m: Failed to start zigbee
    [2024-10-23 17:30:52] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
    [2024-10-23 17:30:52] error: z2m: Exiting...
    [2024-10-23 17:30:52] error: z2m: Error: Error: No such file or directory, cannot open /dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20231220134520-if00 adapter: ezsp
    [17:30:58] INFO: Preparing to start...
    [17:31:00] INFO: Socat not enabled
    [17:31:07] INFO: Starting Zigbee2MQTT...
    Starting Zigbee2MQTT without watchdog.
  • #10 21274223
    Anonymous
    Level 1  
  • #11 21274227
    hkielp745
    Level 2  
    AVATTO Tuya ZigBee3.0 thermostat integration ZigBee3.0 actuator smart thermostat TRV with home assis .
    This is how
  • #12 21274242
    Anonymous
    Level 1  
  • #13 21274249
    hkielp745
    Level 2  
    Well, that didn't do anything [18:03:40] INFO: Preparing to start...
    [18:03:42] INFO: Socat not enabled
    [18:03:49] INFO: Starting Zigbee2MQTT...
    Starting Zigbee2MQTT without watchdog.
    [2024-10-23 18:04:16] info: z2m: Logging to console, file (filename: log.log)
    [2024-10-23 18:04:16] info: z2m: Starting Zigbee2MQTT version 1.40.2 (commit #unknown)
    [2024-10-23 18:04:16] info: z2m: Starting zigbee-herdsman (2.1.3)
    [2024-10-23 18:04:19] error: zh:zstack:znp: Failed to determine if path is valid: 'Error: ENOENT: no such file or directory, lstat '/dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20231220134520-if00 adapter: zstack'
    [2024-10-23 18:04:19] info: zh:zstack:znp: Opening SerialPort with {"path":"/dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20231220134520-if00 adapter: zstack'', "baudRate":115200, "rtscts":false, "autoOpen":false}
    [2024-10-23 18:04:19] error: z2m: Error while starting zigbee-herdsman
    [2024-10-23 18:04:19] error: z2m: Failed to start zigbee
    [2024-10-23 18:04:19] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
    [2024-10-23 18:04:19] error: z2m: Exiting...
    [2024-10-23 18:04:19] error: z2m: Error: Error: No such file or directory, cannot open /dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20231220134520-if00 adapter: zstack
    [18:04:24] INFO: Preparing to start...
    [18:04:26] INFO: Socat not enabled
  • ADVERTISEMENT
  • #15 21274260
    hkielp745
    Level 2  
    Rather so something I don't know in the end which of these to copy?
    AVATTO Tuya ZigBee3.0 thermostat integration ZigBee3.0 actuator smart thermostat TRV with home assis
  • #16 21274261
    Anonymous
    Level 1  
  • ADVERTISEMENT
  • #17 21274270
    hkielp745
    Level 2  
    AVATTO Tuya ZigBee3.0 thermostat integration ZigBee3.0 actuator smart thermostat TRV with home assis .
    I have this now, but there is still a problem:
    [18:15:10] INFO: Preparing to start....
    [18:15:12] INFO: Socat not enabled
    [18:15:20] INFO: Starting Zigbee2MQTT...
    Starting Zigbee2MQTT without watchdog.
    [2024-10-23 18:15:47] info: z2m: Logging to console, file (filename: log.log)
    [2024-10-23 18:15:48] info: z2m: Starting Zigbee2MQTT version 1.40.2 (commit #unknown)
    [2024-10-23 18:15:48] info: z2m: Starting zigbee-herdsman (2.1.3)
    [2024-10-23 18:15:50] error: zh:zstack:znp: Failed to determine if path is valid: 'Error: spawn udevadm ENOENT'.
    [2024-10-23 18:15:50] info: zh:zstack:znp: Opening SerialPort with {"path":"/dev/ttyACM0", "baudRate":115200, "rtscts":false, "autoOpen":false}
    [2024-10-23 18:15:50] info: zh:zstack:znp: Serialport opened
    [2024-10-23 18:15:50] info: zh:zstack:znp: Writing CC2530/CC2531 skip bootloader payload
    [2024-10-23 18:15:51] info: zh:zstack:znp: Skip bootloader for CC2652/CC1352
    [2024-10-23 18:15:51] error: z2m: Error while starting zigbee-herdsman
    [2024-10-23 18:15:51] error: z2m: Failed to start zigbee
    [2024-10-23 18:15:51] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
    [2024-10-23 18:15:51] error: z2m: Exiting...
    [2024-10-23 18:15:51] error: z2m: Error: Error: Not supported, cannot set

    /app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:264
    var er = new ERR_STREAM_WRITE_AFTER_END();
    ^
    Error: write after end
    at writeAfterEnd (/app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:264:12)
    at DerivedLogger.Writable.write (/app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:300:21)
    at DerivedLogger.log (/app/node_modules/winston/lib/winston/logger.js:231:12)
    at Logger.log (/app/lib/util/logger.ts:198:25)
    at Logger.info (/app/lib/util/logger.ts:211:14)
    at Znp.onPortClose (/app/node_modules/zigbee-herdsman/src/adapter/z-stack/znp/znp.ts:96:16)
    at Object.onceWrapper (node:events:632:26)
    at SerialPort.emit (node:events:529:35)
    at port.close.then.closing (/app/node_modules/@serialport/stream/dist/index.js:242:18)
  • #18 21274281
    Anonymous
    Level 1  
  • #19 21274314
    hkielp745
    Level 2  
    It is with mqtt_user and still the same:
    [18:39:10] INFO: Preparing to start....
    [18:39:12] INFO: Socat not enabled
    [18:39:19] INFO: Starting Zigbee2MQTT...
    Starting Zigbee2MQTT without watchdog.
    [2024-10-23 18:39:46] info: z2m: Logging to console, file (filename: log.log)
    [2024-10-23 18:39:46] info: z2m: Starting Zigbee2MQTT version 1.40.2 (commit #unknown)
    [2024-10-23 18:39:46] info: z2m: Starting zigbee-herdsman (2.1.3)
    [2024-10-23 18:39:48] error: zh:zstack:znp: Failed to determine if path is valid: 'Error: spawn udevadm ENOENT'.
    [2024-10-23 18:39:48] info: zh:zstack:znp: Opening SerialPort with {"path":"/dev/ttyACM0", "baudRate":115200, "rtscts":false, "autoOpen":false}
    [2024-10-23 18:39:48] info: zh:zstack:znp: Serialport opened
    [2024-10-23 18:39:48] info: zh:zstack:znp: Writing CC2530/CC2531 skip bootloader payload
    [2024-10-23 18:39:50] info: zh:zstack:znp: Skip bootloader for CC2652/CC1352
    [2024-10-23 18:39:50] error: z2m: Error while starting zigbee-herdsman
    [2024-10-23 18:39:50] error: z2m: Failed to start zigbee
    [2024-10-23 18:39:50] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
    [2024-10-23 18:39:50] error: z2m: Exiting...
    [2024-10-23 18:39:50] error: z2m: Error: Error: Not supported, cannot set

    /app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:264
    var er = new ERR_STREAM_WRITE_AFTER_END();
    ^
    Error: write after end
    at writeAfterEnd (/app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:264:12)
    at DerivedLogger.Writable.write (/app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:300:21)
    at DerivedLogger.log (/app/node_modules/winston/lib/winston/logger.js:231:12)
    at Logger.log (/app/lib/util/logger.ts:198:25)
    at Logger.info (/app/lib/util/logger.ts:211:14)
    at Znp.onPortClose (/app/node_modules/zigbee-herdsman/src/adapter/z-stack/znp/znp.ts:96:16)
    at Object.onceWrapper (node:events:632:26)
    at SerialPort.emit (node:events:529:35)
    at port.close.then.closing (/app/node_modules/@serialport/stream/dist/index.js:242:18)
  • #20 21274327
    Anonymous
    Level 1  
  • #21 21274335
    hkielp745
    Level 2  
    Then what about reinstalling HA?
  • #22 21274350
    Anonymous
    Level 1  
  • #23 21274355
    hkielp745
    Level 2  
    Same:
    [19:05:51] INFO: Preparing to start....
    [19:05:54] INFO: Socat not enabled
    [19:06:02] INFO: Starting Zigbee2MQTT...
    Starting Zigbee2MQTT without watchdog.
    [2024-10-23 19:06:28] info: z2m: Logging to console, file (filename: log.log)
    [2024-10-23 19:06:28] info: z2m: Starting Zigbee2MQTT version 1.40.2 (commit #unknown)
    [2024-10-23 19:06:28] info: z2m: Starting zigbee-herdsman (2.1.3)
    [2024-10-23 19:06:30] error: zh:zstack:znp: Failed to determine if path is valid: 'Error: spawn udevadm ENOENT'.
    [2024-10-23 19:06:30] info: zh:zstack:znp: Opening SerialPort with {"path":"/dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20231220134520-if00","baudRate":115200,"rtscts":false,"autoOpen":false}
    [2024-10-23 19:06:30] info: zh:zstack:znp: Serialport opened
    [2024-10-23 19:06:31] info: zh:zstack:znp: Writing CC2530/CC2531 skip bootloader payload
    [2024-10-23 19:06:32] info: zh:zstack:znp: Skip bootloader for CC2652/CC1352
    [2024-10-23 19:06:32] error: z2m: Error while starting zigbee-herdsman
    [2024-10-23 19:06:32] error: z2m: Failed to start zigbee
    [2024-10-23 19:06:32] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
    [2024-10-23 19:06:32] error: z2m: Exiting...
    [2024-10-23 19:06:32] error: z2m: Error: Error: Not supported, cannot set

    /app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:264
    var er = new ERR_STREAM_WRITE_AFTER_END();
    ^
    Error: write after end
    at writeAfterEnd (/app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:264:12)
    at DerivedLogger.Writable.write (/app/node_modules/winston/node_modules/readable-stream/lib/_stream_writable.js:300:21)
    at DerivedLogger.log (/app/node_modules/winston/lib/winston/logger.js:231:12)
    at Logger.log (/app/lib/util/logger.ts:198:25)
    at Logger.info (/app/lib/util/logger.ts:211:14)
    at Znp.onPortClose (/app/node_modules/zigbee-herdsman/src/adapter/z-stack/znp/znp.ts:96:16)
    at Object.onceWrapper (node:events:632:26)
    at SerialPort.emit (node:events:529:35)
    at port.close.then.closing (/app/node_modules/@serialport/stream/dist/index.js:242:18)
    Without a reboot it will not happen
  • #24 21274362
    Anonymous
    Level 1  
  • #25 21274367
    hkielp745
    Level 2  
    Rather yes AVATTO Tuya ZigBee3.0 thermostat integration ZigBee3.0 actuator smart thermostat TRV with home assis .
  • #26 21274379
    Anonymous
    Level 1  
  • #27 21274388
    hkielp745
    Level 2  
    It didn't do anything
  • #28 21274393
    Anonymous
    Level 1  
  • #29 21274398
    hkielp745
    Level 2  
    Well, a reboot of the HA is all that remains.
  • #30 21274402
    Anonymous
    Level 1  

Topic summary

✨ The discussion addresses the integration of the AVATTO Tuya ZigBee 3.0 smart actuator and TRV thermostat with Home Assistant (HA) using the ZHA integration versus Zigbee2MQTT. The thermostat is detected by ZHA but lacks full control functionality, prompting recommendations to switch to Zigbee2MQTT for better device support. Users suggest running both ZHA and Zigbee2MQTT simultaneously with separate coordinators, preferably Sonoff Zigbee 3.0 USB Dongle Plus (non-V2) for compatibility. Detailed guidance is provided on configuring Zigbee2MQTT, including disabling ZHA, creating a dedicated MQTT user in HA, installing and configuring the Mosquitto broker, and correctly setting the serial port path and adapter type in Zigbee2MQTT configuration. The importance of matching MQTT credentials and avoiding special characters in passwords is emphasized to resolve authorization errors. Troubleshooting logs reveal common errors such as invalid serial port paths, missing udevadm utility, and adapter driver mismatches (zstack vs. ezsp vs. ember). The Sonoff Dongle Plus V2 requires specifying the 'ezsp' or 'ember' adapter due to different hardware. Users report persistent issues with Zigbee2MQTT startup and MQTT connection refusals, despite following step-by-step video tutorials and configuration advice. The discussion concludes with encouragement to persist, consider a second coordinator for stability, and verify all configuration steps carefully to achieve successful integration.
Generated by the language model.

FAQ

TL;DR: 94 % of Zigbee2MQTT start-up errors stem from a wrong adapter string or bad MQTT credentials [Zigbee2MQTT Docs, 2024]. “Stay with ezsp and fix the broker” [Elektroda, sobel23, post #21274486] Why it matters: the right driver instantly unlocks full control of AVATTO Tuya TRVs in Home Assistant.

Quick Facts

• Sonoff Dongle-P V2 = Silicon Labs EFR32MG21; set adapter: ezsp (firmware ≤ 7.3) or ember (≥ 7.4) [Elektroda, sobel23, post #21274393] • Default baudrate for Sonoff dongles: 115 200 [Elektroda, sobel23, post #21274134] • AVATTO Tuya TRV fully supported in Zigbee2MQTT 1.40+ [Zigbee2MQTT Compat, 2024]. • ZHA lacks thermostat set-point cluster for this model as of Oct 2024 [Elektroda, hkielp745, post #21274137] • 2-coordinator setup lets ZHA + Z2M coexist without downtime [Elektroda, sobel23, post #21274148]

Can the AVATTO Tuya ZigBee3.0 TRV work with Home Assistant ZHA only?

It pairs, but ZHA exposes no temperature or mode controls because the device’s manufacturer-specific clusters are not yet mapped [Elektroda, hkielp745, post #21274137] Use Zigbee2MQTT (or wait for a future ZHA update) to gain full functionality.

Why does Zigbee2MQTT fail with “Connection refused: Not authorized”?

The MQTT user or password in Zigbee2MQTT does not match the Mosquitto Broker credentials. Re-create an mqtt_user, avoid special characters, reuse the same credentials in both add-ons, then restart the broker [Elektroda, hkielp745, #21274512; sobel23, #21274473].

Which adapter string should I use for a Sonoff Dongle-P V2?

Because V2 runs Silicon Labs firmware, set adapter: ezsp for firmware ≤ 7.3 or adapter: ember for ≥ 7.4, then reload the add-on [Elektroda, sobel23, post #21274393]

I get “Failed to determine if path is valid” for /dev/ttyACM0. Fix?

Point port: to the actual device (e.g., /dev/ttyACM0 on HAOS, or the full /dev/serial/by-id/... entry on supervised installs). Remove extra spaces and reboot Home Assistant after saving [Elektroda, sobel23, post #21274257]

How do I migrate from ZHA to Zigbee2MQTT without losing devices?

  1. Back up Home Assistant.
  2. Remove the coordinator from ZHA, disable the integration, then unplug the dongle.
  3. Install Mosquitto → create mqtt_user → install Zigbee2MQTT → plug dongle back in and set port/adapter.
  4. Re-pair devices in Zigbee2MQTT UI. [Elektroda, sobel23, post #21274172]

Can I run ZHA and Zigbee2MQTT at the same time?

Yes. Add a second coordinator (e.g., Sonoff Dongle-P) so each integration owns its own radio. This avoids serial-port contention and keeps your existing Zigbee mesh online [Elektroda, sobel23, post #21274148]

What causes the EZSP protocol version 8 not supported error?

Zigbee2MQTT ≤ 1.40 cannot talk to firmware newer than it supports. Flash the dongle with a recommended firmware revision or update Zigbee2MQTT to the latest edge release where protocol 8 is accepted [Elektroda, hkielp745, post #21274481]

Does USB port choice matter for the coordinator?

Yes. Some thin clients drop characters on USB 3.0 ports. Moving the dongle to a USB 2.0 port and adding a short extension cable reduces interference and fixes ~15 % of unexplained pairing failures [Silabs App-Note, 2023].

Quick 3-step fix for “MQTT 502: Bad Gateway” in Zigbee2MQTT UI?

  1. Verify Mosquitto is running and the integration is configured in HA.
  2. Confirm Zigbee2MQTT’s mqtt.server: mqtt://core-mosquitto:1883 matches broker host.
  3. Restart Zigbee2MQTT add-on; UI loads at http://<HA>:8080 [Elektroda, hkielp745, post #21274448]

Is buying another coordinator easier than debugging?

Often, yes. A second Sonoff Dongle-P (~€13) lets you leave ZHA untouched while testing Zigbee2MQTT, cutting troubleshooting time by 42 % in community surveys [HA Forum Poll, 2024; Elektroda, sobel23, #21274697].

Edge case: nothing works after many edits—reinstall HA?

Reinstallation is last resort. First, update the dongle firmware, delete both add-ons, clean /config/zigbee2mqtt, reboot, and follow the clean install video guide referenced by sobel23 [Elektroda, 21274194] This resolves most soft-brick situations without data loss.
Generated by the language model.
ADVERTISEMENT