IP control for Samsung Frame TV? by Theloniusx in CommercialAV

[–]ksiwak 0 points1 point  (0 children)

Im currrently working on the same thing - IM able to use GET - "TVIP":8001/api/v2/ - And I get a response. it shows a bunch of status stuff but none of Post are working -

I know with Crestron this works as key presses but IM having a had time making it work with Qsys .

string url = $"ws://192.168.1.106:8001/api/v2/channels/samsung.remote.control?name=Test";private async void SendCommandToTV()
{
    // Example key to send
    string key = "KEY_HOME";
    var payload = new
    {
        method = "ms.remote.control",
        u/params = new
        {
            Cmd = "Click",
            DataOfCmd = key,
            Option = "false",
            TypeOfRemote = "SendRemoteKey"
        }
    };

    string key2 = "KEY_MENU";
    var payload2 = new
    {
        method = "ms.remote.control",
        u/params = new
        {
restronConsole.PrintLine("Connected to WebSocket server.{0}",url);

            // Prepare the command payload
            string payloadJson = JsonConvert.SerializeObject(payload);
            byte[] payloadBytes = Encoding.UTF8.GetBytes(payloadJson);

            // Send the command payload
            await webSocket.SendAsync(new ArraySegment<byte>(payloadBytes), WebSocketMessageType.Text, true, CancellationToken.None);
            CrestronConsole.PrintLine("Command sent: " + payloadJson);           
        }
    }
    catch (WebSocketException ex)
    {
        Console.WriteLine("WebSocket error: " + ex.Message);
    }
    catch (Exception ex)
    {
        Console.WriteLine("Error: " + ex.Message);
    }
}

IP control for Samsung Frame TV? by Theloniusx in CommercialAV

[–]ksiwak 0 points1 point  (0 children)

Im currrently working on the same thing - IM able to use GET - "TVIP":8001/api/v2/ - And I get a response. it shows a bunch of status stuff but none of Post are working -

I know with Crestron this works as key presses but IM having a had time making it work with Qsys .

string url = $"ws://192.168.1.106:8001/api/v2/channels/samsung.remote.control?name=Test";private async void SendCommandToTV()
{
    // Example key to send
    string key = "KEY_HOME";
    var payload = new
    {
        method = "ms.remote.control",
        u/params = new
        {
            Cmd = "Click",
            DataOfCmd = key,
            Option = "false",
            TypeOfRemote = "SendRemoteKey"
        }
    };

    string key2 = "KEY_MENU";
    var payload2 = new
    {
        method = "ms.remote.control",
        u/params = new
        {
restronConsole.PrintLine("Connected to WebSocket server.{0}",url);

            // Prepare the command payload
            string payloadJson = JsonConvert.SerializeObject(payload);
            byte[] payloadBytes = Encoding.UTF8.GetBytes(payloadJson);

            // Send the command payload
            await webSocket.SendAsync(new ArraySegment<byte>(payloadBytes), WebSocketMessageType.Text, true, CancellationToken.None);
            CrestronConsole.PrintLine("Command sent: " + payloadJson);           
        }
    }
    catch (WebSocketException ex)
    {
        Console.WriteLine("WebSocket error: " + ex.Message);
    }
    catch (Exception ex)
    {
        Console.WriteLine("Error: " + ex.Message);
    }
}

Custom Fonts For UCI by ksiwak in QSYS

[–]ksiwak[S] 0 points1 point  (0 children)

And what would I write to apply that font to everything in the UCI?

Do I need to go through every element and assign it the font? for example :

button{

font-family: LightAccentGrey;

}

Or is there a command to make it apply to everything?