1. This forum section is a read-only archive which contains old newsgroup posts. If you wish to post a query, please do so in one of our main forum sections (here). This way you will get a faster, better response from the members on Motherboard Point.

PCI a Bottleneck in USB 2.0 for Audio?, IRQ Sharing for USB

Discussion in 'PC Hardware' started by Veli-Pekka Tätilä, Nov 11, 2007.

  1. Hi,
    Briefly put, can the real world bandwidth or latency of a PCI-based USB
    2.0 card be a problem for high speed USB devices in soft realtime
    applications like audio and softsynths? For optimal performance, should
    I use the USB on the mobo or the ports on the add-on card?

    I have an Asus M2V mobo (using a Via chipset), an Ati Radeon X300
    graphics card, and among the USB devices are an E-Mu 0404 sound card, an
    M-Audio MidiSport 4x4 interface (USB 1.1) and an Evolution UC-33 MIDI
    knob box (USB compatibility unknown), plus a Lacie hard drive for
    permanent media storage. The kbd and mouse, as well as a headset and
    scanner, are USB as well.

    Having added USb ports, I decided to put everything audio on the new
    ports relying on the PCI card. Lately I have been geting audio dropouts
    in Sonar 4 LE with small buffers of 4 ms, and crackles when a screen
    reader program (speech synth with DirectSound or MME) and non-ASIO audio
    are used simultaneously. This being the Windows world, and since I have
    also updated drivers, I'm unsure whether the crackles are a result of
    USB changes or something else, thus my question.

    I've read a couple USB FAQs and the Wikipedia articles on PCI and USb
    but still cannot figure out whether it could be the bandwidth or not.
    Especially since the ideal data rates are never reached anyway.

    Finally, here's a heavily snipped dump of the PCI devices from PCI32,
    which also shows what USB controllers the system has:

    Craig Hart's PCI+AGP bus sniffer, Version 1.4, freeware made in
    1996-2005.
    Searching for Devices using CFG Mechanism 1 [OS: Win XP Service Pack 2]

    Bus 0 (PCI Express), Device Number 16, Device Function 0
    Vendor 1106h VIA Technologies Inc
    Device 3038h VT82xxxxx UHCI USB 1.1 Controller (All VIA Chipsets)

    Bus 0 (PCI Express), Device Number 16, Device Function 1
    Vendor 1106h VIA Technologies Inc
    Device 3038h VT82xxxxx UHCI USB 1.1 Controller (All VIA Chipsets)

    Bus 0 (PCI Express), Device Number 16, Device Function 2
    Vendor 1106h VIA Technologies Inc
    Device 3038h VT82xxxxx UHCI USB 1.1 Controller (All VIA Chipsets)

    Bus 0 (PCI Express), Device Number 16, Device Function 3
    Vendor 1106h VIA Technologies Inc
    Device 3038h VT82xxxxx UHCI USB 1.1 Controller (All VIA Chipsets)

    Bus 0 (PCI Express), Device Number 16, Device Function 4
    Vendor 1106h VIA Technologies Inc
    Device 3104h VT6202/12 USB 2.0 Enhanced Host Controller

    Bus 7 (PCI), Device Number 6, Device Function 0
    Vendor 1106h VIA Technologies Inc
    Device 3038h VT82xxxxx UHCI USB 1.1 Controller (All VIA Chipsets)

    Bus 7 (PCI), Device Number 6, Device Function 1
    Vendor 1106h VIA Technologies Inc
    Device 3038h VT82xxxxx UHCI USB 1.1 Controller (All VIA Chipsets)

    Bus 7 (PCI), Device Number 6, Device Function 2
    Vendor 1106h VIA Technologies Inc
    Device 3104h VT6202/12 USB 2.0 Enhanced Host Controller

    IRQ Summary: IRQs 14,15,16,17,18,20,21,22,23,24,27,28,31,35,36,39,43 are
    used by PCI devices
    Shared IRQs: IRQ 17 is shared by 2 PCI Devices
    IRQ 21 is shared by 3 PCI Devices
    IRQ control is currently managed by the system APIC controller

    As for the IRQs, here's what Windows reports, is this normal, too?

    17 Microsoft UAA Bus Driver for High Definition Audio OK
    17 VIA Rev 5 or later USB Universal Host Controller OK

    21 Standard Dual Channel PCI IDE Controller OK
    21 VIA Rev 5 or later USB Universal Host Controller OK
    21 VIA USB Enhanced Host Controller OK

    Back in DOS, all IRQ conflicts were something that should be avoided at
    all costs. Then ,much later in Windows PCI devices would share IRQs as a
    result of ACPI and audio manufacturers like Steinberg would advice
    people to install the standard hardware abstraction layer, to avoid
    problems. Now, APIC rules, and there are less ACPI problems in XP, too,
    so I don't know what to think of these IRQ conflicts clashing E-IDE and
    the built-in Realttek audio chip with USB devices. I'm just a technical
    end user and a programmer (Perl, Java), but my knowledge on PC hardware
    is frankly speaking minimal, and acquired on a need to know basis.

    Any help appreciated.
     
    Veli-Pekka Tätilä, Nov 11, 2007
    #1
    1. Advertisements

  2. Veli-Pekka Tätilä

    Arno Wagner Guest

    It is not the bandwidth, but bandwidth allocation. USB devices may
    have to wait a bit to send or receive on USB. Buffers of 4ms are
    very likely too small, expecially when you also have storage on the
    bus. A larger transfer from and to disk can also clog-up PCI, but
    for USB speeds that sounds unlikely. That the USB is on a card should
    not matter at all. But you should try without the disk and you should
    try with the outdio output device having its own IRQ.

    On the other hand, 4ms is pretty tight. Microsoft Windows is a toy
    and not intended to handle anything like this. I don't think
    you can change scheduling strategies and speeds and in my experience
    Windoiws has troubles running more than one app smoothly.

    On Linux you could ty incrrease the sheduling frequency to
    something like 10000Hz (default used to be 100Hz, now it is
    1000Hz) and maybe even change the job sheduler strategy. Also
    running the audiou-out job with significanlty higher priority
    would help. But in the end, it might not be enough. Best
    would be to use a real-time OS like QNX for it,

    Arno
     
    Arno Wagner, Nov 11, 2007
    #2
    1. Advertisements

  3. I see. Then one logical solution would be to use the disk with the USB
    ports on the mobo, and use those on the add-on card for the sound card,
    for instance.
    Put less subjectively, Microsoft Windows is a general purpose operating
    system originally intended for business applications, it is not a
    multimedia OS like BeOS let alone a true soft or hard real time
    operating system like QNX. Even Apple thinks of audio having a higher
    priority compared to MS.
    And there are far too few process priority levels, too. Well actually
    you can tell the OS not to give the process owning the foreground window
    a priority boost which most audio guides recommend (control panel,
    system, advanced, settings, advanced, processor scheduling = backround
    services). Also, precisely because of driver issues before we had WDM
    kernel streaming, Steinberg deviced the ASIO driver standard for
    Windows.

    I do know the actual latency surely is not 4 MS. USb probably adds to
    that, as does the PCI bus hosting the USB card, I presume, not to
    mention the DACs and any other possible delays.
    Interesting, I've heard that many musically oriented distros already
    contain a lot of real time and other kernel patches such as preemption.
    Agreed, QNx is seriously cool at any rate. I've seen the amazing 1
    diskette demo of the OS. But the choice of Os is not just a match of
    technical features, the problem is that I use the OS because of the
    software, not for its accessories or most other user features:

    Linux still lacks apps for wave editing, MIDi sequencing and soft synths
    at all seriously comparable to Sonar, Sound Forge and VST plugs, which
    is what I'm using and have invested some money in. There are some apps,
    but nothing much better than in Windows. Another sad real world problem
    are drivers, those for my USB sound card are experimental at best. LAst
    but not least, accessibility is something I'll have to worry about being
    sight impaired, and while the basic gnome desktop is accessible with
    Orca, music software is not.

    QNX is much worse in terms of hardware support and screen reader
    accessibility. But thanks for the advice anyway. I was kinda hoping that
    after five years or so I might be able to use LInux for serious music
    making with screen reader access to KDE. But that's OT at any rate. and
    we'll see in five years or so how accessible they've managed to make KDE
    and the music apps by then.
     
    Veli-Pekka Tätilä, Nov 12, 2007
    #3
  4. Veli-Pekka Tätilä

    Arno Wagner Guest

    That could work.
    I should rephrase: Anything leaving the scope of a glorified
    single-user typewriter is problematic in Windows. Even the
    typewriter is problematic today.
    Well, so solving this by sheduling priorities is out.
    There is a lot you can do in Linux. For me kernel-level scheduling
    with generous buffers has been enough so far, but I do not do
    adudiom except as a consumer.
    Some real concerns there, yes. I actually have sound driver issues
    as well. I have been wanting to buy a Creative X-FI card for
    some time for gaming, but until there is Linux support, not
    possible. It seems Creative is not even giving datasheets to the
    Linux sound developers. Pretty sad.
    It is really a mess. Good software on bad foundation or bad software
    in good foundations. Were there is good Linux software, it at least
    stays available, since typically it can be ported with minimal effort
    to newer versions or does not need porting at all. So the situation
    should indeed get better.

    Arno
     
    Arno Wagner, Nov 13, 2007
    #4
  5. Veli-Pekka Tätilä

    Joseph Fenn Guest

    Thinking of these USB things a funny thing happened this week after
    I had told the tech at OFFICE/MAX. I installed the Maxtor one touch
    V4 (the installation came without a disk as its alreay on the
    external HD when purhcased. The pamphlet that was included in with
    the V4 maxtor said "copy the contents files on the HD just in case
    you somehow loose them.) So I did useing the "send to" cmd in win
    xp pro to drive E which is my external burner. They went over OK
    and the burner spit out the CD/RW out. But up popped an all white
    screen from border to border and in the middle of the screen it said
    only one word in small type "Register" and thats all. I thought
    register what !!!!!. I bought the Maxtor which contained its own
    drivers inside it and a recommendation to copy those files just
    in case they get fouled up somehow. I did that too. Told the
    whole story to the guy at Office/Max said about it, and he said ignore
    that white Register screen as your bought the Maxtor and you also
    bought a 1 year warranty. Wieird stuff happens!!!!1 with computers
    and specially those wuth USB hubs.
    Joe
     
    Joseph Fenn, Nov 13, 2007
    #5
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.