Advertisement
fkainka

[K3_P8 - MQTT Touch]

Mar 20th, 2019
122
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. [
  2. {
  3. "id": "60b6526a.80f66c",
  4. "type": "tab",
  5. "label": "[K3_P8 - MQTT Touch]",
  6. "disabled": false,
  7. "info": ""
  8. },
  9. {
  10. "id": "30fb997c.b96976",
  11. "type": "mqtt in",
  12. "z": "60b6526a.80f66c",
  13. "name": "",
  14. "topic": "NodeESP/[PID]/touch/state/get/out",
  15. "qos": "2",
  16. "broker": "3c53c9b8.8965a6",
  17. "x": 200,
  18. "y": 80,
  19. "wires": [
  20. [
  21. "d51e50e8.e0eff"
  22. ]
  23. ]
  24. },
  25. {
  26. "id": "d51e50e8.e0eff",
  27. "type": "json",
  28. "z": "60b6526a.80f66c",
  29. "name": "",
  30. "property": "payload",
  31. "action": "",
  32. "pretty": false,
  33. "x": 170,
  34. "y": 180,
  35. "wires": [
  36. [
  37. "fe92302e.84913"
  38. ]
  39. ]
  40. },
  41. {
  42. "id": "fe92302e.84913",
  43. "type": "switch",
  44. "z": "60b6526a.80f66c",
  45. "name": "",
  46. "property": "payload.pin_name",
  47. "propertyType": "msg",
  48. "rules": [
  49. {
  50. "t": "eq",
  51. "v": "Touch1",
  52. "vt": "str"
  53. },
  54. {
  55. "t": "eq",
  56. "v": "Touch2",
  57. "vt": "str"
  58. },
  59. {
  60. "t": "eq",
  61. "v": "Touch3",
  62. "vt": "str"
  63. },
  64. {
  65. "t": "eq",
  66. "v": "Touch4",
  67. "vt": "str"
  68. }
  69. ],
  70. "checkall": "true",
  71. "repair": false,
  72. "outputs": 4,
  73. "x": 310,
  74. "y": 180,
  75. "wires": [
  76. [
  77. "aafb8754.328158"
  78. ],
  79. [
  80. "28572b77.e37014"
  81. ],
  82. [
  83. "6ddbf81b.410828"
  84. ],
  85. [
  86. "8bc1a376.ea252"
  87. ]
  88. ]
  89. },
  90. {
  91. "id": "43faa32f.f7d4ec",
  92. "type": "ui_audio",
  93. "z": "60b6526a.80f66c",
  94. "name": "",
  95. "group": "158410c0.95e66f",
  96. "voice": "de-DE",
  97. "always": "",
  98. "x": 1200,
  99. "y": 180,
  100. "wires": []
  101. },
  102. {
  103. "id": "6a91c1ed.bbe56",
  104. "type": "feedparse",
  105. "z": "60b6526a.80f66c",
  106. "name": "https://iot.fkainka.de/feed",
  107. "url": "https://iot.fkainka.de/category/nodeesp/calendar-2018/feed",
  108. "interval": 15,
  109. "x": 230,
  110. "y": 400,
  111. "wires": [
  112. [
  113. "c127130a.0804"
  114. ]
  115. ]
  116. },
  117. {
  118. "id": "414e9135.653f6",
  119. "type": "feedparse",
  120. "z": "60b6526a.80f66c",
  121. "name": "",
  122. "url": "http://iot.fkainka.de/feed",
  123. "interval": 15,
  124. "x": 780,
  125. "y": 1360,
  126. "wires": [
  127. []
  128. ]
  129. },
  130. {
  131. "id": "c127130a.0804",
  132. "type": "delay",
  133. "z": "60b6526a.80f66c",
  134. "name": "",
  135. "pauseType": "rate",
  136. "timeout": "5",
  137. "timeoutUnits": "seconds",
  138. "rate": "100",
  139. "nbRateUnits": "1",
  140. "rateUnits": "second",
  141. "randomFirst": "1",
  142. "randomLast": "5",
  143. "randomUnits": "seconds",
  144. "drop": false,
  145. "x": 480,
  146. "y": 400,
  147. "wires": [
  148. [
  149. "861e15d3.44e1c8"
  150. ]
  151. ]
  152. },
  153. {
  154. "id": "a5bf77b4.b80d88",
  155. "type": "split",
  156. "z": "60b6526a.80f66c",
  157. "name": "",
  158. "splt": "\\n",
  159. "spltType": "str",
  160. "arraySplt": 1,
  161. "arraySpltType": "len",
  162. "stream": false,
  163. "addname": "",
  164. "x": 490,
  165. "y": 1360,
  166. "wires": [
  167. []
  168. ]
  169. },
  170. {
  171. "id": "39fc0b37.1c3a74",
  172. "type": "batch",
  173. "z": "60b6526a.80f66c",
  174. "name": "",
  175. "mode": "count",
  176. "count": 10,
  177. "overlap": 0,
  178. "interval": 10,
  179. "allowEmptySequence": false,
  180. "topics": [
  181. {
  182. "topic": ""
  183. }
  184. ],
  185. "x": 230,
  186. "y": 1340,
  187. "wires": [
  188. []
  189. ]
  190. },
  191. {
  192. "id": "861e15d3.44e1c8",
  193. "type": "function",
  194. "z": "60b6526a.80f66c",
  195. "name": "Textbuffer: Last Article",
  196. "func": "global.set('RSS', msg.payload);\nreturn msg;",
  197. "outputs": 1,
  198. "noerr": 0,
  199. "x": 700,
  200. "y": 400,
  201. "wires": [
  202. []
  203. ]
  204. },
  205. {
  206. "id": "bbb14dd7.82553",
  207. "type": "http request",
  208. "z": "60b6526a.80f66c",
  209. "name": "Sorry Dave",
  210. "method": "GET",
  211. "ret": "bin",
  212. "url": "http://www.wavsource.com/snds_2018-06-03_5106726768923853/movies/2001/sorry_dave.wav",
  213. "tls": "",
  214. "x": 470,
  215. "y": 360,
  216. "wires": [
  217. [
  218. "86855aad.e44708"
  219. ]
  220. ]
  221. },
  222. {
  223. "id": "86855aad.e44708",
  224. "type": "function",
  225. "z": "60b6526a.80f66c",
  226. "name": "Audiobuffer: DAVE",
  227. "func": "global.set('DAVE', msg.payload);\nreturn msg;",
  228. "outputs": 1,
  229. "noerr": 0,
  230. "x": 690,
  231. "y": 360,
  232. "wires": [
  233. []
  234. ]
  235. },
  236. {
  237. "id": "92e8281c.49b1e8",
  238. "type": "http request",
  239. "z": "60b6526a.80f66c",
  240. "name": "Dog",
  241. "method": "GET",
  242. "ret": "bin",
  243. "url": "http://soundbible.com/grab.php?id=2215&type=mp3",
  244. "tls": "",
  245. "x": 450,
  246. "y": 320,
  247. "wires": [
  248. [
  249. "ca747150.7556a"
  250. ]
  251. ]
  252. },
  253. {
  254. "id": "9a024b1d.78cbc8",
  255. "type": "inject",
  256. "z": "60b6526a.80f66c",
  257. "name": "Execute on Start",
  258. "topic": "",
  259. "payload": "true",
  260. "payloadType": "bool",
  261. "repeat": "",
  262. "crontab": "",
  263. "once": true,
  264. "onceDelay": 0.1,
  265. "x": 230,
  266. "y": 340,
  267. "wires": [
  268. [
  269. "92e8281c.49b1e8",
  270. "bbb14dd7.82553"
  271. ]
  272. ]
  273. },
  274. {
  275. "id": "ca747150.7556a",
  276. "type": "function",
  277. "z": "60b6526a.80f66c",
  278. "name": "Audiobuffer: DOG",
  279. "func": "global.set('DOG', msg.payload);\nreturn msg;",
  280. "outputs": 1,
  281. "noerr": 0,
  282. "x": 690,
  283. "y": 320,
  284. "wires": [
  285. []
  286. ]
  287. },
  288. {
  289. "id": "aafb8754.328158",
  290. "type": "ui_button",
  291. "z": "60b6526a.80f66c",
  292. "name": "",
  293. "group": "158410c0.95e66f",
  294. "order": 0,
  295. "width": 0,
  296. "height": 0,
  297. "passthru": true,
  298. "label": "Time",
  299. "color": "",
  300. "bgcolor": "",
  301. "icon": "",
  302. "payload": "",
  303. "payloadType": "str",
  304. "topic": "",
  305. "x": 470,
  306. "y": 100,
  307. "wires": [
  308. [
  309. "ebdcf839.ce1818"
  310. ]
  311. ]
  312. },
  313. {
  314. "id": "28572b77.e37014",
  315. "type": "ui_button",
  316. "z": "60b6526a.80f66c",
  317. "name": "",
  318. "group": "158410c0.95e66f",
  319. "order": 0,
  320. "width": 0,
  321. "height": 0,
  322. "passthru": true,
  323. "label": "Dog",
  324. "color": "",
  325. "bgcolor": "",
  326. "icon": "",
  327. "payload": "",
  328. "payloadType": "str",
  329. "topic": "",
  330. "x": 470,
  331. "y": 140,
  332. "wires": [
  333. [
  334. "d4eb779f.d12b98"
  335. ]
  336. ]
  337. },
  338. {
  339. "id": "6ddbf81b.410828",
  340. "type": "ui_button",
  341. "z": "60b6526a.80f66c",
  342. "name": "",
  343. "group": "158410c0.95e66f",
  344. "order": 0,
  345. "width": 0,
  346. "height": 0,
  347. "passthru": true,
  348. "label": "Dave",
  349. "color": "",
  350. "bgcolor": "",
  351. "icon": "",
  352. "payload": "",
  353. "payloadType": "str",
  354. "topic": "",
  355. "x": 470,
  356. "y": 180,
  357. "wires": [
  358. [
  359. "727baf1a.ea1e3"
  360. ]
  361. ]
  362. },
  363. {
  364. "id": "8bc1a376.ea252",
  365. "type": "ui_button",
  366. "z": "60b6526a.80f66c",
  367. "name": "",
  368. "group": "158410c0.95e66f",
  369. "order": 0,
  370. "width": 0,
  371. "height": 0,
  372. "passthru": true,
  373. "label": "Last Article",
  374. "color": "",
  375. "bgcolor": "",
  376. "icon": "",
  377. "payload": "",
  378. "payloadType": "str",
  379. "topic": "",
  380. "x": 490,
  381. "y": 220,
  382. "wires": [
  383. [
  384. "ed7aa19c.8169f"
  385. ]
  386. ]
  387. },
  388. {
  389. "id": "ebdcf839.ce1818",
  390. "type": "function",
  391. "z": "60b6526a.80f66c",
  392. "name": "Time to Speechtext",
  393. "func": "var date = new Date();\nvar months = [\"Januar\", \"Februar\", \"März\", \"April\", \"Mai\", \"Juni\", \"July\", \"August\", \"September\", \"Oktober\", \"November\", \"Dezember\"];\nmsg.payload = \"Wir haben \" + date.getHours()+\"Uhr \"+date.getMinutes()+\" am \"+date.getDate()+\". \"+ months[date.getMonth()] +\" \" +date.getFullYear();\nreturn msg;",
  394. "outputs": 1,
  395. "noerr": 0,
  396. "x": 690,
  397. "y": 100,
  398. "wires": [
  399. [
  400. "f257e0a2.a104"
  401. ]
  402. ]
  403. },
  404. {
  405. "id": "d4eb779f.d12b98",
  406. "type": "function",
  407. "z": "60b6526a.80f66c",
  408. "name": "Audiobuffer: DOG",
  409. "func": "msg.payload = global.get('DOG');\nreturn msg;",
  410. "outputs": 1,
  411. "noerr": 0,
  412. "x": 690,
  413. "y": 140,
  414. "wires": [
  415. [
  416. "f257e0a2.a104"
  417. ]
  418. ]
  419. },
  420. {
  421. "id": "727baf1a.ea1e3",
  422. "type": "function",
  423. "z": "60b6526a.80f66c",
  424. "name": "Audiobuffer: DAVE",
  425. "func": "msg.payload = global.get('DAVE');\nreturn msg;",
  426. "outputs": 1,
  427. "noerr": 0,
  428. "x": 690,
  429. "y": 180,
  430. "wires": [
  431. [
  432. "f257e0a2.a104"
  433. ]
  434. ]
  435. },
  436. {
  437. "id": "ed7aa19c.8169f",
  438. "type": "function",
  439. "z": "60b6526a.80f66c",
  440. "name": "Textbuffer: Last Article",
  441. "func": "msg.payload = global.get('RSS');\nreturn msg;",
  442. "outputs": 1,
  443. "noerr": 0,
  444. "x": 700,
  445. "y": 220,
  446. "wires": [
  447. [
  448. "f257e0a2.a104"
  449. ]
  450. ]
  451. },
  452. {
  453. "id": "f257e0a2.a104",
  454. "type": "delay",
  455. "z": "60b6526a.80f66c",
  456. "name": "",
  457. "pauseType": "rate",
  458. "timeout": "5",
  459. "timeoutUnits": "seconds",
  460. "rate": "1",
  461. "nbRateUnits": "5",
  462. "rateUnits": "second",
  463. "randomFirst": "1",
  464. "randomLast": "5",
  465. "randomUnits": "seconds",
  466. "drop": true,
  467. "x": 1020,
  468. "y": 180,
  469. "wires": [
  470. [
  471. "43faa32f.f7d4ec",
  472. "4baa8572.01e80c"
  473. ]
  474. ]
  475. },
  476. {
  477. "id": "4baa8572.01e80c",
  478. "type": "ui_toast",
  479. "z": "60b6526a.80f66c",
  480. "position": "top right",
  481. "displayTime": "3",
  482. "highlight": "",
  483. "outputs": 0,
  484. "ok": "OK",
  485. "cancel": "",
  486. "topic": "",
  487. "name": "",
  488. "x": 1230,
  489. "y": 120,
  490. "wires": []
  491. },
  492. {
  493. "id": "3c53c9b8.8965a6",
  494. "type": "mqtt-broker",
  495. "z": "",
  496. "name": "fkainka.de",
  497. "broker": "broker.fkainka.de",
  498. "port": "1883",
  499. "clientid": "",
  500. "usetls": false,
  501. "compatmode": true,
  502. "keepalive": "60",
  503. "cleansession": true,
  504. "willTopic": "",
  505. "willQos": "0",
  506. "willPayload": "",
  507. "birthTopic": "",
  508. "birthQos": "0",
  509. "birthPayload": ""
  510. },
  511. {
  512. "id": "158410c0.95e66f",
  513. "type": "ui_group",
  514. "z": "",
  515. "name": "Touch Buttons",
  516. "tab": "33c29247.efde4e",
  517. "order": 1,
  518. "disp": true,
  519. "width": "6",
  520. "collapse": false
  521. },
  522. {
  523. "id": "33c29247.efde4e",
  524. "type": "ui_tab",
  525. "z": "",
  526. "name": "[K3_P8]",
  527. "icon": "dashboard",
  528. "order": 8
  529. }
  530. ]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement