Sonoff sensors logging keeps turning off

I have two Sonoff Temp/Humidity sensors, one for my bathroom that is supposed to turn the vent fan on and off, and a second one that I just had in my bedroom because it was a two pack.

The one in the bathroom suddenly stopped reporting info, and after doing a few things with no luck, I decided to just swap the two. But now, both are having issues, which I'm still working on .

But, in the Hubitat Dashboard, they both keep turning debug logging off, and according to the logs it's always about a half hour after I turn it on, and no temp or humidly info reported back from either one. What's odd is they both logged with no problems until the bathroom one stopped reporting and the other one started turning off logging after they were swapped.

If it makes any difference, I did do the Zigbee device swap on them as well when I swapped positions between them, just so all the apps would still work as they should, but that shouldn't cause this.

You're kind of stuck with that 30 min window it seems.

Built-in Hubitat drivers generally follow some conventions, and we may wish to make our driver do the same so as to meet most users' expectations. These include:

  • offering a preference to enable/disable "debug logging," which in Zigbee drivers generally shows the data coming into parse(), possibly parts of how it is (and isn't) handled within parse(), and often when commands like on() are called
  • offering a preference to enable/disable "descriptionText logging," which logs the description text for any events the driver generates (often a result of interpreting the information inside parse()
  • automatically enabling debug logging and descriptionText logging upon installation of the device
  • automatically disabling debug logging 30 minutes after any time it is enabled (including after installation), while leaving descriptionText logging enabled until the user disables it

Sounds like maybe your sensors are having an issue with signal strength in your mesh.

2 Likes

I don't think it's a signal strength issue because the original sensor has been in there for about two years or so, and never missed a beat, until a couple weeks ago.

But what I don't understand is if logging turns off after a half hour, which I do see that it says it does, why was it keeping logs on the one (bedroom one) until I swapped them?

Change the batteries
Re-pair the devices
To keep debug logging on, temporarily switch the driver to “Device”, hit “delete all scheduled jobs” and switch back

Hubitat Dashboard does not display hub logs, which is the only place "debug logging" entries get written to. If you aren't seeing updates for device events (which generally correspond to "descriptionText logging," but the logging is just extra information and doesn't determine if the event actually happens or not), you have some other problem, and the timeline is just coincidental.

The first thing you should do if you're looking at Hubitat Dashboard is to rule out a Dashboard-only problem by looking at the device detail page for the device in question, which has a "Current States" section that should represent the same state(s) you see in Dashboard -- but this is the authoritative source. If it's not right here, no app, including Dashboard, has a chance of being right either.

Assumiung it's also wrong there, you've narrowed it down to a device or perhaps driver problem (but the built-in drivers have been tested with these devices and should work). Some people have repoted that these devices seem to have weak signal and are prone to "falling off" if you don't have repeaters/Zigbee routers nearby -- not a bad idea in general, and see How to Build a Solid Zigbee Mesh | Hubitat Documentation for more tips.

1 Like

Then I'm misunderstanding how the logging works.

But, on this device, I ended up deleting it and adding it back, and now it seems to be working. So, I'm still a little confused, and I seem to be having a few random things going wrong at once, but this one seems to be fixed.

You have listed a number of changes all at once in you original post, which can make it hard to understand and comment on what may be happening. With the relevant points about expected built-in driver logging in mind, it is probably best to focus on how things are both configured and behaving now and to keep changes to a minimum while you try to troubleshoot the issue, to make it easier to assess what may be causing your issues (within reason of course, if you need to change a setting for some other reason, do it).

I'd suggest sticking to one device to start with, picking one that is not behaving as you expect, posting a screenshot of the Device Preferences section of the Device Details page and some screenshots of the logs for that device (whilst those setting have been in place).

I listed the changes so I don't end up with a bunch of suggestions to do things that have already been done.

Fair point...