[RELEASE] iPhone WiFi Presence Sensor



I had this so there is 2 options.
A. change it to group 2 so they both have to leave to trigger but only one has to arrive (this works great for me as it was the arrival that was my issue)
B. Turn on a delay for leaving also in his app. This would stop the in outs asking as it only disappears for a while (again this is like mine, but I'm Andoid)

Edit if you do go with A delete the old child app and start again on each presence device. Then make sure you toggle all the inputs so the app knows the state of the devices. Since I have done this @Cobra presence central app has not dropped a beat.


Unfortunately I'm out of ideas without having direct access to your hub. If you can send more screenshots, I may see something in there, but we should probably take that to DMs. Hopefully we can work it out.


@aaron I do think the key here is that you say BOTH apps are misbehaving. That points to more of a configuration problem, either in how the virtual devices are configured, the apps are configured, or the output automations are configured.


So, I was planning on waiting to update the firmware until the Xiaomi drivers are updated (there are other threads on that topic).

My question now is, will this new change for the latest firmware still work with the old firmware? Or, should I wait to update all of the Hubitat firmware, the Xiaomi driver and the iPhone WiFi Presence driver all at the same time? (asked anothwer way .... if I install this iPhone WiFi Presence Driver update on the prior firmware and will it still function or does this update only work on the hub firmware update?)



I think it will work with the old firmware. It was a one line code change to remove a criteria from an if() statement. The other criteria for that if() statement work fine under the old and new firmware.


It should work with both. The code change required is minor and is supposedly the proper way to parse the response.

The upgrade broke battery reporting ,temperature reporting and tilt reporting on my devices. A few code changes and it looks like it's parsing again fine. So wouldn't be too hard to fix and should work with new and old firmware.

Also. It's a good practice to keep the old code when you upgrade. Just save it to a text file. Then upgrade the driver and do your tests. If it doesn't work then just paste back in the old driver code and you should be good to go.


I'm sorry everyone, I'm so confused here. I'm new to Hubitat...just got it a few days ago, so I'm not up to speed on a lot. Here is the issue.

  1. I want the alarm to set automatically when BOTH my wife and I leave the house.
  2. I want the alarm to disarm automatically when EITHER my wife or I come back home.

I copied jwetzel's code (thank you Sir!) and created two virtual devices, one for my iPhone, one for my wife's iPhone.

I created a triggered rule:
Danny, Pamela (my wife) leave
Send text and Arm Away.

So now, I'm getting texts every few minutes or so but the alarm state is the same.

What am I doing wrong?


Unfortunately it's going to take a bit more machinery to get what you want. The iphone Wifi sensor needs some additional help, because iPhones regularly go to sleep. (This is why you're getting texts every few minutes.) I recommend reading through this whole thread, and also read through all of:

You'll need to use the iPhone Wifi Sensor, along with a geofencing sensor (such as Homekit or Alexa), and use Combined Presence.

I wish it were easier, but right now there is no single physical presence sensor available that is reliable enough to do this on its own. We have to combine the results of multiple types of presence sensors.


Roger that. Thank you so much...what I have found these past few days is that this online community is amazing!


@dannycerezo You can also use "Locative" on the iPhone for a Geofence Presence option that does NOT us any cloud services, other than the Hubitat Cloud server as a Maker API endpoint.


I do this with locative (use iOS version on my phone and android version on here) with combined presence.

I have a virtual presence sensor called “someone is home” and use combined presence to set it based on our individual presence and then use HSM to check the someone is home sensor.


Anyone have any thoughts on why I can't put a tile on a dashboard for this virtual device drivers state?

The driver is working fine for presence. I even created a periodic trigger to refresh it more often and added it to the mode manager to handle the mode changes with combinations. But when I try to add a tile to an existing dashboard, so I can monitor the behavior, I don't see this device listed.



Did you authorize that device in the dashboard app?


Duh. Sorry for the easy question. I am new to Hubitat and still getting used to its particulars. I missed that. Thanks patrick.


Don't worry. I've been using it for two months and still forget to update authorizations when I add new devices, and I'm pretty sure I'm not the only one. :slight_smile:


Works great with Huawei Mate 20 Pro, Make sure to go to: Settings>Battery>More Battery Settings>Stay connected when device sleeps (Your Wi-Fi or mobile data connection will remain active after the screen turns off)

I made sure the selector was ON for the above option and it is working 100%


Works great on my Huawei P20.
Works on my windows 10 PC but only when i turn windows firewall off. Which isn't great and i haven't been able to figure out the firewall settings to get it to work.

edit: installed ZoneAlarm and its working now


You’re using a windows PC as a presence sensor?


yeah. i have hubitat wake my PC up at a certain time and want to automate things based on if the computer is active and if not wake the pc up


Anyone having an issue with this device driver? I just realized that the virtual devices for all three of the iphones in my house stopped working when I upgraded the hub firmware to 2.0.7. @jwetzel1492