I'm trying to make a Python script to detect if there is motion on set-top box or not. When stb is off the script connect the stb but when de cicle kicks in again this error appears
gstrtspsrc.c(5590): gst_rtspsrc_send (): /GstPipeline:pipeline1/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source:
Stream Not Found
------------------------------------------------------------------------------------------------------------------------------------------------------------
but i have image streaming...
this is the part of my code that makes the loop:
------------------------------------------------------------------------------------------------------------------------------------------------------------
def _make_test(self):
validated = False
while not validated:
print "WHILE ENTRY ---> " + str(validated)
try:
for motion_result in detect_motion():
if motion_result.motion is False:
print "#1 MOTION" + " " + str(motion_result)
self.remote.send_key_once(MeoRemote.BTN_5)
time.sleep(4)
for motion_result_2 in detect_motion():
if motion_result_2.motion is True:
validated = True
print "#2 MOTION" + " " + str(motion_result_2) + "\n" + "VALIDATED--> " + str(validated)
self.remote.send_key_once(MeoRemote.BTN_1)
time.sleep(4)
break
else:
print "NO MOTION ON SCREEN"
break
else:
self.remote.send_key_once(MeoRemote.BTN_1)
validated = True
time.sleep(4)
print "#3 MOTION" + " " + str(motion_result) + "\n" "VALIDATED--> " + str(validated)
break
except UITestError as error_stb_off:
validated = False
print "STB IS OFF!!!! ERROR: " + " " + str(error_stb_off) + "\n" + "Turning ON..." + "\n" + "VALIDATED--> " + str(validated)
self.remote.send_key_once(MeoRemote.POWER)
time.sleep(10)
break
return validated