Skip to content

wavoigt/HA-Router-Reset

Repository files navigation

HA-Router-Reset

Home Assistant Router hard reset if hanging
Reset des Internet router durch power cycling wenn er sich aufhängt oder bei Internet Ausfall

Meine Fritzbox hängt ab und zu und weder Internet noch Wlan funktionieren. Durch Unterbrechen der Stromversorgung funktioniert alles wieder. Um das zu automatisieren habe ich in Homeassistant eine Automatisierung erstellt, die bei Router- oder Internetausfall den Router über eine an das RasPi Wlan angeschlossene Schaltsteckdose aus- und 10 Sek später wieder einschaltet.

Requisiten:

  • Raspberry Pi
  • wlan0 verfügbar oder externer Wifi Stick z.B "Anadol Wifi USB Stick" o.ä.
  • Tasmota WLan SchaltSteckdose NOUS A1T o.ä.
  • (anstelle von wlan wäre auch ein Zigbee Stick mit entsprechender Schaltsteckdose denkbar)
  • Home Assistant

Installation:

English:
Reset the Internet router by power cycling when it hangs or when the Internet fails

My Fritzbox hangs from time to time and neither the Internet nor Wi-Fi work. By interrupting the power supply, everything works again. To automate this, I have created an automation in Homeassistant that switches the router off via a switch socket connected to the RasPi Wlan in the event of a router- or internet failure and switches it on again 10 seconds later.

Props:

  • Raspberry Pi
  • wlan0 available or external wifi stick e.g. “Anadol Wifi USB Stick” or similar.
  • Tasmota WLan switching socket NOUS A1T or similar.
  • (instead of wifi, a Zigbee stick with corresponding switch socket would also be conceivable)
  • Home Assistant

Installation:

Automation:

# FritzBox Hard Reset wegen Internet Ausfall
alias: FritzBox Internet Down
description: ""
triggers:
  - entity_id:
      - binary_sensor.8_8_8_8
    to: "off"
    trigger: state
    from: "on"
    for:
      hours: 1
      minutes: 0
      seconds: 0
conditions: []
actions:
  - type: turn_off
    # Schaltsteckdose, im visuellen Editor konfigurieren 
    device_id: da44b5d192f832e526ae811c612c2ea1
    entity_id: 30125932e9b60481aee8d689284cc49b
    domain: switch
  - delay:
      hours: 0
      minutes: 0
      seconds: 10
      milliseconds: 0
  - type: turn_on
    # Schaltsteckdose, im visuellen Editor konfigurieren 
    device_id: da44b5d192f832e526ae811c612c2ea1
    entity_id: 30125932e9b60481aee8d689284cc49b
    domain: switch
  - action: system_log.write
    data:
      message: FritzBox Reboot wegen Internet Ausfall
      level: critical
  - action: notify.mobile_app_sm_g973f
    # Nachricht an Smartphone HA App
    data:
      message: FritzBox Reboot wegen Internet Ausfall
      title: Home Assistant
mode: single

About

Home Assistant Router hard reset if hanging

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published