From b9e7d097c7167811629e39c8f3972fc0deb78b67 Mon Sep 17 00:00:00 2001 From: Tim van der Heide Date: Mon, 27 Jan 2020 12:30:51 +0800 Subject: [PATCH] Update remote.xiaomi_miio.markdown Added configuration example to create UI button in Lovelace to send IR command. --- .../_integrations/remote.xiaomi_miio.markdown | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/source/_integrations/remote.xiaomi_miio.markdown b/source/_integrations/remote.xiaomi_miio.markdown index d06af7d90436..ec4686169f97 100644 --- a/source/_integrations/remote.xiaomi_miio.markdown +++ b/source/_integrations/remote.xiaomi_miio.markdown @@ -85,6 +85,25 @@ remote: - pronto:pronto_hex:[optional_repeat] ``` +## Add command as entity button in Lovelace UI + +```yaml +type: entity-button +tap_action: + action: call-service + service: remote.send_command + service_data: + command: activate_towel_heater + entity_id: remote.xiaomi_miio_ir +hold_action: + action: more-info +show_icon: true +show_name: true +entity: remote.xiaomi_miio_ir +icon: 'mdi:radiator' +name: Activate Towel Heater +``` + ## Use named commands to create UI buttons ```yaml