From 80aba4ad1df933e479dd32e07f601cdad418c03e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=2E=20=C3=81rkosi=20R=C3=B3bert?= Date: Wed, 12 Apr 2023 14:04:54 +0200 Subject: [PATCH] Update lambda_magic.rst (#2822) --- cookbook/lambda_magic.rst | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/cookbook/lambda_magic.rst b/cookbook/lambda_magic.rst index b3969b3aa..b2e5bbfa4 100644 --- a/cookbook/lambda_magic.rst +++ b/cookbook/lambda_magic.rst @@ -186,12 +186,15 @@ And in YAML: text_sensors: id: "uart_readline" -**Example usage** +.. _lambda_magic_uart_switch: -Here is an example switch using the uart text sensor to set switch state. +Custom UART Switch +------------------ + +Here is an example switch using the uart text sensor above to set switch state. Here we use interval to request status from the device. The response will be stored in uart text sensor. -Then the switch uses the text sensor state to set its own state. +Then the switch uses the text sensor state to publish its own state. .. code-block:: yaml @@ -219,9 +222,9 @@ Then the switch uses the text sensor state to set its own state. See Also -------- +- :ref:`config-lambda` +- :ref:`automation` - :doc:`/components/uart` - :doc:`/custom/uart` -- :ref:`lambda ` -- :ref:`automation` - :ghedit:`Edit`