Samsung TV Binding (Beta)

@11194

That’s an Openhab thing, it does that. Nothing to do with the binding.

Post your samsungtv TRACE log, and I’ll take a look, but it sounds like you have something else going on.

@guterm

I have updated my test binding (that I gave you the link to earlier). I have changed the channel number to now return a float. The binding always used a DecimalType for channel, so this should not change the binding or items at all (ie Number).

This means that “57-1” will become 57.1, “2-11” will become 2.11, and “21-1” will become 21.1. ordinary channel numbers such as “23” should still be 23. you get -1 for no channel number.

please let me know if you can try it out, I have it working, but I have no off air channels, so I just get the expected -1.

Thank you Nicholas, this is perfect!

@guterm

have you tried the new binding yet? i just posted an update, which fixes some issues with setting the input, as Smarthings seems to have changed how it reports the supported inputs.

Same link as before.

There was nothing in logs from the binding. Problem was solved by deleting the binding, restarting openHab and then force removing the thing. Other users experienced similar problems when the binding was not adopted to the new openHab’s way for channels upgrading.

Have not managed to get 4.2 running yet, sorry.
Will updated version work on 4.1?

@guterm

No, sorry. OpenHab has updated some dependencies, so when the binding compiles now it requires the 4.2 libraries, so it won’t start in OH 4.1 due to unmet dependencies.

I had to upgrade to 4.2 M1 just to test it.

I, I would appreciate a hint:

Openhabian 3.4.4, Samsung 2024 GQ43QN90DATXZG, Firmware 1106.9

SamsungTV 1.14 SNAPSHOT-3.3.0

(can not upgrade to OpenHAB 4 currently)

Configured Thing with PAT and added the Device ID. I can do some functions (I see channel and volume, but can not change volume. Can power on TV, but not power Off).

Main Problem is that the WebsocketRemote fails to connect, and no pop-up shows on the TV that I could accept. I tried port 8001 and 8002, to no avail.

I tried with connection manager setting to off / first time only / on and never got a popup to accept a connection.

Smartthings from IOS cell phone works fine and gets the popup to accept the connection on the TV, only openhab does not.

Logs:
: WebSocketRemote connecting without Token, please accept the connection on the TV within 30 seconds
01:59:39.372 [DEBUG] [ungtv.internal.protocol.WebSocketBase] - 192.168.2.25: WebSocketRemote connecting to: wss://192.168.2.25:8002/api/v2/channels/samsung.remote.control?name=b3BlbkhBQg==
01:59:39.376 [DEBUG] [ungtv.internal.protocol.WebSocketBase] - 192.168.2.25: WebSocketArt connecting to: wss://192.168.2.25:8002/api/v2/channels/com.samsung.art-app?name=b3BlbkhBQg==
01:59:39.387 [DEBUG] [ungtv.internal.protocol.WebSocketBase] - 192.168.2.25: WebSocketV2 connecting to: wss://192.168.2.25:8002/api/v2?name=b3BlbkhBQg==
01:59:39.393 [DEBUG] [gtv.internal.handler.SamsungTvHandler] - 192.168.2.25: Started service for: GQ43QN90DATXZG, RemoteControlReceiver ()
01:59:39.398 [DEBUG] [nternal.service.SmartThingsApiService] - 192.168.2.25: Creating a Samsung TV Smartthings Api service
01:59:39.403 [TRACE] [nternal.service.SmartThingsApiService] - 192.168.2.25: SSE Starting job
01:59:39.405 [INFO ] [nternal.service.SmartThingsApiService] - 192.168.2.25: SSE Creating Smartthings Subscription
01:59:39.409 [TRACE] [nternal.service.SmartThingsApiService] - 192.168.2.25: subscription: {“subscriptionFilters”:[{“type”:“DEVICEIDS”,“value”:[“b679adec-321f-ced6-4776-78abc122c7fb”]}],“name”:“OpenHAB Subscription”}
01:59:39.416 [TRACE] [nternal.service.SmartThingsApiService] - 192.168.2.25: Sending https://api.smartthings.com:443/subscriptions
01:59:39.469 [DEBUG] [ungtv.internal.protocol.WebSocketBase] - 192.168.2.25: WebSocketRemote connection error PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
01:59:39.490 [DEBUG] [ungtv.internal.protocol.WebSocketBase] - 192.168.2.25: WebSocketV2 connection error PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
01:59:39.496 [DEBUG] [ungtv.internal.protocol.WebSocketBase] - 192.168.2.25: WebSocketArt connection error PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

@Olafsc

Your problem is that 2024 Samsung TV’s do not have valid certificates. This is why the websocket will not connect.

This is fixed in the latest versions of the binding (which allows untrusted certificates).

Unfortunately, the latest versions of the binding only work on OH 4.2 or higher (due to dependancies).

Thanks - I tried, but i have another critical binding compliled for 4.0.0 and that loaded in 4.1.3 but seems not anymore under 4.2M3, so I am stuck it seems, requesting that owner to update to make it load at 4.2 (I am surprised, I thought a 4.0.0 Binding jar should load in 4.2m3 but so there…

See you when I can get to 4.2!

O

@Olafsc

Unfortunately OpenHab updated a lot of older libraries in 4.2, so bindings that were compiled with the older versions won’t work anymore.

When 4.2 is released, my samsungtv binding should be part of the standard add-ons though.