Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

小米空气净化器4 屏幕亮度和提示音不可调节 #1572

Closed
SodaWithoutSparkles opened this issue Mar 12, 2024 · 7 comments
Closed

Comments

@SodaWithoutSparkles
Copy link
Contributor

SodaWithoutSparkles commented Mar 12, 2024

Device model / 设备型号

xiaomi.airp.mp4

Component version / 插件版本

0.7.16

HA core version / HA版本

2024.3.0

Integrated mode / 集成方式

Local (本地模式)

The problem / 问题详情

米家app中,可以调节 屏幕亮度 (关/微亮/正常) 和 提示音(开/关),但是这里缺少有关实体

Entity attributes / 实体属性

preset_modes:
  - Auto
  - Sleep
  - Favorite
  - None
percentage: null
percentage_step: 33
preset_mode: None
model: xiaomi.airp.mp4
lan_ip: 192.168.1.212
mac_address: C8:5C:CC:xx:xx:xx
entity_class: MiotFanEntity
home_room: 我的家 臥室
exclude_miot_services:
  - custom_service
miot_type: urn:miot-spec-v2:device:air-purifier:0000A007:xiaomi-mp4:1
air_purifier.on: false
air_purifier.fault: 0
air_purifier.mode: 6
air_purifier.fan_level: 0
air_purifier.anion: true
rfid.rfid_tag: 91:12:1d:xx:xx:xx:4
rfid.rfid_factory_id: "0:0:41:xx"
rfid.rfid_product_id: "16"
rfid.rfid_time: "0:23:8:xx"
rfid.rfid_serial_num: "0:71:75:xx"
air_purifier_favorite.fan_level: 1
screen.brightness: 1
physical_controls_locked: false
alarm: true
filter.filter_life_level: 71
filter.filter_used_time: 1015
filter.filter_left_time: 2485
environment.relative_humidity: 72
environment.temperature: 19
environment.air_quality: 0
environment.pm2_5_density: 7
state_updater: lan
friendly_name: Xiaomi Smart Air Purifier 4 Air Purifier
supported_features: 9
sub_entities:
  - environment-3.relative_humidity-1
  - environment-3.temperature-2
  - environment-3.air_quality-3
  - environment-3.pm2_5_density-4
  - filter-4.filter_life_level-1
  - filter-4.filter_used_time-2
  - filter-4.filter_left_time-3
  - physical_controls_locked-8.physical_controls_locked-1

Home Assistant Logs / 系统日志

No response

@SodaWithoutSparkles
Copy link
Contributor Author

SodaWithoutSparkles commented Mar 12, 2024

亮度估计和screen.brightness: 1有关

已确认以下 screen.brightness: 的关系:

  1. 正常
  2. 微亮
  3. 息屏

提示音估计和alarm 项有关

已确认 alarm: 的true/false对应提示音 开启/关闭,true是开启

@SodaWithoutSparkles SodaWithoutSparkles changed the title 小米空气净化器4屏幕亮度不可调节 小米空气净化器4 屏幕亮度和提示音不可调节 Mar 12, 2024
@SodaWithoutSparkles
Copy link
Contributor Author

SodaWithoutSparkles commented Mar 12, 2024

这两个比较重要,虽然负离子开关也不见了,不过负离子一般都是长期开启/关闭的

建议上述两项放在 Configurations 里面,和 physical control locked一起

@al-one
Copy link
Owner

al-one commented Mar 14, 2024

尝试master分支

@SodaWithoutSparkles
Copy link
Contributor Author

SodaWithoutSparkles commented Mar 14, 2024

没看见选项?

edit: 好像出bug了不能下载master...

This error originated from a custom integration.

Logger: custom_components.hacs
Source: custom_components/hacs/base.py:730
integration: HACS (documentation, issues)
First occurred: 12:03:04 AM (1 occurrences)
Last logged: 12:03:04 AM

Download failed - Got status code 404 when trying to download https://github.com/al-one/hass-xiaomi-miot/releases/download/master/xiaomi_miot.zip
Traceback (most recent call last):
  File "/config/custom_components/hacs/base.py", line 730, in async_download_file
    raise HacsException(
custom_components.hacs.exceptions.HacsException: Got status code 404 when trying to download https://github.com/al-one/hass-xiaomi-miot/releases/download/master/xiaomi_miot.zip

看来hacs出bug了

@SodaWithoutSparkles
Copy link
Contributor Author

SodaWithoutSparkles commented Mar 14, 2024

我试试手动更改 af2beab 更改的东西。提示音和负离子开关没问题

屏幕就不行了。

当屏幕为非关闭状态,调节Screen项目:

  1. 屏幕关闭
  2. 提示音响起
  3. 米家APP显示息屏
  4. state 转变为 screen.brightness: 2
  5. Screen项目短暂关闭之后保持开启

当屏幕为关闭状态 (什么事也没发生,因为不能打开一个已经开了的项目)

当屏幕为任意状态,调节米家APP,需要大概20秒 screen.brightness 才会转变。不过我一直是用local连接的。这个可能和屏幕会在 调节模式/功能/开关机 的时候短暂点亮有关,因为调节屏幕状态后,先等十几秒,稳定之后才推送状态更新,就可以避免米家APP在屏幕短暂点亮的时候误判屏幕亮度。

而且似乎没有方法调节亮度。可能可以在light effects那里塞进去?或者直接设置微亮是50%,正常是100%?现在不论是正常还是微亮都是0%就有点怪。

@SodaWithoutSparkles
Copy link
Contributor Author

release 0.7.17 已经把"缺少选项"处理了。"屏幕选项有bug"的问题我会再新开一个issue,先把这个关了。

@SodaWithoutSparkles
Copy link
Contributor Author

related to: #1775

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants