Closed rherban closed 2 months ago
Yeah, I'm not downloading that.
It's malware and mediafire already flagged and removed it. It seems there is a surge of these malware attacks on GitHub. Only yesterday there was another malware post on SoapySDR.
Interestingly the malware poster seems to be a recent target of malware himself: https://github.com/contentauth/c2pa-c/issues/17
To your question: is it possible that this is a race condition where you still have the usb descriptor open? Those Adding and Removing lines enumerate USB devices in your codes, right?
Yes, the adding and removing lines are from my code.
I have a periodic call to SoapySDR.Device.enumerate()
and stash that into an array and subsequent removal when the device is unplugged, hence the issues I'm opening. But if Soapy still thinks a device is attached, it throws a wrench into the works.
That sounds like safe operations and if you are not accessing USB yourself this error should not happen. It might be that the Python wrapper somehow keeps the device open, but for that there would need to be a make device somewhere not just enumerate. I'll try to test this in C.
I can confirm that this happens in plain C too.
The [WARNING] Unable to scan local: -19
just means a backend is not available (e.g. "local:" on MacOS).
The ERROR: Unable to claim interface
happens when the Device is still open (e.g. SoapySDRDevice_make()
but no matching SoapySDRDevice_unmake()
before a rescan). But that's limited to the usb: backend, the ip: backend should still work, if you have that available.
I'll get rid of the local backend as I don't think I have a real use for that.
But for unmake()
, I'm not sure how to do that in Python. None of the examples do an explicit unmake, they just deactivate and close the stream.
Can you provide an example?
As far as I can see close()
will also unmake the device and del
will close()
. So sdr.close()
or del sdr
should do. https://github.com/pothosware/SoapySDR/blob/master/swig/python/SoapySDR.in.i#L410
Debian 9 on Beaglebone Black
Soapy bits Lib Version: v0.8.1-gbb33b2d2 API Version: v0.8.200 ABI Version: v0.8-3
SoapyPlutoSDR 0.2.2-03b5ae2-cache (Removing the cache results from issue #66 )
libiio 0.25 Built with:
../../cmake-3.27.4/bin/cmake ../ -DCPP_BINDINGS=ON -DPYTHON_BINDINGS=ON -WITH_USB_BACKEND=ON -WITH_LOCAL_BACKEND=ON
And also tried (per recommendations in #50 ):../../cmake-3.27.4/bin/cmake ../ -DCPP_BINDINGS=ON -DPYTHON_BINDINGS=ON -DWITH_USB_BACKEND=ON -DWITH_LOCAL_BACKEND=NO -DWITH_IIOD=NO
But it still fails to load the device:
(The
Adding
andRemoving
lines are from my code)dmesg:
SoapySDRUtil:
If I revert to SoapyPlutSDR 0.2.1 it works as expected, as evidenced on another beaglebone here: