only re-start dsp if dsp has been started before
This commit is contained in:
parent
ff34e793a0
commit
34414de4e5
@ -133,6 +133,9 @@ class OpenWebRxReceiverClient(OpenWebRxClient, SdrSourceEventClient):
|
|||||||
self.configSub = None
|
self.configSub = None
|
||||||
self.connectionProperties = {}
|
self.connectionProperties = {}
|
||||||
|
|
||||||
|
# to be able to remember if the dsp has been started before
|
||||||
|
self.dspState = False
|
||||||
|
|
||||||
try:
|
try:
|
||||||
ClientRegistry.getSharedInstance().addClient(self)
|
ClientRegistry.getSharedInstance().addClient(self)
|
||||||
except TooManyClientsException:
|
except TooManyClientsException:
|
||||||
@ -183,6 +186,7 @@ class OpenWebRxReceiverClient(OpenWebRxClient, SdrSourceEventClient):
|
|||||||
if "type" in message:
|
if "type" in message:
|
||||||
if message["type"] == "dspcontrol":
|
if message["type"] == "dspcontrol":
|
||||||
if "action" in message and message["action"] == "start":
|
if "action" in message and message["action"] == "start":
|
||||||
|
self.dspState = True
|
||||||
self.startDsp()
|
self.startDsp()
|
||||||
|
|
||||||
if "params" in message:
|
if "params" in message:
|
||||||
@ -274,6 +278,7 @@ class OpenWebRxReceiverClient(OpenWebRxClient, SdrSourceEventClient):
|
|||||||
self.__sendProfiles()
|
self.__sendProfiles()
|
||||||
|
|
||||||
self.sdr.addSpectrumClient(self)
|
self.sdr.addSpectrumClient(self)
|
||||||
|
if self.dspState:
|
||||||
self.startDsp()
|
self.startDsp()
|
||||||
|
|
||||||
def handleNoSdrsAvailable(self):
|
def handleNoSdrsAvailable(self):
|
||||||
|
Loading…
Reference in New Issue
Block a user