aboutsummaryrefslogtreecommitdiffstats
path: root/host/examples
diff options
context:
space:
mode:
authorLars Amsel <lars.amsel@ni.com>2021-10-07 17:19:06 +0200
committerAaron Rossetto <aaron.rossetto@ni.com>2021-10-11 10:43:10 -0700
commit0fa4f7179b952c51137177b191c67501051ade81 (patch)
tree9f20f5a111c0f74a60a897da8a6a050c2618e498 /host/examples
parent5e093c1e4834115036a1352a192cc69f43e19feb (diff)
downloaduhd-0fa4f7179b952c51137177b191c67501051ade81.tar.gz
uhd-0fa4f7179b952c51137177b191c67501051ade81.tar.bz2
uhd-0fa4f7179b952c51137177b191c67501051ade81.zip
bug: fix channel indexing when reading USRP power
the USRP power meter will only receive from a single channel which is configured by the argument parameter. The streamer receive data will therefor alwalys have a single channel. So do not index with chan when passing the streamer to uhd.dsp.signals.get_usrp_power.
Diffstat (limited to 'host/examples')
-rw-r--r--host/examples/python/usrp_power_meter.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/host/examples/python/usrp_power_meter.py b/host/examples/python/usrp_power_meter.py
index ffda7d32e..fc59ae689 100644
--- a/host/examples/python/usrp_power_meter.py
+++ b/host/examples/python/usrp_power_meter.py
@@ -123,7 +123,7 @@ def main():
while RUN:
try:
power_dbfs = uhd.dsp.signals.get_usrp_power(
- streamer, num_samps=int(args.samps_per_est), chan=chan)
+ streamer, num_samps=int(args.samps_per_est))
except RuntimeError:
# This is a hack b/c the signal handler is not gracefully handling
# SIGINT