RC sockets & sensors with Node-RED & RaspyRFM
The RaspyRFM is a compact add-on module for the raspberry PI enabling the raspberry senden & recieving radio signals in the 434 MHz and the 868 MHz band. Controll your RC sockets, e. g. Intertechno, Logilight, Hama, Voltcraft, Emylo, Pilota Casa, and many others from Node-RED. The RC pulsenode is also capable of receiving remote controls, motion sensors, and windowcontacts.
What you need:
- Raspberry PI
- RaspyRFM 434 Mhz radio module with antenna
- Some RC sockets, controllers or sensors from a supported brand, see this list for supported devices
Node-RED does not need to be installed and run on the same PI where the RaspyRFM module is connected. The RaspyRFM nodes in Node-RED communicate with the RaspyRFM using TCP sockets.
Installation:
Install RaspyRFM nodes for Node-RED, can also be installed in Node-RED using the palettemanager:
npm install node-red-contrib-raspyrfm
Install python module for the RaspyRFM
On the Raspberry PI where the RaspyRFM is connected run the gateway for controlling RC sockets:
./rcpulsegw.py
If you are using the ELV FS-20 sockets also set the frequency:
./rcpulsegw.py -f 868.35
Also the RaspyRFM twin can be used, just supply the modulnumber 1 or 2:
./rcpulsegw.py -m 2 -f 868.35
The RC pulse node
After correct installation of all components a new node „RC pulse“ is available in your palette. This node is capable of sending (controlling sockets) and receiving (listen to buttons, sensors) the radio signals. The RC pulse’s properties are dependent of the selected protocol. E. g. when protocol „Intertechno Tristate“ is selected, you can specify housecode, group, unit and command. When all properties are set properly, hit the save button and make sure the status of your RC pulse node is „connected“. On the Raspberry Pi with the RaspyRFM radio module simply run
/apps/rcpulsegw.py
which is the backend for the RC pulse nodes. The connection is done automatically and restarts when connection is lost. When hitting the button at the node, the configured command is sent out.
Flow Examples
Emulate an intertechno tristate remote control capable of switching units 1-4 on and off:

[{"id":"681e98ad.d9e5b","type":"ui_button","z":"d6011d38.26be9","name":"1 on","group":"6a478c75.2c6ad4","order":1,"width":"1","height":"1","passthru":true,"label":"","tooltip":"","color":"","bgcolor":"","icon":"fa-toggle-on","payload":"{\"command\":\"on\",\"unit\":1}","payloadType":"json","topic":"","x":1070,"y":460,"wires":[["41777153.43ba98"]]},{"id":"6a82c5ad.b5852c","type":"ui_button","z":"d6011d38.26be9","name":"1 off","group":"6a478c75.2c6ad4","order":3,"width":"1","height":"1","passthru":true,"label":"","tooltip":"","color":"","bgcolor":"","icon":"fa-toggle-off","payload":"{\"command\": \"off\", \"unit\": 1}","payloadType":"json","topic":"","x":1070,"y":500,"wires":[["41777153.43ba98"]]},{"id":"b7f85350.562888","type":"ui_button","z":"d6011d38.26be9","name":"2 on","group":"b5a8a466.c775a8","order":1,"width":"1","height":"1","passthru":false,"label":"","tooltip":"","color":"","bgcolor":"","icon":"fa-toggle-on","payload":"{\"command\": \"on\", \"unit\": 2}","payloadType":"json","topic":"","x":1070,"y":560,"wires":[["41777153.43ba98"]]},{"id":"50bbbce3.cc58c4","type":"ui_button","z":"d6011d38.26be9","name":"2 off","group":"b5a8a466.c775a8","order":3,"width":"1","height":"1","passthru":false,"label":"","tooltip":"","color":"","bgcolor":"","icon":"fa-toggle-off","payload":"{\"command\": \"off\", \"unit\": 2}","payloadType":"json","topic":"","x":1070,"y":600,"wires":[["41777153.43ba98"]]},{"id":"1f836231.954e5e","type":"ui_button","z":"d6011d38.26be9","name":"3 on","group":"c2a7333f.12c7","order":0,"width":"1","height":"1","passthru":false,"label":"","tooltip":"","color":"","bgcolor":"","icon":"fa-toggle-on","payload":"{\"command\": \"on\", \"unit\": 3}","payloadType":"json","topic":"","x":1070,"y":660,"wires":[["41777153.43ba98"]]},{"id":"9d39803d.368968","type":"ui_button","z":"d6011d38.26be9","name":"3 off","group":"c2a7333f.12c7","order":0,"width":"1","height":"1","passthru":false,"label":"","tooltip":"","color":"","bgcolor":"","icon":"fa-toggle-off","payload":"{\"command\": \"off\", \"unit\": 3}","payloadType":"json","topic":"","x":1070,"y":700,"wires":[["41777153.43ba98"]]},{"id":"3887990c.2cc536","type":"ui_button","z":"d6011d38.26be9","name":"4 on","group":"abd316e1.a677e","order":0,"width":"1","height":"1","passthru":false,"label":"","tooltip":"","color":"","bgcolor":"","icon":"fa-toggle-on","payload":"{\"command\": \"on\", \"unit\": 4}","payloadType":"json","topic":"","x":1070,"y":760,"wires":[["41777153.43ba98"]]},{"id":"6c3f3e59.9867d8","type":"ui_button","z":"d6011d38.26be9","name":"4 off","group":"abd316e1.a677e","order":0,"width":"1","height":"1","passthru":false,"label":"","tooltip":"","color":"","bgcolor":"","icon":"fa-toggle-off","payload":"{\"command\": \"off\", \"unit\": 4}","payloadType":"json","topic":"","x":1070,"y":800,"wires":[["41777153.43ba98"]]},{"id":"41777153.43ba98","type":"rcpulse","z":"d6011d38.26be9","name":"MuFu","server":"65e4ed3f.2e05c4","datatype":"ittristate","house":"A","house_catchall":false,"group":"1","group_catchall":false,"unit":"1","unit_catchall":false,"code":"","code_catchall":false,"rcid":"","rcid_catchall":false,"command":"on","command_catchall":false,"dips":[],"dips_catchall":false,"x":1230,"y":460,"wires":[[]]},{"id":"6a478c75.2c6ad4","type":"ui_group","name":"MuFu 1","tab":"918e68b6.3f9678","order":1,"disp":true,"width":"3","collapse":false},{"id":"b5a8a466.c775a8","type":"ui_group","name":"MuFu 2","tab":"918e68b6.3f9678","order":2,"disp":true,"width":"3","collapse":false},{"id":"c2a7333f.12c7","type":"ui_group","name":"MuFu 3","tab":"918e68b6.3f9678","order":3,"disp":true,"width":"3","collapse":false},{"id":"abd316e1.a677e","type":"ui_group","name":"Stern","tab":"918e68b6.3f9678","order":5,"disp":true,"width":"3","collapse":false},{"id":"65e4ed3f.2e05c4","type":"rfmserver","host":"localhost","port":"1989"},{"id":"918e68b6.3f9678","type":"ui_tab","name":"Lichter","icon":"dashboard","disabled":false,"hidden":false}]