[PORT] LG Smart TV Discovery 2012+

Do you know if WOL works with C9 tv?

Afraid not, easy enough to try and see.

Yeah, I tried and it didn't work but maybe I'm doing something wrong

Happy to help -- tell me what you did, which app you used, and we can compare notes!

Thanks! So I download the LG webOS driver (Which is now with your revised code).

I also downloaded the WOL app. Added to the app my LG C9 TV as a device and added to it the MAC&IP address of the tv.

Now, if I press "on" on the WOL device, I get this warning line in the log section..."Error occured with UDP message: SocketTimeoutException: Receive timed out".

I also created a basic rule (Please see attached screenshot) but it didn't work.

Which WOL app are you using? I had some trouble too until I used this one. Maybe give it a try. Worked for me.

Yep, I'm using this one

Hmm maybe others can comment. I believe the TV has to support WOL and there is usually some setting that allows the TV to operate at a low power sleep state. Maybe check that out?

Also I believe your router has to allow WOL as well.

A couple places to look for solutions?

I'm going to chime in. It's been awhile but I installed this app some years back. Seems I had trouble in wol.

I think I wound up having wifi and Ethernet both connected on the TV. One of the two would respond to wol the other wouldn't..

Thanks but no change even with wifi on :confused:

I think I need to find out how to allow WOL on my router

The driver worked great for me, including power-on (my TV is connected only to wi-fi). I made one enhancement, adding this one line to the metadata:
capability "Actuator"
That allows me to actually access the values of the Command variables in a rule. I now have the TV responding to a power-on event by turning on my Denon receiver AND switching to YouTubeTV (just set the externalInput to "YouTube TV").

can you post the rule? I've been trying to do somethin gsimilar with some lights and never quite have been able to get it to work reliably. You'd t hink it would be simple but apparently not for me :slight_smile:

Sure thing. Rules are tricky, especially the obscure way to set parameters for custom devices.
Hopefully these screen snaps help (not sure if I know how to add pictures!)...
Screen Shot 2021-12-29 at 11.44.50 AM
Screen Shot 2021-12-29 at 11.44.23 AM

Yeah I have something similar. (Are you missing an ENDIF btw?) The problem I have is sometimes when I turn the TV on physically the device driver just never realizes it.

Yes, sometimes it misses the "on" event, but it mostly works. And thanks for catching that! Added the ENDIF!

1 Like

Hey sorry, don't come here too often any longer so didn't see your response.

I think I explained it somewhere in this thread above but the app has to do a poll to determine when the TV is on. Basically, webconnect has to reconnect before the TV is on. The timing of that poll is customizable. In the preferences, the poll is called "Device Reconnect Delay". I've set mine to 30s.

So what that means is that it could take a max of 30s after the TV is on before the app notices that. That might be what you're experiencing.

Also, you'd want to turn "Quick Start+" on. That's what allows it reconnect quickly.

Also, look at my post here:

It's a bit weird that your app would show switch as "off" if you powered on from HE. The "switch" attribute doesn't actually depend on whether the TV is on or off. It's changed to "on" as soon you power on from HE.

Also, I'd recommend using the "power" attribute in your rule. That is the true signal of whether the TV is on or off. Also, like I said in the last post, there would be some delay (Device Reconnect Delay) between the TV turning on and the power attribute changing to "on".

That delay is likely because of a race condition between turning off the TV and turning it back on. Look at my post here:

I fixed it in my driver code that I posted above. I've been using it for 1.5 years and haven't had power on misses:

Thanks for the tips. Can you please expand on the "power" attribute?