Moin,
mein Samsung hat Netzwerk...
oben beim environment
Code
# TV ip and port (comment to disable)
env tv_ip=192.168.178.21
export tv_ip
env tv_port=55000
export tv_port
im python Teil eine Funktion zum prüfen...
Code
def check_tv():
try:
tvip = os.environ['tv_ip']
tvport = os.environ['tv_port']
except:
return False
if subprocess.call(["nc", "-z", "-w", "1", tvip, tvport]):
return False
else:
return True
Alles anzeigen
und die if-Abfrage um check_tv() ergänzen...
Code
# attach frontend if vdr has not been started for a timer or an acpi
# wakeup event or tv is offline
if check_tv() and settings.manualstart == True and settings.acpi_wakeup != True and settings.conf['start_always_detached'] == '0':
resume(frontend.status())
S.