mirror of
https://github.com/ha7ilm/openwebrx.git
synced 2026-04-04 22:17:34 +00:00
switch hackrf to soapy
This commit is contained in:
parent
e0648d63ad
commit
e90973bcd4
3 changed files with 15 additions and 41 deletions
|
|
@ -1,23 +1,8 @@
|
|||
from .direct import DirectSource
|
||||
from .soapy import SoapyConnectorSource
|
||||
from owrx.command import Option
|
||||
import time
|
||||
|
||||
|
||||
class HackrfSource(DirectSource):
|
||||
def getCommandMapper(self):
|
||||
return super().getCommandMapper().setBase("hackrf_transfer").setMappings(
|
||||
{
|
||||
"samp_rate": Option("-s"),
|
||||
"tuner_freq": Option("-f"),
|
||||
"rf_gain": Option("-g"),
|
||||
"lna_gain": Option("-l"),
|
||||
"rf_amp": Option("-a"),
|
||||
"ppm": Option("-C"),
|
||||
}
|
||||
).setStatic("-r-")
|
||||
|
||||
def getFormatConversion(self):
|
||||
return ["csdr convert_s8_f"]
|
||||
|
||||
def sleepOnRestart(self):
|
||||
time.sleep(1)
|
||||
class HackrfSource(SoapyConnectorSource):
|
||||
def getDriver(self):
|
||||
return "hackrf"
|
||||
Loading…
Add table
Add a link
Reference in a new issue