• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

michaelmcarthur/GoogleGeocode-HASS

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

michaelmcarthur/GoogleGeocode-HASS

开源软件地址(OpenSource Url):

https://github.com/michaelmcarthur/GoogleGeocode-HASS

开源编程语言(OpenSource Language):

Python 100.0%

开源软件介绍(OpenSource Introduction):

Google Geocode

This component has been created to be used with Home Assistant.

Google geocode is the process of converting device tracker location into a human-readable address.

The sensor will update the address each time the device tracker location changes. If the device tracker is in a zone it will display the zone.

Installation:

Copy the manifest.json file and place it in <config_dir>/custom_components/google_geocode/manifest.json

Copy the sensor.py file and place it in <config_dir>/custom_components/google_geocode/sensor.py

Example Screenshot:

alt text

Example entry for configuration.yaml

sensor:

  - platform: google_geocode
    origin: device_tracker.mobile_phone

Configuration variables:

origin (Required): Tracking can be setup to track entity type device_tracker. The component updates it will use the latest location of that entity and update the sensor.

name (Optional): A name to display on the sensor. The default is “Google Geocode"

options (Optional): Select what level of address information you want. Choices are 'street_number', 'street', 'city', 'county', 'state', 'postal_code', 'country' or 'formatted_address'. You can use any combination of these options, separate each option with a comma. The default is “street, city"

display_zone (Optional): Choose to display a zone when in a zone. Choices are 'show' or 'hide'. The default is 'show'

gravatar (Optional): An email address for the device’s owner. You can set up a Gravatar here. If provided, it will override picture The default is 'none'

api_key (Optional): Your application’s API key (get one by following the instructions below). This key identifies your application for purposes of quota management. Most users will not need to use this unless multiple sensors are created.

You need to register for an API key to use Google Geocode. This can be done by following these instructions

  • Go to Google Maps Platform API
  • Click on 'Get Started'
  • Select 'Maps' and 'Places' then click 'continue'
  • Create a new project or select an existing one then click 'next'.
  • Clcik 'Create Billing Account'
  • Create a name for the account then click 'Continue'
  • Confirm your Country then click 'Confirm'
  • Fill in your detail the click 'Submit and enable billing'
  • To Emable your API's Click 'Next'
  • Copy your API key.

Example with optional entry for configuration.yaml

- platform: google_geocode
  name: michael
  origin: device_tracker.mobile_phone
  options: street_number, street, city
  display_zone: hide
  gravatar: [email protected]
  api_key: XXXX_XXXXX_XXXXX



鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap