The CLI exposes most of the library functionality, including:
App management
Remote control keys
Device information
Wake-on-LAN
Full Art Mode management
Supported TVs
This library is designed to support all Samsung Smart TVs running Tizen OS (2016+).
It also provides support for older Orsay-based TVs, specifically:
H series (2014)
Part of J series (2015)
Support for Orsay devices is mainly provided through the encrypted v1 API.
Pre-2014 TVs (C, D, E and F series) only accept key presses through the legacy
remote protocol on port 55000:
from samsungtvws.legacy.remote import SamsungTVLegacyAsyncRemote
async with SamsungTVLegacyAsyncRemote("192.168.1.10", timeout=30) as remote:
await remote.control("KEY_VOLUP")
The first connection shows a prompt on the TV; timeout also bounds how long
the user has to allow it. A denied or cancelled prompt raises
UnauthorizedError, an unknown reply raises ResponseError and a lost
connection raises ConnectionFailure.
Samsung Smart TVs do not allow WebSocket connections across different subnets or VLANs.
If your TV is not on the same subnet as Home Assistant, the connection may fail.
Depending on the network setup, this limitation might be mitigated using:
IP masquerading (NAT)
A proxy
Samsung TV keeps asking for permission
The default setting on newer televisions is to ask for permission on every connection
attempt.
To avoid this behavior, adjust:
Device Connection Manager → Access Notification Settings → First Time Only
It is also recommended to clean up previous attempts in:
Device Connection Manager → Device List
Patreon and Tips!
(I have this block in all my GPL projects)
Those who want to help buy testing hardware or just give me a tip, you can do it by sending donations to my Binance account.
I also made a Patreon