YoLink Power Failure Alarm#91934
Conversation
|
Please add a a link to the changelog, or at minimum a diff between library versions to the PR description |
|
@gjohansson-ST Thanks, The description has been updated |
| YoLinkSensorEntityDescription( | ||
| key="state", | ||
| device_class=SensorDeviceClass.ENUM, | ||
| name="State", |
There was a problem hiding this comment.
This seems like a vague name, maybe name it "Power failure alarm"?
| YoLinkSensorEntityDescription( | ||
| key="mute", | ||
| device_class=SensorDeviceClass.ENUM, | ||
| name="Mute", |
There was a problem hiding this comment.
Same comment as above about this possibly being too vague
| icon="mdi:volume-mute", | ||
| options=["yes", "no"], | ||
| exists_fn=lambda device: device.device_type in ATTR_DEVICE_POWER_FAILURE_ALARM, | ||
| value=lambda value: "yes" if value is True else "no", |
There was a problem hiding this comment.
Since this is not a control but a sensor, should the states be "muted" and "unmuted"?
There was a problem hiding this comment.
There is a physical mute button on the device, This entity is used to show whether the device is in silent mode
| YoLinkSensorEntityDescription( | ||
| key="sound", | ||
| device_class=SensorDeviceClass.ENUM, | ||
| name="Volume", |
There was a problem hiding this comment.
Same comment as above about this possibly being too vague
| YoLinkSensorEntityDescription( | ||
| key="beep", | ||
| device_class=SensorDeviceClass.ENUM, | ||
| name="Beep", |
There was a problem hiding this comment.
Same comment as above about this possibly being too vague
| icon="mdi:bullhorn", | ||
| options=["enable", "disable"], | ||
| exists_fn=lambda device: device.device_type in ATTR_DEVICE_POWER_FAILURE_ALARM, | ||
| value=lambda value: "enable" if value is True else "disable", |
There was a problem hiding this comment.
Since this is not a control but a sensor, should the states be "enabled" and "disabled"?
There was a problem hiding this comment.
Our API does not support change the settings of the beeper, but the mobile application can , this entity is used to display the status of the beeper
|
Please take a look at the requested changes, and use the Ready for review button when you are done, thanks 👍 |
Proposed change
Add YoLink Power Failured Alarm(YS7106) Support
YoLink API changes
YoSmart-Inc/yolink-api@v0.2.8...v0.2.9
Type of change
Additional information
Checklist
black --fast homeassistant tests)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest.requirements_all.txt.Updated by running
python3 -m script.gen_requirements_all..coveragerc.To help with the load of incoming pull requests: