『瀚思彼岸』» 智能家居技术论坛

 找回密码
 立即注册
查看: 6474|回复: 6

[已解决] homebridge连接homeassisant鉴权问题

[复制链接]

1

主题

11

帖子

190

积分

注册会员

Rank: 2

积分
190
金钱
179
HASS币
0
发表于 2019-3-4 16:55:34 | 显示全部楼层 |阅读模式
本帖最后由 lvmukeke 于 2019-3-4 23:14 编辑

homeassisant中已经添加http:

   api_password:Raspberry123
configuration.yaml如下:

homeassistant:
  # Name of the location where Home Assistant is running
  name: Home
  # Location required to calculate the time the sun rises and sets
  latitude: 27.5066
  longitude: 120.5101
  # Impacts weather/sunrise data (altitude above sea level in meters)
  elevation: 0
  # metric for Metric, imperial for Imperial
  unit_system: metric
  # Pick yours from here: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
  time_zone: Asia/Shanghai
  # Customization file
  customize: !include customize.yaml

# Show links to resources in log and frontend
introduction:

# Enables the frontend
frontend:

# Enables configuration UI
config:

# Uncomment this if you are using SSL/TLS, running in Docker container, etc.
# http:
#   base_url: example.duckdns.org:8123
        http:
                api_password:Raspberry123
# Checks for available updates
# Note: This component will send some information about your system to
# the developers to assist with development of Home Assistant.
# For more information, please see:
# https://home-assistant.io/blog/2016/10/25/explaining-the-updater/
updater:
  # Optional, allows Home Assistant developers to focus on popular components.
  # include_used_components: true

# Discover some devices automatically
discovery:

# Allows you to issue voice commands from the frontend in enabled browsers
conversation:

# Enables support for tracking state changes over time
history:

# View all events in a logbook
logbook:

# Enables a map showing the location of tracked devices
map:

# Track the sun
sun:

# Allow diagnosing system problems
system_health:

# Sensors
sensor:
  # Weather prediction
  - platform: yr

# Text to speech
tts:
  - platform: google

# Cloud
cloud:

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml










homebridge中config.json配置为
{

  "bridge": {

    "name": "Home Assistant",

    "pin": "123-45-678",

    "port": 51826,

    "username": "B8:27:EB:E0D:9A"

  },

  "description": "Homebridge for Home Assistant",

  "platforms": [

    {

      "platform": "HomeAssistant",

      "name": "HomeAssistant",

      "host": "http://192.168.31.175:8123",

      "password": "Raspberry123",

      "supported_types": ["fan", "binary_sensor", "sensor", "garage_door", "input_boolean", "light", "lock", "media_player", "rollershutter", "scene", "switch"],

      "default_visibility": "visible",

      "logging": true

    }

  ]

}


启动homebridge连接过程一直提示鉴权失败是什么问题呢,状态如下
(node:1344) [DEP0022] DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.
[2019/3/4 上午8:54:17] Loaded config.json with 0 accessories and 1 platforms.
[2019/3/4 上午8:54:17] ---
[2019/3/4 上午8:54:18] Loaded plugin: homebridge-homeassistant
[2019/3/4 上午8:54:18] Registering platform 'homebridge-homeassistant.HomeAssistant'
[2019/3/4 上午8:54:18] ---
[2019/3/4 上午8:54:18] Loading 1 platforms...
[2019/3/4 上午8:54:18] [HomeAssistant] Initializing HomeAssistant platform...
[2019/3/4 上午8:54:18] [HomeAssistant] Fetching HomeAssistant devices.
[2019/3/4 上午8:54:18] [HomeAssistant] Failed getting devices: Error: You are not authenticated. Retrying...
[2019/3/4 上午8:54:23] [HomeAssistant] Fetching HomeAssistant devices.
[2019/3/4 上午8:54:23] [HomeAssistant] Failed getting devices: Error: You are not authenticated. Retrying...
[2019/3/4 上午8:54:28] [HomeAssistant] Fetching HomeAssistant devices.
[2019/3/4 上午8:54:28] [HomeAssistant] Failed getting devices: Error: You are not authenticated. Retrying...
[2019/3/4 上午8:54:33] [HomeAssistant] Fetching HomeAssistant devices.
[2019/3/4 上午8:54:33] [HomeAssistant] Failed getting devices: Error: You are not authenticated. Retrying...
[2019/3/4 上午8:54:38] [HomeAssistant] Fetching HomeAssistant devices.
[2019/3/4 上午8:54:38] [HomeAssistant] Failed getting devices: Error: You are not authenticated. Retrying...
[2019/3/4 上午8:54:43] [HomeAssistant] Fetching HomeAssistant devices.
[2019/3/4 上午8:54:43] [HomeAssistant] Failed getting devices: Error: You are not authenticated. Retrying...
[2019/3/4 上午8:54:48] [HomeAssistant] Fetching HomeAssistant devices.
[2019/3/4 上午8:54:48] [HomeAssistant] Failed getting devices: Error: You are not authenticated. Retrying...
[2019/3/4 上午8:54:53] [HomeAssistant] Fetching HomeAssistant devices.
[2019/3/4 上午8:54:53] [HomeAssistant] Failed getting devices: Error: You are not authenticated. Retrying...



回复

使用道具 举报

40

主题

3056

帖子

1万

积分

超级版主

Nero

Rank: 8Rank: 8

积分
11149
金钱
8042
HASS币
182
发表于 2019-3-4 17:08:00 | 显示全部楼层
homebridge 的homeassistant插件已停止维护
Nero
回复

使用道具 举报

0

主题

10

帖子

55

积分

注册会员

Rank: 2

积分
55
金钱
45
HASS币
0
发表于 2019-3-4 17:18:06 | 显示全部楼层
直接用homeassistant吧,放弃HB了,在configuration.yaml里面加homekit:
回复

使用道具 举报

1

主题

11

帖子

190

积分

注册会员

Rank: 2

积分
190
金钱
179
HASS币
0
 楼主| 发表于 2019-3-4 20:48:11 | 显示全部楼层
ys0290 发表于 2019-3-4 17:18
直接用homeassistant吧,放弃HB了,在configuration.yaml里面加homekit:

好的  感谢,新手刚学不清楚技术发展
回复

使用道具 举报

0

主题

52

帖子

211

积分

论坛积极会员

积分
211
金钱
159
HASS币
0
发表于 2019-3-5 00:32:32 | 显示全部楼层
应该是这样
http:   
  api_password: Raspberry123


回复

使用道具 举报

7

主题

87

帖子

525

积分

高级会员

Rank: 4

积分
525
金钱
438
HASS币
0
发表于 2019-8-24 17:31:07 | 显示全部楼层
同样的问题,请问楼主解决了吗?
回复

使用道具 举报

0

主题

27

帖子

329

积分

中级会员

Rank: 3Rank: 3

积分
329
金钱
302
HASS币
0
发表于 2020-1-29 00:12:14 | 显示全部楼层
同样的问题,请问怎么解决了的,一直查不到问题所在,主要hass里的集成hb不能使用camera组件,只能使用hb独立的。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|手机版|小黑屋|Hassbian

GMT+8, 2024-12-31 05:00 , Processed in 0.052014 second(s), 28 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表