Guest User

Untitled

a guest
Sep 17th, 2018
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 14.75 KB | None | 0 0
  1. -- Persistent Data
  2. local multiRefObjects = {
  3.  
  4. } -- multiRefObjects
  5. local obj1 = {
  6. [1] = {
  7. ["rawData"] = {
  8. [1] = "15";
  9. };
  10. ["lastUpdate"] = "2018-09-17 03:17:06";
  11. ["id"] = 18;
  12. ["batteryLevel"] = 255;
  13. ["deviceType"] = "Lighting 2";
  14. ["deviceID"] = "0C849F2";
  15. ["data"] = {
  16. ["levelVal"] = 15;
  17. ["hardwareID"] = 2;
  18. ["hardwareTypeValue"] = 1;
  19. ["protected"] = false;
  20. ["hardwareType"] = "RFXCOM - RFXtrx433 USB 433.92MHz Transceiver";
  21. ["icon"] = "lightbulb";
  22. ["_nValue"] = 0;
  23. ["unit"] = 11;
  24. ["maxDimLevel"] = 15;
  25. ["hardwareName"] = "RFXCOMM";
  26. ["usedByCamera"] = true;
  27. ["_state"] = "Off";
  28. };
  29. ["lastLevel"] = 100;
  30. ["switchType"] = "On/Off";
  31. ["changed"] = false;
  32. ["subType"] = "AC";
  33. ["timedOut"] = true;
  34. ["baseType"] = "device";
  35. ["signalLevel"] = 12;
  36. ["switchTypeValue"] = 0;
  37. ["description"] = "";
  38. ["name"] = "Portail";
  39. };
  40. [2] = {
  41. ["rawData"] = {
  42. [1] = "1545.819";
  43. [2] = "22763004.000";
  44. };
  45. ["lastUpdate"] = "2018-09-17 17:47:50";
  46. ["id"] = 20;
  47. ["batteryLevel"] = 255;
  48. ["deviceType"] = "General";
  49. ["deviceID"] = "00000201";
  50. ["data"] = {
  51. ["hardwareID"] = 3;
  52. ["hardwareTypeValue"] = 21;
  53. ["usage"] = "1545.82 Watt";
  54. ["counterToday"] = "44.742 kWh";
  55. ["hardwareType"] = "OpenZWave USB";
  56. ["whActual"] = 1545.819;
  57. ["whTotal"] = 22763004;
  58. ["protected"] = false;
  59. ["unit"] = 1;
  60. ["icon"] = "current";
  61. ["hardwareName"] = "Zstick5";
  62. ["_nValue"] = 0;
  63. ["_state"] = "1545.819;22763004.000";
  64. };
  65. ["lastLevel"] = 0;
  66. ["switchType"] = "On/Off";
  67. ["changed"] = true;
  68. ["subType"] = "kWh";
  69. ["timedOut"] = false;
  70. ["baseType"] = "device";
  71. ["signalLevel"] = 12;
  72. ["switchTypeValue"] = 0;
  73. ["description"] = "";
  74. ["name"] = "0 Solar kWh";
  75. };
  76. [3] = {
  77. ["rawData"] = {
  78. [1] = "1558.745";
  79. [2] = "15845831.000";
  80. };
  81. ["lastUpdate"] = "2018-09-17 17:47:55";
  82. ["id"] = 39;
  83. ["batteryLevel"] = 255;
  84. ["deviceType"] = "General";
  85. ["deviceID"] = "00000401";
  86. ["data"] = {
  87. ["hardwareID"] = 3;
  88. ["hardwareTypeValue"] = 21;
  89. ["usage"] = "1558.74 Watt";
  90. ["counterToday"] = "11.903 kWh";
  91. ["hardwareType"] = "OpenZWave USB";
  92. ["whActual"] = 1558.745;
  93. ["whTotal"] = 15845831;
  94. ["protected"] = false;
  95. ["unit"] = 1;
  96. ["icon"] = "current";
  97. ["hardwareName"] = "Zstick5";
  98. ["_nValue"] = 0;
  99. ["_state"] = "1558.745;15845831.000";
  100. };
  101. ["lastLevel"] = 0;
  102. ["switchType"] = "On/Off";
  103. ["changed"] = false;
  104. ["subType"] = "kWh";
  105. ["timedOut"] = false;
  106. ["baseType"] = "device";
  107. ["signalLevel"] = 12;
  108. ["switchTypeValue"] = 0;
  109. ["description"] = "";
  110. ["name"] = "0 Home kWh";
  111. };
  112. [4] = {
  113. ["rawData"] = {
  114. [1] = "-596.008";
  115. [2] = "3278969.000";
  116. };
  117. ["lastUpdate"] = "2018-09-17 17:47:18";
  118. ["id"] = 40;
  119. ["batteryLevel"] = 255;
  120. ["deviceType"] = "General";
  121. ["deviceID"] = "00000402";
  122. ["data"] = {
  123. ["hardwareID"] = 3;
  124. ["hardwareTypeValue"] = 21;
  125. ["usage"] = "-596.008 Watt";
  126. ["counterToday"] = "-0.143 kWh";
  127. ["hardwareType"] = "OpenZWave USB";
  128. ["whActual"] = -596.008;
  129. ["whTotal"] = 3278969;
  130. ["protected"] = false;
  131. ["unit"] = 1;
  132. ["icon"] = "current";
  133. ["hardwareName"] = "Zstick5";
  134. ["_nValue"] = 0;
  135. ["_state"] = "-596.008;3278969.000";
  136. };
  137. ["lastLevel"] = 0;
  138. ["switchType"] = "On/Off";
  139. ["changed"] = false;
  140. ["subType"] = "kWh";
  141. ["timedOut"] = false;
  142. ["baseType"] = "device";
  143. ["signalLevel"] = 12;
  144. ["switchTypeValue"] = 0;
  145. ["description"] = "";
  146. ["name"] = "R Home kWh";
  147. };
  148. [5] = {
  149. ["rawData"] = {
  150. [1] = "-476.787";
  151. [2] = "7579970.000";
  152. };
  153. ["lastUpdate"] = "2018-09-17 17:47:17";
  154. ["id"] = 41;
  155. ["batteryLevel"] = 255;
  156. ["deviceType"] = "General";
  157. ["deviceID"] = "00000403";
  158. ["data"] = {
  159. ["hardwareID"] = 3;
  160. ["hardwareTypeValue"] = 21;
  161. ["usage"] = "-476.787 Watt";
  162. ["counterToday"] = "2.144 kWh";
  163. ["hardwareType"] = "OpenZWave USB";
  164. ["whActual"] = -476.787;
  165. ["whTotal"] = 7579970;
  166. ["protected"] = false;
  167. ["unit"] = 1;
  168. ["icon"] = "current";
  169. ["hardwareName"] = "Zstick5";
  170. ["_nValue"] = 0;
  171. ["_state"] = "-476.787;7579970.000";
  172. };
  173. ["lastLevel"] = 0;
  174. ["switchType"] = "On/Off";
  175. ["changed"] = false;
  176. ["subType"] = "kWh";
  177. ["timedOut"] = false;
  178. ["baseType"] = "device";
  179. ["signalLevel"] = 12;
  180. ["switchTypeValue"] = 0;
  181. ["description"] = "";
  182. ["name"] = "S Home kWh";
  183. };
  184. [6] = {
  185. ["rawData"] = {
  186. [1] = "485.122";
  187. [2] = "4986892.000";
  188. };
  189. ["lastUpdate"] = "2018-09-17 17:47:18";
  190. ["id"] = 42;
  191. ["batteryLevel"] = 255;
  192. ["deviceType"] = "General";
  193. ["deviceID"] = "00000404";
  194. ["data"] = {
  195. ["hardwareID"] = 3;
  196. ["hardwareTypeValue"] = 21;
  197. ["usage"] = "485.122 Watt";
  198. ["counterToday"] = "26.212 kWh";
  199. ["hardwareType"] = "OpenZWave USB";
  200. ["whActual"] = 485.122;
  201. ["whTotal"] = 4986892;
  202. ["protected"] = false;
  203. ["unit"] = 1;
  204. ["icon"] = "current";
  205. ["hardwareName"] = "Zstick5";
  206. ["_nValue"] = 0;
  207. ["_state"] = "485.122;4986892.000";
  208. };
  209. ["lastLevel"] = 0;
  210. ["switchType"] = "On/Off";
  211. ["changed"] = false;
  212. ["subType"] = "kWh";
  213. ["timedOut"] = false;
  214. ["baseType"] = "device";
  215. ["signalLevel"] = 12;
  216. ["switchTypeValue"] = 0;
  217. ["description"] = "";
  218. ["name"] = "T Home kWh";
  219. };
  220. [7] = {
  221. ["rawData"] = {
  222. [1] = "15";
  223. };
  224. ["lastUpdate"] = "2018-09-15 18:03:14";
  225. ["id"] = 43;
  226. ["batteryLevel"] = 255;
  227. ["deviceType"] = "Lighting 2";
  228. ["deviceID"] = "10ECF8A";
  229. ["data"] = {
  230. ["levelVal"] = 15;
  231. ["hardwareID"] = 2;
  232. ["hardwareTypeValue"] = 1;
  233. ["protected"] = false;
  234. ["hardwareType"] = "RFXCOM - RFXtrx433 USB 433.92MHz Transceiver";
  235. ["icon"] = "lightbulb";
  236. ["_nValue"] = 0;
  237. ["unit"] = 11;
  238. ["maxDimLevel"] = 15;
  239. ["hardwareName"] = "RFXCOMM";
  240. ["usedByCamera"] = false;
  241. ["_state"] = "Off";
  242. };
  243. ["lastLevel"] = 100;
  244. ["switchType"] = "On/Off";
  245. ["changed"] = false;
  246. ["subType"] = "AC";
  247. ["timedOut"] = true;
  248. ["baseType"] = "device";
  249. ["signalLevel"] = 12;
  250. ["switchTypeValue"] = 0;
  251. ["description"] = "";
  252. ["name"] = "Jardin";
  253. };
  254. [8] = {
  255. ["rawData"] = {
  256. [1] = "99";
  257. };
  258. ["lastUpdate"] = "2018-09-17 03:10:08";
  259. ["id"] = 45;
  260. ["batteryLevel"] = 255;
  261. ["deviceType"] = "Light/Switch";
  262. ["deviceID"] = "0001407D";
  263. ["data"] = {
  264. ["levelVal"] = 99;
  265. ["hardwareID"] = 5;
  266. ["hardwareTypeValue"] = 15;
  267. ["protected"] = false;
  268. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  269. ["icon"] = "lightbulb";
  270. ["_nValue"] = 0;
  271. ["unit"] = 1;
  272. ["maxDimLevel"] = 100;
  273. ["hardwareName"] = "SONOFF";
  274. ["usedByCamera"] = false;
  275. ["_state"] = "Off";
  276. };
  277. ["lastLevel"] = 99;
  278. ["switchType"] = "On/Off";
  279. ["changed"] = false;
  280. ["subType"] = "Switch";
  281. ["timedOut"] = true;
  282. ["baseType"] = "device";
  283. ["signalLevel"] = 12;
  284. ["switchTypeValue"] = 0;
  285. ["description"] = "";
  286. ["name"] = "GB01";
  287. };
  288. [9] = {
  289. ["rawData"] = {
  290. [1] = "99";
  291. };
  292. ["lastUpdate"] = "2018-09-17 03:10:08";
  293. ["id"] = 46;
  294. ["batteryLevel"] = 255;
  295. ["deviceType"] = "Light/Switch";
  296. ["deviceID"] = "0001407E";
  297. ["data"] = {
  298. ["levelVal"] = 99;
  299. ["hardwareID"] = 5;
  300. ["hardwareTypeValue"] = 15;
  301. ["protected"] = false;
  302. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  303. ["icon"] = "lightbulb";
  304. ["_nValue"] = 0;
  305. ["unit"] = 1;
  306. ["maxDimLevel"] = 100;
  307. ["hardwareName"] = "SONOFF";
  308. ["usedByCamera"] = false;
  309. ["_state"] = "Off";
  310. };
  311. ["lastLevel"] = 99;
  312. ["switchType"] = "On/Off";
  313. ["changed"] = false;
  314. ["subType"] = "Switch";
  315. ["timedOut"] = true;
  316. ["baseType"] = "device";
  317. ["signalLevel"] = 12;
  318. ["switchTypeValue"] = 0;
  319. ["description"] = "";
  320. ["name"] = "GB02";
  321. };
  322. [10] = {
  323. ["rawData"] = {
  324. [1] = "99";
  325. };
  326. ["lastUpdate"] = "2018-09-17 03:10:08";
  327. ["id"] = 47;
  328. ["batteryLevel"] = 255;
  329. ["deviceType"] = "Light/Switch";
  330. ["deviceID"] = "0001407F";
  331. ["data"] = {
  332. ["levelVal"] = 99;
  333. ["hardwareID"] = 5;
  334. ["hardwareTypeValue"] = 15;
  335. ["protected"] = false;
  336. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  337. ["icon"] = "lightbulb";
  338. ["_nValue"] = 0;
  339. ["unit"] = 1;
  340. ["maxDimLevel"] = 100;
  341. ["hardwareName"] = "SONOFF";
  342. ["usedByCamera"] = false;
  343. ["_state"] = "Off";
  344. };
  345. ["lastLevel"] = 99;
  346. ["switchType"] = "On/Off";
  347. ["changed"] = false;
  348. ["subType"] = "Switch";
  349. ["timedOut"] = true;
  350. ["baseType"] = "device";
  351. ["signalLevel"] = 12;
  352. ["switchTypeValue"] = 0;
  353. ["description"] = "";
  354. ["name"] = "GB03";
  355. };
  356. [11] = {
  357. ["rawData"] = {
  358. [1] = "0";
  359. };
  360. ["lastUpdate"] = "2017-10-22 13:41:05";
  361. ["id"] = 48;
  362. ["batteryLevel"] = 255;
  363. ["deviceType"] = "Light/Switch";
  364. ["deviceID"] = "00014080";
  365. ["data"] = {
  366. ["levelVal"] = 0;
  367. ["hardwareID"] = 5;
  368. ["hardwareTypeValue"] = 15;
  369. ["protected"] = false;
  370. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  371. ["icon"] = "lightbulb";
  372. ["_nValue"] = 0;
  373. ["unit"] = 1;
  374. ["maxDimLevel"] = 100;
  375. ["hardwareName"] = "SONOFF";
  376. ["usedByCamera"] = false;
  377. ["_state"] = "Off";
  378. };
  379. ["lastLevel"] = 0;
  380. ["switchType"] = "On/Off";
  381. ["changed"] = false;
  382. ["subType"] = "Switch";
  383. ["timedOut"] = true;
  384. ["baseType"] = "device";
  385. ["signalLevel"] = 12;
  386. ["switchTypeValue"] = 0;
  387. ["description"] = "";
  388. ["name"] = "GB04";
  389. };
  390. [12] = {
  391. ["rawData"] = {
  392. [1] = "100";
  393. };
  394. ["lastUpdate"] = "2017-10-22 13:26:53";
  395. ["id"] = 49;
  396. ["batteryLevel"] = 255;
  397. ["deviceType"] = "Light/Switch";
  398. ["deviceID"] = "00014081";
  399. ["data"] = {
  400. ["levelVal"] = 100;
  401. ["hardwareID"] = 5;
  402. ["hardwareTypeValue"] = 15;
  403. ["protected"] = false;
  404. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  405. ["icon"] = "lightbulb";
  406. ["_nValue"] = 0;
  407. ["unit"] = 1;
  408. ["maxDimLevel"] = 100;
  409. ["hardwareName"] = "SONOFF";
  410. ["usedByCamera"] = false;
  411. ["_state"] = "Off";
  412. };
  413. ["lastLevel"] = 0;
  414. ["switchType"] = "On/Off";
  415. ["changed"] = false;
  416. ["subType"] = "Switch";
  417. ["timedOut"] = true;
  418. ["baseType"] = "device";
  419. ["signalLevel"] = 12;
  420. ["switchTypeValue"] = 0;
  421. ["description"] = "";
  422. ["name"] = "GB05";
  423. };
  424. [13] = {
  425. ["rawData"] = {
  426. [1] = "0.0";
  427. };
  428. ["lastUpdate"] = "2017-11-19 13:07:30";
  429. ["id"] = 51;
  430. ["batteryLevel"] = 255;
  431. ["deviceType"] = "General";
  432. ["deviceID"] = "00082051";
  433. ["data"] = {
  434. ["hardwareID"] = 7;
  435. ["hardwareTypeValue"] = 15;
  436. ["protected"] = false;
  437. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  438. ["icon"] = "hardware";
  439. ["_nValue"] = 0;
  440. ["hardwareName"] = "Water";
  441. ["unit"] = 1;
  442. ["_state"] = "0.0";
  443. };
  444. ["lastLevel"] = 0;
  445. ["switchType"] = "On/Off";
  446. ["changed"] = false;
  447. ["subType"] = "Percentage";
  448. ["timedOut"] = true;
  449. ["baseType"] = "device";
  450. ["signalLevel"] = 12;
  451. ["switchTypeValue"] = 0;
  452. ["description"] = "";
  453. ["name"] = "Tank Level%";
  454. };
  455. [14] = {
  456. ["rawData"] = {
  457. [1] = "100";
  458. };
  459. ["lastUpdate"] = "2017-11-19 13:07:52";
  460. ["id"] = 52;
  461. ["batteryLevel"] = 255;
  462. ["deviceType"] = "Light/Switch";
  463. ["deviceID"] = "00014084";
  464. ["data"] = {
  465. ["levelVal"] = 100;
  466. ["hardwareID"] = 7;
  467. ["hardwareTypeValue"] = 15;
  468. ["protected"] = false;
  469. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  470. ["icon"] = "lightbulb";
  471. ["_nValue"] = 0;
  472. ["unit"] = 1;
  473. ["maxDimLevel"] = 100;
  474. ["hardwareName"] = "Water";
  475. ["usedByCamera"] = false;
  476. ["_state"] = "Off";
  477. };
  478. ["lastLevel"] = 0;
  479. ["switchType"] = "On/Off";
  480. ["changed"] = false;
  481. ["subType"] = "Switch";
  482. ["timedOut"] = true;
  483. ["baseType"] = "device";
  484. ["signalLevel"] = 12;
  485. ["switchTypeValue"] = 0;
  486. ["description"] = "";
  487. ["name"] = "Well Pump";
  488. };
  489. [15] = {
  490. ["rawData"] = {
  491. [1] = "0";
  492. };
  493. ["lastUpdate"] = "2017-11-23 12:50:39";
  494. ["id"] = 53;
  495. ["batteryLevel"] = 255;
  496. ["deviceType"] = "Light/Switch";
  497. ["deviceID"] = "00014085";
  498. ["data"] = {
  499. ["levelVal"] = 0;
  500. ["hardwareID"] = 7;
  501. ["hardwareTypeValue"] = 15;
  502. ["protected"] = false;
  503. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  504. ["icon"] = "lightbulb";
  505. ["_nValue"] = 0;
  506. ["unit"] = 1;
  507. ["maxDimLevel"] = 100;
  508. ["hardwareName"] = "Water";
  509. ["usedByCamera"] = false;
  510. ["_state"] = "Off";
  511. };
  512. ["lastLevel"] = 0;
  513. ["switchType"] = "On/Off";
  514. ["changed"] = false;
  515. ["subType"] = "Switch";
  516. ["timedOut"] = true;
  517. ["baseType"] = "device";
  518. ["signalLevel"] = 12;
  519. ["switchTypeValue"] = 0;
  520. ["description"] = "";
  521. ["name"] = "House Pump";
  522. };
  523. [16] = {
  524. ["rawData"] = {
  525. [1] = "100";
  526. };
  527. ["lastUpdate"] = "2017-11-19 13:08:55";
  528. ["id"] = 54;
  529. ["batteryLevel"] = 255;
  530. ["deviceType"] = "Light/Switch";
  531. ["deviceID"] = "00014086";
  532. ["data"] = {
  533. ["levelVal"] = 100;
  534. ["hardwareID"] = 7;
  535. ["hardwareTypeValue"] = 15;
  536. ["protected"] = false;
  537. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  538. ["icon"] = "lightbulb";
  539. ["_nValue"] = 0;
  540. ["unit"] = 1;
  541. ["maxDimLevel"] = 100;
  542. ["hardwareName"] = "Water";
  543. ["usedByCamera"] = false;
  544. ["_state"] = "Off";
  545. };
  546. ["lastLevel"] = 0;
  547. ["switchType"] = "On/Off";
  548. ["changed"] = false;
  549. ["subType"] = "Switch";
  550. ["timedOut"] = true;
  551. ["baseType"] = "device";
  552. ["signalLevel"] = 12;
  553. ["switchTypeValue"] = 0;
  554. ["description"] = "";
  555. ["name"] = "Garden Pump";
  556. };
  557. [17] = {
  558. ["rawData"] = {
  559. [1] = "0";
  560. [2] = "-335369";
  561. };
  562. ["lastUpdate"] = "2018-09-17 12:10:19";
  563. ["id"] = 55;
  564. ["batteryLevel"] = 255;
  565. ["deviceType"] = "General";
  566. ["deviceID"] = "00082055";
  567. ["data"] = {
  568. ["hardwareID"] = 4;
  569. ["hardwareTypeValue"] = 15;
  570. ["usage"] = "0 Watt";
  571. ["counterToday"] = "0 kWh";
  572. ["hardwareType"] = "Dummy (Does nothing, use for virtual switches only)";
  573. ["whActual"] = 0;
  574. ["whTotal"] = -335369;
  575. ["protected"] = false;
  576. ["unit"] = 1;
  577. ["icon"] = "current";
  578. ["hardwareName"] = "EDP";
  579. ["_nValue"] = 0;
  580. ["_state"] = "0;-335369";
  581. };
  582. ["lastLevel"] = 0;
  583. ["switchType"] = "On/Off";
  584. ["changed"] = false;
  585. ["subType"] = "kWh";
  586. ["timedOut"] = true;
  587. ["baseType"] = "device";
  588. ["signalLevel"] = 12;
  589. ["switchTypeValue"] = 0;
  590. ["description"] = "";
  591. ["name"] = "Compteur_Elec";
  592. };
  593. [18] = {
  594. ["description"] = "";
  595. ["data"] = {
  596. ["_state"] = "Off";
  597. };
  598. ["deviceIDs"] = {
  599. [1] = 45;
  600. [2] = 47;
  601. [3] = 46;
  602. };
  603. ["id"] = 2;
  604. ["baseType"] = "group";
  605. ["lastUpdate"] = "2018-09-17 03:10:08";
  606. ["changed"] = false;
  607. ["name"] = "Lampes Jardin";
  608. };
  609. }
  610. return obj1
Advertisement
Add Comment
Please, Sign In to add comment