added file player source
See “file_player” in config. Requires updated csdr with —bigendian option to convert_s16_f and iq_swap_ff. Also requires xzcat to be installed. Sample files in new samples/ subdirectory. If larger sample file is too big for distro remove it and reconfigure to use smaller one (which will wrap around more quickly).
This commit is contained in:
9
owrx/source/file_player.py
Normal file
9
owrx/source/file_player.py
Normal file
@ -0,0 +1,9 @@
|
||||
from .direct import DirectSource
|
||||
|
||||
class FilePlayerSource(DirectSource):
|
||||
def getCommandMapper(self):
|
||||
cmd = "(while true; do xzcat {p[file]}; done) | csdr flowcontrol $(csdr ={p[samp_rate]}*{p[bytes_per_sample]}*1.05) 20 | {p[format_conversion]}"
|
||||
return super().getCommandMapper().setBase(cmd)
|
||||
|
||||
def getEventNames(self):
|
||||
return super().getEventNames() + ["file", "bytes_per_sample", "format_conversion"]
|
Reference in New Issue
Block a user