8000 Xiaomi MiIO Switch: Allow unavailable devices at startup by model setting by syssi · Pull Request #12626 · home-assistant/core · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Xiaomi MiIO Switch: Allow unavailable devices at startup by model setting #12626

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

Merged

Conversation

syssi
Copy link
Member
@syssi syssi commented Feb 23, 2018

Description:

A new configuration key "model" can be used to define the device type. The key is optional but required to bypass the device model detection f.e. if the device isn't available at the startup of homeassistant.

Pull request in home-assistant.github.io with documentation (if applicable): home-assistant/home-assistant.io/pull/4782

Example entry for configuration.yaml (if applicable):

switch:
  - platform: xiaomi_miio
    name: Xiaomi Mi Smart Power Strip
    host: 192.168.130.60
    token: 0ed0fdccb2d0cd718108f18a447726a6
    model: zimi.powerstrip.v2

'zimi.powerstrip.v2',
'chuangmi.plug.m1',
'chuangmi.plug.v2',
]),

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

closing bracket does not match visual indentation

@syssi
Copy link
Member Author
syssi commented Mar 5, 2018

@rytilahti Could you care about this one, too? It's the same like #12449 which is already merged.

@rytilahti
Copy link
Member
rytilahti commented Mar 5, 2018

Looks good to me, although the title is wrong, adding availability is more a minor change wrt the model setting, right?

@syssi
Copy link
Member Author
syssi commented Mar 5, 2018

The model setting is the requirement for the unavailable state. If you set the model the entity can be instantiated (= unavailable entity) and becomes available after the first successful request.

@syssi syssi changed the title Xiaomi MiIO Switch: Unavailable state introduced if the device isn't reachable Xiaomi MiIO Switch: Allow unavailable devices at startup by model setting Mar 5, 2018
@rytilahti
Copy link
Member

Indeed, however, the updated title will inform anyone reading the changelogs much better, thanks!

@rytilahti rytilahti merged commit e7b8443 into home-assistant:dev Mar 5, 2018
@balloob balloob mentioned this pull request Mar 9, 2018
@home-assistant home-assistant locked and limited conversation to collaborators Jul 26, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0