cancel
Showing results for 
Search instead for 
Did you mean: 

Device dwell time calculation

New here

Device dwell time calculation

So I'm not a developer but I'm making an attempt at putting together charts of visitor dwell time from the scanning API.  The scanning API posts a timestamp of when a device is seen, but there's no data element indicating when a device leaves.  I'm looking to understand how the length of stay is calculated based on the data elements that the scanning API will post.  I think the idea is each 60-ish seconds the post happens and a MAC will be seen, and if it's seen each post, that's considered a minute of dwell time... but to be frank, it's confusing to me.  If anyone could provide any guidance, it would be very much appreciated.  Thanks!

3 REPLIES
Getting noticed

Re: Device dwell time calculation

You've got the basic idea.  You can also consider signal strength, ssid, and perhaps device location.  It all depends on your specific use case and requirements.

 

To get some ideas, read through document 3965 in Meraki's help.  Go through the entire document, as the really useful information is throughout.  Don't forget the footnotes, either.

 

Also note that several companies have devoted a significant amount of development to converting presence-based data streams (like Meraki's Scanning API) into actionable intelligence.

New here

Re: Device dwell time calculation

Thank you!
Here to help

Re: Device dwell time calculation

Hi,

 

The API can deliver an array of the 'point in time' detections as you've quite rightly highlighted. From that there is typically a job to do to sort through these individual detections and work out those which are in the middle of a visit..

 

When we've done this previously we've maintained an intermediary SQL based database and some logic in the receiver script/program, broadly outlined as follows:

 

For each recorded detection:

"have I seen this Mac address in the last 3 minutes?"

 - if yes, update the last_seen on a visit entry.

 - if no, create a new visit and add the information.

 

We've found this is the best way of cleanly doing it. This then allows you the ability to hold a table full of 'visits' which can be analysed separately to 'detections'.

 

Hope that helps,

 

Chris