send failure message to client

This commit is contained in:
Jakob Ketterl 2019-10-12 20:46:32 +02:00
parent fce8c294d3
commit 70d8fe82b3
2 changed files with 4 additions and 0 deletions

View File

@ -266,6 +266,9 @@ class OpenWebRxReceiverClient(Client):
def write_aprs_data(self, data):
self.send({"type": "aprs_data", "value": data})
def write_sdr_error(self, message):
self.send({"type": "sdr_error", "value": message})
class MapConnection(Client):
def __init__(self, conn):

View File

@ -654,6 +654,7 @@ class DspManager(csdr.output):
def onSdrFailed(self):
logger.debug("received onSdrFailed, shutting down DspSource")
self.dsp.stop()
self.handler.write_sdr_error("sdr failed")
class CpuUsageThread(threading.Thread):