xmikos / qspectrumanalyzer

Spectrum analyzer for multiple SDR platforms (PyQtGraph based GUI for soapy_power, hackrf_sweep, rtl_power, rx_power and other backends)
GNU General Public License v3.0
1.22k stars 246 forks source link

qspectrumanalyzer hangs after a few seconds and only shows noise #92

Open marcoboehrs opened 3 years ago

marcoboehrs commented 3 years ago

Qspectrumanalyzer runs hackrf_sweep with the following parameters (happens with other frequency ranges too): hackrf_sweep -f 5120:5500 -B -w 312500 -l 0 -g 4

and after i few seconds i get:

Traceback (most recent call last):
  File "/usr/local/lib/python3.8/dist-packages/qspectrumanalyzer/backends/hackrf_sweep.py", line 163, in run
    self.parse_output(buf)
  File "/usr/local/lib/python3.8/dist-packages/qspectrumanalyzer/backends/hackrf_sweep.py", line 128, in parse_output
    self.databuffer["y"].append(data[i])
AttributeError: 'numpy.ndarray' object has no attribute 'append'
421 total sweeps completed, 21.30 sweeps/second
422 total sweeps completed, 21.30 sweeps/second
423 total sweeps completed, 21.30 sweeps/second
425 total sweeps completed, 21.34 sweeps/second
425 total sweeps completed, 21.29 sweeps/second
427 total sweeps completed, 21.34 sweeps/second
428 total sweeps completed, 21.33 sweeps/second
429 total sweeps completed, 21.33 sweeps/second
430 total sweeps completed, 21.33 sweeps/second
430 total sweeps completed, 21.27 sweeps/second
430 total sweeps completed, 21.22 sweeps/second

Couldn't transfer any data for one second.

Exiting... hackrf_is_streaming() result: HACKRF_TRUE (1)
Total sweeps: 430 in 20.26419 seconds (21.22 sweeps/second)

If i run the command hackrf_sweep -f 5120:5500 -B -w 312500 -l 0 -g 4 standalone in bash, it runs forever

hackrf_info output:

hackrf_info version: git-f202160
libhackrf version: git-f202160 (0.5)
Found HackRF
Index: 0
Serial number: 0000000000000000XXX....
Board ID Number: 2 (HackRF One)
Firmware Version: git-f202160 (API:1.04)
Part ID Number: 0xa000cb3c 0x004c4f67

OS: Ubuntu 20.04 LTS qspectrumanalyzer 2.2.0