This commit is contained in:
Bluepr1nt
2017-03-29 13:14:41 +02:00
parent 1ee1f5f5f8
commit cffab53c2f
+9 -8
View File
@@ -19,15 +19,16 @@ var parseTelegram = function(data, callback){
var str = data;
var entry = JSON.search(data,'1-0:1.8.1');
console.log(entry);
//var entry = JSON.search(data,'1-0:1.8.1');
//console.log(entry);
//TOE1
regx = new RegExp("^([a-z0-9]{*,})$");
if (regx.test(str)){
console.log("Yes binnen");
}else {
console.log("No!!!!")
}
//regx = new RegExp("^([a-z0-9]{*,})$");
// if (regx.test(str)){
// console.log("Yes binnen");
// }else {
// console.log("No!!!!")
//}
regx = /1-0:1\.8\.1\((\d{6}\.\d{3})\*kWh\)/g
found = str.match(regx);
console.log("\n\nPARSING\n");