Smart_09_RF_receiver

SMICK

[{"id":"f4607959.7d6668","type":"tab","label":"RF_receiver"},{"id":"e015f8cc.f9dd68","type":"link out","z":"f4607959.7d6668","name":"command","links":["1096456f.bfc93b"],"x":1255,"y":100,"wires":[]},{"id":"2373e092.125a3","type":"comment","z":"f4607959.7d6668","name":"Description","info":"Smick_03_digital_output\n____________________________________________________________________\nPackage : Smick v.1\nModule  : digital output\nAuthor  : Curci\nLicence : (CC) BY-NC-SA\n\nThis work is licensed under a Creative Commons \nAttribution-NonCommercial-ShareAlike \n4.0 International License.\n\nHistory\n\nDate        Author  Description\n2016.12.26  Curci   genesis\n_______________________________________________________________________________\n\nDescription\n\ntodo\n\n_______________________________________________________________________________\n\nBill Of Material\n\nHardware:\n\n    1 Human internet terminal (PC, tablet or smartphone) connected to the internet\n    1 Smick Wi-Fi connected to the internet\n\nHW Connections:\n\n    None.\n\nFlow Connections:\n\n    None\n\nAccount:\n\n    Wi-Fi router\n    MQTT broker\n    FRED\n","x":160,"y":100,"wires":[]},{"id":"10a3bb8.3f10745","type":"ui_switch","z":"f4607959.7d6668","name":"","label":"disable/enable","group":"16021f01.431691","order":1,"width":"6","height":"1","passthru":true,"topic":"","style":"","onvalue":"RFR::D2","onvalueType":"str","onicon":"","oncolor":"","offvalue":"RFR::NULL","offvalueType":"str","officon":"","offcolor":"","x":440,"y":100,"wires":[["e015f8cc.f9dd68"]]},{"id":"6dbc5ada.1624e4","type":"link in","z":"f4607959.7d6668","name":"event","links":["ca2d688.4211598"],"x":155,"y":320,"wires":[["9d1f3ea3.cf3f","37083a2c.5cca96"]]},{"id":"29d97c07.24b3d4","type":"ui_text","z":"f4607959.7d6668","group":"16021f01.431691","order":3,"width":"6","height":"1","name":"","label":"RF code received","format":"{{msg.payload.RF}}","layout":"row-spread","x":930,"y":200,"wires":[]},{"id":"80f9ea7.6f7ca18","type":"debug","z":"f4607959.7d6668","name":"","active":true,"console":"false","complete":"true","x":1190,"y":660,"wires":[]},{"id":"ff659a14.8bc868","type":"switch","z":"f4607959.7d6668","name":"parse RF","property":"payload.RF","propertyType":"msg","rules":[{"t":"gt","v":"0","vt":"num"},{"t":"else"}],"checkall":"false","outputs":2,"x":720,"y":360,"wires":[["29d97c07.24b3d4","666a27d6.1c9aa8"],[]]},{"id":"9d1f3ea3.cf3f","type":"debug","z":"f4607959.7d6668","name":"","active":false,"console":"false","complete":"true","x":300,"y":300,"wires":[]},{"id":"b114c83c.fd7928","type":"json","z":"f4607959.7d6668","name":"","x":570,"y":360,"wires":[["ff659a14.8bc868"]]},{"id":"ff407e25.7cb1","type":"change","z":"f4607959.7d6668","name":"' -> \"","rules":[{"t":"change","p":"payload","pt":"msg","from":"'","fromt":"str","to":"\"","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":430,"y":360,"wires":[["b114c83c.fd7928"]]},{"id":"37083a2c.5cca96","type":"switch","z":"f4607959.7d6668","name":"json {","property":"payload","propertyType":"msg","rules":[{"t":"regex","v":"^{","vt":"str","case":true},{"t":"else"}],"checkall":"false","outputs":2,"x":290,"y":380,"wires":[["ff407e25.7cb1"],[]]},{"id":"666a27d6.1c9aa8","type":"function","z":"f4607959.7d6668","name":"","func":"// rx are flowContext registers\n//var ctx = this.context().global;\n\n\nvar c1 = context.get('c1')||0;\nvar c2 = context.get('c2')||0;\n\nvar c=msg.payload.RF;\n\nif (c) {\n    if (c!=c1 && c!=c2) {\n        c2=c1;c1=c;\n        context.set('c1',c1);\n        context.set('c2',c2);\n    }\n} \nvar msg1={payload:c1};\nvar msg2={payload:c2};\nreturn [msg1,msg2];\n\n","outputs":"2","noerr":0,"x":730,"y":480,"wires":[["9c54051a.e8d0a8"],["9c54051a.e8d0a8"]]},{"id":"f500eb4f.e99c78","type":"ui_text","z":"f4607959.7d6668","group":"2451cd5c.4c3ca2","order":1,"width":"4","height":"1","name":"","label":"RF code","format":"{{msg.payload}}","layout":"row-left","x":960,"y":680,"wires":[]},{"id":"f695a2ef.f71b4","type":"ui_text","z":"f4607959.7d6668","group":"2451cd5c.4c3ca2","order":3,"width":"4","height":"1","name":"","label":"RF code","format":"{{msg.payload}}","layout":"row-left","x":880,"y":740,"wires":[]},{"id":"406c80b.30b518","type":"ui_button","z":"f4607959.7d6668","name":"","group":"2451cd5c.4c3ca2","order":2,"width":"2","height":"1","label":"send","color":"","icon":"","payload":"","payloadType":"str","topic":"","x":1010,"y":620,"wires":[[]]},{"id":"a0811961.32c5e8","type":"function","z":"f4607959.7d6668","name":"RT=n","func":"msg.payload=\"RT=\"+msg.payload;\nreturn msg;","outputs":1,"noerr":0,"x":890,"y":620,"wires":[["406c80b.30b518"]]},{"id":"3271f459.92b8fc","type":"function","z":"f4607959.7d6668","name":"RT=n","func":"msg.payload=\"RT=\"+msg.payload;\nreturn msg;","outputs":1,"noerr":0,"x":870,"y":800,"wires":[["92c187e.4404b78"]]},{"id":"92c187e.4404b78","type":"ui_button","z":"f4607959.7d6668","name":"","group":"2451cd5c.4c3ca2","order":4,"width":"2","height":"1","label":"send","color":"","icon":"","payload":"","payloadType":"str","topic":"","x":1010,"y":800,"wires":[[]]},{"id":"9c54051a.e8d0a8","type":"link out","z":"f4607959.7d6668","name":"RF send code","links":["ba735d6f.e56d3"],"x":915,"y":480,"wires":[]},{"id":"16021f01.431691","type":"ui_group","z":"","name":"remote control sniffer","tab":"325b8f2a.81b9c","order":1,"disp":true,"width":"6"},{"id":"2451cd5c.4c3ca2","type":"ui_group","z":"","name":"last 2 codes sniffed","tab":"325b8f2a.81b9c","order":2,"disp":true,"width":"6"},{"id":"325b8f2a.81b9c","type":"ui_tab","z":"","name":"RF receiver","icon":"dashboard","order":6}]

Flow Info

Created 7 years, 11 months ago
Rating: not yet rated

Owner

Actions

Rate:

Node Types

Core
  • change (x1)
  • comment (x1)
  • debug (x2)
  • function (x3)
  • json (x1)
  • link in (x1)
  • link out (x2)
  • switch (x2)
Other
  • tab (x1)
  • ui_button (x2)
  • ui_group (x2)
  • ui_switch (x1)
  • ui_tab (x1)
  • ui_text (x3)

Tags

Copy this flow JSON to your clipboard and then import into Node-RED using the Import From > Clipboard (Ctrl-I) menu option