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

[samsungtv] Tv configured via Thing file duplicated by discovery and permission issue #6317

Closed
francemgit opened this issue Nov 1, 2019 · 11 comments
Labels
bug An unexpected problem or unintended behavior of an add-on

Comments

@francemgit
Copy link

OpenHab 2.5.0 Snapshot version running on Pi 4.
TV Samsung 6 Series55.

Bindings works perfectly using websocket but:

  • my Tv defined via configuration file is discovered during search but and marked as NEW and not IGNORED. Any issue with "representation property" to get auto-ignore working?
  • each time i turn on TV (via openHab or through remote) the TV keep asking for OpenHab permission

Marco

@francemgit francemgit added the bug An unexpected problem or unintended behavior of an add-on label Nov 1, 2019
@jaywiseman1971
Copy link

RE: each time I turn on TV, the TV keep asking for OpenHab permission

I have the same thing happening ONLY when I restart OH on one (newest one) of my 8 Samsung TVs.

Best, Jay

@Cossey
Copy link
Contributor

Cossey commented Nov 27, 2019

When openHAB restarts I also get a Permission Prompt on the TV, definitely an issue in implementation (unless TV firmware has updated since my last check and does something different in the websocket implementation).

I recall in testing with a direct Websocket to the TV a while back that as long as I specified correct token and app name in the remote control api URL it would remember permissions.

@jaywiseman1971 Do you have an N series TV among those 8? If so, does your TV have issues with Powering On/Off not always working consistently? How its implemented in the binding and how the Websocket Protocol works needs some additional tweaking which I'm planning on working on (the TV needs to either be sent the TV_POWER command over Websocket or a Wake on LAN packet; the web socket service still runs up to 30-90 after power off which means that the WoL approach won't work until the API service dies).

@jaywiseman1971
Copy link

jaywiseman1971 commented Dec 2, 2019

Hi @Cossey.

Here's my problem TV which is the newest one.

Brand : Samsung
Model : UN65MU6290 (bought from Costco)

  1. Asks permissions whenever I restart OH
  2. Can power it ON from OH but can't power it OFF

Defined in THINGS as

Thing samsungtv:tv:basementwired "Samsung Basement Wired" [ hostName="192.168.0.128", port=8002, refreshInterval=15, macAddress="xx:xx:xx:xx:xx:xx" ]

Best, Jay

@francemgit
Copy link
Author

Still present with latest snapshot 2.5.0.

Each time the TV is turned on is discovered as new thing (although already present via configuration file):

[home.event.InboxAddedEvent] - Discovery Result with UID 'samsungtv:tv:.........

Each time the TV is turned off the inbox discovered one is removed:

[me.event.InboxRemovedEvent] - Discovery Result with UID 'samsungtv:tv:.........

The TV keep asking permission while powered.

Best,
Marco

@Cossey
Copy link
Contributor

Cossey commented Dec 8, 2019

@francemgit Noted.

@jaywiseman1971 Looks like your TV is a 2017 model. Might be missing the protocol="WebSocket" or protocol="SecureWebSocket" setting in your Thing config, this was only implemented in 2.5.0.M2 onwards.

The asking of permission after reboot is definitely a bug though.

@jaywiseman1971
Copy link

Re: protocol="WebSocket" or protocol="SecureWebSocket"

Can someone provide the documentation where this is referenced? I'm not using either of these in my THING config.

Thing samsungtv:tv:basementwired "Samsung Basement Wired" [ hostName="192.168.0.128", port=8002, refreshInterval=15, macAddress="9c:8c:6e:69:b6:fe" ]

Best, Jay

@webhamster2000
Copy link

Can someone provide the documentation where this is referenced? I'm not using either of these in my THING config.

I can't point to documentation, but I can verify that the protocol-parameter is used and working (OH 2.5)

@francemgit
Copy link
Author

francemgit commented Feb 22, 2020

Update to OH 2.5.2, issue still present.
Trying to make some test, problem seems to be related to OH installation of plugin openhab-core-io-transport-upnp that is needed by other bindings I have.

Marco

@jaywiseman1971
Copy link

Please be aware that there is some fundamental issues with the SamsungTV Binding and jUpNp that is trying to be worked out.

#5892

Best, Jay

@francemgit
Copy link
Author

francemgit commented Apr 27, 2020

Made some test today and partially resolved my issue. (openHAB 2.5.4)

I've removed the protocol and port parameters from things file, the binding auto select secure websocket.
All works perfectly and stopped asking permission each time i turn on tv.

Auto discovery still find and remove a copy of the TV in the inbox each time i turn on and off, it's annoying but not a serius issue :)

Marco

t2000 added a commit to t2000/openhab2-addons that referenced this issue Jun 18, 2020
Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
cpmeister pushed a commit that referenced this issue Jun 18, 2020
Contributes to #6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
knikhilwiz pushed a commit to knikhilwiz/openhab2-addons that referenced this issue Jul 12, 2020
…#7936)

Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
CSchlipp pushed a commit to CSchlipp/openhab-addons that referenced this issue Jul 26, 2020
…#7936)

Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
Signed-off-by: CSchlipp <[email protected]>
andrewfg pushed a commit to andrewfg/openhab-addons that referenced this issue Aug 31, 2020
…#7936)

Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
andrewfg pushed a commit to andrewfg/openhab-addons that referenced this issue Aug 31, 2020
…#7936)

Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
andrewfg pushed a commit to andrewfg/openhab-addons that referenced this issue Aug 31, 2020
…#7936)

Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
andrewfg pushed a commit to andrewfg/openhab-addons that referenced this issue Aug 31, 2020
…#7936)

Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
DaanMeijer pushed a commit to DaanMeijer/openhab-addons that referenced this issue Sep 1, 2020
…#7936)

Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
Signed-off-by: Daan Meijer <[email protected]>
markus7017 pushed a commit to markus7017/openhab-addons that referenced this issue Sep 19, 2020
…#7936)

Contributes to openhab#6317 and should hide a result if there is already a thing
defined which does not have the same ThingUID but points to the same TV.

Signed-off-by: Stefan Triller <[email protected]>
@hmerk
Copy link
Contributor

hmerk commented Jul 25, 2021

closed

@hmerk hmerk closed this as completed Jul 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An unexpected problem or unintended behavior of an add-on
Projects
None yet
Development

No branches or pull requests

5 participants