logo elektroda
logo elektroda
X
logo elektroda

[Solved] How do I restart the WIFI router to which the Sonoff is connected?

8850 1098 4
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
  • #1 20561273
    8850
    Level 21  
    Is it possible to reverse the impulse so that pressing the ON/OFF button in the ewalink app on the smartphone restarts the router (power off and on in a second) on whose power cable the Sonoff is? I can't switch this anywhere, is this possible? If not, how and with what do I achieve this?

    Sonoff Basic R2 on the 220V cable supplying the socket with the WIFI router.
    Wifi router Xiaomi mi3G Padavan firmware. Provides fibre optic internet to the flat
  • ADVERTISEMENT
  • ADVERTISEMENT
  • #3 20561635
    8850
    Level 21  
    I need an emergency physical/radio remote exit when a router crashes.
    I have access to the router via ssh and https:// from the WAN side, but if the connection/router crashes I can't do anything remotely, I need to use a sonoff that I have in stock. How do I do this?
  • ADVERTISEMENT
  • #4 20561659
    kindlar
    Level 42  
    Check that the sonoff executes the program when disconnected from the wifi. By program I mean the power scenario. Let's say the programme looks as follows: in one minute turn off the power for 30 seconds and turn it on.
    When you want to reset the router you run this program but by the time it turns on there is no wifi. Will the sonoff save the actions in memory.
  • #5 20561729
    8850
    Level 21  
    Thank you kindlar, you have solved my problem. The script in sonoff is a timer that can be programmed remotely (as long as the internet->router->sonoff connection is still running, but the router has hung up and you can't access it with ssh/www). The smallest time slot is 1 minute. I set a timer in Ewelink in the smartphone app for 1 minute - off and immediately below it for 2 minutes on. In sonoff, I have permanently set the status when the power is switched off - always on. Sonoff internally saves the settings of the timer scenario you wrote about and it can even be disconnected from the internet, it will automatically restart the router and without a wifi connection it will switch on the power after 2 minutes to the router.

    The second way seems to be the best, leaving a second phone at home with an active SIM and GSM/3G/4G connection with a wifi hotspot to which the sonoff is connected (and not under the wifi router). If the internet connection in the router fails, the sonoff will restart via the backup connection on the phone. Perhaps a third way, but an unreliable one, would be to insert a GSM modem on the USB port of the router with an active SIM card and to set the router so that it switches to Internet transmission via the GSM modem if the fibre connection fails, which is unlikely. If the router crashes completely, this is of no use to me as a third way.

    Just in case, I have also set the router in the administration panel to restart automatically every 6 hours (non-original firmware Padavan on my router allows access to a crontab where I set what is to be done and when at what time.

    Click helped.
ADVERTISEMENT