How to update the fimware of Sonoff SNZB-02D?

I have Sonoff SNZB-02D with firmware 1.0.9, but I want to install the new version of 2.2.0.

I’ve tried this in configuration.yaml:

zha:
  zigpy_config:
    ota:
      extra_providers: [{'type': 'sonoff'}]

But it does nothing.

I’ve also tried to execute this action:

data:
  ieee: 0c:ef:f6:ff:fe:68:68:34
  endpoint_id: 1
  cluster_type: out
  command_type: client
  cluster_id: 25
  command: 0
  args:
    - 0
    - 100
action: zha.issue_zigbee_cluster_command

The action itself was successful, but the software did not update.

Is there a working way to update firmware?

Would it work if I buy a Sonoff Bridge Pro ZB (eWeLink), pair SNZB-02D with it, update via smartphone, reset, and connect it back to HA?

Are you sure the firmware is indeed available? I went looking for it two weeks ago and could not find it anywhere… Even reaching out to sonoff did not yield anything (not released yet)

I’ve seen some posts about successful updates over eWeLink. I’ve ordered Sonoff Bridge Pro ZB and will try to update via their app.

I have to update those or throw them away, because they update temperature sometimes frequently, sometimes every few hours, they are totally useless. Maybe they have problem communicating with Nous A1Z, because I’m using those as repeaters. But I have also Aurora, and those sensors work perfect.

Would be super nice if you could capture the ewelink OTA somehow…

I have no idea how to do it

there is an update - installing it now.

Update worked, and I was able to reconect to HA.

Nice. Can you share your experience about the update frequency/threshold? Still 0.2K? Also have you noticed a change on the humidity accuracy? Mine are always 5%relh offset


not sure how long it will last, but for now it looks good. Took sensor few times outside and it updated immediately.

this is another sensor - clearly after update it refreshes frequently

Looks promising. If anyone from itead is reading this, could you please provide the ota file?

They are actually reasonably responsive by email but last time the answer was it’s not ready. Which is weird if ewelink can install it… Having said that, mine are more frequent than the first period, even on the old firmware.

Okay, I don’t understand something like that. They could let the community test updates for free, instead they roll it out to their own end customers. I hope they took my email feedback to heart and added a calibration offset for humidity.

If I understand correctly, my configuration is correct, there is jus no update? Is there a way to tell if there is an update? Maybie specific log entry?

It is shown in the device page of z2m addon. Or in the mqtt device.

For ZHA I don’t remember. It was not so easy to find.

I asked SONOFF to provide their firmware. They said it is only available by app. Maybe they copycat their support strategy by german company :rofl:

So i requested firmware by z2m team and they put it now into their library. Thank them.

2 Likes

I managed to update a sensor with zigbee2mqtt. You have to wait for the next release or if you can’t wait:

  1. Create file: /homeassistant/zigbee2mqtt/external_converters/snzb-02d-ota.js and paste:
const m = require('zigbee-herdsman-converters/lib/modernExtend');

const definition = {
   zigbeeModel: ['SNZB-02D'],
   model: 'SNZB-02D',
   vendor: 'SONOFF',
   description: 'Automatically generated definition',
   extend: [m.battery(), m.temperature(), m.humidity()],
   ota: true,
   meta: {},
};

module.exports = definition;
  1. Open zigbee2mqtt
  2. In settings change /Settings/OTA-Updates change OTA index override file name to

https://raw.githubusercontent.com/Koenkk/zigbee-OTA/master/index.json


4. Restart Zigbee2MQTT

After this you should be able to update one device after another by OTA panel:

  1. Wake up device by button
  2. Press search for update at the device
  3. After button turn red, press update device.
  4. Wake up device by button
  5. Wait for update to finish (30 minutes)
  6. Proceed with next device.
    Don’t update more than one device in parallel!!!

After you finished all update maybe it is better to remove the index.json and snzb-02d-ota.js

Good luck.

3 Likes

Did you notice anything new / different? Mine seem to work fine so I think I’ll just wait for the next z2m release

Today, an OTA update of my 6 devices popped up in HA:

I’m using ZHA and have no special ota config.