18 lines
394 B
Python
18 lines
394 B
Python
class WaitState:
|
|
def waitMsg(self, context):
|
|
data = context.connection.receive()
|
|
if not data:
|
|
print("[WaitState] : Connection lost with camera at {}:{}".format(context.connection.addr, context.connection.port))
|
|
context.close()
|
|
return None
|
|
else:
|
|
return data
|
|
|
|
|
|
def handle(self, context):
|
|
raise NotImplementedError()
|
|
|
|
|
|
def tic(self, context):
|
|
raise NotImplementedError()
|