This deffinetly works outside of homeassistant. What would we need to do to get this working in homeassistant to control brightness?
https://github.com/home-assistant/home-assistant/pull/18091 is the pull request you want to follow. It should automatically detect those dimmers without extra configuration.
Is this going to be added to the next version of HA? Sorry im a bit new to all of this and how updates get implemented.
It is going to be added when it’s ready, no idea if it makes into the next release though, but make an update here when it’s been merged.
Oh damn… I just got a new HS220 and just took for granted it was working…
It was so simple to setup all my TP-Link smart switches and plugs, I never stopped to confirm if this one was supported lol…
Oh well, I’ll be patient then and use it as simple switch in the mean time
me too. Hoping for support soon
Some investigation in the dimmer commands has been done:
The research looks promising
As I mentioned before, the support has been there in the PR I’ve been working on: https://github.com/home-assistant/home-assistant/pull/18091 - this should be working just fine for HS220 (it’s just that the tests are missing to get this merged), but I haven’t heard anyone reporting back on it so far…
id be glad to test and post any logs needed… just need to know what i can do to test it. I have a HS220 that installed and ready to test with!
Same here with a HS220, I would help but not sure how and what to test …
I can test too but don’t know how or what to do
The testing this is a bit more involved than a custom component, and is simplest done if you are using/used to virtualenv-based systems which will keep your regular system intact. The basic procedure is somewhat following (with the same user homeassistant is normally run):
<first, stop running homeassistant instance>
$ virtualenv testenv
$ source testenv/bin/activate
$ pip install -e git+https://github.com/rytilahti/home-assistant.git@tplink_unique_id#egg=homeassistant
<wait for install to complete>
$ hass
After homeassistant has started, you need to go to Configuration -> Integrations to activate the integration, which will then automatically discover your devices.
The configuration has changed, the PR has a configuration example (in case the autodetection is not wanted, or not working), more in https://github.com/home-assistant/home-assistant.io/pull/7338 .
After testing you can simply remove the testenv directory to get rid of it and relaunch the regular homeassistant instance.
Im running my homeassistant in a docker container so i dont think that will really work for me… any way to start it up using docker in a new container?
this is basically the commands i run to uninstall and pull the latest updated docker container for homeassistant…
docker stop home-assistant
docker rm home-assistant -f
docker container prune -f
docker volume prune -f
docker image prune -a -f
docker pull homeassistant/home-assistant
docker run -d --name=“home-assistant” -v /usr/share/hassio/homeassistant:/config -v /etc/localtime:/etc/localtime:ro --net=host homeassistant/home-assistant
You would need to check out that PR branch, and build a container manually from it. Unfortunately I have no idea how that should be done properly (docker build and then launching the built container?). If someone knows how to do that, it would be nice to have it documented in homeassistant’s docs as it would be useful for other testers, too.
Any update on this? I’m looking forward to it
I’ve been trying to read some posts about similar questions but nothing I can really understand fully
Seems like if you submit the PR there is testing already
but then I also read something about TOX …which I guess is some unit testing tool or something
I have just picked up one of these dimmers and would be willing to test, how do I get the tplink.py script for install/activation?
Any updates on this and when it will be available?
It will be available when it’s ready. I created the necessary tests and there should be only one showstopper (unloading & reloading the discovery on the configuration page) anymore to get this merged. It would still be nice if someone could test it, I have just a single plug I have used to test it, and sofar no one has reported back if it is working or not with the 220.