snosrap / artmode

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ArtMode

Overview

A Python library and command line interface for interacting with the Samsung Frame's Art Mode.

Background

The latest SmartThings iOS app doesn't work consistently and isn't scriptable in any case. The samsung-tv-ws-api project initially looked promising, but it didn't work on my 2019 Frame (software version 1401).

My ancient iPad mini runs an older version of SmartThings, which does consistently connect to the Frame. Using rvictl and WireShark, I was able to record a packet trace of the unencrypted websocket traffic. Unlike samsung-tv-ws-api, which appears to upload images on another port, my 2019 Frame expects "Binary WebSockets", in which both the JSON message and the content of the image are transmitted in the same connection.

Usage

artmode can be used as either a library or via the command line.

Library

import artmode

conn = ArtMode("samsung_tv.local.") # mDNS record or IP address
print(conn.get_content_list())

Command Line

$ python artmode.py samsung_tv.local. list

About

License:MIT License


Languages

Language:Python 100.0%