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

 找回密码
 立即注册
楼主: 27hh

[修仙教程] 【持续更新优化】小米米家智能设备通用接入HomeAssistant插件

  [复制链接]

15

主题

212

帖子

1268

积分

金牌会员

Rank: 6Rank: 6

积分
1268
金钱
1056
HASS币
0
发表于 2021-6-7 08:15:47 来自手机 | 显示全部楼层
更新到5.18的版本,空调伴侣使用有点问题,主要是空调点制冷后,1s后空调会直接关闭,不知道什么情况
回复

使用道具 举报

0

主题

1

帖子

8

积分

新手上路

Rank: 1

积分
8
金钱
7
HASS币
0
发表于 2021-6-28 19:20:02 | 显示全部楼层
收藏学习中
回复

使用道具 举报

2

主题

7

帖子

44

积分

新手上路

Rank: 1

积分
44
金钱
37
HASS币
0
发表于 2021-7-7 13:18:42 | 显示全部楼层
添加设备出现
Can't request MIoT api
Traceback (most recent call last):
  File "/config/custom_components/xiaomi_miot_raw/deps/xiaomi_cloud_new.py", line 187, in request_miot_api
    r = await self.session.post(url, cookies={
  File "/usr/local/lib/python3.8/site-packages/aiohttp/client.py", line 381, in _request
    raise RuntimeError("Session is closed")
RuntimeError: Session is closed
回复

使用道具 举报

4

主题

144

帖子

1712

积分

论坛积极会员

积分
1712
金钱
1563
HASS币
20
发表于 2021-7-7 16:33:23 | 显示全部楼层
cover (卷帘/晾衣架/升降帘/窗帘)
我买的设备可以接入可以控制,但是就是反馈不正常,没有百分比,都是在关闭状态,型号是Model: babai.curtain.bb82mj这种,家里有4个,可以麻烦大神看看需要修改那些地方吗
回复

使用道具 举报

0

主题

5

帖子

64

积分

注册会员

Rank: 2

积分
64
金钱
59
HASS币
0
发表于 2021-7-20 14:23:05 | 显示全部楼层
请问如果这个插件后续更新,是自动会更新吗?还是需要重新下载最新的插件覆盖重装 MIoT ?
回复

使用道具 举报

0

主题

24

帖子

58

积分

注册会员

Rank: 2

积分
58
金钱
34
HASS币
0
发表于 2021-7-28 09:10:00 | 显示全部楼层
超级大佬,一个空净,5个opple灯,试试看!!
回复

使用道具 举报

0

主题

1

帖子

4

积分

新手上路

Rank: 1

积分
4
金钱
3
HASS币
0
发表于 2021-8-4 18:29:22 | 显示全部楼层
谢谢楼主!~
回复

使用道具 举报

175

主题

2967

帖子

7606

积分

超级版主

我就是六神

Rank: 8Rank: 8

积分
7606
金钱
4614
HASS币
398

活跃会员教程狂人灌水之王

QQ
发表于 2021-10-21 19:37:21 | 显示全部楼层
马桶盖没有binarysensor 状态呀
回复

使用道具 举报

4

主题

605

帖子

2170

积分

金牌会员

Rank: 6Rank: 6

积分
2170
金钱
1560
HASS币
20
发表于 2021-10-22 22:12:07 | 显示全部楼层
本帖最后由 zsqduke 于 2021-10-22 23:50 编辑

求助一下楼主,我的圈厨油烟机,成功接入了,但是有个小瑕疵:油烟机的灯没能接入,设备参数我复制在这里,你能否帮我看看参数该如何修改。可以确定灯就是那个“照明开关按钮”(siid7,piid4)

这是自动生成的参数
{"hood":{"switch_status":{"siid":2,"piid":1},"fault":{"siid":2,"piid":2},"mode":{"siid":2,"piid":4},"off_delay":{"siid":2,"piid":5},"off_delay_time":{"siid":2,"piid":6}}}
{"hood":{"switch_status":{"power_on":true,"power_off":false},"fault":{"LightingToRemind":0,"CleanRemind":1},"mode":{"Standby":0,"Low":1,"High":2,"Turbo":3,"HeatCleaning":4},"off_delay":{"access":7,"format":"bool","unit":null},"off_delay_time":{"access":7,"format":"uint32","unit":"minutes","value_range":[0,3,1]},"main":true}}
我尝试了在参数里面添加一个hood_light项目,siid7piid4,成功把油烟机灯变成一个attribute,正确反馈灯的状态。然后我又尝试单独创建一个light集成,但是失败了。

还有个小问题是用自动生成的参数生成两个实体,一个是油烟机一个是延时关机,延时关机的实体可以输入数字,但是输入完以后并没有改变设备上的延时,而如果在米家中设置了延时关机会正确反馈到ha。


这是设备属性
{"type":"urn:miot-spec-v2:device:hood:0000A01B:xckj-z90:1","description":"Hood","services":[{"iid":1,"type":"urn:miot-spec-v2:service:device-information:00007801:xckj-z90:1","description":"Device Information","properties":[{"iid":1,"type":"urn:miot-spec-v2:property:manufacturer:00000001:xckj-z90:1","description":"Device Manufacturer","format":"string","access":["read"]},{"iid":2,"type":"urn:miot-spec-v2:property:model:00000002:xckj-z90:1","description":"Device Model","format":"string","access":["read"]},{"iid":3,"type":"urn:miot-spec-v2:property:serial-number:00000003:xckj-z90:1","description":"Device Serial Number","format":"string","access":["read"]},{"iid":4,"type":"urn:miot-spec-v2:property:firmware-revision:00000005:xckj-z90:1","description":"Current Firmware Version","format":"string","access":["read"]}]},{"iid":2,"type":"urn:miot-spec-v2:service:hood:0000782B:xckj-z90:1","description":"Hood","properties":[{"iid":1,"type":"urn:miot-spec-v2:property:on:00000006:xckj-z90:1","description":"Switch Status","format":"bool","access":["read","write","notify"]},{"iid":2,"type":"urn:miot-spec-v2:property:fault:00000009:xckj-z90:1","description":"Device Fault","format":"uint8","access":["read","notify"],"value-list":[{"value":0,"description":"照明提醒"},{"value":1,"description":"油杯清洁提醒"}]},{"iid":4,"type":"urn:miot-spec-v2:property:mode:00000008:xckj-z90:1","description":"Mode","format":"uint8","access":["read","write","notify"],"value-list":[{"value":0,"description":"待机"},{"value":1,"description":"低速"},{"value":2,"description":"高速"},{"value":3,"description":"爆炒"},{"value":4,"description":"热清洗"}]},{"iid":5,"type":"urn:miot-spec-v2:property:off-delay:00000053:xckj-z90:1","description":"Power Off Delay","format":"bool","access":["read","write","notify"]}]},{"iid":7,"type":"urn:xckj-spec:service:informed:00007801:xckj-z90:1","description":"","properties":[{"iid":1,"type":"urn:xckj-spec:property:working-state:00000001:xckj-z90:1","description":"灶头1工作状态","format":"uint8","access":["read","notify"],"value-list":[{"value":0,"description":"机器不启动"},{"value":1,"description":"机器启动"},{"value":2,"description":"小火"},{"value":3,"description":"大火"}]},{"iid":2,"type":"urn:xckj-spec:property:other-state:00000002:xckj-z90:1","description":"灶头2工作状态","format":"uint8","access":["read","notify"],"value-list":[{"value":0,"description":"机器不启动"},{"value":1,"description":"机器启动"},{"value":2,"description":"小火"},{"value":3,"description":"大火"}]},{"iid":3,"type":"urn:xckj-spec:property:run-timer:00000003:xckj-z90:1","description":"机器运行时间","format":"uint32","access":["notify","read"],"unit":"minutes","value-range":[0,9999999,1]},{"iid":4,"type":"urn:xckj-spec:property:lighting:00000004:xckj-z90:1","description":"照明开关按钮","format":"bool","access":["read","notify","write"]},{"iid":5,"type":"urn:xckj-spec:property:linkage:00000005:xckj-z90:1","description":"","format":"bool","access":["read","notify"]}]}]}


回复

使用道具 举报

4

主题

605

帖子

2170

积分

金牌会员

Rank: 6Rank: 6

积分
2170
金钱
1560
HASS币
20
发表于 2021-10-24 22:02:13 | 显示全部楼层
zsqduke 发表于 2021-10-22 22:12
求助一下楼主,我的圈厨油烟机,成功接入了,但是有个小瑕疵:油烟机的灯没能接入,设备参数我复制在这里, ...

油烟机的灯的问题已经解决了,单独重新创建了一个light实体
回复

使用道具 举报

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

本版积分规则

Archiver|手机版|小黑屋|Hassbian

GMT+8, 2024-11-24 15:29 , Processed in 0.496712 second(s), 38 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

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