The LG C2 TV annoyingly defaults to HDMI
Input Mode Type.
This mode has hight latency and bad image quality.
The PC
Input Mode Type fixes that, but it's deeply nested under the webOS Home Dashboard, and resets every time the cable is disconnected (e.g. to plug it into another device).
This script makes it so that your macOS device listens to the TV being available via AirPlay, and changes all HDMI's Input Mode Type to PC.
Tested in macOS Sonoma 14.0
- Install the bscpylgtv library
- Place
lg-pc-mode.sh
in~/.bin
or equivalent folder. - Make it executable
- Run
chmod +x ~/.bin/lg-pc-mode.sh
- Run
- (Optional): Run and test it now:
- Run
~/.bin/lg-pc-mode.sh
- You should see your TV listed under "Instance Name"
- Run
- Add cron to run it upon every reboot:
- Run
crontab -e
- Add and save:
@reboot ~/.bin/lg-pc-mode.sh
- Confirm it's been added running:
crontab -l
- Run
- You need to have the
bscpylgtvcommand
binary inside/opt/homebrew/bin
- Change the path used in the
debounce
function calls if you have it elsewhere.
- Change the path used in the
- Find your monitor model
- Run
dns-sd -B _airplay._tcp
- Get the model number and update line 22 of the script with it.
- Example output (your model number would be:
OLED42C24LA
):
- Run
Browsing for _airplay._tcp
DATE: ---Sat 14 Oct 2023---
8:48:47.228 ...STARTING...
Timestamp A/R Flags if Domain Service Type Instance Name
8:48:47.229 Add 3 14 local. _airplay._tcp. MacBook Pro
8:48:47.229 Add 3 1 local. _airplay._tcp. MacBook Pro
8:48:47.229 Add 3 19 local. _airplay._tcp. MacBook Pro
8:48:47.229 Add 3 21 local. _airplay._tcp. MacBook Pro
8:48:47.229 Add 3 23 local. _airplay._tcp. MacBook Pro
8:48:47.229 Add 3 15 local. _airplay._tcp. MacBook Pro
8:48:47.229 Add 2 15 local. _airplay._tcp. [LG] webOS TV OLED42C24LA
- alin23 - Helping and providing the simplest solution using dns-sd. Also check out his awesome app for controlling monitors, Lunar.
- ToggleHDR Apple Shortcut, also from alin23 lets you quickly enable/disable HDR in any monitor, including the LG C2 TV. This enhances brightness and arguably improves image quality.
- bscpylgtv library by chros73 lets us control the webOS based LG TVs like the C2.