-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[Tapocontrol] Binding to control Tapo (by TP-Link) Devices #11111
Conversation
This pull request has been mentioned on openHAB Community. There might be relevant details there: https://community.openhab.org/t/tapocontrol-new-binding-for-tapo-smart-wifi-device/118389/1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I reviewed the readme, so far.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The credential configuration looks good!
There are some checkstyle warnings left. You could take a look at target/code-analysis/report.html
after building it with mvn clean install
.
There are some compiler warnings about null access left. You could take a look at mvn clean install
. To fix these, you need to store the field to a local variable and do the null check on that.
The sign off message needs to be your full name and have a valid email address. You can post the complete line in the comments, I will adopt it during merging, then.
...control/src/main/java/org/openhab/binding/tapocontrol/internal/TapoControlConfiguration.java
Outdated
Show resolved
Hide resolved
...ocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoControlThingHandler.java
Outdated
Show resolved
Hide resolved
bundles/org.openhab.binding.tapocontrol/src/main/resources/OH-INF/thing/thing-types.xml
Outdated
Show resolved
Hide resolved
bundles/org.openhab.binding.tapocontrol/src/main/resources/OH-INF/thing/thing-types.xml
Outdated
Show resolved
Hide resolved
bundles/org.openhab.binding.tapocontrol/src/main/resources/OH-INF/thing/thing-types.xml
Outdated
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/device/TapoSmartBulb.java
Outdated
Show resolved
Hide resolved
bundles/org.openhab.binding.tapocontrol/src/main/resources/OH-INF/thing/thing-types.xml
Outdated
Show resolved
Hide resolved
Thanks very very much to @daMihe to help me fixing my github history. |
Signed-off-by: Christian Wild <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great that you two figured it out! Looking forward seeing the fixing tutorial!
Is this ready for review again? I only reviewed the discovery for now.
...ontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoControlHandlerFactory.java
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoDiscoveryService.java
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoDiscoveryService.java
Outdated
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoDiscoveryService.java
Outdated
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoDiscoveryService.java
Outdated
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoDiscoveryService.java
Outdated
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoDiscoveryService.java
Outdated
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoDiscoveryService.java
Outdated
Show resolved
Hide resolved
Would be great if you can review it all. So i can fix all review remarks next week. Binding looks to work good in that version so no bigger changes should be necessary at the moment. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some compiler warnings about null access left. You could take a look at mvn clean install
. To fix these, you need to store the field to a local variable and do the null check on that.
There are some checkstyle warnings left. You could take a look at target/code-analysis/report.html
after building it with mvn clean install
.
...ontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoControlHandlerFactory.java
Show resolved
Hide resolved
...tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/TapoDiscoveryService.java
Outdated
Show resolved
Hide resolved
...ntrol/src/main/java/org/openhab/binding/tapocontrol/internal/device/TapoUniversalDevice.java
Outdated
Show resolved
Hide resolved
...ntrol/src/main/java/org/openhab/binding/tapocontrol/internal/structures/TapoLightEffect.java
Outdated
Show resolved
Hide resolved
...binding.tapocontrol/src/main/java/org/openhab/binding/tapocontrol/internal/test/TapoUDP.java
Outdated
Show resolved
Hide resolved
bundles/org.openhab.binding.tapocontrol/src/main/resources/OH-INF/config/config.xml
Outdated
Show resolved
Hide resolved
bundles/org.openhab.binding.tapocontrol/src/main/resources/OH-INF/thing/testdevice.xml
Outdated
Show resolved
Hide resolved
So guys. I think i resolved all review-requests. Anyway big THX to all reviewers (of any plugin etc.) for the time you spent into this and help others to get better 👍 👍 |
Signed-off-by: Christian Wild <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some compiler warnings about null access left. You could take a look at mvn clean install
. To fix these, you need to store the field to a local variable and do the null check on that.
I re-reviewed the readme for now.
Signed-off-by: Christian Wild <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Now, you could add your binding's logo to the openHAB website. See https://next.openhab.org/docs/developer/bindings/#add-your-binding-s-logo-to-the-openhab-website |
added logo for tapocontrol-binding wich is merged with pull-request openhab/openhab-addons#11111
added logo for tapocontrol-binding wich is merged with pull-request openhab/openhab-addons#11111 Signed-off-by: Christian Wild <christianwild-bw.de>
added logo for tapocontrol-binding wich is merged with pull-request openhab/openhab-addons#11111 Signed-off-by: Christian Wild <christianwild-bw.de>
…1111) * [tapocontrol] New Source Upload Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Delete bundles/org.openhab.binding.tapocontrol directory Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Snapshot 3.2 Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update CODEOWNERS Fixed bindingname Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update README.md Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] new "Bridge-Version" Credentials (TapoCloud) where now set in a bridge device. Things now had to be attached to a bridge. Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed device discovery bug fixed device discovery bug added bridge to thing-types.xml Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update bundles/org.openhab.binding.tapocontrol/README.md Co-authored-by: Fabian Wolter <[email protected]> Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] code cleanup and optimization - general code cleanup and optimization - limited max connections and queued requests to 10 per destination - device error handling revised - review remarks of pull request processed Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] solved review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] LightStrip L900 basicly supported Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed compiler warnings Signed-off-by: Christian Wild <[email protected]> Co-authored-by: Fabian Wolter <[email protected]> Signed-off-by: Nick Waterton <[email protected]>
…1111) * [tapocontrol] New Source Upload Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Delete bundles/org.openhab.binding.tapocontrol directory Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Snapshot 3.2 Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update CODEOWNERS Fixed bindingname Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update README.md Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] new "Bridge-Version" Credentials (TapoCloud) where now set in a bridge device. Things now had to be attached to a bridge. Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed device discovery bug fixed device discovery bug added bridge to thing-types.xml Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update bundles/org.openhab.binding.tapocontrol/README.md Co-authored-by: Fabian Wolter <[email protected]> Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] code cleanup and optimization - general code cleanup and optimization - limited max connections and queued requests to 10 per destination - device error handling revised - review remarks of pull request processed Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] solved review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] LightStrip L900 basicly supported Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed compiler warnings Signed-off-by: Christian Wild <[email protected]> Co-authored-by: Fabian Wolter <[email protected]> Signed-off-by: Michael Schmidt <[email protected]>
…1111) * [tapocontrol] New Source Upload Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Delete bundles/org.openhab.binding.tapocontrol directory Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Snapshot 3.2 Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update CODEOWNERS Fixed bindingname Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update README.md Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] new "Bridge-Version" Credentials (TapoCloud) where now set in a bridge device. Things now had to be attached to a bridge. Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed device discovery bug fixed device discovery bug added bridge to thing-types.xml Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update bundles/org.openhab.binding.tapocontrol/README.md Co-authored-by: Fabian Wolter <[email protected]> Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] code cleanup and optimization - general code cleanup and optimization - limited max connections and queued requests to 10 per destination - device error handling revised - review remarks of pull request processed Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] solved review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] LightStrip L900 basicly supported Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed compiler warnings Signed-off-by: Christian Wild <[email protected]> Co-authored-by: Fabian Wolter <[email protected]>
…1111) * [tapocontrol] New Source Upload Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Delete bundles/org.openhab.binding.tapocontrol directory Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Snapshot 3.2 Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update CODEOWNERS Fixed bindingname Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update README.md Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] new "Bridge-Version" Credentials (TapoCloud) where now set in a bridge device. Things now had to be attached to a bridge. Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed device discovery bug fixed device discovery bug added bridge to thing-types.xml Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update bundles/org.openhab.binding.tapocontrol/README.md Co-authored-by: Fabian Wolter <[email protected]> Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] code cleanup and optimization - general code cleanup and optimization - limited max connections and queued requests to 10 per destination - device error handling revised - review remarks of pull request processed Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] solved review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] LightStrip L900 basicly supported Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed compiler warnings Signed-off-by: Christian Wild <[email protected]> Co-authored-by: Fabian Wolter <[email protected]>
…1111) * [tapocontrol] New Source Upload Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Delete bundles/org.openhab.binding.tapocontrol directory Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Snapshot 3.2 Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update CODEOWNERS Fixed bindingname Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update README.md Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] new "Bridge-Version" Credentials (TapoCloud) where now set in a bridge device. Things now had to be attached to a bridge. Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed device discovery bug fixed device discovery bug added bridge to thing-types.xml Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] Update bundles/org.openhab.binding.tapocontrol/README.md Co-authored-by: Fabian Wolter <[email protected]> Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] code cleanup and optimization - general code cleanup and optimization - limited max connections and queued requests to 10 per destination - device error handling revised - review remarks of pull request processed Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] solved review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] LightStrip L900 basicly supported Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed review requests Signed-off-by: Christian Wild <[email protected]> * [tapocontrol] fixed compiler warnings Signed-off-by: Christian Wild <[email protected]> Co-authored-by: Fabian Wolter <[email protected]>
TapoControl
this is the initial contribution of a new binding to control "Tapo SmartDevices"
Control Tapo (TP-Link) P100 WiFi-Sockets, L510 and 530 SmartBulbs with openhab
It's possible to switch the devices On/Off, change colors and brighness (if supported) and gather some informations from the devices.
The connection will be established between openhab and the device directly by ip-adresses but credentials for Tapo-cloud are required because the communication is encrypted with them.
compiled with maven and testet with the vs-code-developer-ide and one openhabian device
link to the source
link to the .jar