klattimer/LGWebOSRemote

lgtv scan not working

Closed this issue · 6 comments

cdam06 commented

Followed install instructions. This is what I am seeing when attempting the lgtv scan ssl command. Any help would be appreciated.

(lgtv) chandu@ChandusacStudio lgtv % lgtv scan ssl
Traceback (most recent call last):
  File "/Users/chandu/opt/lgtv/bin/lgtv", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/Users/chandu/opt/lgtv/lib/python3.11/site-packages/LGTV/__init__.py", line 123, in main
    results = LGTVScan()
              ^^^^^^^^^^
  File "/Users/chandu/opt/lgtv/lib/python3.11/site-packages/LGTV/scan.py", line 25, in LGTVScan
    response, address = sock.recvfrom(512)
                        ^^^^^^^^^^^^^^^^^^
TimeoutError: timed out

Erm, you may need higher privileges to run the recvfrom, either that or it received nothing back, it looks like it just got nothing back.

You need your TV on the same network.

cdam06 commented

Thank you for the response. The TV is on and connected to the same network.

NcLax5 commented

Hi just wanted to add I am also receiving a similar error code on my LG C3

lgtv scan ssl is working fine on my LG C2

~/opt/lgtv$ lgtv scan
{"result": "ok", "count": 1, "list": [{"uuid": "bc67s921-s92s-920d-ab3b-s8dj2kd8sa0", "tv_name": "Bob", "address": "192.168.1.147"}]}

I'll close this, as the latest code appears to have fixed the underlying issue.

Same issue in LG C3 in MacOS 14.2.1