add direct_sampling mapping for rtl_sdr

This commit is contained in:
Jakob Ketterl
2020-04-01 23:37:40 +02:00
parent 78704885d7
commit 70ba0cd618
3 changed files with 9 additions and 6 deletions

View File

@ -1,14 +1,15 @@
from .connector import ConnectorSource
from owrx.command import Flag
from owrx.command import Flag, Option
class RtlSdrSource(ConnectorSource):
def getCommandMapper(self):
return super().getCommandMapper().setBase("rtl_connector").setMappings(
{
"bias_tee": Flag("-b")
}
return (
super()
.getCommandMapper()
.setBase("rtl_connector")
.setMappings({"bias_tee": Flag("-b"), "direct_sampling": Option("-e")})
)
def getEventNames(self):
return super().getEventNames() + ["bias_tee"]
return super().getEventNames() + ["bias_tee", "direct_sampling"]