bwssytems / ha-bridge

Home automation bridge that emulates a Philips Hue light system and can control other systems such as a Vera, Harmony Hub, Nest, MiLight bulbs or any other system that has an http/https/tcp/udp interface. This is a compact impl to run on small format computers. This is impl started from this project https://github.com/armzilla/amazon-echo-ha-bridge.
Apache License 2.0
1.45k stars 198 forks source link

Anyone know commands for LG TV? #637

Closed crsnwby closed 7 years ago

crsnwby commented 7 years ago

I can see a WebOS 3 TV can be controlled using python, is there any way of controlling it using ha-bridge?

Tried using the xml but dont know what im doing

?xml version="1.0" encoding="utf-8"? envelope api type="command" nameHandleKeyInput/name value21/value #21 being the remote code for HOME button /api /envelope

digiltd commented 7 years ago

It does look possible, but it doesn't look easy, especially if you don't know much about this sort of stuff.

https://community.smartthings.com/t/smartthings-control-of-lg-webos-3-0-tvs/75302/16

The results are also not really worth it, I did the same to my Samsung but the whole concept was massively flawed because the TV had to be on in order to receive a signal. So if you turned it off, you could not turn it back on again using the network.

edit: though it seems the LG does allow power on using the network https://github.com/Danovadia/lgtv-http-server

You are better off getting a Harmony Hub

crsnwby commented 7 years ago

I see that does look a bit too much work for not moving my arm 3 inches to pick up the remote. I wondered as the android app anymote works without a hub so assumed/hoped there were HTTP commands I could just use in ha-bridge.

digiltd commented 7 years ago

Oh, well that is something different, I am pretty sure I have heard of others using Anymote, so I think it is possible. In that instance the Android device is the hub. Looks like you can also use Alexa with Anymote directly.

crsnwby commented 7 years ago

Yea but didn't want to use anymore as it's a pain and another app to keep running. Was hoping to just add commands to ha bridge

masterchop commented 7 years ago

Yes, you can there is an option to execute command line commands. you can just do like:

python scriptname.py <parameters> that works for me. i was using python and bash

crsnwby commented 7 years ago

Do you have a working example? not sure how to set it up using python.