allow only limited parameters to be set on the dsp

This commit is contained in:
Jakob Ketterl 2021-01-24 20:10:37 +01:00
parent 8710a2a1d3
commit 862a251295

View File

@ -28,7 +28,7 @@ class DspManager(csdr.output, SdrSourceEventClient):
self.props = PropertyStack() self.props = PropertyStack()
# local demodulator properties not forwarded to the sdr # local demodulator properties not forwarded to the sdr
self.props.addLayer(0, PropertyLayer().filter( self.localProps = PropertyLayer().filter(
"output_rate", "output_rate",
"hd_output_rate", "hd_output_rate",
"squelch_level", "squelch_level",
@ -39,7 +39,8 @@ class DspManager(csdr.output, SdrSourceEventClient):
"mod", "mod",
"secondary_offset_freq", "secondary_offset_freq",
"dmr_filter", "dmr_filter",
)) )
self.props.addLayer(0, self.localProps)
# properties that we inherit from the sdr # properties that we inherit from the sdr
self.props.addLayer(1, self.sdrSource.getProps().filter( self.props.addLayer(1, self.sdrSource.getProps().filter(
"audio_compression", "audio_compression",
@ -177,7 +178,7 @@ class DspManager(csdr.output, SdrSourceEventClient):
self.setProperty(k, v) self.setProperty(k, v)
def setProperty(self, prop, value): def setProperty(self, prop, value):
self.props[prop] = value self.localProps[prop] = value
def getClientClass(self): def getClientClass(self):
return SdrSource.CLIENT_USER return SdrSource.CLIENT_USER