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

[androidtv] Add CLI for PIN process #15143

Closed
morph166955 opened this issue Jun 27, 2023 · 5 comments · Fixed by #15146
Closed

[androidtv] Add CLI for PIN process #15143

morph166955 opened this issue Jun 27, 2023 · 5 comments · Fixed by #15146
Assignees
Labels
enhancement An enhancement or new feature for an existing add-on

Comments

@morph166955
Copy link
Contributor

As requested in #14282 by @jlaur -

Recommend adding a CLI interface for the PIN process similar to the BoschIndego binding.

https://github.com/openhab/openhab-addons/blob/main/bundles/org.openhab.binding.boschindego/src/main/java/org/openhab/binding/boschindego/internal/console/BoschIndegoCommandExtension.java

@morph166955 morph166955 added the enhancement An enhancement or new feature for an existing add-on label Jun 27, 2023
@morph166955 morph166955 self-assigned this Jun 27, 2023
@openhab-bot
Copy link
Collaborator

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

https://community.openhab.org/t/androidtv-binding-3-2-0-4-0-0/142203/471

@morph166955
Copy link
Contributor Author

@jlaur I notice in your example that you apply the command to the bridge. I don't think that will work here for people with multiple local devices (like me). Is there a mechanism where we can specify the thingId on the cli and match against it?

@mlobstein
Copy link
Contributor

Take a look at this one also... It is almost exactly the same use case to trigger a PIN display and submit it back: https://github.com/openhab/openhab-addons/blob/main/bundles/org.openhab.binding.vizio/src/main/java/org/openhab/binding/vizio/internal/console/VizioCommandExtension.java

@morph166955
Copy link
Contributor Author

Thank you @mlobstein ! This is exactly the logic I was looking for.

@morph166955
Copy link
Contributor Author

I decided to take a slightly different approach on this. Instead of locking this to the pin, I basically made the interpreter send to any channel. This serves three purposes. 1) It resolves this feature request by enabling pin on the command line. 2) It allows users to also send keypress/keycode from the command line for testing. 3) It allows me to work a little easier with the debug channels when doing testing.

PR coming forthwith.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An enhancement or new feature for an existing add-on
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants