Sonoff SNZB-04 as a rain sensor - 6 months later

Since the topic is closed, I’d like to revisit this and hear the original author how things have gone, and perhaps others that are also curious can be inspired.

Thanks @Will for taking the time and share this with us.
Here are the initial questions I had for this project, looking back:

  1. how is the sensor hooked up to the SNZB-04?
  2. is the 3d print on thingyverse or similar platform?
  3. any comments on the tinned vs clean part of the sensor and how that is looking.after 6 months?

Sorry for the delayed answer. I wanted to do it right and snap a few photos :slight_smile:

how is the sensor hooked up to the SNZB-04?

This part is very straight forward and no electronic is required. You only need to unsolder 2 points and resolder.
The SNZB-04 has a “proximity” sensor that looks like a little glass capsule. Inside, you will find 2 small blades. I think one is magnetic and the other is not. If you bring a magnet, the magnetic blade moves and closes the contact. This sensor is not polarised so there is no right or wrong way to install it as long as the contact closes when the magnet gets close.

I did unsolder this capsule and I hooked up the “rain sensor” there.
The rain sensor is also very simple and has no electronic. You will just need to hook up 2 cables to the sensor and bring those 2 cables to the SNZB-04.

is the 3d print on thingyverse or similar platform?

I usually publish models on printables but see I did not publish that one. I did not publish because the mounting part is rather “custom”. It may or not work for you.

I am attaching some pics of the model. If there is interest, I can share this model, no problem.

Typical “outside” view.

Bottom view, we can see the 2 holes made for the 2 cables.

Here we see how the SNZB-04 PCB slides in my 3d printed enclosure.

Finally the a back view. The big circular hole is where the cables are connected to the PCB of the rain sensor. I usually seal that with a good amount of glue to protect the connections against weather, humidity… and small fingers :slight_smile:

any comments on the tinned vs clean part of the sensor and how that is looking.after 6 months?

Actually yes and I even have photos now. I did not feel like leaving the copper traces exposed. I think there is just no way it can survive long without oxidation. So when I built my second sensor, I tinned also the remaining half of the second.
We can see small oxidation dots where I tinned super thin. Those sensors are cheap so I don’t mind if they die after a while and I would probably just re-tin them. I would however recommend to tin “fat”. On the photos, we can see the 2 options and where I tinned fat, it still looks better atm.

Extra comments:

Besides the answer to your questions, I can add a few things:

  • I has been working pretty good and that works very well with the automatic retraction of my shades
  • The main issues I ran into where about the SNZB-04 losing connection. Usually I just need to repair and it works again. I guess the main issue there is that the sensors are mounted on a metal balcony that acts as a huge antenna… potentially screwing up the comm. Since I have more ZigBee decides (ie routers), I see less issues.

As far as battery goes, here is the chart over the last 6 months:

1 Like

Maybe an extra note since I ran into that this morning: beautiful day, sunny yet cold, my shades did not extend. I realized one of my rain detection was “ON” although no rain in sight.
In the morning, the dew will trip the sensor. In my case, it was not that much of an issue as it means that the sun is not strong anought yet to get rid of the dew. One hour later, the dew was gone and the sensor was back to dry.
It is just something to keep in mind as this “rain” detector may trip also there is no rain at all.

1 Like

Thanks for the inputs! :smiley:

I’ve fiddled around with the Sonoff, and have made a prototype using a cjmcu-606 board as the rain sensor which worked a treat.

But I’ve decided to go with an esp32 based solution instead, as I will go for an array of rain sensors instead of just 1 coupled to each sonoff. I’ve also bought some 5V heatpads to see if that can mitigate the dew problem in periods where this may be an issue, and also when the rain has stopped is should speed the “reset” as they will help the rain sensor pads to dry quicker. Thanks for the updates, I really appreciate it, and if there are more cases you see that I should take into consideration please report back :smile:

I’ll post when I have the heatpads and my rain sensor v2 will begin tests, probably around mid December, as delivery will probably be some 2-3 weeks