JPersson77 / LGTVCompanion

Power On and Off WebOS LG TVs together with your PC
MIT License
944 stars 40 forks source link

tv will not switch inputs #227

Open reaps101 opened 1 month ago

reaps101 commented 1 month ago

Describe the bug

Tv will power on and off fine but if tv is on say hdmi 2, when powering on it will not switch to the pc's hdmi 4

How to reproduce the bug?

leave tv on hdmi 2, turn tv off, start pc, tv turns on but does not switch to pc input

What was the expected behavior

tv switch to hdmi 4

What is your system?

Win 11, build 22631.3737, LG OLED C1

Log file and screenshots

https://pastebin.com/1WH7wHu4

JPersson77 commented 1 month ago

Hi, can you double check the pastebin link please. It does not seem to work for me. Cheers

Edit: the link works when copy pasting the text..The log actually indicate that hdmi 4 was set. Is this an intermittent issue for you or does it always occur?

reaps101 commented 1 month ago

seems to have fixed itself, it didnt work after i updated to the latest version, but after switching the settings off and on a couple of times it seems to have fixed it

JPersson77 commented 1 month ago

The only thing that stood out in the log was that the TV was quite slow to respond. Not sure what to make of it but maybe it is related

reaps101 commented 1 month ago

You got me wondering now if a factory reset of the tv would be a good idea

JPersson77 commented 1 month ago

Yeah it wouldnt be the first time it helped with weird issues. Maybe start with pulling the plug for a few minutes though and see if things run smoothly from there

hapklaar commented 1 month ago

Hmm, interesting. I have the same or similar issue. Instead of creating a new issue I thought I'd add here.

I have two PC's connected to an LG C2, one on HDMI1 and the other on HDMI4. The one connected to HDMI1 always works correctly and switches the input to HDMI1 when turned on.

The laptop connected to HDMI4 never switches to HDMI4 when turned on.

I pasted a debug log here: https://pastebin.com/m430VVtt

JPersson77 commented 1 month ago

Hi @hapklaar there are no issues with your log, everything looks as expected. Since the TV powers on fine and responds to the request to switch HDMI, but doesn't actually do it, Isuspect that the TV needs slightly more time after being powered on before the HDMI-switch command is sent. Currently on vacation so it'll take a few weeks but I'll have a look

hapklaar commented 1 month ago

Thanks @JPersson77 for responding while on holiday! No rush at all, I hope you have a good one!

In the mean time, I'll do some additional testing.

hapklaar commented 1 month ago

I've been testing with alternate inputs, but all behave the same as hdmi4. It works only 1 out of 20something times. Your suspicion about it being a timing issues might be correct, but then I would expect input switching to occur always when the TV is already on but on the wrong input when I power up the laptop. This doesn't seem to be the case (or maybe I tested it wrong...)