Is Zigbee the answer to slow wifi PIRs? If it is, how when using hyper-v?

I got a couple of cheap wifi PIR sensors from Ali express like these, which work reliably through Local Tuya, but they’re too slow to respond (and I’d refer being able to use them through Tuya Local but cant get them added).
I’ve got one controlling lights above my stairs, and I often get 2/3 of the way up the stairs before the lights are triggered. It’s only 3-5 seconds, but makes quite a difference.

I’ve done some reading and it seems that using zigbee PIR sensors might be the best change I could make to improve the delay?

Zigbee seems like a huge can of worms though, and I really can’t figure out the best way to go about it.
I’ve got home assistant running in hyper-v, so just passing through a USB dongle isn’t an option.

I think there might be two ways to get it talking to zigbee devices?

  1. Add a PCI-E USB card to the hyper-v host, and pass through the whole USB controller to the HA VM using DDA/SR-IOV like here
    Trouble is, I’ve read that not all USB cards/controllers support doing this (the hosts USB controllers on its motherboard don’t seem to) and almost no listings for cards mention if they do or not, and I’m not sure what card/controller HAOS would be happy with.
    I’ve found one post that mentions a specific card, but it looks hard to get outside the US and I’m in the UK.
  2. A network-based zigbee controller… maybe something like these
    There are wifi and cabled versions, but staying away from wifi seems sensible.
    I can find very little info on how to connected these with HA though… what I’d have to add to HA and how to configure it. Everything seems to be geared towards the USB zigbee controllers.

So…
Can my existing wifi PIR sensors be added to Tuya Local somehow? (I’m pretty sure that wouldn’t change the delay though)
Is using zigbee PIR sensors the way to remove the delay?
If it is, USB card and USB adapter, or networked hub?
Am I just miles off understanding?

I’d really appreciate and guidance/experience anyone could offer

LocalTuya seems to be quite buggy with the latest HA update, so you might need some patience there.
You issue is more likely a question about detector distance and another brand might solve it, but you need to research at what distance they can reliably detect presence.
Some PIR also combine the PIR with a mmWave sensor, which might work better on the distance.
Also take notice that the way the sensor is made physically might block its view in certain directions. This means it can sometimes be a good idea to tilt it 90 degrees to make it cover more up and down, if it is originally designed to cover left and right.

My Zigbee PIR sensors certainly respond immediately, but in your case Zigbee is probably not a good solution.

It works best when sensors are supported by a dense mesh of mains-powered routers - ideally every light and every socket in the house should also be Zigbee. It’s not suitable when you are just trying to connect with a small number of sensors and attempts to do this can be really, really frustrating, quite apart from the hyper-v thing.

Don’t throw money at it - it won’t work.

Localtuya can be a bit buggy, thats exactly why I’d like to get them going in tuyalocal.
I’ve got some cheap WiFi lights working perfectly in tuyalocal, but it doesn’t seem to get on with a couple of leak sensors or these PIRs so I’ve had to set up in localtuya.

I don’t think its them detecting motion that’s slow. They have lights on them that trigger almost immediately, but then there’s a few seconds delay as they wake up and do their thing over the WiFi.
That’s whats got me thinking ZigBee…

If you go that path, look for a network connected coordinator in that case. I’d follow current guidance by Hedda as to zigbee hardware. Just realize zigbee Requires a strong mesh to have good responsive signals. So it’s jot just throwing up a coordinator and a few battery devices. You have to be ready to build a full zigbee network including adequate routing devices.

1 Like

Do you know, I hadn’t thought of that? What a brilliant, simple idea! :grin:

1 Like

Ah, I didn’t realise ZigBee would need more than one radio device talking to a couple of sensors.

The place isn’t very big, but there are a couple of walls between the hyper-v host and where I’d want the PIRs.

Does this mean replacing everything with ZigBee, or sticking with what I’ve got?
The battery life of these WiFi sensors isn’t all that great either, but I’m not sure that and a few second delay would make changing everything worth it tbh

Pretty much, yes.

Thanks a lot, but dammit!

I guess that changes my question to:
Does anyone know any wifi based PIR sensors that are quicker than what I’ve got, and have reasonable battery life?
Or, is there some other kind of battery-powered sensor that might do it?

Yes zigbee is an ULTRA low power network and uses the redundancy of multiple powered repeating devices (battery devices dont repeat) to carry the signal. Spec says you should get 100’ in open air line of sight. But people dogs cats walls and plants (all things that absorb signals) are things and Zigbee being as low power yields to pretty much all other rf interference. Because of those things I use 25’ (approx 8-10m)as my planning distance between powered repeating nodes to cover my space THEN AND ONLY then do I deploy battery devices - pairing in place. So you can ensure that they have good signals.

So that means one or more good quality powered repeating nodes are tables takes for any new zigbee mesh. So many try to deploy a coordinator and battery devices only and fail miserably.

Wifi and good battery are almost always mutually exclusive - because wifi is not a low power network…

I do have a couple of wifi smart sockets that could potentially be swaped too, which might be enough to make zigbee work out OK…
I’m on a small budget here though, and it’s getting a bit expensive just to remove a few seconds delay tbh.
Other than the few seconds delay with these PIR sensors and their not great battery life, the wifi stuff I’ve got works a treat.

I bet it’s a story you’ve heard before, but I got wifi gear (calex from tesco) in the first place to work with the smartlife app - then discovered Home Assistant and got slightly bigger ideas (HAs more capable automations, and having local control).
I would probably have gone zigbee from the word go if I knew of HA back then.

2 Likes

You do not have to have that many devices.
I use a single Silvercrest Coordinator and have no routers, since I have no mains powered Zigbee devices, but I have 5 Zigbee sensors.
It works fine.

The benefit with more devices that act as routers are that the mesh network becomes more resilient and also self-healing if a router dies.

I might still give it a go with one of the network based things like I linked.
The place isn’t very big, and theyre cheap enough to take a bit of a gamble. I’ll keep replacing the sockets in mind if I have coverage trouble.
How is that kind of thing set up with HA though?
The listings for them all seem to mention zigbee2mqtt rather than ZHA…
Is mosquito broker and zigbee2mqtt the way to go? Anything I can find assumes a USB device rather than network, and mentions connecting it to a serial device rather than anything by IP.

In the listing you linked, don’t forget to choose the ‘Tasmota MQTT’ one. You don’t really want to use Ewelink (same problems as Tuya)

I have one of these Tasmota MQTT ones, it seems to work with both ZHA and Zigbee2MQTT

Thanks.
I’d seen there are two base types, good to have the right one confirmed.
ZHA seems to be the friendler approach too, so good to read.

If I install ZHA though, the first thing it asks for is radio/chipset type. How do you connect it over the network?

My silvercrest Zigbee hub is just linked to HA with a socket I think.
It was quite easy to set up and after that it is just inside HA I work.

The guide I used for it is this:

The first part is because the Silvercrest is “hacked”.

You would probably start at the headline " Using Home Assistant’s ZHA to integrate the device"

I’d just seen the mention of adding it using and IP:port here too, that I’d missed before.
Before your link and noticing that it was a bit of a mystery.
I’ll give it a try.

Thanks everyone

1 Like

@mad-tunes I have one wifi tuya motion sensor, and I connect to it via node-red and ping node set to ping the motion sensor once every second. You just need to set a static IP to your motion sensor and you can set the ping interval to 0.5 seconds if you need the info quicker.

These sensor go to sleep when not in use, and when motion is detected they wake up and are reached by ping, this is probably much quicker to get a ping to go through then waiting for the tuya integration to get info upon motion.

Interesting.
I’ve just set a ping -t running against one of them and then triggered it, and I did get a reply quicker than it currently triggers in HA.
It took about a second, maybe 1.5. That’d be much better than the 3-5 ish I currently get.
I know 5 seconds isnt a long time, but it is if you’re in the dark waiting for a light to come on.

I’ve never used node red though, would you mind sharing how you’ve got this set up please?