Removing dependency on SoapySDRUtil. Using new owrx-connector now.

This commit is contained in:
Marat Fayzullin 2024-01-31 19:34:44 -05:00
parent 5e3f8c91a2
commit ccb5e049a1
2 changed files with 5 additions and 10 deletions

5
debian/control vendored
View File

@ -17,9 +17,8 @@ Architecture: all
Depends: adduser, Depends: adduser,
python3 (>= 3.5), python3 (>= 3.5),
python3-pkg-resources, python3-pkg-resources,
owrx-connector (>= 0.6), owrx-connector (>= 0.6.5),
python3-csdr (>= 0.18.17), python3-csdr (>= 0.18.18),
soapysdr-tools,
${python3:Depends}, ${python3:Depends},
${misc:Depends} ${misc:Depends}
Recommends: python3-digiham (>= 0.6), Recommends: python3-digiham (>= 0.6),

View File

@ -308,14 +308,10 @@ class FeatureDetector(object):
def _has_soapy_driver(self, driver): def _has_soapy_driver(self, driver):
try: try:
process = subprocess.Popen(["SoapySDRUtil", "--info"], stdout=subprocess.PIPE, stderr=subprocess.DEVNULL) process = subprocess.Popen(["soapy_connector", "--listdrivers"], stdout=subprocess.PIPE, stderr=subprocess.DEVNULL)
factory_regex = re.compile(r"^Available factories\\.\\.\\. ?(.*)$")
drivers = [] drivers = [line.decode().strip() for line in process.stdout]
for line in process.stdout: process.wait(1)
matches = factory_regex.match(line.decode())
if matches:
drivers = [s.strip() for s in matches.group(1).split(", ")]
return driver in drivers return driver in drivers
except FileNotFoundError: except FileNotFoundError: