Hi,
I need to get a few traffic data bytes ~ 16 B from my dongle. libusb's bulk transfer and therefore rtlsdr_read_sync, will fail with -8 if used with less than 1024 B. Can anyone think of another way to read them? (async also uses libusb's fill_bulk_transfer :-()
I could possibly use rtlsdr_read_array, except that i don't know the block and address that I need to use for traffic data :-(
Thanks, Nikos
On Mon, 13 Jan 2014 23:26:43 +0200 Nikos Balkanas nikos.balkanas@eyeonix.com wrote:
I need to get a few traffic data bytes ~ 16 B from my dongle. libusb's bulk transfer and therefore rtlsdr_read_sync, will fail with -8 if used with less than 1024 B. Can anyone think of another way to read them? (async also uses libusb's fill_bulk_transfer :-()
AFAIK, usbfs has no such limitation inherently and in fact I have transferred arbitrary amounts, for example in printer drivers. So you can go directly to usbfs if that helps.
-- Pete
What function from the libusb API are you using for the read?
TIA, Nikos
On Tue, Jan 14, 2014 at 12:08 AM, Pete Zaitcev zaitcev@kotori.zaitcev.uswrote:
On Mon, 13 Jan 2014 23:26:43 +0200 Nikos Balkanas nikos.balkanas@eyeonix.com wrote:
I need to get a few traffic data bytes ~ 16 B from my dongle. libusb's
bulk
transfer and therefore rtlsdr_read_sync, will fail with -8 if used with less than 1024 B. Can anyone think of another way to read them? (async
also
uses libusb's fill_bulk_transfer :-()
AFAIK, usbfs has no such limitation inherently and in fact I have transferred arbitrary amounts, for example in printer drivers. So you can go directly to usbfs if that helps.
-- Pete
On Tue, 14 Jan 2014 01:14:26 +0200 Nikos Balkanas nikos.balkanas@eyeonix.com wrote:
What function from the libusb API are you using for the read?
I wrote usbfs, not libusb. Of course it's no use for you if you're on OSX, but it works on Linux. See here: http://people.redhat.com/zaitcev/linux/canonf50.tar.gz
-- Pete
You are using ioctl to talk directly to the kernel driver, bypassing libusb. Maybe it is time to download libusb sources and check it out. The call I am doing is run upto 10000x. It is part of a tunning scanner ;-)
Thnx, Nikos
On Tue, Jan 14, 2014 at 3:10 AM, Pete Zaitcev zaitcev@kotori.zaitcev.uswrote:
On Tue, 14 Jan 2014 01:14:26 +0200 Nikos Balkanas nikos.balkanas@eyeonix.com wrote:
What function from the libusb API are you using for the read?
I wrote usbfs, not libusb. Of course it's no use for you if you're on OSX, but it works on Linux. See here: http://people.redhat.com/zaitcev/linux/canonf50.tar.gz
-- Pete
Hi,
On 13.01.2014 22:26, Nikos Balkanas wrote:
I need to get a few traffic data bytes ~ 16 B from my dongle. libusb's bulk transfer and therefore rtlsdr_read_sync, will fail with -8 if used with less than 1024 B. Can anyone think of another way to read them? (async also uses libusb's fill_bulk_transfer :-()
Read more and throw the rest away, what's the issue with that? But what do you need *16 bytes* for? That's just 62.5µs of samples...
I could possibly use rtlsdr_read_array, except that i don't know the block and address that I need to use for traffic data :-(
Those functions trigger control transfers and have nothing to do with the actual I/Q samples at all, so no, you can't use them.
I have no idea what you're trying to accomplish, but it seems to me whatever it is, you are completely off track.
Regards, Steve
On Tue, Jan 14, 2014 at 1:11 AM, Steve Markgraf steve@steve-m.de wrote:
Hi,
On 13.01.2014 22:26, Nikos Balkanas wrote:
I need to get a few traffic data bytes ~ 16 B from my dongle. libusb's bulk transfer and therefore rtlsdr_read_sync, will fail with -8 if used with less than 1024 B. Can anyone think of another way to read them? (async also uses libusb's fill_bulk_transfer :-()
Read more and throw the rest away, what's the issue with that? But what do you need *16 bytes* for? That's just 62.5盜 of samples...
Performance is very important, Call is repeated many times. BTW that's what I am using right now, but looking for better.
I could possibly use rtlsdr_read_array, except that i don't know the block and address that I need to use for traffic data :-(
Those functions trigger control transfers and have nothing to do with the actual I/Q samples at all, so no, you can't use them.
I have no idea what you're trying to accomplish, but it seems to me whatever it is, you are completely off track.
I am not. Control transfers are fine with me. There must be a memory region where traffic I/O takes place.
Regards, Steve
Hi,
On 14.01.2014 00:20, Nikos Balkanas wrote:
Performance is very important, Call is repeated many times. BTW that's what I am using right now, but looking for better.
With the approach you're taking you're going to have no performance whatsoever, please learn about how USB bulk transfers work, especially about the size of URBs.
I am not. Control transfers are fine with me. There must be a memory region where traffic I/O takes place.
There is no such 'memory region', because the FIFO of the RTL2832 has it's own memory, which is completely outside of the 8051 address space and thus cannot be accessed with control transfers.
Anyway, I'm out of the discussion.
Regards, Steve