288 lines
No EOL
14 KiB
HTML
288 lines
No EOL
14 KiB
HTML
<!doctype html>
|
||
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
|
||
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
|
||
<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
|
||
<!--[if gt IE 8]><!--> <html> <!--<![endif]-->
|
||
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
||
<title>Owntracks - Home Assistant</title>
|
||
<meta name="author" content="Paulus Schoutsen">
|
||
<meta name="description" content="Instructions how to use Owntracks to track devices in Home Assistant.">
|
||
|
||
<meta name="viewport" content="width=device-width">
|
||
<link rel="canonical" href="https://home-assistant.io/components/device_tracker.owntracks/">
|
||
|
||
<meta property="fb:app_id" content="338291289691179">
|
||
<meta property="og:title" content="Owntracks">
|
||
<meta property="og:site_name" content="Home Assistant">
|
||
<meta property="og:url" content="https://home-assistant.io/components/device_tracker.owntracks/">
|
||
<meta property="og:type" content="article">
|
||
<meta property="og:description" content="Instructions how to use Owntracks to track devices in Home Assistant.">
|
||
<meta property="og:image" content="https://home-assistant.io/images/home-assistant-logo-2164x2164.png">
|
||
|
||
<meta name="twitter:card" content="summary">
|
||
<meta name="twitter:site" content="@home_assistant">
|
||
|
||
<meta name="twitter:title" content="Owntracks">
|
||
<meta name="twitter:description" content="Instructions how to use Owntracks to track devices in Home Assistant.">
|
||
<meta name="twitter:image" content="https://home-assistant.io/images/home-assistant-logo-2164x2164.png">
|
||
|
||
<link href="/stylesheets/screen.css" media="screen, projection" rel="stylesheet">
|
||
<link href="/atom.xml" rel="alternate" title="Home Assistant" type="application/atom+xml">
|
||
<link rel='shortcut icon' href='/images/favicon.ico' />
|
||
<link rel='icon' type='image/png' href='/images/favicon-192x192.png' sizes='192x192' />
|
||
</head>
|
||
|
||
<body >
|
||
|
||
<header>
|
||
<div class="grid-wrapper">
|
||
<div class="grid">
|
||
|
||
<div class="grid__item three-tenths lap-two-sixths palm-one-whole ha-title">
|
||
<a href="/" class="site-title">
|
||
<img width='40' src='/demo/favicon-192x192.png'>
|
||
<span>Home Assistant</span>
|
||
</a>
|
||
</div>
|
||
|
||
<div class="grid__item seven-tenths lap-four-sixths palm-one-whole">
|
||
<nav>
|
||
<input type="checkbox" id="toggle">
|
||
<label for="toggle" class="toggle" data-open="Main Menu" data-close="Close Menu"></label>
|
||
<ul class="menu pull-right">
|
||
<li>
|
||
<a>Getting started <i class="icon icon-caret-down"></i></a>
|
||
<ul>
|
||
<li><a href='/getting-started/'>Installing Home Assistant</a></li>
|
||
<li><a href='/getting-started/configuration/'>Configuration Basics</a></li>
|
||
<li><a href='/getting-started/devices/'>Adding devices</a></li>
|
||
<li><a href='/getting-started/presence-detection/'>Presence Detection</a></li>
|
||
<li><a href='/getting-started/automation/'>Automation</a></li>
|
||
<li><a href='/topics/'>Advanced Topics</a></li>
|
||
</ul>
|
||
</li>
|
||
<li><a href='/components/'>Components</a></li>
|
||
<li><a href='/cookbook'>Examples</a></li>
|
||
<li>
|
||
<a>Developers <i class="icon icon-caret-down"></i></a>
|
||
<ul>
|
||
<li><a href="/developers/">Setup Development</a></li>
|
||
<li><a href="/developers/architecture/">Architecture</a></li>
|
||
<li><a href="/developers/frontend/">Frontend Development</a></li>
|
||
<li><a href="/developers/creating_components/">
|
||
Creating Components
|
||
</a></li>
|
||
<li><a href="/developers/add_new_platform/">
|
||
Adding Platform Support
|
||
</a></li>
|
||
<li><a href="/developers/api/">API</a></li>
|
||
<li><a href="/developers/credits/">Credits</a></li>
|
||
</ul>
|
||
</li>
|
||
<li><a href="/blog/">Blog</a></li>
|
||
<li><a href="/help/">Need help?</a></li>
|
||
</ul>
|
||
</nav>
|
||
</div>
|
||
|
||
</div>
|
||
</div>
|
||
</header>
|
||
|
||
|
||
|
||
<div class="grid-wrapper">
|
||
<div class="grid grid-center">
|
||
|
||
<div class="grid__item two-thirds lap-one-whole palm-one-whole">
|
||
|
||
|
||
<article class="page">
|
||
|
||
|
||
|
||
|
||
<header>
|
||
<h1 class="title indent">
|
||
Owntracks
|
||
</h1>
|
||
</header>
|
||
<hr class="divider">
|
||
|
||
|
||
<p>This platform allows you to detect presence using <a href="http://owntracks.org/">Owntracks</a>. OwnTracks allows users to track their location on Android and iOS phones and publish it to an MQTT broker. This platform will connect to the broker and monitor for new locations.</p>
|
||
|
||
<p>This component requires <a href="/components/mqtt/">the MQTT component</a> to be set up and works very well together with <a href="/components/zone/">the zone component</a>.</p>
|
||
|
||
<p>To integrate Owntracks in Home Assistant, add the following section to your <code>configuration.yaml</code> file:</p>
|
||
|
||
<div class="highlighter-coderay"><div class="CodeRay">
|
||
<div class="code"><pre><span class="comment"># Example configuration.yaml entry</span>
|
||
<span class="key">device_tracker</span>:
|
||
<span class="key">platform</span>: <span class="string"><span class="content">owntracks</span></span>
|
||
<span class="key">max_gps_accuracy</span>: <span class="string"><span class="content">200</span></span>
|
||
</pre></div>
|
||
</div>
|
||
</div>
|
||
|
||
<p>Configuration variables:</p>
|
||
|
||
<ul>
|
||
<li><strong>max_gps_accuracy</strong> (<em>Optional</em>): Sometimes Owntracks can report GPS location with a very low accuracy (few kilometers). That can trigger false zoning in your Home Assistant installation. With the parameter, you can filter these GPS reports. The number has to be in meter. For example, if you put 200 only GPS report with an accuracy under 200 will be take in account.</li>
|
||
</ul>
|
||
|
||
<h3><a class="title-link" name="using-owntracks-with-other-device-trackers" href="#using-owntracks-with-other-device-trackers"></a> Using Owntracks with other device trackers</h3>
|
||
<p>Owntracks can also be used with other device trackers, such as <a href="/components/device_tracker.nmap_scanner/">Nmap</a> or <a href="/components/device_tracker.netgear/">Netgear</a>. To do this, fill in the <code>mac</code> field to the Owntracks entry in <code>known_devices.yaml</code> with the MAC address of the device you want to track. This way the state of the device will be determined by the source that reported last.</p>
|
||
|
||
<h3><a class="title-link" name="using-owntracks-regions" href="#using-owntracks-regions"></a> Using Owntracks regions</h3>
|
||
<p>Owntracks can track regions, and send region entry and exit information to Home Assistant(HA). You set up a region in the Owntracks app which you should name the same as your HA Zone, and then make sure to turn on the <code>share</code> option for the region in the owntracks app. Please see the <a href="http://owntracks.org/booklet/guide/waypoints/">owntracks documentation</a></p>
|
||
|
||
<p>Home Assistant will use the enter and leave messages to set your zone location. Your location will be set to the center of zone when you enter. Location updates from OwnTracks will be ignored while you are inside a zone.</p>
|
||
|
||
<p>When you exit a zone, Home Assistant will start using location updates to track you again. To make sure that Home Assistant correctly exits a zone (which it calculates based on your GPS co-ordinates), you may want to set your Zone radius in HA to be slightly smaller that the Owntracks region radius.</p>
|
||
|
||
<h3><a class="title-link" name="using-owntracks-regions---forcing-owntracks-to-update-using" href="#using-owntracks-regions---forcing-owntracks-to-update-using"></a> Using Owntracks regions - forcing Owntracks to update using iBeacons</h3>
|
||
<p>When run in the usual <code>significant changes mode</code> (which is kind to your phone battery), Owntracks sometimes doesn’t update your location as quickly as you’d like when you arrive at a zone. This can be annoying if you want to trigger an automation when you get home. You can improve the situation using iBeacons.</p>
|
||
|
||
<p>iBeacons are simple bluetooth devices that send out an “I’m here” message. They are supported by IOS and some Android devices. Owntracks explain more <a href="http://owntracks.org/booklet/guide/beacons/">here</a></p>
|
||
|
||
<p>When you enter an iBeacon region, Owntracks will send a <code>region enter</code> message to HA as described above. So if you want to have an event triggered when you arrive home, you can put an iBeacon outside your front door. If you set up an OwnTracks iBeacon region called <code>home</code> then getting close to the beacon will trigger an update to HA that will set your zone to be <code>home</code>.</p>
|
||
|
||
<p>When you exit an iBeacon region HA will switch back to using GPS to determine your location. Depending on the size of your zone, and the accuracy of your GPS location this may change your HA zone.</p>
|
||
|
||
<p>Sometimes Owntracks will lose connection with an iBeacon for a few seconds. If you name your beacon starting with <code>-</code> Owntracks will wait longer before deciding it has exited the beacon zone. HA will ignore the <code>-</code> when it matches the Owntracks region with Zones. So if you call your Owntracks region <code>-home</code> then HA will recognise it as <code>home</code>, but you will have a more stable iBeacon connection.</p>
|
||
|
||
<h3><a class="title-link" name="using-owntracks-ibeacons-to-track-devices" href="#using-owntracks-ibeacons-to-track-devices"></a> Using Owntracks iBeacons to track devices</h3>
|
||
<p>iBeacons don’t need to be stationary. You could put one on your key ring, or in your car.</p>
|
||
|
||
<p>When your phone sees a mobile iBeacon that it knows about, it will tell HA the location of that iBeacon. If your phone moves while you are connected to the iBeacon, HA will update the location of the iBeacon. But when your phone loses the connection, HA will stop updating the iBeacon location.</p>
|
||
|
||
<p>To use mobile iBeacons with HA, you just set up a region that doesn’t match your Zone names. If HA sees an entry event for a iBeacon region that doesn’t match a Zone name (say <code>keys</code>) - it will start tracking it, calling the device <code>device_tracker.beacon_keys</code>).</p>
|
||
|
||
<p>This allows you to write zone automations for devices that can’t track themselves (for example <code>alert me if I leave the house and my keys are still at home</code>). Another example would be <code>open the gates if my car arrives home</code>.</p>
|
||
|
||
<h3><a class="title-link" name="using-mobile-and-fixed-ibeacons-together" href="#using-mobile-and-fixed-ibeacons-together"></a> Using mobile and fixed iBeacons together</h3>
|
||
<p>You can use iBeacons of both types together, so if you have a Zone <code>drive</code> with an iBeacon region called <code>-drive</code> and you arrive home with a mobile iBeacon called <code>-car</code>, then <code>device_tracker.beacon_car</code> will be set to a state of <code>drive</code>.</p>
|
||
|
||
|
||
|
||
</article>
|
||
|
||
|
||
</div>
|
||
|
||
|
||
<aside id="sidebar" class="grid__item one-third lap-one-whole palm-one-whole">
|
||
<div class="grid">
|
||
|
||
|
||
<section class="aside-module grid__item one-whole lap-one-half">
|
||
<div class='edit-github'><a href='https://github.com/balloob/home-assistant.io/tree/master/source/_components/device_tracker.owntracks.markdown'>Edit this page on GitHub</a></div>
|
||
<div class='brand-logo-container section'>
|
||
<img src='/images/supported_brands/owntracks.png' />
|
||
</div>
|
||
<div class='section'>
|
||
This is a platform for
|
||
<a href='/components/device_tracker/'>the Device Tracker component</a>.
|
||
</div>
|
||
<div class='section'>
|
||
<h1 class="title delta">Category Presence Detection</h1>
|
||
<ul class='divided'>
|
||
<li>
|
||
<a href='/components/device_tracker.asuswrt/'>ASUSWRT</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.actiontec/'>Actiontec</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.aruba/'>Aruba</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.ddwrt/'>DD-WRT</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.fritz/'>FRITZ!Box</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.locative/'>Locative</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.mqtt/'>MQTT Device Tracker</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.netgear/'>Netgear</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.nmap_scanner/'>Nmap</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.luci/'>OpenWRT (luci)</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.ubus/'>OpenWRT (ubus)</a>
|
||
</li>
|
||
<li>
|
||
Owntracks
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.snmp/'>SNMP</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.tplink/'>TP-Link</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.thomson/'>Thomson</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.tomato/'>Tomato</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.unifi/'>Ubiquiti Unifi WAP</a>
|
||
</li>
|
||
<li>
|
||
<a href='/components/device_tracker.icloud/'>iCloud</a>
|
||
</li>
|
||
</ul>
|
||
</div>
|
||
</section>
|
||
|
||
</div>
|
||
</aside>
|
||
|
||
</div>
|
||
</div>
|
||
|
||
<footer>
|
||
<div class="grid-wrapper">
|
||
<div class="grid">
|
||
<div class="grid__item">
|
||
<div class="copyright">
|
||
<a rel="me" href='https://twitter.com/home_assistant'><i class="icon-twitter"></i></a>
|
||
<a rel="me" href='https://github.com/balloob/home-assistant'><i class="icon-github"></i></a>
|
||
|
||
<div class="credit">
|
||
Website powered by <a href='http://jekyllrb.com/'>Jekyll</a> and the <a href='https://github.com/coogie/oscailte'>Oscalite theme</a>.<br />
|
||
Hosted by <a href='https://pages.github.com/'>GitHub</a> and served by <a href='https://cloudflare.com'>CloudFlare</a>.
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</footer>
|
||
|
||
<!--[if lt IE 7]>
|
||
<p class="chromeframe">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> or <a href="http://www.google.com/chromeframe/?redirect=true">activate Google Chrome Frame</a> to improve your experience.</p>
|
||
<![endif]-->
|
||
|
||
<script>
|
||
var _gaq=[['_setAccount','UA-57927901-1'],['_trackPageview']];
|
||
(function(d,t){var g=d.createElement(t),s=d.getElementsByTagName(t)[0];
|
||
g.src=('https:'==location.protocol?'//ssl':'//www')+'.google-analytics.com/ga.js';
|
||
s.parentNode.insertBefore(g,s)}(document,'script'));
|
||
</script>
|
||
|
||
</body>
|
||
</html> |