diff --git a/all_automations.json b/all_automations.json index eac8a7ec71..eacff62c3d 100644 --- a/all_automations.json +++ b/all_automations.json @@ -287,6 +287,7 @@ "remote_transmitter.transmit_dish", "remote_transmitter.transmit_dooya", "remote_transmitter.transmit_drayton", + "remote_transmitter.transmit_dyson", "remote_transmitter.transmit_haier", "remote_transmitter.transmit_jvc", "remote_transmitter.transmit_keeloq", diff --git a/components/remote_receiver.rst b/components/remote_receiver.rst index f83a2d48b2..d3ff7c416c 100644 --- a/components/remote_receiver.rst +++ b/components/remote_receiver.rst @@ -44,6 +44,7 @@ Configuration variables: - **dish**: Decode and dump Dish infrared codes. - **dooya**: Decode and dump Dooya RF codes. - **drayton**: Decode and dump Drayton Digistat RF codes. + - **dyson**: Decode and dump Dyson Cool AM7 tower fan codes. - **jvc**: Decode and dump JVC infrared codes. - **gobox**: Decode and dump Go-Box infrared codes. - **keeloq**: Decode and dump KeeLoq RF codes. @@ -154,6 +155,9 @@ Automations: - **on_drayton** (*Optional*, :ref:`Automation `): An automation to perform when a Drayton Digistat RF code has been decoded. A variable ``x`` of type :apistruct:`remote_base::DraytonData` is passed to the automation for use in lambdas. +- **on_dyson** (*Optional*, :ref:`Automation `): An automation to perform when a + Dyson cool AM07 code has been decoded. A variable ``x`` of type :apistruct:`remote_base::DysonData` + is passed to the automation for use in lambdas. - **on_gobox** (*Optional*, :ref:`Automation `): An automation to perform when a Go-Box remote code has been decoded. A variable ``x`` of type :apistruct:`remote_base::GoboxData` is passed to the automation for use in lambdas. @@ -367,6 +371,11 @@ Remote code selection (exactly one of these has to be included): - **channel** (**Required**, int): The 7-bit switch/channel to listen for. - **command** (**Required**, int): The 5-bit command to listen for. +- **dyson**: Trigger on a decoded dyson cool AM07 infrared remote code with the given data. + + - **code** (**Required**, int): The 16-bit code to trigger on, e.g. 0x1200=power, 0x1215=fan++,0x122a=swing..., see dumper output for more info. + - **index** (**Required**, int): The 8-bit rolling index [0..3], to be increased with every transmit, see dumper output for more info. + - **gobox**: Trigger on a decoded Go-Box remote code with the given data. - **code** (**Required**, int): The Go-Box code to trigger on, see dumper output for more info. diff --git a/components/remote_transmitter.rst b/components/remote_transmitter.rst index 41b8bdc6fb..dd93cb2756 100644 --- a/components/remote_transmitter.rst +++ b/components/remote_transmitter.rst @@ -193,6 +193,7 @@ companies. .. _remote_transmitter-transmit_beo4: ``remote_transmitter.transmit_beo4`` **Action** +*********************************************** This :ref:`action ` sends a B&O Beo4 infrared protocol code to a remote transmitter. @@ -377,9 +378,40 @@ Configuration variables: - **command** (**Required**, int): The command to send, between 0 and 63 inclusive. - All other options from :ref:`remote_transmitter-transmit_action`. +.. _remote_transmitter-transmit_dyson: + +``remote_transmitter.transmit_dyson`` **Action** +************************************************ + +This :ref:`action ` sends a Dyson cool AM07 infrared protocol code to a remote transmitter. + +.. code-block:: yaml + + on_...: + - remote_transmitter.transmit_dyson: + code: '0x1200' + index: !lambda |- + uint8_t idx = id(idx); + id(idx) = (id(idx) + 1) & 3; + return idx; + +Configuration variables: + +- **code** (**Required**, int): The 16-bit code to trigger on, e.g. 0x1200=power, 0x1215=fan++,0x122a=swing..., see dumper output for more info. +- **index** (**Required**, int): The 8-bit rolling index (range=0..3) +- All other options from :ref:`remote_transmitter-transmit_action`. + +.. note:: + + The **dyson** devices use rolling codes, i.e. each remote button generates 4 different codes in a pseudo random manner. + On every transmit the **index** variable must loop to let the **..transmit_dyson** function generate a code that differ + from the previous one. + + .. _remote_transmitter-transmit_gobox: ``remote_transmitter.transmit_gobox`` **Action** +************************************************ This :ref:`action ` sends a command to a Go-Box via the IR transmitter.