usb_claim_interface error -6

Main forum to discuss RTL-SDR related topics.
Post Reply
oz1sej
Posts: 6
Joined: Sun Feb 12, 2017 5:39 pm

usb_claim_interface error -6

Post by oz1sej » Mon Feb 10, 2020 4:32 pm

I've installed rtl-sdr on a raspberry pi. Now, since I'm going to use it remotely, I want to use Stephen Blinick's ring buffer rewrite of rtl_tcp as detailed here: https://www.rtl-sdr.com/significantly-i ... g-buffers/

Unfortunately, I started out by installing rtl-sdr. Now, when I run my local copy of Stephen's rtl-sdr, I get

Code: Select all

Kernel driver is active, or device is claimed by second instance of librtlsdr.
In the first case, please either detach or blacklist the kernel module
(dvb_usb_rtl28xxu), or enable automatic detaching at compile time.

usb_claim_interface error -6
Failed to open rtlsdr device #0.
I've tried removing the official rtl-sdr, but that didn't change anything.

What does it mean that the device is claimed by a second instance of librtlsdr? How do I control, which instance of librtlsdr can claim the device?

Aussie Susan
Posts: 51
Joined: Sun Jul 31, 2016 1:55 am

Re: usb_claim_interface error -6

Post by Aussie Susan » Tue Feb 11, 2020 2:33 am

Did you blacklist the RTL-SDR to stop the default kernel driver from grabbing the interface (the first thing the error message mentioned)?
I also got this message when I accidentally tried to run two of the RTL-SDR apps at the same time.
Susan

oz1sej
Posts: 6
Joined: Sun Feb 12, 2017 5:39 pm

Re: usb_claim_interface error -6

Post by oz1sej » Tue Feb 11, 2020 7:11 am

No I didn't - maybe I should try that! The reasons I didn't were 1. I don't know how to, 2. I was afraid that the two copies of rtl-sdr would use the same kernel module, so if I blacklisted it, the other copy wouldn't work either.

Would you happen to know how to blacklist a kernel module?

oz1sej
Posts: 6
Joined: Sun Feb 12, 2017 5:39 pm

Re: usb_claim_interface error -6

Post by oz1sej » Tue Feb 11, 2020 9:26 am

Found out - it works. Thank you! :)

Aussie Susan
Posts: 51
Joined: Sun Jul 31, 2016 1:55 am

Re: usb_claim_interface error -6

Post by Aussie Susan » Wed Feb 12, 2020 1:28 am

Glad to hear it.
The things that you seemed to be misunderstanding was the word 'driver'. This is a part of the Linux kernel and,unless you blacklist it, it will grab the RTL-SDR interface and expect that all of the user software will use it to talk to the device.
This works in exactly the same way as a disk driver - you talk to it and it takes care of the low level details that vary from one disk type to another.
In this case you don't want that driver to be running.
Susan

cadetali007
Posts: 4
Joined: Sat Jan 02, 2021 4:11 am

Re: usb_claim_interface error -6

Post by cadetali007 » Sat Jan 02, 2021 4:13 am

oz1sej wrote:
Tue Feb 11, 2020 9:26 am
Found out - it works. Thank you! :)
hello
i am facing the same problem..
please share the solution..
best regards

cadetali007
Posts: 4
Joined: Sat Jan 02, 2021 4:11 am

Re: usb_claim_interface error -6

Post by cadetali007 » Sat Jan 02, 2021 5:42 am

Aussie Susan wrote:
Tue Feb 11, 2020 2:33 am
Did you blacklist the RTL-SDR to stop the default kernel driver from grabbing the interface (the first thing the error message mentioned)?
I also got this message when I accidentally tried to run two of the RTL-SDR apps at the same time.
Susan
hello
facing same issue .plzz share the solution
best regards

HakimJacob
Posts: 1
Joined: Mon Jan 04, 2021 3:35 pm

Re: usb_claim_interface error -6

Post by HakimJacob » Mon Jan 04, 2021 4:45 pm

Hi.... you may want to enable Debug inside libusb-win32 and use DebugView to debug the error. By the way, I am not so sure if VC++ plays a part in the error or not. I have not used it with libusb-win32. I kind of remember there were reports that VC++ might be the problem.

Instruction to use DebugView with libusb-win32.
Three steps to capture the debug message.
1) add usb_set_debug(255) to your code after the call of usb_init()
2) download DebugView from microsoft.com

adamlayne
Posts: 1
Joined: Tue Jan 12, 2021 3:05 am
Contact:

Re: usb_claim_interface error -6

Post by adamlayne » Tue Jan 12, 2021 3:07 am

I have the same issue. Any solution?

Post Reply