Skip to content
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

[somfymylink] Somfy MyLink Binding initial contribution #5652

Merged
merged 53 commits into from May 25, 2020

Conversation

LoungeFlyZ
Copy link

This is a binding to support the Somfy MyLink device for control of RTS blinds/shades.

It supports control of individual motors as well as scenes.

This PR Fixes #4438

Many thanks to @mhilbush for his wonderful guidance on development of my first binding.

Signed-off-by: Chris Johnson chrisfjohnson@live.com

@LoungeFlyZ LoungeFlyZ requested a review from a team as a code owner May 28, 2019 06:00
@J-N-K J-N-K added the new binding If someone has started to work on a binding. For a new binding PR. label May 28, 2019
@J-N-K J-N-K changed the title Initial contribution [somfymylink] Initial contribution May 28, 2019
@openhab-bot
Copy link
Collaborator

This pull request has been mentioned on openHAB Community. There might be relevant details there:

https://community.openhab.org/t/somfy-mylink-somfy-synergy-api-binding/60415/7

@wborn wborn changed the title [somfymylink] Initial contribution [somfymylink] Somfy MyLink Binding initial contribution May 30, 2019
@LoungeFlyZ
Copy link
Author

Any chance of a review pass on this so I can make any adjustments needed?

@J-N-K J-N-K self-assigned this Aug 28, 2019
@J-N-K
Copy link
Member

J-N-K commented Aug 28, 2019

I‘ll try to have a look today.

Copy link
Member

@Hilbrand Hilbrand left a comment

Choose a reason for hiding this comment

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

Thank you for your contribution. I'll do a more detailed review later. But you can start with writing the readme. And adding your binding to the CODEOWNERS, bom/openhab2-addons/pom.xml and create a feature.xml file. All these file changes are also done when creating a basis binding with the skeleton script. So you could use the script to make the changes and copy the changes to your binding.
Also make sure the coding style is correct in all java files. Eclipse should take care off it when saving a file, or use ctrl-shift-f in eclipse.

@LoungeFlyZ
Copy link
Author

Thanks @Hilbrand will do! this is my first time ... so i appreciate the guidance!

Copy link
Member

@Hilbrand Hilbrand left a comment

Choose a reason for hiding this comment

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

Here is my review. The code looks good. Mostly some style issues, which some repeated on several places, which causes the high number of comments. With Ctrl-Shift-F (auto format) in Eclipse you should be able to solve a number of my comments. Also check the report html generated when you do a maven build of the binding.

About the scenelist on the bridge. Is that something that doesn't change after a thing has been added? Because it now only gets the list when the thing is created. But I would assume this is something dynamic and can change when the user changes the scenes? I also don't know what it's for on the bridge. The channel is readonly, this means the ui might show only one item. It's then not possible to open the list.

I'll will have a second look at the discovery class later, as the way it registers itself as service can be improved to follow the preferred conventions.

@Hilbrand
Copy link
Member

Hilbrand commented Oct 7, 2019

Hi Chris, @LoungeFlyZ any progress on the review comments or do you need any help?

@LoungeFlyZ
Copy link
Author

@Hilbrand apologies for the late reply (been travelling). I am a VS Code user and need to work out what the major formatting issues are so i can manually apply them vs. in Eclipse. I'm not a pro Java dev and struggle with Eclispe and had more luck with VS Code. Anyway, this is not your problem and i just need to figure out what the style rules are and get them sorted. I'll try and get time shortly to do that. Thanks for the offer of help.

@Hilbrand
Copy link
Member

Hilbrand commented Nov 14, 2019

@LoungeFlyZ good news. The tool spotless has been integrated. You can use this to reformat the code with maven. Rebase you code base and you can apply the tool. See: https://www.openhab.org/docs/developer/guidelines.html#b-code-formatting-rules-style

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
… classes

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
…riter to avoid buffers for writing to socket

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
…try blocks

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
Signed-off-by: Chris Johnson <chrisfjohnson@live.com>
@LoungeFlyZ
Copy link
Author

@cpmeister updated. also attempted to fix the missing DCO's but doesnt look like it worked. I accepted a change suggested via the github UI and it seems to break the DCO?

@cpmeister
Copy link
Contributor

Manually checked sign-off.

@cpmeister cpmeister merged commit 2176127 into openhab:2.5.x May 25, 2020
@cpmeister cpmeister removed the cre Coordinated Review Effort label May 25, 2020
@cpmeister cpmeister added this to the 2.5.6 milestone May 25, 2020
@LoungeFlyZ
Copy link
Author

Thanks again to @cpmeister, @Hilbrand and @mhilbush for helping me get this contribution ready. I very much appreciated all your support and assistance. Thanks again.

bodiroga pushed a commit to bodiroga/openhab-addons that referenced this pull request May 26, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
@LoungeFlyZ LoungeFlyZ deleted the somfymylink branch May 26, 2020 21:54
LoungeFlyZ pushed a commit to LoungeFlyZ/openhab2-addons that referenced this pull request Jun 8, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
@Hilbrand
Copy link
Member

@LoungeFlyZ the somfymylink is still missing a feature.xml (and also missing from bom/openhab2-addons/pom.xml) which means it won't show up in PaperUI and user can't install the binding. Can you fix in a new PR as this one is merged. See also #8008

@LoungeFlyZ
Copy link
Author

LoungeFlyZ commented Jun 28, 2020

@Hilbrand submitted PR #8024.

J-N-K pushed a commit to J-N-K/openhab-addons that referenced this pull request Jul 14, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
CSchlipp pushed a commit to CSchlipp/openhab-addons that referenced this pull request Jul 26, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
Signed-off-by: CSchlipp <christian@schlipp.de>
andrewfg pushed a commit to andrewfg/openhab-addons that referenced this pull request Aug 31, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
andrewfg pushed a commit to andrewfg/openhab-addons that referenced this pull request Aug 31, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
andrewfg pushed a commit to andrewfg/openhab-addons that referenced this pull request Aug 31, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
andrewfg pushed a commit to andrewfg/openhab-addons that referenced this pull request Aug 31, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
DaanMeijer pushed a commit to DaanMeijer/openhab-addons that referenced this pull request Sep 1, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
Signed-off-by: Daan Meijer <daan@studioseptember.nl>
markus7017 pushed a commit to markus7017/openhab-addons that referenced this pull request Sep 19, 2020
* Initial contribution

Signed-off-by: Chris Johnson <chrisfjohnson@live.com>

Co-authored-by: Connor Petty <mistercpp2000+gitsignoff@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new binding If someone has started to work on a binding. For a new binding PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[somfymylink] Add Somfy MyLink Binding
8 participants