Hello,
I am currently setting up a lot of things on the node-red side. I wanted to add Wi-Fi detection via the smartphone. Has anyone already managed to set this up? The limitations are probably from Docker in my opinion. Any ideas?
(I tried with a Wi-Fi detection tool on node red but it tells me no scanning utility found)
The Node-RED plugin must certainly have prerequisites with programs to install on the system.
Otherwise, the limitation is that recent iOS and Android devices regularly change their MAC address to avoid being too tracked.
You may therefore not easily identify your phone unless you explicitly ask it not to change its MAC address.
Yes, I was wondering if anyone had these limitations, I’m going to dig into the code to see what it uses
Not sure about the Wi-Fi side, you need to be able to identify MAC addresses to be able to block (security in particular). So I think it doesn’t change.
Hello,
On my installation, I detect the presence of users exclusively via Wi-Fi with a ping in Node-RED that returns to Gladys via MQTT when the ping has worked (palette: node-red-node-ping).
It works great.
Available for more details.
That’s clever! Especially if you block the IPs statically
Thanks, I’ll put that in place 
However, I would like some information, how do you associate a user with a presence sensor in Gladys?
I have the impression that it doesn’t work as I wish, perhaps I am mistaken, but my MQTT sensor receives 0 = not present and 1 = present.
It tells me that it saw it a few seconds ago, but the user is no longer there. Is it me or is there a problem with the functioning of this feature?
In my opinion, your scene is: « If presence = 1, the user is there », but since the sensor returns 0 after a few seconds (or its state is reset to 0 by Gladys, it’s the same), it quickly marks you as absent.
This is always a difficulty in relying solely on motion sensors to define a user’s presence. Gladys does not yet make this easy, in my opinion.
Here’s how I see things:
- A scene that marks a person as present in case of movement from a sensor
- A scene that marks a person as absent in case of no movement for 10 minutes
Where it gets stuck is scene 2, which will never wait 10 minutes after detecting movement to mark you as absent. It will just run every 10 minutes, movement or not. So your presence detection will be terrible.
I had this idea at the beginning, then I switched to an app that sends a signal to Gladys via Wi-Fi using MQTT. That way, when I’m on Wi-Fi, I’m detected, when I leave, I’m marked as absent.
Well, in that case I go through Node Red and it manages it like this:
- I find the phone => presence
- no phone => no presence
So in both cases it’s a real information.
But what I can’t do in Gladys is define a capture? or a state that says yes the user « Thibaut » is indeed present. And therefore that I send the info to node red?
Actually, the « presence » feature doesn’t work for my case (maybe in other cases I don’t know).
For me, presence is yes or no, here it’s seen there is X time
Yes, you create a « virtual » sensor in the MQTT integration, and then you create 2 scenes that will bridge this sensor and the native presence management:
IF sensor = 1 THEN user damalgos seen at home
IF sensor = 0 THEN user damalgos has left the house
You should see this virtual sensor as a kind of variable where you store a state.
Ahhhhh thank you! Great, I hadn’t understood this particular case of setting the scene. Super thank you, that’s great
I hadn’t understood the context, indeed it’s simpler like this in Gladys!