[wdmaudiodev] Re: Building an USB audio interface with a PIC18F4550

  • From: DJ Sisolak <dsisolak@xxxxxxxxxxxxxxxxxxxxxx>
  • To: "wdmaudiodev@xxxxxxxxxxxxx" <wdmaudiodev@xxxxxxxxxxxxx>
  • Date: Tue, 27 Mar 2007 16:53:59 -0700

Hi All,

Answers dispersed below...

Thx,
DJ Sisolak
Microsoft Corp

-----Original Message-----
From: wdmaudiodev-bounce@xxxxxxxxxxxxx 
[mailto:wdmaudiodev-bounce@xxxxxxxxxxxxx] On Behalf Of Tim Roberts
Sent: Monday, March 26, 2007 10:56 AM
To: wdmaudiodev@xxxxxxxxxxxxx
Subject: [wdmaudiodev] Re: Building an USB audio interface with a PIC18F4550

Elios Elios Elios wrote:
>
> I'm making my end of career project (telecomunications engineering),
> that consist in a USB interface for capturing audio by 4 channels. We
> are using as IC the PIC18F4550 of Microchip. We have made the PCB, and
> we have comunicated the PIC and the PC with an C# example that we have
> found in the WEB. This example is for low speed, and for audio isn't
> very good...

To do 44.1kHz audio at 16 bits per sample with 4 channels takes 353
kB/sec.  That's double what a low-speed device can do.  You'll need full
speed.

[DJ Sisolak] Correct, all spec compliant USB Audio devices MUST be full speed.

> So, what is the better way to make an USB Audio Interface?
>
> I read the "USB Device Class Definition for Audio Devices 1.0" and the
> 2.0... I think that if we follow the specification, we could to
> control the interface with the driver Usbaudio.sys and programme it
> with an Native API like WDMAudio Driver (winmm.dll, isn't?), or Core
> Audio ...

Yes, the best way to build an audio device is to meet the USB Audio
Class Spec, as you describe above.  The trickiest part is creating the
descriptors to describe your architecture, and even that's not too hard;
there are samples in the documents on the USB web site.  You will want
to do your streaming with an isochronous pipe.

[DJ Sisolak] Again, correct. Streaming for USB Audio per the spec (MIDI being 
the exception) is done via Isochronous pipes. Descriptor generation for USB 
Audio 1.0 device is pretty straight forward from the spec. You may want to look 
at the guidelines as posted on 
http://www.microsoft.com/whdc/device/audio/UAA_HWdesign.mspx for some other 
information on this.

> I read that there is a problem with USB 2.0 (the PIC18F4550 works in
> USB 2.0, full speed) and Usbaudio.sys... Somebody knows it?

Not that I know of.  There are a few discussions of this on the
Microchip web site, but nothing negative.

[DJ Sisolak] Full speed USB Audio devices should work just fine with USB 2.0 
bus. There are some issues for getting a High Speed USB Audio 1.0 devices to 
work though.


> Maybe the other solution can be to make a driver with Windriver... I
> have listened that is very easy to do. But in this way only we could
> to control our interface with our own driver... isn't?

Making a simple driver with WinDriver might be easy, but making an audio
driver of any kind is not easy.  Unless you run into some very serious
problem, you should strive to make your device USB Audio Class compliant.

[DJ Sisolak] I heartily agree. If for some reason you feel that the 
usbaudio.sys class driver does not fit your needs feel free to let me know why.

--
Tim Roberts, timr@xxxxxxxxx
Providenza & Boekelheide, Inc.

******************

WDMAUDIODEV addresses:
Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
Unsubscribe:  mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx

URL to WDMAUDIODEV page:
http://www.wdmaudiodev.com/

******************

WDMAUDIODEV addresses:
Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
Unsubscribe:  mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx

URL to WDMAUDIODEV page:
http://www.wdmaudiodev.com/

Other related posts: