Short version: I have a more complicated HA setup and am not seeing any Tuya/Smart Life devices in Home Assistant when I set up Tuya integration.
Short version: Everything about my network setup seems to be working, but the Tuya devices do not appear in HA. I don’t know if it’s because the devices secretly can’t communicate with HA, or if there’s some other problem.
Previously, I was running Home Assistant on a Rasperry Pi. I decided to move it because my Pi became corrupted and I didn’t want to have to deal with that. I moved it to a Docker container running on a Synology NAS.
I also have a separate VLAN on my network for IoT devices. This is a Unifi network and the controller is currently also in a docker instance on the same Synology NAS. It also used to live on the Pi but was moved for the same reason. The Synology has two network ports, and I’ve plugged both into my switch. One of the switch’s ports is configured to be part of my main home network, and the other is configured to be part of the IoT network. Lastly, the Synology’s IoT interface has been configured with a static IP on the IoT network, and is tagged with the appropriate VLAN ID.
All my Tuya devices had already been set up on the IoT VLAN and were working with the HA installation that was running on the Raspberry Pi. When I migrated to the Synology, I set up the Docker network to use the macvlan driver which lets me force that container to use the correct interface on the Synology to be part of the IoT network. It’s on a
192.168.2.0/24 subnet (so it should be able to see everything else in that IP range) and has an IP range of
192.168.2.192/28 (I couldn’t manually assign an IP, so that ensured it wouldn’t try to take a lower IP that was already in use on my network). I am able to ping my Tuya light switches from the terminal in my Home Assistant container, as well as ping Google. It appears that the container has all the network access it needs to find the devices and to access my Tuya account.
I don’t think this matters, but I’ll mention it anyway. I have firewall rules which disallow IoT-to-Main VLAN connections. I do, however, allow connections in the other direction, and those connections are allowed to communicate back and forth (i.e. the IoT VLAN is allowed to continue established/related communication that initiated from the main VLAN)
What I know
The network seems to be working correctly in general. I’m able to access HA, my Unifi controller, and everything else. I can ping all devices (including the Tuya light switches) on either VLAN from my computer (which is on my main VLAN), but devices on the IoT network are not able to ping anything on my main VLAN. That all seems perfect.
My devices should all work with Tuya’s API. It’s just some Smart Life light switches and smart plugs, all of which worked prior to moving my HA install to the Synology.
HA does not find any of my Tuya Devices. I found a few threads that state that it might be a problem with Tuya’s API, but that seems unlikely since my previous HA instance (on the RasPi) worked great.
I’ve tried manually adding the Tuya integration information into my configuration.yaml file (despite this being deprecated). When I do, the integration appears in my list of integrations in HA after a restart. Still no devices, however.
I’ve tried using the
tuya.force_updateservices. Still no devices.
I’ve been trying to avoid flashing the Tuya devices using
tuya-convert. It’s extra work that I don’t think is necessary right now. Is this hopeless without doing so?
I’m running version 2021.2.3 of Home Assistant. The Docker image I’m using is
Does anyone have any thoughts on this situation? What else can I try? Do I have to go back to the Raspberry Pi?