Hi all,

To answer Jeff's question and Phil's reply I'll give a little background on the USB audio project.

For some time I've been working on a project to connect a high performance audio A/D converter to a PC via USB. The idea is to eliminate the sound card and send the recovered I/Q signals from the SDR1000 (SD40 etc) to the PC in a digital format. There are a number of reasons for wanting to do this.

1. It should help with removing ground loops
2. We will not need any special sound card drivers anymore
3. Compared with high end sound cards it should be low cost since even with an expensive sound card we are really only using the A/D and D/A chips
4. Potential for reduced latency
5. It will be fun and I expect to lean a lot!

Once this was working I intended to add D/A's for the I/Q signals on Tx and a simple A/D for the microphone. Next was to be a good quality stereo D/A for the audio output and then replace the PIO board completely with USB controlled IO.

Since I have some experience in programming PIC's in C I decided to use a USB enabled PIC uP the 18F4550. This turned out to not be a good choice mainly due the very buggy IDE/C compiler we selected and very poor support for the uP in other than an RS232 to USB replacement mode. However, I was able to use the on chip 12 bit A/D converter (to be used for mic input) to send data over the USB port to the PC and receiver the data there. Long term this does not look like a good solution since although the uP is specked at 12MB/s over full speed USB in practice no one seems to be able to get near this lever of performance. We will also need a faster interface if we want to do stereo 192kbs at 24bit which the Wolfson chip is capable of.

In the mean time I had built a USB2 (480Mbps) interface to my PC using a Cypress FX2 chip for another project. This worked very well, lots of free code and advice on the Internet and supported with free development tools. It is also the USB interface that Phil (N8VB) is using so I knew where to go as soon as I got stuck (thanks Phil!).

At work I have the pleasant task of mentoring overseas students whilst they do 12 weeks of industry experience in order to get their engineering degrees. One of these had FPGA development experience and wanted to work on a project where she could write in VHDL. Whilst we have FPGA development systems in the lab I could not justify handing one over to her for 12 weeks so had a look round for something more cost effective. That's when I found the Xylo board (www.fpga4fun.com). This looked ideal for the student but also as an alternative for the PIC uP since it used an FX2 USB2 chip to interface the FPGA to the PC.

As well as an USB interface, which can be used to program the FPGA and FX2, then allows the FPGA to access the USB port and send data to the PC. It also supports I2C and TCP/IP. Since the Wolfson A/D chip can be set up via I2C this seemed like a good way to interface the chip. The data out of the Wolfson is in I2S format and you can find free I2S code for the FPGA on the net.

The Xylo board comes with enough sample PC and FPGA code to get started and all the examples compiled and ran first time. The USB interface is straightforward and the sample C code makes it easy to write code on the PC to talk to the FPGA.

Progress has been good so far. We have interfaced the Wolfson chip to the FPGA and can configure it over the USB using I2C. We also added an I2C I/O port expander to the I2C bus and that works fine also. We have written some test code to send data from the PC over the USB, read it into the FPGA, modify it and write it back to the PC. This runs very fast, so off to a good start.

At the moment we are writing VHDL code for the FPGA so that we can read the data from the Wolfson A/D, send it over the USB link and play it back using PortAudio on the PC. At the current rate of progress we should get that running this week, in which case the next step will be to alter the SDR1000 code and try it there.

There are a couple of issues with the Xylo board. The supplier will not let you have a circuit diagram. That does not seem to be much of a problem since both Phil and I have worked out enough of the circuit to see what pins of the FX2 are connected to the FPGA. The other issue is that unlike the SDR1000 this is not an open source project so we don't have the code for the various drivers that they use. I don't see this as a problem in the short term but I may be in the long run. I expect there are enough skills lurking in this group to overcome this when need be.

There are many other things we can do with as USB interface and an FPGA. We will have lots of I/O for operating external relays etc. We could use the 1 pps signal from a GPS to stabilize an oscillator. Perhaps replace the DDS with an NCO. As Phil suggested we can test PWM D/A converters for the I/Q signals and if they are not good enough then Wolfson make a great range of D/A and A/D converters (as do other companies, its just that Wolfson have been very generous with samples so far!).

I have never worked with FPGAs before so am starting the VHDL learning curve. I see that the preferred HDL language in the US is Verilog whilst down here and in Europe it seems to be VHDL.

There is plenty of room for others to play if interested. The slow part for me will be the FPGA coding so if anyone has those skills and would like to help out then I'll be happy to lean VHDL later on!

Sorry about the long post but I didn't see that a short reply would do this exciting project justice.

73's  Phil... VK6APH







----- Original Message ----- From: "Philip Covington" <[EMAIL PROTECTED]>
To: "ecellison" <[EMAIL PROTECTED]>
Cc: <FlexRadio@flex-radio.biz>
Sent: Monday, November 21, 2005 1:19 AM
Subject: Re: [Flexradio] Teamspeak Forum Audio - 11-19-05


Hi Eric,

On the D/A part of the equation we need to look at whether we could
use PWM output from the FPGA into a LPF.  I have done this for audio
output into a speaker (with an amp in between), but we would have to
see if it would give use the dynamic range we would require for the I
and Q outputs to the QSE.  I think this should work...  Using two pins
for PWM output from the FPGA would eliminate the need for an external
stereo D/A.

Phil N8VB


On 11/20/05, ecellison <[EMAIL PROTECTED]> wrote:



Jeff



I really need Phil – VK6APH to comment, and maybe Phil – N8VB will chime in
on this thread. Phil was going to eliminate the DAC by using the PIC to do
the DAC for transmit. If I remember, he did have that working. I think it
was 10 bit which was enough for SSB but Digi modes were in question. The
feeling was that we could stream the digital stream back through the USB. I
am having difficulty remembering exactly what Phil1, (here we go
again(smile)) VK6APH had proposed. Phil1 is on a trip to South Australia so
dunno when he will be available for comment.  I do know he will be very
anxious to chat with you! Hopefully we can get you and some others with FPGA
experience to help us along!



Phil Covington N8VB is designing an entire SDR around an Altera FPGA (and
other wonderful things!)



http://www.philcovington.com/



See HPSDR Board picts at the top of his page.



Thanks

Eric
_______________________________________________
FlexRadio mailing list
FlexRadio@flex-radio.biz
http://mail.flex-radio.biz/mailman/listinfo/flexradio_flex-radio.biz



--
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.362 / Virus Database: 267.13.3/174 - Release Date: 17/11/2005




--
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.362 / Virus Database: 267.13.4/176 - Release Date: 20/11/2005


Reply via email to