@@ -24,7 +24,7 @@ def test_sdr(
2424 ss_iq_path = "./ss_iq" ,
2525 ss_power_path = "./ss_power" ,
2626 check_freq = 401500000 ,
27- timeout = 5
27+ timeout = 20
2828):
2929 """
3030 Test the prescence / functionality of a SDR.
@@ -60,8 +60,8 @@ def test_sdr(
6060 # if not os.path.isfile('tune'):
6161 # logging.critical("Could not find KA9Q-Radio 'tune' binary! This may need to be compiled and installed.")
6262 # return False
63- # if not os.path.isfile('pcmcat '):
64- # logging.critical("Could not find KA9Q-Radio 'pcmcat ' binary! This may need to be compiled and installed.")
63+ # if not os.path.isfile('pcmrecord '):
64+ # logging.critical("Could not find KA9Q-Radio 'pcmrecord ' binary! This may need to be compiled and installed.")
6565 # return False
6666 # TBD - whatever we need for spectrum use.
6767 # if not os.path.isfile('TBD'):
@@ -281,7 +281,8 @@ def get_sdr_iq_cmd(
281281 sdr_hostname = "" ,
282282 sdr_port = 5555 ,
283283 ss_iq_path = "./ss_iq" ,
284- scan = False
284+ scan = False ,
285+ channel_filter = None
285286):
286287 """
287288 Get a command-line argument to get IQ (signed 16-bit) from a SDR
@@ -303,7 +304,8 @@ def get_sdr_iq_cmd(
303304 Arguments for KA9Q SDR Server / SpyServer:
304305 sdr_hostname (str): Hostname of KA9Q Server
305306 sdr_port (int): Port number of KA9Q Server
306- scan (bool): Create unique SSRC for scan attempts
307+ scan (bool): Create unique SSRC for scan attempts (KA9Q Only)
308+ channel_filter (int/float): Set a high/lowpass frequency for a KA9Q channel.
307309
308310 Arguments for SpyServer Client:
309311 ss_iq_path (str): Path to spyserver IQ client utility.
@@ -361,9 +363,9 @@ def get_sdr_iq_cmd(
361363 return _cmd
362364
363365 if sdr_type == "KA9Q" :
364- _cmd = ka9q_get_iq_cmd (sdr_hostname , frequency , sample_rate , scan )
366+ _cmd = ka9q_get_iq_cmd (sdr_hostname , frequency , sample_rate , scan , channel_filter )
365367
366- if dc_block :
368+ if dc_block and ( "KA9Q" not in sdr_type ) :
367369 _cmd += _dc_remove
368370
369371 return _cmd
@@ -779,7 +781,6 @@ def get_power_spectrum(
779781 _ssrc = f"{ round (_center_freq / 1000 )} 03"
780782
781783 _powers_cmd = (
782- f"LANG=C " # temporary workaround for https://github.com/ka9q/ka9q-radio/pull/65#issuecomment-2480243690
783784 f"{ _timeout_cmd } { ka9q_powers_path } "
784785 f"{ sdr_hostname } "
785786 f"-f { _center_freq } "
0 commit comments