Guest User

Untitled

a guest
Sep 11th, 2018
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
JSON 13.13 KB | None | 0 0
  1. [
  2.     {
  3.         "id": "3cac3927.abaf16",
  4.         "type": "inject",
  5.         "z": "127fd315.6c04dd",
  6.         "name": "",
  7.         "topic": "",
  8.         "payload": "OPEN",
  9.         "payloadType": "str",
  10.         "repeat": "",
  11.         "crontab": "",
  12.         "once": false,
  13.         "x": 165.5,
  14.         "y": 176,
  15.         "wires": [
  16.             [
  17.                 "4d2ba3b8.29ec84",
  18.                 "72652330.3a11ac",
  19.                 "6da9c580.db005c"
  20.             ]
  21.         ]
  22.     },
  23.     {
  24.         "id": "25fb8c64.060d0c",
  25.         "type": "inject",
  26.         "z": "127fd315.6c04dd",
  27.         "name": "",
  28.         "topic": "",
  29.         "payload": "CLOSED",
  30.         "payloadType": "str",
  31.         "repeat": "",
  32.         "crontab": "",
  33.         "once": false,
  34.         "x": 158,
  35.         "y": 208,
  36.         "wires": [
  37.             [
  38.                 "4d2ba3b8.29ec84",
  39.                 "72652330.3a11ac",
  40.                 "6da9c580.db005c"
  41.             ]
  42.         ]
  43.     },
  44.     {
  45.         "id": "bda906de.dfdf78",
  46.         "type": "comment",
  47.         "z": "127fd315.6c04dd",
  48.         "name": "Item Door",
  49.         "info": "This block displays a Door item from openHAB with the status OPEN/CLOSED",
  50.         "x": 154.5,
  51.         "y": 145,
  52.         "wires": []
  53.     },
  54.     {
  55.         "id": "6d8cfd0d.a20944",
  56.         "type": "inject",
  57.         "z": "127fd315.6c04dd",
  58.         "name": "",
  59.         "topic": "",
  60.         "payload": "ON",
  61.         "payloadType": "str",
  62.         "repeat": "",
  63.         "crontab": "",
  64.         "once": false,
  65.         "x": 170,
  66.         "y": 409,
  67.         "wires": [
  68.             [
  69.                 "c7d3f01.b3cba1",
  70.                 "5fd52631.fe9be8",
  71.                 "b69b8cef.4fec58"
  72.             ]
  73.         ]
  74.     },
  75.     {
  76.         "id": "3a25038.87822fc",
  77.         "type": "inject",
  78.         "z": "127fd315.6c04dd",
  79.         "name": "",
  80.         "topic": "",
  81.         "payload": "OFF",
  82.         "payloadType": "str",
  83.         "repeat": "",
  84.         "crontab": "",
  85.         "once": false,
  86.         "x": 171.5,
  87.         "y": 441,
  88.         "wires": [
  89.             [
  90.                 "c7d3f01.b3cba1",
  91.                 "5fd52631.fe9be8",
  92.                 "b69b8cef.4fec58"
  93.             ]
  94.         ]
  95.     },
  96.     {
  97.         "id": "cf9b9b63.27f8e",
  98.         "type": "comment",
  99.         "z": "127fd315.6c04dd",
  100.         "name": "Item Movement Detection",
  101.         "info": "This block displays a movment detection from openHAB\nwith the states ON/OFF",
  102.         "x": 115,
  103.         "y": 378,
  104.         "wires": []
  105.     },
  106.     {
  107.         "id": "78014ba9.80a13c",
  108.         "type": "comment",
  109.         "z": "127fd315.6c04dd",
  110.         "name": "Logic Gate Info",
  111.         "info": "I used this \"Addon\"\nhttps://flows.nodered.org/node/node-red-contrib-bool-gate",
  112.         "x": 667.5,
  113.         "y": 612,
  114.         "wires": []
  115.     },
  116.     {
  117.         "id": "4a8849d1.f8a308",
  118.         "type": "comment",
  119.         "z": "127fd315.6c04dd",
  120.         "name": "openHAB INFO",
  121.         "info": "so far as I have noticed, openHAB items do not\npublish a topic so we need to \"inject a topic ourself\"\n",
  122.         "x": 666.5,
  123.         "y": 580,
  124.         "wires": []
  125.     },
  126.     {
  127.         "id": "a9865891.288bd",
  128.         "type": "change",
  129.         "z": "127fd315.6c04dd",
  130.         "name": "topic=mov",
  131.         "rules": [
  132.             {
  133.                 "t": "set",
  134.                 "p": "topic",
  135.                 "pt": "msg",
  136.                 "to": "mov",
  137.                 "tot": "str"
  138.             }
  139.         ],
  140.         "action": "",
  141.         "property": "",
  142.         "from": "",
  143.         "to": "",
  144.         "reg": false,
  145.         "x": 555,
  146.         "y": 443,
  147.         "wires": [
  148.             [
  149.                 "e36cea52.be3638",
  150.                 "f21e0fc0.db63e8",
  151.                 "efbc1126.53ca4"
  152.             ]
  153.         ]
  154.     },
  155.     {
  156.         "id": "cbc9801c.5635e8",
  157.         "type": "change",
  158.         "z": "127fd315.6c04dd",
  159.         "name": "topic=door",
  160.         "rules": [
  161.             {
  162.                 "t": "set",
  163.                 "p": "topic",
  164.                 "pt": "msg",
  165.                 "to": "door",
  166.                 "tot": "str"
  167.             }
  168.         ],
  169.         "action": "",
  170.         "property": "",
  171.         "from": "",
  172.         "to": "",
  173.         "reg": false,
  174.         "x": 590,
  175.         "y": 202,
  176.         "wires": [
  177.             [
  178.                 "2cda8f2f.a5bb98",
  179.                 "a5c3cc89.843c78",
  180.                 "f2afec2d.eb6ca"
  181.             ]
  182.         ]
  183.     },
  184.     {
  185.         "id": "4d2ba3b8.29ec84",
  186.         "type": "debug",
  187.         "z": "127fd315.6c04dd",
  188.         "name": "",
  189.         "active": true,
  190.         "console": "false",
  191.         "complete": "false",
  192.         "x": 348.5,
  193.         "y": 97,
  194.         "wires": []
  195.     },
  196.     {
  197.         "id": "72652330.3a11ac",
  198.         "type": "debug",
  199.         "z": "127fd315.6c04dd",
  200.         "name": "",
  201.         "active": true,
  202.         "console": "false",
  203.         "complete": "topic",
  204.         "x": 338,
  205.         "y": 130,
  206.         "wires": []
  207.     },
  208.     {
  209.         "id": "2cda8f2f.a5bb98",
  210.         "type": "debug",
  211.         "z": "127fd315.6c04dd",
  212.         "name": "",
  213.         "active": true,
  214.         "console": "false",
  215.         "complete": "false",
  216.         "x": 850,
  217.         "y": 112,
  218.         "wires": []
  219.     },
  220.     {
  221.         "id": "a5c3cc89.843c78",
  222.         "type": "debug",
  223.         "z": "127fd315.6c04dd",
  224.         "name": "",
  225.         "active": true,
  226.         "console": "false",
  227.         "complete": "topic",
  228.         "x": 839.5,
  229.         "y": 145,
  230.         "wires": []
  231.     },
  232.     {
  233.         "id": "6da9c580.db005c",
  234.         "type": "delay",
  235.         "z": "127fd315.6c04dd",
  236.         "name": "",
  237.         "pauseType": "delay",
  238.         "timeout": "5",
  239.         "timeoutUnits": "seconds",
  240.         "rate": "1",
  241.         "nbRateUnits": "1",
  242.         "rateUnits": "second",
  243.         "randomFirst": "1",
  244.         "randomLast": "5",
  245.         "randomUnits": "seconds",
  246.         "drop": false,
  247.         "x": 401.5,
  248.         "y": 204,
  249.         "wires": [
  250.             [
  251.                 "cbc9801c.5635e8"
  252.             ]
  253.         ]
  254.     },
  255.     {
  256.         "id": "b69b8cef.4fec58",
  257.         "type": "delay",
  258.         "z": "127fd315.6c04dd",
  259.         "name": "",
  260.         "pauseType": "delay",
  261.         "timeout": "5",
  262.         "timeoutUnits": "seconds",
  263.         "rate": "1",
  264.         "nbRateUnits": "1",
  265.         "rateUnits": "second",
  266.         "randomFirst": "1",
  267.         "randomLast": "5",
  268.         "randomUnits": "seconds",
  269.         "drop": false,
  270.         "x": 389,
  271.         "y": 443,
  272.         "wires": [
  273.             [
  274.                 "a9865891.288bd"
  275.             ]
  276.         ]
  277.     },
  278.     {
  279.         "id": "c7d3f01.b3cba1",
  280.         "type": "debug",
  281.         "z": "127fd315.6c04dd",
  282.         "name": "",
  283.         "active": true,
  284.         "console": "false",
  285.         "complete": "false",
  286.         "x": 355,
  287.         "y": 337,
  288.         "wires": []
  289.     },
  290.     {
  291.         "id": "5fd52631.fe9be8",
  292.         "type": "debug",
  293.         "z": "127fd315.6c04dd",
  294.         "name": "",
  295.         "active": true,
  296.         "console": "false",
  297.         "complete": "topic",
  298.         "x": 344.5,
  299.         "y": 370,
  300.         "wires": []
  301.     },
  302.     {
  303.         "id": "f2afec2d.eb6ca",
  304.         "type": "delay",
  305.         "z": "127fd315.6c04dd",
  306.         "name": "",
  307.         "pauseType": "delay",
  308.         "timeout": "5",
  309.         "timeoutUnits": "seconds",
  310.         "rate": "1",
  311.         "nbRateUnits": "1",
  312.         "rateUnits": "second",
  313.         "randomFirst": "1",
  314.         "randomLast": "5",
  315.         "randomUnits": "seconds",
  316.         "drop": false,
  317.         "x": 832,
  318.         "y": 217,
  319.         "wires": [
  320.             [
  321.                 "f431570a.0bd32",
  322.                 "3d7e8aef.ff113e"
  323.             ]
  324.         ]
  325.     },
  326.     {
  327.         "id": "efbc1126.53ca4",
  328.         "type": "delay",
  329.         "z": "127fd315.6c04dd",
  330.         "name": "",
  331.         "pauseType": "delay",
  332.         "timeout": "5",
  333.         "timeoutUnits": "seconds",
  334.         "rate": "1",
  335.         "nbRateUnits": "1",
  336.         "rateUnits": "second",
  337.         "randomFirst": "1",
  338.         "randomLast": "5",
  339.         "randomUnits": "seconds",
  340.         "drop": false,
  341.         "x": 802,
  342.         "y": 449,
  343.         "wires": [
  344.             [
  345.                 "f431570a.0bd32",
  346.                 "3d7e8aef.ff113e"
  347.             ]
  348.         ]
  349.     },
  350.     {
  351.         "id": "f431570a.0bd32",
  352.         "type": "and-gate",
  353.         "z": "127fd315.6c04dd",
  354.         "name": "",
  355.         "rules": [
  356.             {
  357.                 "t": "eq",
  358.                 "v": "OPEN",
  359.                 "vt": "str",
  360.                 "propertyType": "msg",
  361.                 "property": "payload",
  362.                 "topic": "door"
  363.             },
  364.             {
  365.                 "t": "eq",
  366.                 "v": "ON",
  367.                 "vt": "str",
  368.                 "propertyType": "msg",
  369.                 "property": "payload",
  370.                 "topic": "mov"
  371.             }
  372.         ],
  373.         "outputTopic": "resultTopic",
  374.         "gateType": "and",
  375.         "emitOnlyIfTrue": true,
  376.         "x": 1046.5,
  377.         "y": 322,
  378.         "wires": [
  379.             [
  380.                 "80597c64.31837",
  381.                 "be7ce667.592698"
  382.             ]
  383.         ]
  384.     },
  385.     {
  386.         "id": "e36cea52.be3638",
  387.         "type": "debug",
  388.         "z": "127fd315.6c04dd",
  389.         "name": "",
  390.         "active": true,
  391.         "console": "false",
  392.         "complete": "false",
  393.         "x": 724,
  394.         "y": 351,
  395.         "wires": []
  396.     },
  397.     {
  398.         "id": "f21e0fc0.db63e8",
  399.         "type": "debug",
  400.         "z": "127fd315.6c04dd",
  401.         "name": "",
  402.         "active": true,
  403.         "console": "false",
  404.         "complete": "topic",
  405.         "x": 716.5,
  406.         "y": 384,
  407.         "wires": []
  408.     },
  409.     {
  410.         "id": "80597c64.31837",
  411.         "type": "debug",
  412.         "z": "127fd315.6c04dd",
  413.         "name": "",
  414.         "active": true,
  415.         "console": "false",
  416.         "complete": "false",
  417.         "x": 1241,
  418.         "y": 289,
  419.         "wires": []
  420.     },
  421.     {
  422.         "id": "be7ce667.592698",
  423.         "type": "debug",
  424.         "z": "127fd315.6c04dd",
  425.         "name": "",
  426.         "active": true,
  427.         "console": "false",
  428.         "complete": "topic",
  429.         "x": 1231.5,
  430.         "y": 321,
  431.         "wires": []
  432.     },
  433.     {
  434.         "id": "f1219097.361278",
  435.         "type": "comment",
  436.         "z": "127fd315.6c04dd",
  437.         "name": "Information!",
  438.         "info": "This Flow aims to ask for 2 States of 2 Items and\ncheck for both results OPEN/ON to forward to the\nnext stepp.",
  439.         "x": 656,
  440.         "y": 547,
  441.         "wires": []
  442.     },
  443.     {
  444.         "id": "fc18ecd4.206ed",
  445.         "type": "comment",
  446.         "z": "127fd315.6c04dd",
  447.         "name": "inject topic door",
  448.         "info": "",
  449.         "x": 600.5,
  450.         "y": 232,
  451.         "wires": []
  452.     },
  453.     {
  454.         "id": "127ea454.adb43c",
  455.         "type": "comment",
  456.         "z": "127fd315.6c04dd",
  457.         "name": "inject topic mov",
  458.         "info": "",
  459.         "x": 565,
  460.         "y": 475,
  461.         "wires": []
  462.     },
  463.     {
  464.         "id": "3d7e8aef.ff113e",
  465.         "type": "or-gate",
  466.         "z": "127fd315.6c04dd",
  467.         "name": "",
  468.         "rules": [
  469.             {
  470.                 "t": "eq",
  471.                 "v": "OPEN",
  472.                 "vt": "str",
  473.                 "propertyType": "msg",
  474.                 "property": "payload",
  475.                 "topic": "door"
  476.             },
  477.             {
  478.                 "t": "eq",
  479.                 "v": "ON",
  480.                 "vt": "str",
  481.                 "propertyType": "msg",
  482.                 "property": "payload",
  483.                 "topic": "mov"
  484.             }
  485.         ],
  486.         "outputTopic": "",
  487.         "gateType": "or",
  488.         "emitOnlyIfTrue": true,
  489.         "x": 1040.5,
  490.         "y": 441,
  491.         "wires": [
  492.             [
  493.                 "df869ae4.3bf64",
  494.                 "2ac08dd8.fb5fe2"
  495.             ]
  496.         ]
  497.     },
  498.     {
  499.         "id": "c06f6f07.95d598",
  500.         "type": "comment",
  501.         "z": "127fd315.6c04dd",
  502.         "name": "INFO",
  503.         "info": "This gate will only forward if the \"Door\" is OPEN\nand the Movement Detection is \"ON\"\n\n\"True Restriction\" meens only forward the payload\nif the gates is **green** TRUE",
  504.         "x": 1037.5,
  505.         "y": 290,
  506.         "wires": []
  507.     },
  508.     {
  509.         "id": "a0bf7769.6bf8c",
  510.         "type": "comment",
  511.         "z": "127fd315.6c04dd",
  512.         "name": "INFO",
  513.         "info": "This gate will forward if the \"door\" is OPEN **OR**\nthe movment detection is ON\n\n\"True Restriction\" meens only forward the payload\nif the gates is **green** TRUE",
  514.         "x": 1032,
  515.         "y": 409,
  516.         "wires": []
  517.     },
  518.     {
  519.         "id": "df869ae4.3bf64",
  520.         "type": "debug",
  521.         "z": "127fd315.6c04dd",
  522.         "name": "",
  523.         "active": true,
  524.         "console": "false",
  525.         "complete": "false",
  526.         "x": 1218,
  527.         "y": 421,
  528.         "wires": []
  529.     },
  530.     {
  531.         "id": "2ac08dd8.fb5fe2",
  532.         "type": "debug",
  533.         "z": "127fd315.6c04dd",
  534.         "name": "",
  535.         "active": true,
  536.         "console": "false",
  537.         "complete": "topic",
  538.         "x": 1207.5,
  539.         "y": 454,
  540.         "wires": []
  541.     }
  542. ]
Advertisement
Add Comment
Please, Sign In to add comment