Hey guys,
i'm fairly new to node-red and currently trying to make a flow that detects if a person comes home and then doing something once (open door, turn lights on or something else) but i can't figure out how i make the msg a one time message.
for scanning i use the noble ( Scan BLE) node and then a function block which contains
var msg1 = {};
if(msg.payload.peripheralUuid == "UUID HERE OF DEVICE") {
msg1.payload = 50;
return msg1;
}
else {
msg1.payload = 25;
return msg1;
}
but now i cant figure out how i only get one message when the scanble is finding the device when it previously didnt find it.
i tried to use the rbe node for the payload to check if it changes but i dont rly understand how the node is working internally.
greetings