After power is restored, the SNZB-02B problem
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 15.7k
- Forks
- 2k
- Avg merge
- 18h 55m
- Merged PRs (30d)
- 35
Description
What happened?
Hello,
I am experiencing a problem with the SONOFF SNZB-02B temperature and humidity sensor in my Zigbee network.
In my country, power outages happen quite frequently. When the power goes out, my Zigbee coordinator and all Zigbee routers are powered off. After the power is restored, most of my Zigbee devices reconnect and work normally, but the SNZB-02B does not properly recover its communication with the Zigbee network.
Previously, I was using an SNZB-02P in exactly the same location, and it worked correctly in this situation: after a complete power outage and restoration, it automatically resumed normal communication.
I replaced the SNZB-02P with an SNZB-02B because I specifically need the Dew Point measurement provided by the SNZB-02B.
I have now tested two different SNZB-02B devices, and both behave exactly the same way.
There is an important detail: the SNZB-02B does not necessarily become completely "offline" in Zigbee2MQTT.
For example, Zigbee2MQTT currently shows:
Availability: Online 1 day ago
Last seen: 2026-09-13 03:31:06 +03:00
and the current device state is:
{
"battery": 100,
"dew_point": 17.7,
"humidity": 74.3,
"humidity_calibration": 0,
"last_seen": "2026-09-13T03:31:06+03:00",
"linkquality": 204,
"temperature": 22.5,
"temperature_calibration": 0,
"update": {
"installed_version": 4101,
"latest_release_notes": null,
"latest_source": null,
"latest_version": 4101,
"state": "idle"
},
"vpd": 0.7
}
The firmware is therefore already at the latest available version, 4101.
However, although Zigbee2MQTT may report the device as Online, the sensor stops providing regular measurements. The Home Assistant history shows the following behavior:
sensor.t_g1_temperature,24.7,2026-09-12T23:54:03.556Z
sensor.t_g1_temperature,24.5,2026-09-12T23:55:24.587Z
sensor.t_g1_temperature,24.3,2026-09-12T23:55:58.285Z
sensor.t_g1_temperature,24.1,2026-09-12T23:56:36.274Z
sensor.t_g1_temperature,23.9,2026-09-12T23:57:09.394Z
sensor.t_g1_temperature,23.7,2026-09-12T23:57:59.404Z
sensor.t_g1_temperature,23.5,2026-09-12T23:59:05.452Z
sensor.t_g1_temperature,23.3,2026-09-13T00:00:39.474Z
sensor.t_g1_temperature,23.1,2026-09-13T00:02:56.769Z
sensor.t_g1_temperature,22.9,2026-09-13T00:06:26.738Z
sensor.t_g1_temperature,22.7,2026-09-13T00:12:52.122Z
sensor.t_g1_temperature,22.5,2026-09-13T00:22:31.188Z
sensor.t_g1_temperature,unavailable,2026-09-13T00:37:37.640Z
sensor.t_g1_temperature,22.5,2026-09-13T03:08:01.445Z
sensor.t_g1_temperature,unavailable,2026-09-13T06:13:06.068Z
sensor.t_g1_temperature,22.5,2026-09-13T07:59:35.902Z
sensor.t_g1_temperature,unavailable,2026-09-13T12:00:01.114Z
sensor.t_g1_temperature,22.5,2026-09-13T15:03:40.679Z
sensor.t_g1_temperature,unavailable,2026-09-13T21:21:19.706Z
sensor.t_g1_temperature,unknown,2026-09-13T21:21:20.938Z
sensor.t_g1_temperature,22.5,2026-09-13T21:22:08.035Z
sensor.t_g1_temperature,unavailable,2026-09-14T01:14:03.840Z
sensor.t_g1_temperature,22.5,2026-09-14T01:14:06.879Z
This suggests that the device is not simply disconnected permanently. Instead, after the power outage it appears to lose normal communication with the Zigbee network and only occasionally sends or responds to something. The device can remain marked as Online in Zigbee2MQTT while the sensor data is no longer updated normally.
A short press of the button on the SNZB-02B does not restore normal communication.
The only reliable way I have found to recover the device is to hold the button for a longer period and then enable pairing mode in Zigbee2MQTT, effectively forcing the device to join the network again.
This is particularly inconvenient because the sensor is installed in my basement. Manually going there and repairing the device after every power outage is not practical.
My Zigbee network itself appears to be working correctly because the other Zigbee devices recover normally after the coordinator and routers restart.
@CubeZ2mDeveloper
What did you expect to happen?
No response
How to reproduce it (minimal and precise)
No response
Zigbee2MQTT version
2.14.1
Adapter firmware version
9.1.1 [GA]
Adapter
Ember
Setup
x86-64, containerized
Device database.db entry
No response
Debug log
No response
Notes
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing a coordinator and router power cycle with the SONOFF SNZB-02B, then collect the missing device database entry and debug log requested in the issue. Compare the device's post-restart reporting with the working SNZB-02P behavior; done means the SNZB-02B resumes regular measurements without re-pairing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- embedded-iot
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100