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

 找回密码
 立即注册
查看: 1235|回复: 5

[技术探讨] ESPHome总是不可用,求大佬指点

[复制链接]

26

主题

150

帖子

1277

积分

金牌会员

Rank: 6Rank: 6

积分
1277
金钱
1122
HASS币
20
发表于 2023-1-15 12:51:15 | 显示全部楼层 |阅读模式
本帖最后由 hass943 于 2023-1-15 12:51 编辑


我通过esphome集成了一个VL53L1X传感器进Homeassistant,刚开始都好好的,但是会随机变成不可用,这个时间不确定,可能是一个小时,可能是一天,可能是两天,但反正用不长,就会变成不可用,解决办法只能重新拔插一下esp8266
1、我通过路由器查看,并没有发现该设备有断开WiFi的记录,并且使用终端也能ping通该设备ip,该设备的连接信号-50db,也不高
2、查看homeassistant的日志记录显示如下

2023-01-15 12:43:12.215 WARNING (MainThread) [aioesphomeapi.reconnect_logic] Can't connect to ESPHome API for cf @ 192.168.88.184: Hello timed out
2023-01-15 12:44:14.585 WARNING (MainThread) [homeassistant.components.esphome] Error getting initial data for 192.168.88.184: 
2023-01-15 12:44:46.974 WARNING (MainThread) [homeassistant.components.esphome] Error getting initial data for 192.168.88.184: 
2023-01-15 12:45:26.228 WARNING (MainThread) [homeassistant.components.esphome] Error getting initial data for 192.168.88.184: 
2023-01-15 12:45:58.008 WARNING (MainThread) [aioesphomeapi.reconnect_logic] Can't connect to ESPHome API for cf @ 192.168.88.184: Hello timed out
2023-01-15 12:47:22.232 WARNING (MainThread) [homeassistant.components.esphome] Error getting initial data for 192.168.88.184: 
2023-01-15 12:47:39.923 WARNING (MainThread) [homeassistant.components.esphome] Error getting initial data for 192.168.88.184: Timeout waiting for response for <class 'api_pb2.DeviceInfoRequest'> after 10.0s
2023-01-15 12:48:06.928 WARNING (MainThread) [aioesphomeapi.reconnect_logic] Can't connect to ESPHome API for cf @ 192.168.88.184: Timeout waiting for response for <class 'api_pb2.ConnectRequest'> after 10.0s

3、在集成页面进行该设备的重载无效,依旧不可用
4、哪怕是重启homeassistant,该设备依旧显示不可用
5、下面是我的esphome yaml文件,请大佬帮忙


esphome:
  name: cf

esp8266:
  board: esp01_1m

[b]# Enable logging
logger:

[b]# Enable Home Assistant API
api:
  encryption:
    key: "xxxxxxxx"

ota:
  password: "xxxxxxxxx"

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password

[b]  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Cufang Fallback Hotspot"
    password: "xxxxxxx"

captive_portal:

external_components:
  - source: github://Lyr3x/Roode@master
    refresh: always
vl53l1x:
roode:
  roi: auto

number:
  - platform: roode
    people_counter:
      name: People Count
```


回复

使用道具 举报

3

主题

46

帖子

270

积分

中级会员

Rank: 3Rank: 3

积分
270
金钱
224
HASS币
0
发表于 2023-1-15 15:25:05 来自手机 | 显示全部楼层
我是小白,才会弄8266上接继电器,
但我看你并没有指定ip,也没有关闭wifi节能,不知道有没有关系,,
回复

使用道具 举报

2

主题

124

帖子

1719

积分

金牌会员

Rank: 6Rank: 6

积分
1719
金钱
1595
HASS币
0
发表于 2023-1-15 19:11:08 | 显示全部楼层
换一块8266试试看吧,说不定就是芯片有问题
回复

使用道具 举报

3

主题

194

帖子

1645

积分

金牌会员

Rank: 6Rank: 6

积分
1645
金钱
1451
HASS币
15
发表于 2023-1-15 21:37:37 | 显示全部楼层
换电源,8266我自己测试下来感觉电源不好就非常不稳,苹果5V1A头试一试
回复

使用道具 举报

0

主题

24

帖子

287

积分

中级会员

Rank: 3Rank: 3

积分
287
金钱
263
HASS币
0
发表于 2023-1-16 11:08:05 | 显示全部楼层
esphome的logger开个debug看看呗

最好换个板子看看吧,或者看下电源连接,要是杜邦插头可能会松动
回复

使用道具 举报

42

主题

421

帖子

1508

积分

金牌会员

Rank: 6Rank: 6

积分
1508
金钱
1087
HASS币
0
发表于 2023-1-16 11:12:17 | 显示全部楼层
是不是wifi信号不好!
回复

使用道具 举报

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

本版积分规则

Archiver|手机版|小黑屋|Hassbian

GMT+8, 2024-6-2 13:40 , Processed in 0.091741 second(s), 27 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

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