[ST Edge] LAN Device Monitor

Will this work on iPhones for Wifi presence?

Sorry, it will not. iPhones donā€™t respond to LAN discovery requests via SSDP. You should be able to use Automations for this, thoughā€¦ What are you wanting to do?

Ya, I just tried, didnā€™t work :frowning: Too bad, because this looks great. I want to know if the iPhone is on the Wifi network or not, hence, on the network = home, away from the network = not home. I realize there is GPS, etc. built into ST, but I find Wifi occupancy best and most accurate without having to provision various phones on STā€™s.

1 Like

If you configured your router to keep a static address for your iphone, it wouldnā€™t be too difficult to create a device driver that pings for it periodically. That would give you what youā€™re looking for.

Yes, thatā€™s already set up. Iā€™m for sure not a programmer, but Iā€™d love to have this ability. It might be helpful for others, too, as Iā€™m not aware of something like this as an edge driver.

OK, Iā€™ll do some experimentation and get back to you. Got a few things Iā€™m working on this week, but will try to get to it this weekend.

Awesome. Happy to test it out, too. It will be more than one iPhone with static IPā€™s.

1 Like

Iā€™ll second the desire to setup wifi connection status as a prescence device, though youā€™ve already helped me tremendously. I use tasker and SharpTools for my Android phone prescence, but have to rely on the poor ST location integration (unreliable) for iPhone.

I donā€™t have an Android phone but am wondering if it supports UPnP. If there is a way to enable it in your settings, you might be able to use my LAN device monitor driver to track its online/offline status. Not sure what happens when the phone is asleep thoughā€¦

Android does not natively support UPnP as far as I can tell. However, there are a few apps that do by running it as a media server, like BubbleUPnP, but thatā€™s a bit excessive of a solution probably.

Iā€™m happy / ok with the Android tasker integration for as long as it still works (connect / disconnect wifi triggers tasker to tell sharp tools to tell ST to update prescence).

Ok, it was just a thought. Iā€™m going to have to see if phones will allow any kind of network connection if they are present. Thereā€™s no way to issue ping commands from the hub. I could add it as a function of my bridge server where I can do ping commands, but I know a hub-only solution would be highly preferred.

Just to chime in, I had something like this a long time ago on my network that pinged the phones to test for presence. When I had it set up the iPhones would drop off the network when they were idle.

My android phone would stay connected and it would work. Every time the iPhone sat idle it would drop the network connection and trigger an away event, pick it up and use it and it would be back.

Itā€™s been a while since I was doing that so maybe things have changed.

Just an FYI from my personal experiences.

1 Like

Thanks for sharing your experience. I was worried something like that would be the case. This just may not be possible, unfortunately. Presence sensors on your keychain may be the best way to go.

Do you have any other computers or servers on your network that are always on? If this canā€™t be done strictly from an Edge driver running on a hub, I have a bridge server that allows Edge drivers to ā€˜escapeā€™ some of the restrictions there are in the Edge platform. I could use my bridge server to do regular pings of a mobile device and report status back to the Edge driver. But I know many people donā€™t want the complication of depending on something running outside the hub.

I do - a Raspberry Pi. I donā€™t mind it, it was fairly common for me to use my Raspberry Pi for Smartthings integrations.

OK! Weā€™ll keep that as an option then. I know @netcsk has a server (Blue Iris) as well where heā€™s already running the bridge server.

1 Like

As you know Todd, I have no experience in programing at all but the discussion above about phones appearing on a network had me check my phone version of fing, my android phone appears in fing with all relevant details but non of the standard checks resolve the phone as expected, instead the bonjour service seems to be resolving the data and displaying the info

Would it be feasible to implement the bonjour service in an Edge driver ??

Youā€™re volunteering, so no complaints from me on how it gets done.

Iā€™d have to understand it a bit more, but from my limited knowledge, isnā€™t it a proprietary Apple thing? Would it be available on Android?

I donā€™t know how it works, but seems to be Appleā€™s version of DNS-SD or UPnP? I suppose if mobile phones (both iOS and Andriod) responded to service discovery then this could be another way to check for presence of the phone.

The hub restricts us to IP-layer protocols like TCP and UDP. To get down to the kind of things that ping does, for example, requires access to ICMP messaging, which to my knowledge is not possible in the Edge sandbox. Iā€™ll have to do some research to see what level the Bonjour service is operating at.

Thanks for the idea.

From my limited knowledge Bonjour is everywhere, I have no apple products but Bonjour is used by fing to either gain information or report

As discussed above fing reports no details for a phone port scan, ping, Ip discovery but non the less all phone details are reported inc ip address, mac, name, os, os vers and first seen details

That info must come from somewhere, as a non developer it appears to my amateur eyes it is resolved using or listening to a Bonjour service