let the client initiate the dsp again
This commit is contained in:
parent
34414de4e5
commit
71a2352d2b
@ -249,12 +249,17 @@ DemodulatorPanel.prototype.updateButtons = function() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
DemodulatorPanel.prototype.setCenterFrequency = function(center_freq) {
|
DemodulatorPanel.prototype.setCenterFrequency = function(center_freq) {
|
||||||
if (this.center_freq === center_freq) {
|
var me = this;
|
||||||
return;
|
if (me.centerFreqTimeout) {
|
||||||
|
clearTimeout(me.centerFreqTimeout);
|
||||||
|
me.centerFreqTimeout = false;
|
||||||
}
|
}
|
||||||
this.stopDemodulator();
|
this.centerFreqTimeout = setTimeout(function() {
|
||||||
this.center_freq = center_freq;
|
me.stopDemodulator();
|
||||||
this.startDemodulator();
|
me.center_freq = center_freq;
|
||||||
|
me.startDemodulator();
|
||||||
|
me.centerFreqTimeout = false;
|
||||||
|
}, 50);
|
||||||
};
|
};
|
||||||
|
|
||||||
DemodulatorPanel.prototype.parseHash = function() {
|
DemodulatorPanel.prototype.parseHash = function() {
|
||||||
|
@ -133,9 +133,6 @@ 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:
|
||||||
@ -186,7 +183,6 @@ 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:
|
||||||
@ -278,8 +274,6 @@ class OpenWebRxReceiverClient(OpenWebRxClient, SdrSourceEventClient):
|
|||||||
self.__sendProfiles()
|
self.__sendProfiles()
|
||||||
|
|
||||||
self.sdr.addSpectrumClient(self)
|
self.sdr.addSpectrumClient(self)
|
||||||
if self.dspState:
|
|
||||||
self.startDsp()
|
|
||||||
|
|
||||||
def handleNoSdrsAvailable(self):
|
def handleNoSdrsAvailable(self):
|
||||||
self.write_sdr_error("No SDR Devices available")
|
self.write_sdr_error("No SDR Devices available")
|
||||||
|
Loading…
Reference in New Issue
Block a user