Exact Word Match
+ Home
+ Purchase
+ TPW Article Archives
+ Contact Us









Tim Ludy of Data Translation, invites you to reprint this article in your publication, ezine, or on your website.

This is a Free-Reprint article. The only requirements for publishing this article are:

  • You must leave the article and resource box unedited. You are not allowed to change our recommendations, nor are you allowed to change the context of the article.
  • You may not use this article in UCE (Unsolicited Commercial Email). Email distribution of this article MUST be opt-in email only.
  • You must forward a copy of the ezine or newsletter that contains the article inside to the author at: tim.ludy@thephantomwriters.com
  • If you post this article on a website, you MUST set any URL's in the body of the article and most especially in the Author's Resource Box as hyperlinks. You must also send us a copy of the URL where you have posted this article.

  • If you find any of the rules to be unsavory or unacceptable, please do not publish this article. While we are happy to make the content available to you for your own use, we must insist on having our rules and *Terms of Reprint* honored in full.

    Thank you for adhering to these four very simple rules.



    High-Performance Data Acquisition on USB
    Copyright © 2006, Tim Ludy

    A common belief among engineers is that, to get the best 
    performance, a PC based data acquisition module must plug into the 
    PCI bus. Properly implemented, however, a data acquisition module 
    can use the PC's USB 2.0 port to pump data into a PC as fast as 
    PCI-based cards. The keys to achieving this performance are a 
    hardware USB interface on the module and optimized driver 
    software for the host system.
    
    Because the Universal Serial Bus (USB) was originally developed 
    to replace lowspeed peripheral cabling, many engineers fail to 
    see its potential as a high performance data acquisition channel. 
    The original USB specification did offer only a modest bit rate, 
    but USB 2.0 handles 480 Mbits/sec, fast enough to handle 60 
    Mbyte/sec data streams. Even with the protocol reserving some 
    bandwidth for interrupts and control transfers, and the header 
    overhead on data packets, the bus can easily sustain more than 
    10 Mbytes/sec of continual data transfer. This is fast enough 
    to support extremely high performance data acquisition (DAQ) 
    hardware.
    
    Utilizing the USB as a data portal provides many advantages for 
    data acquisition (DAQ). For one, the external connector and 
    "plug-and-play" software installation of USB peripherals means 
    that users do not have to open their PC, then set-up and 
    configure the hardware in order to begin acquiring data. The USB-
    based DAQ module sets itself up upon installation. Addressing 
    and other potential resource utilization conflicts resolve 
    automatically.
    
    Software for handling the data also becomes simpler to implement. 
    The host system USB drivers separate data streams into logical 
    channels called "pipes." This means that the host system software 
    will automatically form a logical connection from a DAQ channel 
    to a destination within the application software, simplifying 
    software and hardware set-up. Applications simply need to 
    identify the logical pipe they wish to connect with and the 
    system software ensures that data travels to the right 
    destination. Application software does not need to know the 
    details of peripheral addressing, interrupt placement, or other 
    installation dependent parameters as it must for PCI plug-in 
    cards. The USB also has electronic advantages. The bus can power 
    the peripheral (within limits) so that the DAQ system does not 
    need its own power source. This further eases system installation 
    and use and has the added benefit of removing the sensitive A/D 
    converters and amplifiers from the electrically noisy environment 
    inside the PC's housing. Unlike PCI plug-in cards, a USB-based 
    DAQ module is easily shielded for achieving high bit-level 
    resolution. The benefits of USB operation are compelling for a 
    DAQ system, but implementing the system does require care in 
    order to ensure a high-bandwidth connection. Engineers often 
    assume that high data-rate systems should use the USB data 
    transfer mode with the highest raw bandwidth and least overhead 
    penalty: isochronous transfer. But isochronous transfers are a 
    "best-effort" channel. Data that suffers from errors cannot be 
    resent. The proper mode to use for DAQ on USB is the bulk 
    transfer mode.
    
    1). This mode supports the resending of corrupted packets, 
    ensuring data accuracy, and allows fairly large 512-byte blocks, 
    keeping overhead effects down.
    
    The drawback is that bulk transfers do not have guaranteed 
    timing. The USB host controller assigns bandwidth for bulk 
    transfers but reserves priority for interrupt and control 
    transfers. Thus, the bandwidth obtained by using bulk transfers 
    is an average - not a sustained - data rate while the DAQ module 
    needs to send data at a constant speed.
    
    There are two approaches to dealing with the uncertainty in the 
    instantaneous bandwidth available for bulk transfers. One is to 
    keep the data rate low in order to maximize the likelihood that 
    bandwidth available will always exceed the DAQ module's data 
    rate. This is the simpler approach, but results in severe 
    underutilization of USB's potential.
    
    The alternative approach is for the DAQ module to incorporate 
    FIFO buffering to hold data while waiting for the bus to become 
    available. Dual buffers are needed in the module - one to fill 
    while the other is emptying. The larger the buffers, the more 
    tolerant the module becomes of shifting bandwidth availability 
    and the closer its data rate can approach the average bandwidth 
    available.
    
    In addition to the FIFO buffering on the DAQ module, the software 
    drivers should allocate buffer space in the host system at the 
    receiving end. This decouples the host system's data processing 
    activity from the data acquisition so that neither activity can 
    delay or impede the other's performance.
    
    While FIFO buffering maximizes the DAQ module's ability to 
    utilize the available bulk transfer bandwidth, however, it is not 
    the only way to improve the achievable speed on the USB. The 
    module's USB interface hardware and latency in the host 
    controller software can seriously constrain achievable USB data 
    rates if not implemented with high performance in mind. For the 
    interface hardware, using a state-machine hardware controller 
    optimized for 512-byte transfers (the largest bulk transfer 
    packet) produces a much faster interface than the use of a 
    software-dependent USB microcontroller.
    
    On the host side, careful driver design can reduce latency by 
    speeding the host system's response to incoming USB data. The 
    traditional Windows drivers allocate buffer space in response to 
    an incoming USB transfer, taking many milliseconds getting ready 
    to receive data once the DAQ module declares data ready to send. 
    Drivers that are proactive instead of reactive, pre-allocating 
    buffer spaces of the right size can decrease host latency by an 
    order of magnitude. These are not simply theoretical suggestions. 
    Data Translation has achieved a data rate of 250k samples/sec on 
    12 simultaneous channels with its DT9836 USB data acquisition 
    module and 2M samples/sec on 2 simultaneous channels at with the 
    DT9832A. Experience has shown that the USB can provide reliable, 
    sustainable data rates as great as 10.9 Mbytes/sec, corresponding 
    to sample rates of 5.45M samples/sec. The potential exists to 
    take USB-based data acquisition to even higher levels with 
    additional buffering and driver optimization.
    
    But a high data rate is not all that is required of a high-
    performance DAQ module. Issues such as accuracy, aperture 
    uncertainty, and noise levels are equally important. Further, the 
    inclusion of additional capabilities such as digital I/O lines, 
    counter/timers, analog outputs, and quadrature encoders can 
    greatly increase the utility of a DAQ module. The DT9832 and 
    DT9836 series offer all of these features.
    
    Accuracy in a high-performance DAQ module has many facets. The 
    most obvious is the A/D converter's resolution. The Simultaneous 
    Series offer 16-bit A/D conversion: 2 channels at 2.0 MHz for 
    the DT9832A, 4 channels at 1.25 MHz for the DT9832, and 6 or 12 
    channels at 225 kHz for the DT9836. The modules are fabricated 
    with 12-layer boards, keeping the signal integrity intact and 
    typically achieving an ENOB (effective number of bits) rating 
    of greater then 14-bits.
    
    Accuracy also involves timing, however, especially in a multi-
    channel DAQ module. In order to properly compare and correlate 
    sampled signals it is important to know the relative timing of 
    samples from one channel to the next. Most DAQ systems use a 
    single A/D converter with a multiplexer front-end to handle 
    multiple channels. This results in each channel's signal being 
    sampled at a different time, forcing the use of interpolation to 
    bring the signal data into temporal alignment and resulting in 
    relative timing errors or phase noise. Ideally, the samples for 
    all channels should be made simultaneously to eliminate phase 
    noise.
    
    The DT9836 and DT9832 series modules do not use a multiplexer. 
    Each channel has its own track-and-hold stage with an independent 
    successive-approximation A/D converter (see Figure 4). The 
    converters use a common clock and the track-and-hold stages have 
    a common trigger, so that the modules offer true simultaneous 
    sampling. The channels have an aperture delay of 35 nsec with 
    uncertainty (aperture jitter) of 1 nsec, and channels are well 
    matched so that there is less than 5 nsec difference between 
    channels. This virtually eliminates phase noise in data.
    
    With sample rate, bit accuracy, and timing accuracy at high 
    levels, the availability of additional features is simply a 
    performance bonus. The Simultaneous Series offer these extras, as 
    shown in Figure 2. Each module includes two 16-bit D/A channels, 
    16 digital output channels, 16 digital input channels, two 32-bit 
    counter timers, and 3 quadrature encoders. The additional digital 
    I/O lines provide considerable flexibility for incorporating 
    functions such as time stamping, pattern recognition, and 
    synchronization with external events. The counter/timers offer a 
    convenient means of triggering test events while the quadrature 
    decoders simplify the use of the module with X/Y positioning and 
    rotation.
    
    Supporting these additional signal lines means that the data 
    channel must be fast enough to handle the additional signal and 
    control bits without impacting the module's sampling rate. The 
    USB is fast enough. It has proven that it can provide the needed 
    capacity, and offers significant ease-of-use benefits. There is 
    no longer a need to pry open a PC to assemble a high-performance 
    DAQ system. Simply plug one in to the USB port.
    
    For related images and graphs, see: 
    http://www.datx.com/white_papers/High-Performance-DAQ-on-USB-white-paper.pdf  
    



    Writer's Resource Box:
    Tim Ludy is a Product Marketing Manager with Data Translation. 
    Mr. Ludy graduated from Northeastern University with a degree 
    in Computer Science. http://www.datx.com email: tludy@datx.com




    More Articles Written by Tim Ludy

    Notice: thePhantomWriters.com / Article-Distribution.com played no part in creating this content.

    Our client has purchased thePhantomWriters.com / Article-Distribution.com Distribution Services, and we have distributed this article to over 6,000 publishers and webmasters. As part of this service, we offer this page and the Copy-and-Paste version of this article on autoresponder.



    Are you curious about where this article has been published? This article was first distributed on:
    Tue Mar 28 03:20:20 EST 2006


    Check out these links to get a real good idea. Keep in mind that these links will only show those websites who have posted the article and have been submitted the page to the respective search engines.
  • Google Results
  • All the Web Results
  • AltaVista Results
  • Yahoo! Results
  • MSN Results
  • Lycos Results
  • Wind Seek Results


  • The article on this page is Copyright © 2006, Tim Ludy
    You are not required to show the creative commons license
    notice when you reprint this work.


    Creative Commons License
    This work is licensed under a
    Creative Commons License.


    Article Marketing Tips:
    • Stand out from the crowds. Educate your prospects and they will turn to you for more knowledge. When they turn to you for more, they will visit your website. It is up to your website copy to sell your products, NOT your article. Provide great information and at your website, address how the prospect will benefit from what you are offering. Using these things in conjuction will help your cash register to ring.




    Subscribe to Article Distribution
    Email:
    Browse Archives at groups-beta.google.com

    Sign up for PayPal and start accepting credit card payments instantly.

    Unless Otherwise Noted, All Copy and Images are:
    Copyright © 2001-2008, Bill Platt, thePhantomWriters.com

    thePhantomWriters Ghost Writing Services

    thePhantomWriters Article Submission Services

    Other Website Properties owned by Bill Platt:
    Links And Traffic - Guaranteed Link Building Services
    Blogger Support | Double-Eagles | Windstorm Computing
    TechCentral Publishing | The Historical Wild West
    Bill-Platt.com | Byte-Sized Marketing Tips
    Niche Content Finder | The Article Depot | Web Impact
    The Audio Video Cabling Guide | Driving to California (Humor)
    Alien-Experiences Merchandise
    Sample Domain URL - Unique Web Directory
    Invisible MBA - Educational Articles
    Super Home Ideas

    Website Properties owned by Friends:
    Apex Cable TV | JMP Designs .net
    Invisible MBA - Educational Articles

    Marketing and Services provided by:
    Bill Platt

    Stillwater, Oklahoma 74075
    (405) 780-7327 (home)