2021-09-07 15:31:32 +00:00
|
|
|
from csdr.chain.demodulator import BaseDemodulatorChain, FixedIfSampleRateChain, FixedAudioRateChain
|
2021-09-08 11:48:11 +00:00
|
|
|
from pycsdr.modules import Convert, Downmix
|
2021-09-07 15:31:32 +00:00
|
|
|
from pycsdr.types import Format
|
|
|
|
from owrx.drm import DrmModule
|
|
|
|
|
|
|
|
|
|
|
|
class Drm(BaseDemodulatorChain, FixedIfSampleRateChain, FixedAudioRateChain):
|
|
|
|
def __init__(self):
|
2021-09-08 11:48:11 +00:00
|
|
|
workers = [Convert(Format.COMPLEX_FLOAT, Format.COMPLEX_SHORT), DrmModule(), Downmix()]
|
2021-09-07 15:31:32 +00:00
|
|
|
super().__init__(workers)
|
|
|
|
|
2021-09-08 11:48:11 +00:00
|
|
|
def supportsSquelch(self) -> bool:
|
|
|
|
return False
|
|
|
|
|
2021-09-07 15:31:32 +00:00
|
|
|
def getFixedIfSampleRate(self) -> int:
|
|
|
|
return 48000
|
|
|
|
|
|
|
|
def getFixedAudioRate(self) -> int:
|
|
|
|
return 48000
|