joelwetzel / hubitat-iphone-presence-sensor Goto Github PK
View Code? Open in Web Editor NEWA virtual presence sensor for Hubitat that checks if an iPhone/Android is on the WiFi network.
License: Apache License 2.0
A virtual presence sensor for Hubitat that checks if an iPhone/Android is on the WiFi network.
License: Apache License 2.0
Hi Joel,
Thank you for this useful tool.
One suggestion, add: , importUrl: "https://raw.githubusercontent.com/joelwetzel/Hubitat-iPhone-Presence-Sensor/master/iphoneWiFiPresenceSensor.groovy"
into the definition name, so when clicking import, it will auto-fill the url for a quick update.
Love the driver, thanks. I was updating it but I realized I can't really tell afterwards if i did or not since you don't have a version history in the source. Please add it. While you're at it, update the copyright to say 2019-2020. That's what I was looking for in absence of a version changelist.
I'm in the process of updating my home network and was using this tool to detect presence of my mobile phone. Everything was working fine until I moved the Hubitat and other IoT devices to their own subnet. I thought this sensor would continue to work but alas, it does not. Traffic is blocked between my IoT VLAN and my secure VLAN. I created a firewall rule to allow Ping (ICMP) from the IoT VLAN to the secure VLAN and confirmed it working.
It looks like this sensor uses and HTTP call to determine presence. Have you thought about including a method to detect presence using Ping (ICMP)?
Really appreciate this app. Thank.s
One issue is when using it for a phone that is assigned a dynamic IP address. To resolve the possibility that a phone's IP address may change, could you consider adding an option that either (1) allows a user to configure using the MAC address of the phone instead which doesn't change, and (2) possibly using the phone's IP address for the "First" connection, and then having the code determine the MAC address from the first connection to the phone at that IP address and store the MAC address for future use.
Thanks for considering this.
Seems like every few minutes the phone is being marked as present, then not present.
Phone is ping'able
Not sure why it keeps showing as not-present?
Thanks for this iPhone-Presence-Sensor it has worked well for me.
Then I got thinking, I think it can have more uses.
I have an issue with some devices that they do not remember state after a power outage & restore. And I found quite a bit of discussion and suggestions around being aware of a power outage and then restoring the previous state. My location has frequent power outages so I have a ups on the Hubitat Hub and a backup generator for much of the house, so it is only some of the individual bulbs etc that have a porblem with power outage. Actually there are multiple issues as some bulbs are not on the generator, and if they are it is 30 seconds of outage before the generator backup power, and there is an extremely short break or surge when the generator switch goes back to mains power. So if the iPhone-Presense-Sensor can ping any device with an ip, and if the device fails ping and then returns, then power must have been out then restored. So if the state of the device was saved previously I assume it would not be hard with RM to recognize and replace the previous state. I am very new to this Hubitat stuff and do not understand much. But I tried to install iPhone-Presence-Sensor driver twice, even changing the name the second time, and could not get it to work set to a non phone ip device. Now I am thinking; is it using variables or something that need to be unique for each instance? Or what other reason, (besides I could easily have done something wrong), is there that it didnt work. Is there something unique about pinging a phone or can it check any device type with an ip? So far I had only tested with my phone (and it is great), but I am going to wish to add my wifes phone etc soon, so if there is something special I need to do to deal wih multiple devices I need to figure that out anyway. But I do think ability to test multiple an other types of devices could be very usefull. Maybe even Zwave and Zigbee devices if it could be that flexible.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.