From d5b551732a41474e0aa102eae79ddb64dd5a89ed Mon Sep 17 00:00:00 2001 From: DubhAd Date: Sun, 28 Apr 2019 22:42:33 +0100 Subject: [PATCH] Added details of `device_tracker.see` (#9272) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Turns out, we don't actually document the service at all 🤷‍♂️ --- source/_components/device_tracker.markdown | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/source/_components/device_tracker.markdown b/source/_components/device_tracker.markdown index 6f63703e70f..351cf4a37eb 100644 --- a/source/_components/device_tracker.markdown +++ b/source/_components/device_tracker.markdown @@ -115,3 +115,17 @@ If you want to track whether either your GPS based tracker or your local network ## {% linkable_title Device states %} The state of your tracked device will be `'home'` if it is in the [home zone](/components/zone#home-zone), detected by your network or Bluetooth based presence detection. If you're using a presence detection method that includes coordinates then when it's in a zone the state will be the name of the zone (in lower case). When a device isn't at home and isn't in any zone, the state will be `'not_home'`. + +## {% linkable_title `device_tracker.see` service %} + +The `device_tracker.see` service can be used to manually update the state of a device tracker: + +| Service data attribute | Optional | Description | +| ---------------------- | -------- | ----------- | +| `dev_id` | no | The second half of the `entity_id`, for example `tardis` for `device_tracker.tardis` | +| `location_name` | no | The location, `home`, `not_home`, or the name of the zone | +| `host_name` | yes | The hostname of the device tracker | +| `mac` | yes | The MAC address of the entity (only specify if you're updating a network based tracker) | +| `gps` | yes | If you're providing a location, for example `[51.513845, -0.100539]` | +| `gps_accuracy` | yes | The accuracy of the GPS fix | +| `battery` | yes | The battery level of the device |