~ubuntu-branches/ubuntu/precise/gnuradio/precise

« back to all changes in this revision

Viewing changes to usrp/host/lib/legacy/README_OSX

  • Committer: Bazaar Package Importer
  • Author(s): Kamal Mostafa
  • Date: 2010-03-13 07:46:01 UTC
  • mfrom: (2.1.2 sid)
  • Revision ID: james.westby@ubuntu.com-20100313074601-zjsa893a87bozyh7
Tags: 3.2.2.dfsg-1ubuntu1
* Fix build for Ubuntu lucid (LP: #260406)
  - add binary package dep for libusrp0, libusrp2-0: adduser
  - debian/rules clean: remove pre-built Qt moc files

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
USRP Darwin Fast USB Changes
 
2
Version 0.2 of 2006-04-27
 
3
Michael Dickens <mdickens @at@ nd .dot. edu>
 
4
 
 
5
The files included in this archive are:
 
6
 
 
7
circular_buffer.h
 
8
circular_linked_list.h
 
9
darwin_libusb.h
 
10
fusb_darwin.cc
 
11
fusb_darwin.h
 
12
mld_threads.h
 
13
 
 
14
These files allow GNURadio code for Darwin / MaxOS X to talk to the
 
15
USRP via USB 2.0 at rates up to around 30 Mega-Bytes/sec (MBps), up
 
16
from 4-8 MBps without the changes.
 
17
 
 
18
I implemented the buffering myself; there are probably GR buffers
 
19
available which would do the work but as this is "beta" software it's
 
20
a good place to start.  Speed improvements are made by porting
 
21
LIBUSB's non-true async bulk read and write functions into USRP's
 
22
"fusb", and upgrading them to handle -true- async transfers.
 
23
Unfortunately, the easiest way to do this is to spawn a thread or 2 to
 
24
handle the "async" part of the transfers.  This implementation uses
 
25
Darwin's pthreads to do the work for mutexes, conditions, and threads.
 
26
Previous implementations (0.1 and before) used "omni_threads" as
 
27
provided by gnuradio-core, which caused issues with compiling and
 
28
execution ... I'm glad that this is no longer the case.
 
29
 
 
30
As far as I have tested, there is no way to improve the throughput to
 
31
32+ MBps without moving into Darwin's "port"s ... a kernel-level data
 
32
transport method with a user/application layer for USB-specific
 
33
functions.  Unfortunately, Apple's documentation for these "port"s is
 
34
minimal; I have learned more from reading the Darwin source code
 
35
< http://darwinsource.opendarwin.org/ > than by reading Apple's
 
36
documents!  This would also require -not- using LIBUSB, of which the
 
37
removal from the rest of the USRP code would be potentially tedious.
 
38
 
 
39
If you run into issues either compiling or testing the USRP on
 
40
OSX, please send me a note.
 
41
 
 
42
(1) Go through the bootstrap, configure, compile, and install as
 
43
usual (e.g. see < http://www.nd.edu/~mdickens/GNURadio/ > for my
 
44
usual).
 
45
 
 
46
(2) from .../usrp/host/apps :  run the scripts
 
47
++++++++++++++++
 
48
./test_usrp_standard_tx
 
49
./test_usrp_standard_rx
 
50
++++++++++++++++
 
51
 
 
52
For -all- systems I've tested on thus far, both of these return
 
53
exactly 41 overruns / underruns, and -most- systems start out with a
 
54
stalled pipe.  This stall comes in a usb_control function call to
 
55
LIBUSB; one would have to change the LIBUSB code to handle this issue.
 
56
 
 
57
(3) from gr-build/gnuradio-examples/python/usrp :
 
58
++++++++++++++++
 
59
./benchmark_usb.py
 
60
++++++++++++++++
 
61
 
 
62
(4) If you get to here, the try doing the FM receiver (gui or not).
 
63
If that sounds correct, then the USB is working.  Yay!
 
 
b'\\ No newline at end of file'