Raspberry Pi RF Switch
The rpi_rf
switch platform allows you to control devices over 433/315MHz LPD/SRD signals with generic low-cost GPIO RF modules on a Raspberry Pi.
Interoperable with codes sniffed via the rpi-rf module or rc-switch. For more info see the PyPi module description: rpi-rf.
To enable, add the following to your configuration.yaml
:
# Example configuration.yaml entry
switch:
platform: rpi_rf
gpio: 17
switches:
bedroom_light:
code_on: 1234567
code_off: 1234568
ambilight:
pulselength: 200
code_on: 987654
code_off: 133742
living_room_light:
protocol: 5
code_on: 654321
code_off: 654320
Configuration variables:
- gpio (Required): GPIO to which the data line of the TX module is connected.
- switches: (Required): The array that contains all switches.
- [entry] (Required): Name of the switch. Multiple entries are possible.
- code_on (Required): Decimal code to switch the device on.
- code_off (Required): Decimal code to switch the device off.
- protocol (Optional): RF Protocol (Default is
1
). - pulselength (Optional): Pulselength (Default is the protocol default).
- [entry] (Required): Name of the switch. Multiple entries are possible.