Announcement

Collapse
No announcement yet.

How to use BLLAN as occupancy sensor

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Tillsy
    replied
    As most of you know, the iPhone (and no doubt other phones) doesn't stay online non-stop... your battery would go flat in no time. To that end it just intermittently connects as required depending on the OS and apps.

    To that end what I did is create a timer for my iPhone and my wife's iPhone. I created an event that RESTARTS that counter if the status of the relevant phone changes to 0 (e.g. contact has been lost). Each time the phone connects and then subsequently reconnects that timer resets. This happens quite a few times per hour for as long as we are home.

    HOWEVER, when we leave the timer obviously keeps going up and up because the phone isn't connecting and disconnecting. So I then have a second event - if the relevant phone changes to 100 (e.g. has reconnected) AND the relevant phone time has counted over 1 hour AND it is night time, then the front light of the house turns on.

    Thus at home nothing happens as the timer just keeps resetting. Go out for the day and come back during the day, nothing happens timer keeps resetting as its day time. But go out and return in the evening and as soon as we are approaching our home (and thus our phone connects to our WiFi) the front lights come on.

    Hope this helps others who have been trying to come up with a way to determine occupancy - as you could use the same approach to know someone is still home but depending upon the counter being LESS than 1 hour (or possibly a lower value, I just play safe as we wouldn't go out and come back in less time).

    Leave a comment:


  • randman
    replied
    I tlad the same trouble. I now use PHLocation plug-in and Geofency. Works great!

    Leave a comment:


  • NotYetRated
    replied
    Anyone using this method with an Android phone for presence tracking?

    My phone stops responding to ping requests after about 15 minutes of having the screen off. Cannot find a way to fix it! Anyone have something?

    Leave a comment:


  • randman
    replied
    Originally posted by cheeryfool View Post
    Have you tried WireShark? I haven't yet for this, but currently reasonably happy with having FollowMee keep the phone awake enough for Ping.
    I don't currently use a GPS tracking device, and my wife may not like it on her iPhone :-).

    Leave a comment:


  • randman
    replied
    Originally posted by S-F View Post
    Just noticed somethign else in the change log.


    Code:
    2.0.19.0  
    • Added ability to perform an HTTP HEAD for a computer instead of a ping.
    I'm not entirely sure what this means but could this be a better way to track iphones?
    Not sure but it sounds like it only applies to computers running an http server.

    Leave a comment:


  • S-F
    replied
    Just noticed somethign else in the change log.


    Code:
    2.0.19.0  
    • Added ability to perform an HTTP HEAD for a computer instead of a ping.
    I'm not entirely sure what this means but could this be a better way to track iphones?

    Leave a comment:


  • randman
    replied
    Originally posted by cheeryfool View Post
    Have you tried WireShark? I haven't yet for this, but currently reasonably happy with having FollowMee keep the phone awake enough for Ping.
    I haven't tried it but I read it can detect mDNS. Wondering it it has a way that f calling a script. I'll check it out.

    Leave a comment:


  • S-F
    replied
    Just a heads up guys. There was a new version pushed out.


    Code:
    2.0.21.0  
    • Changed ON value for device to 100.
    I'm as of yet unsure of this will effect existing events. I hope not.

    I'm moving slowly from BLLan to jjon00's network monitor any way. And that has the same issues with iphones.

    Leave a comment:


  • cheeryfool
    replied
    Originally posted by randman View Post
    The iPhone sends out mDNS packets every few minutes. Not sure what it does when sleeping, but it doesn't really sleep anyway given that it continues to receive notifications and email when not in active use. There's some free Bonjour monitors, and I want to observe how often and when the iPhone sends mDNS packets. If reliable, this would be more reliable than using ping, which will not work unless you're using an app that keeps the iPhone in a certain state (maybe a higher power usage state). That would be a good enhancement for BLLAN. Meanwhile, if there is a simple Bonjour app that can be run in the HomeSeer PC to detect an iPhone, then a simple call to HS3's JSON API to run an on/off type of HS3 event can be used to turn a virtual occupancy device on or off.

    Have you tried WireShark? I haven't yet for this, but currently reasonably happy with having FollowMee keep the phone awake enough for Ping.

    Leave a comment:


  • randman
    replied
    The iPhone sends out mDNS packets every few minutes. Not sure what it does when sleeping, but it doesn't really sleep anyway given that it continues to receive notifications and email when not in active use. There's some free Bonjour monitors, and I want to observe how often and when the iPhone sends mDNS packets. If reliable, this would be more reliable than using ping, which will not work unless you're using an app that keeps the iPhone in a certain state (maybe a higher power usage state). That would be a good enhancement for BLLAN. Meanwhile, if there is a simple Bonjour app that can be run in the HomeSeer PC to detect an iPhone, then a simple call to HS3's JSON API to run an on/off type of HS3 event can be used to turn a virtual occupancy device on or off.

    Leave a comment:


  • TomTom
    replied
    Ok thanks guys, those values weren't set in the device so thats why the on/off didn't show up.. Don't know if they were supposed to be in there or set up by user. In any case thanks!


    Sent from my iPhone using Tapatalk

    Leave a comment:


  • cheeryfool
    replied
    Originally posted by S-F View Post
    1 is on and 0 is off I believe.

    Yes. And if you set status text you should see those.

    Leave a comment:


  • S-F
    replied
    1 is on and 0 is off I believe.

    Leave a comment:


  • TomTom
    replied
    Ok I didn't realize that BLLAN creates a devices directly. Some of Blade's plugin's seem like you had to set up a virtual device for state(don't remember for sure).
    Ok in events
    Device Value Is > This Device Changes and Becomes > Choose Tom's iPhone(created by BLLAN) > the only options I get are
    1. custom value or value range
    2. Set to "Any Value"
    3. An Invalid or Error State

    So this is why I thought I had to create a virtual device first. There is no "ON" in the last option for me?

    Leave a comment:


  • cheeryfool
    replied
    Originally posted by TomTom View Post
    So I've moved on to the next step to set up events for my iphone's virtual device. Not sure if I'm doing something wrong, but the virtual devices status does not change.

    Here are the events:

    What are you trying to do?

    I have events that key directly off the status change of the BLLAN device for my iPhone.

    Leave a comment:

Working...
X