logo elektroda
logo elektroda
X
logo elektroda

Which battery-powered PIR sensor for Home Assistant? SNZB-03 commissioning and interior

p.kaczmarek2 1731 12
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
📢 Listen (AI):
  • Sonoff SNZB-03 motion sensor with packaging. .
    The Sonoff SNZB-03 is a tiny (only 40x35x28mm) PIR sensor that is compatible with Home Assistant via, among other things, Zigbee2MQTT. It is available to buy for around £40-50, depending on whether you order from China or our country. It is powered by a tiny CR2450 (3V) battery. Properly configured, it is capable of triggering various automations, such as turning on a light when movement is detected.
    Packaging of Sonoff SNZB-03 motion sensor resting on a table. Sonoff SNZB-03 PIR motion sensor with a paper manual and double-sided 3M tape on a wooden background. .
    In addition to the sensor, we get a strip of 3M double-sided tape for mounting. There is also an instruction manual:
    User manual for Sonoff SNZB-03 motion sensor. Installation and setup instructions for the Sonoff SNZB-03 sensor in various languages. User manual for the Sonoff SNZB-03 sensor. User manual for Sonoff SNZB-03 sensor in multiple languages. Sonoff SNZB-03 user manual with QR code and FCC information. User manual for Sonoff SNZB-03 sensor with QR code. .
    However, I will skip the pairing with the manufacturer's gateway and give it a go with HA straight away.
    Back of Sonoff SNZB-03 motion sensor with manufacturer information. .

    Pairing with Home Assistant Pairing with Home Assistant.
    I have Home Assistant set up according to a theme from a few years ago, but obviously updated:
    Home Assistant tutorial - setup, WiFi, MQTT, Zigbee, Tasmota .
    Zigbee2MQTT I also updated:
    How do I update Zigbee2MQTT Home Assistant to the latest version? Unsupported device? .
    If you need to, reset the device as instructed, at HA make sure pairing is enabled.
    Close-up of the Sonoff SNZB-03 sensor with a tool for opening the case. .
    The sensor should appear in our panel:
    Zigbee2MQTT user interface displaying a list of connected devices. Zigbee2MQTT interface displaying details of the Sonoff SNZB-03 motion sensor. Screenshot of Zigbee2MQTT configuration panel showing the Sonoff SNZB-03 sensor status. Screenshot of the Zigbee2MQTT panel displaying sensor states. .
    The sensor provides an 'occupancy' status, i.e. detection of movement, which is cleared after 60 seconds. In addition to this, we have the battery status (by percentage, there is a separate low battery warning), tamper and connection quality. The tamper, in turn, determines whether someone has taken down the sensor and its implementation depends on the device.
    A PIR paired in this way can already trigger events:
    Home Assistant - how to trigger an event with a PIR sensor? Zigbee and WiFi, lighting up Home Assistant - how to trigger an event with a PIR sensor.


    Interior of SNZB-03 .
    For educational purposes only. We take a look inside:
    Interior of Sonoff SNZB-03 sensor with visible circuit board and CC2530 chip. Interior of the Sonoff SNZB-03 sensor showing the circuit board and electronic components. Interior of Sonoff SNZB-03 sensor showing the CC2530 chip on a circuit board. Interior of the Sonoff SNZB-03 sensor showing the CC2530 chip. Inside of the Sonoff SNZB-03 sensor showing the PCB and electronic components. .
    The sensor is based on the CC2530, as are brother products including the SNZB-04 (door/window opening sensor).
    Technical specification of the CC2530 chip from Texas Instruments. .
    The CC2530 is a Zigbee 2.6 compliant SoC solution offering 256kB of Flash memory, 8kB of RAM and 21 GPIOs, including a 12-bit, 8-channel ADC, 2 SPI/UART and 4 timers.

    Summary .
    Seamless pairing, you can go straight to scripting the automation. I guess the only thing to keep in mind is that this sensor doesn't extend the range of our Zigbee network as it is a battery powered device, but that shouldn't cause us any problems.
    I have already shown an example of an automation done based on this sensor:
    Home Assistant - how to trigger an event with a PIR sensor? Zigbee and WiFi, lighting up .
    For my part, that's it. And what PIR-based automations would you guys create? .

    Cool? Ranking DIY
    Helpful post? Buy me a coffee.
    About Author
    p.kaczmarek2
    Moderator Smart Home
    Offline 
    p.kaczmarek2 wrote 12186 posts with rating 10132, helped 580 times. Been with us since 2014 year.
  • ADVERTISEMENT
  • #2 21405427
    @GUTEK@
    Level 31  
    I recently bought such a sensor in china https://www.zigbee2mqtt.io/devices/ZP01.html
    Basically works the same as the one described by the author of the topic, only that it is powered by 2xAAA. Which are, however, more easily available, and everyone has one at home.
    It provides the same entities, i.e. charge level, low battery level, detection (Occupancy) and violation (Tamper). Except that there is no switch from violation, so it's a dummy.
    When motion is detected it holds the status for about 40s, then if no one is present it goes back to no detection.

    I have this problem though, I don't know if it's the fault of this sensor or the hub I'm using, but there are times when a status change won't be picked up by the Z2M. It is sporadic, but I connected a Christmas tree light for Christmas under the automation with this sensor and it happened that despite motion detection (the LED flashed) the status did not change, the same in the other way, the sensor was able to not send a non-detection.

    Overall a cool toy, especially when integrated with HA. The big plus of the Zigbee version is the instantaneous status transmission. Where the same WiFi version of the sensor, apart from the higher power consumption has some 6s delay until it connects to the network.
  • ADVERTISEMENT
  • #3 21405668
    jarekgol
    Level 39  
    How long does something like this run on batteries? Assuming it's indoors and for 16h is triggered several times for each hour?
  • #4 21406377
    krzbor
    Level 27  
    In the screenshot I see that the "Friendly names" are not particularly friendly. This happens when a new device is connected. If HA is running at the moment, it unfortunately takes on these bizarre meanings. To change this you need to:
    1. set the "Friendly name" correctly in Z2M
    2. in HA remove this device (it is as a device in MQTT).
    3. reboot the Z2M (the reboot option is available from the browser).
    After the restart, Z2M will register our device again with the name we set.
  • ADVERTISEMENT
  • #5 21406493
    CMS
    Administrator of HydePark
    Quite large and expensive. I prefer such 33x27mm https://pl.aliexpress.com/item/10050081588407..._id=202501230824352596395740709020006331535_4

    Powered by a Cr2450 battery, the Chinese one claims a life of 1.5 years with 10 triggers per day. At my place it has been working in the kitchen since November 2022. It is active from dusk to dawn, and making a dozen triggers a day. At the moment, the battery has 1%



    Screenshot of an app showing battery alarm settings. .
  • ADVERTISEMENT
  • #6 21406527
    p.kaczmarek2
    Moderator Smart Home
    @krzbor I don't know if we are talking about the same thing, but isn't it enough in Zigbee2MQTT in HA to click rename?
    I have had a device with an unchanged name for a few days now. I now follow these steps:


    .
    Immediately afterwards I have:
    User interface showing a list of devices connected to the Zigbee2MQTT system. .
    Screenshot of Zigbee2MQTT interface in Home Assistant showing device information and logbook. .
    I have not rebooted anything.
    Helpful post? Buy me a coffee.
  • #8 21406978
    @GUTEK@
    Level 31  
    krzbor wrote:
    In the screenshot I can see that the "Friendly names" are not particularly friendly. This happens when connecting a new device. If HA is running at the moment, it unfortunately takes on these bizarre meanings. To change this you need to:
    1. set the "Friendly name" correctly in Z2M
    2. in HA remove this device (it is as a device in MQTT).
    3. reboot the Z2M (the reboot option is available from the browser).
    After the restart, Z2M will re-register our device with the name we set.
    .
    At the bottom you click on the icon to change the device name. In addition, you tick "Update Home Assistants entity ID" and that's it. You don't have to do anything extra, you don't have to restart anything. The name changes in both Z2M and HA.
  • #9 21407519
    krzbor
    Level 27  
    @GUTEK@ wrote:
    Additionally, you tick "Update Home Assistant entity ID" and that's it.
    .
    Was this option in the older Z2M? I have it now, but don't know if it was before. Renaming changed the name in HA, but the entities had the old numeric identifiers. I'll be pairing something up soon and see if it works that way.
  • #10 21407626
    @GUTEK@
    Level 31  
    I started using from version 1.42, now I have 2.0. And in these versions it was, as before I don't know.
  • #11 21411772
    Michal8883
    Level 5  
    What is the best way to connect zigbee sensors? Via a dongle to a raspberry zero2w or just a gateway and an app e.g. HA?
  • #13 21412932
    @GUTEK@
    Level 31  
    Michal8883 wrote:
    How best to connect the zigbee sensors? Via dongle to raspberry zero2w or just a gateway and application e.g. HA?
    .
    If you want under HA it is best via a dongle e.g. from Sonoff. Gateways are usually under cloud systems e.g. Tuya, eWelink. Some can be reprogrammed and used with HA.


    gsm_42 wrote:
    Ikea has also recently added a PIR sensor on Zigbee. In my opinion, with 2x AAA power supply, they will definitely last longer than the Chinese Sonoff fakes.
    https://www.ikea.com/us/en/p/vallhorn-wireless-motion-sensor-smart-white-40504348/
    .

    These sensors are plentiful. I have now bought one with a radar function out of curiosity. I will just be testing it out.

    Motion sensor ZG-2042S with radar function on green PCB. .
📢 Listen (AI):

Topic summary

The discussion centers around the Sonoff SNZB-03 PIR sensor, which is compatible with Home Assistant via Zigbee2MQTT. Users share experiences regarding its performance, battery life, and setup. The SNZB-03 is compact, powered by a CR2450 battery, and can trigger automations like lighting upon motion detection. Alternatives, such as a sensor powered by 2xAAA batteries, are mentioned for their availability and similar functionality. Users also discuss issues with device naming in Home Assistant and the ease of connecting Zigbee sensors through various methods, including dongles and gateways. The IKEA Vallhorn PIR sensor is noted as a viable alternative with potentially longer battery life.
Summary generated by the language model.
ADVERTISEMENT