LG WebOS better integration

The LG WebOS webbrowser app has the ability to display another input ‘picture-in-picture’.
E.g. show television input on HDMI1 in a small PIP window while showing a webpage.
(can be enabled by either ‘blue button’ or icon on top of the screen)
Although my remote does not show any PiP option, it seems it’s technically possible on the TV.
@MaxvandeLaar did you perhaps see any option in the LG WebOS API’s to trigger PiP?
Would be great to e.g. show doorbell video or Homey Dash in PiP rather than taking over full display while binge watching… :slight_smile:

@Ollem, I didn’t come across any PiP features. However, whenever launching an app or input, I can send additional parameters (undocumented). For example, I figured out the parameters for sending alerts with buttons with some trial and error and guess work. This makes it very difficult to figure out all the possibilities for apps/inputs.

But to be honest, even if I figured out a few of them, I can’t support most apps and it would be extremely complex for me to implement this dynamics in the flow cards. And even then, it would be pretty complex for uses to understand how to use them.

Don’t get me wrong, I understand your use case. However, the research, development, implementation, and user execution makes this really question if it is anything I should even start to look in too. If you have suggestions on how send me a PM and we’ll discuss.

Which version of LG WebOS will this app support?
My newest LG TV Oled 55C9 modell year 2019 has version 4.7.

@Goran_Hernell, Since I only have 2 TV’s and both running WebOS 3.5 I can not test nor fully support WebOS 4+. Some users do use the app while running WebOS 4.X so I suggest just give it a try and let me know if you run into issues (please check GitHub issues first)

@Jurgen
I just released version v2.1.0. This does not include a polling mechanism as I found some unexpected behaviour for some tv’s when turning on/off. However, due to this behaviour I found another way to check if the tv is on/off so I added that to the on/off check.

  • Added flow triggers for (un)muted event
  • Further improved on/off check

May someone encounter any issues please check the GitHub issues first and if it does not yet exist, please create an issue there. :slight_smile:

@MaxvandeLaar Thanks for the new release. I will install it tonight and provide feedback. Looking forward to check your implementation of mute and also of on/off (as this wasn’t working correctly with my tv in version 2.0.0 :wink:
Update: Release 2.1.0 works perfect. (Un)mute action! Thanks @MaxvandeLaar

@Jurgen and how about the on/off check? Does that work now as well?

Detection of on/off went from 8 seconds to instant with this update. :raised_hands:

1 Like

Same here,
On/off detection went from about 5 seconds to instantly on an Oled 65B6V.
Great work Max !!

1 Like

@Tomm @Martin_van_der_Aart, good to hear these unexpected improvements. I added extra checks to all listeners (volume, input/app, channel changes) to make it more reliable actually not faster. Still great that it is even faster now :slight_smile:

Checked again this morning, and it took now about 4 seconds to detect on/off while yesterday after i installed the new version it was practically instant. Maybe it is because i power the tv completely off during the night?
Still 4 seconds is just fine for me, thanks for you work on the app.

@Martin_van_der_Aart The speed mostly depends on when the tv sends a notification to the app to let it know a value (channel, app/input, volume, power state) has changed. A complete shutdown could indeed slow down the flow. 4 seconds is still pretty fast. I mean, the first app used to be 2 minutes :wink: and I consider anything below 10 seconds as very fast.

Thanks for the updated release!
I use an external soundbar connected by optical out, and so I have disabled the internal speakers of the tv set. As a result the mute button on the LG remote doesn’t function.
Therefore I was very curious if I could use the ‘mute’ button to trigger some kind of Flow, e.g. to trigger to dim or toggle the lights.
Unfortunately this doesn’t work now, because it seems a current state is trying to be determined, which doesn’t exist because internal sound is disabled…
Logs only display the following when pressing ‘mute’ button:
[log] [ManagerDrivers] [webos_plus] [0] _handleResponse: ssap://audio/getVolume
Do you see any option to change this to provide some kind of return anyway? Or maybe even add another homey function linked to the mute button to be used in case sound is disabled?

Another question: any idea what tiggers the ‘authorize remote access’ dialog on the tv? Only a few days ago I had to reconfirm and now again.

@Ollem, interesting use case…

So the reason why this isn’t working for you, is that (probably) the TV isn’t actually changing the mute value, thus, I am not ‘triggering’ the flow card in code since there is no change. The TV appears to notify me there is a something happening to the volume however I only react to changes in volume or mute at the moment. I might have a look at what is possible here but I can’t make any promises as this is an edge case. A customisable button to trigger a flow would actually be pretty cool, however I can’t ‘catch’ a remote button press, I can only act on notifications I receive and these are limited to power/volume/channel/app/input changes as far as I can tell.

Related to your authorisation question… this should only occur if the code can’t find (or has invalid) authentication key. This key is stored in your user data folder in the Homey itself /userdata/com.maxvandelaar.webos-plus-keyfile-${IPADDRESS HERE}. So Homey is removing this file or you IP-address changes every few days forcing you to reauthorise your tv. I can try to looking to change this to something more robust, but as you can probably guess… no promises here.

PS: If I do change the authorisation file name, everyone must reauthorise. Not a big deal, just something to keep in mind.

Maybe I overlooked this completely, but when can we expect this app in the app store?
I don’t have a laptop so Cli seems no option to me.
Hope to hear from you.

Cheers,
Eric

@friethoe if it was up to me a few months ago. I submitted it twice for the App Store and got rejected by Athom due to its working better then their own app and they can’t compete with it. They actually considered copying features without discussing with me but decided the feature are too complex for users :joy:.

So in conclusion you won’t be seeing this app in the store unless Athom gets their act together. Sorry to bring you this sad news. Still frustrates me a lot actually.

@MaxvandeLaar Unfortunately the on/off does not work with my LG tv as expected. After +/- 20 seconds it receives trigger “TV ON”, a couple seconds later 'TV OFF" . When selecting something on TV the trigger “TV ON” is received When switching tv off it almost immediately sends a trigger “TV OFF”.

:thinking:

@Jurgen Hmm sorry to hear that, I was already working on implementing a polling mechanism when I decided to see if I could fix it without adding it by making previously said changes. The polling mechanism will be somewhat slower than listening for state changes however, I will try to keep it as fast as possible though.

Everyone, @Jurgen, I just released a new version (tested it for some weeks). The new version allows you to toggle per TV how to check on/off state. By API method (default) or by polling the IP address. I am using API on one tv and polling on another as the latter doesn’t seem to be reliable with the API. You can do this in the TV settings per device. The polling state is obviously slower in detecting but still useable for me.

1 Like

Hello my friends :wink:

So in (kinda but not really) secret I’ve been working on a side project since my app got rejected for stupendous reasons. Yep that’s right, the Homey Community App Store (beta version) has arrived! No more CLI to side-load apps, just hit the install button!

Since everyone here always was very friendly and gave me great feedback I thought maybe some of you are willing to give it a try. You can read the Forum post here

And find the Homey Community Store here Homey Community Space

5 Likes