I have an old Sonoff TH16 (like this one) flashed with the Tasmota firmware to use it via MQTT. I have a mosquitto broker on an external server.

It ran fine for several months inside my friend's LAN but since a couple of weeks it's able to transmit a sensor packet only few times per day. In the rest of the time I get the LWT "offline" message.

I have other MQTT sensors (not Sonoff - they are Arduino-based board with my own firmware) that work correctly. Hence I don't think is the WiFi network.

I tried to change the position and the plug (it is very close to the router, though) but nothing has changed. Instead, connecting the sensor inside my LAN it works fine!

What else could cause this odd behavior?

  • 3
    In your friend's network the Sonoff device only occasionally works and in your network the same Sonoff device always works? Do you know the Sonoff device's IP address when in your friend's network? If you power the Sonoff device down, will a ping to that IP address produce an answer despite the Sonoff device being powered down?
    – st2000
    Apr 9 at 4:29
  • @st2000 yes for the first question. For the others I'm going to check. Good advice, it can be a dup IP!
    – Mark
    Apr 9 at 6:40
  • This is what happened to me. I had forgotten about a downstream router that turned out to assume the same IP address on its WAN port as my media server. Messed with me for days. Let me know if it turns out to be a duplicate IP address and I'll turn the comment into an answer. Or you can answer your own question.
    – st2000
    Apr 10 at 5:14
  • @st2000, of course. It may take some days before I can do this test, though
    – Mark
    Apr 10 at 7:28


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.