al-one / hass-xiaomi-miot

Automatic integrate all Xiaomi devices to HomeAssistant via miot-spec, support Wi-Fi, BLE, ZigBee devices. 小米米家智能家居设备接入Hass集成
https://miot-spec.com
Apache License 2.0
4.63k stars 660 forks source link

请求支持领普 s2dw3 开关的自定义文本显示功能(自定义文本设置) #1936

Open hainru opened 1 week ago

hainru commented 1 week ago

Device model / 设备型号

linp.switch.s2dw3

Component version / 插件版本

0.7.20

HA core version / HA版本

No response

Integrated mode / 集成方式

Automatic (自动模式)

The problem / 问题详情

感谢您此前对 #1890号问题的支持!但您解决该问题,并更新 master 后仍有一个问题。无法将“自定义文本输入值” 赋予 该设备的“ text_b” 或 “text_a” 值,现在该设备只能在传感器中显示“ text_b” 或 “text_a” 值,但无法编辑该值。这个 text_b 和 text_a 在米家app中是可以任意修改,并显示在实体面板上的。可否参照小爱音箱的自定义输入文本的朗读播放,给这个 s2sw3 设备也添加类似功能呢?万分感谢。附图1是该设备在米家app支持自定义更改的界面。附图2是我利用米家中枢网关,在该设备上实现自定义文本显示的实拍图。这两张图希望能帮助您理解,“ text_b” 或 “text_a” 值的功能和效果,希望这一功能可以与Home Assistant兼容,谢谢! IMG_9873 2 IMG_9877

Entity attributes / 实体属性

model: linp.switch.s2dw3
lan_ip: 192.168.66.110
mac_address: 8C:D0:B2:3F:76:26
entity_class: MiotSwitchEntity
home_room: 珊瑚湾 主卧
miot_type: urn:miot-spec-v2:device:switch:0000A003:linp-s2dw3:2:0000D042
switch-3.on: false
switch-3.mode: 1
vd_panel_a.text_a: 欢迎来到主卧!
vd_panel_a.text_b: 南面室外温度28.2°C\n东面室外温度26.4°C\n 客厅当前温度29.3℃
vd_panel_a.text_c: 主卧当前温度29°C\n次卧当前温度28.5°C\n厨房当前温度28.6°C
vd_panel_a.text_s: 你好!
vd_motor_b.target_position: 50
vd_motor_a.target_position: 50
vd_thmst_b.on: false
vd_thmst_b.target_temperature: 25
vd_thmst_b.mode: 0
vd_thmst_b.fan_level: 0
vd_thmst_a.on: false
vd_thmst_a.target_temperature: 27.5
vd_thmst_a.mode: 1
vd_thmst_a.fan_level: 0
vd_light_c.on: false
vd_light_c.brightness: 50
vd_light_c.color_temperature: 4000
vd_light_c.color: 16777215
vd_light_c.color_mode: 0
vd_light_b.on: false
vd_light_b.brightness: 50
vd_light_b.color_temperature: 4000
vd_light_a.on: false
vd_light_a.brightness: 50
vd_light_a.color_temperature: 4000
vendor.city: "101310101"
vendor.screen_saver: true
vendor.night_mode: true
vendor.night_mode_start: 75600
vendor.night_mode_over: 32400
vendor.sensitivity: 2
vendor.occupy: false
vendor.relay_lock: false
vendor.access_token: ""
vendor.refresh_token: ""
vendor.time_fmt: 0
vendor.ss_brightness: 20
vendor.rotate: false
screen_set.screen_a: "0"
screen_set.screen_b: 73,1,空调|主卧,1
screen_set.screen_c: 75,1,信息中心|通知,1
screen_set.screen_d: >-
  5,(5,12,67,0),(1,0,28,0),(2,0,0,0),(3,0,28,0),(4,0,0,2),(0,0,0,0),(0,0,0,0),(0,0,0,0)
screen_set.screen_e: ""
screen_set.screen_f: ""
screen_set.theme: https://s2dw.ks3-cn-shanghai.ksyuncs.com/v1/hy/theme.bin
screen_set.names: 开窗帘,开窗,关窗帘,关窗,空调开关,,,,,,,,,,,,
screen_set.theme_cfg: 10,291,10,266,3,15,10,234,3,164,0,0,0,0,15
screen_set.scene_a: ""
screen_set.scene_b: ""
screen_set.screen_g: ""
screen_set.screen_h: ""
screen_set.screen_ss: ""
screen.brightness: 28
screen.auto_screen_off: true
screen.auto_screen_brightness: true
screen.auto_screen_off_time: 1
screen.on: true
state_updater: lan
device_class: switch
friendly_name: Linptech Touch Screen Switch S2 Second Switch Service
supported_features: 0

Home Assistant Logs / 系统日志

No response

al-one commented 1 week ago

升级插件。。。