-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: Create switch/button in Home Assistant for restarting NUKI Hub #158
Comments
Hi, you can already connect with MQTT explorer and trigger a reboot by setting the maintenance/reset node to 1. |
OK that's good news - and a welcome prerequisite for the target of having an entity for that in HA. Step 1: how to template this? (MQTT noob asking) Step 2: why not making this button available out of the box? |
You can easily setup a button (trigger the "MQTT: Publish" service) that will publish an MQTT packet with topic: |
How? To be precise: not talking bout a simple GUI button but a If one could provide a full working example, that would be helpful I guess. |
You can either template the button with Home Assistant (https://www.home-assistant.io/integrations/template/) manually or extend nuki_hub by adding mqtt autodiscovery for the button |
Sorry, still no news - I'm really looking for a working example on how to achieve this. |
@bcutter I don't want to sound harsh, but you could just look that up in HA's MQTT documentation. Anyway, here's a working configuration: mqtt:
button:
- name: "Restart Nuki Hub"
unique_id: <some unique ID>
qos: 2
availability:
topic: "nuki/maintenance/mqttConnectionState"
payload_available: online
payload_not_available: offline
device:
identifiers: <your lock>
device_class: restart
entity_category: config
payload_press: 1
command_topic: "nuki/maintenance/reset" |
Check Release 8.21. |
Can we have an out of the box switch (or button meanwhile) entity in Home Assistant for restarting the NUKI hub?
I had some situations where this was needed, physical access to the ESP was not possible and logging in to the web interface (open MQTT/network settings and click save to trigger restart) is only possible for me (due to the access protection) but still neither handy nor quickly.
Latest occurrence (which made me finally write this FR) by the way: SL died (Bluetooth died), pulled the battery. After that, NUKI hub did not reconnect automatically within few minutes - at least changing settings (LED off/on etc.) from HA had no effect on the SL. For that a quick restart sent from HA would just be perfect.
The text was updated successfully, but these errors were encountered: