![]() Samsungctl samsungctl is a library and a command line tool for remote controlling Samsung televisions via a TCP/IP connection. It currently supports both pre-2016 TVs as well most of the modern Tizen-OS TVs with Ethernet or Wi-Fi connectivity. Snake xenzia game online. Dependencies • Python 3 • websocket-client (optional, for 2016+ TVs) • curses (optional, for the interactive mode) Installation samsungctl can be installed using pip: # pip install samsungctl Alternatively you can clone the Git repository and run: # python setup.py install It's possible to use the command line tool without installation: $ python -m samsungctl Command line usage You can use samsungctl command to send keys to a TV: $ samsungctl --host [options] [key.] host is the hostname or IP address of the TV. Key is a key code, e.g. There is also an interactive mode (ncurses) for sending the key presses: $ samsungctl --host [options] --interactive Use samsungctl --help for more information about the command line arguments: usage: samsungctl [-h] [--version] [-v] [-q] [-i] [--host HOST] [--port PORT] [--method METHOD] [--name NAME] [--description DESC] [--id ID] [--timeout TIMEOUT] [key [key.]] Remote control Samsung televisions via TCP/IP connection positional arguments: key keys to be sent (e.g. KEY_VOLDOWN) optional arguments: -h, --help show this help message and exit --version show program's version number and exit -v, --verbose increase output verbosity -q, --quiet suppress non-fatal output -i, --interactive interactive control --host HOST TV hostname or IP address --port PORT TV port number (TCP) --method METHOD Connection method (legacy or websocket) --name NAME remote control name --description DESC remote control description --id ID remote control id --timeout TIMEOUT socket timeout in seconds (0 = no timeout) E.g. Samsungctl --host 192.168.0.10 --name myremote KEY_VOLDOWN The settings can be loaded from a configuration file. ![]() The file is searched from $XDG_CONFIG_HOME/samsungctl.conf, ~/.config/samsungctl.conf, and /etc/samsungctl.conf in this order. A simple default configuration is bundled with the source as. Library usage samsungctl can be imported as a Python 3 library. With samsungctl.Remote(config) as remote: # Use the remote object The constructor takes a configuration dictionary as a parameter. All configuration items must be specified. Key Type Description host string Hostname or IP address of the TV. Port int TCP port number. (Default: 55000) method string Connection method ( legacy or websocket) name string Name of the remote controller. Description string Remote controller description. Id string Additional remote controller ID. Timeout int Timeout in seconds.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |