PC music players

Status
Not open for further replies.
Re: Re: Re: Explanation

Most definitely. No Thugfir for me.

So what are your plans then?
It sounds like you want to do somthing like CDP -> DSP -> DAC.

Unless you just dump the audio data at high speed and let the external card sort it out.

Sounds like your a glutton for punishment.

Oh no it isn't. There are other methods that are either excessive or would require a paradigm shift in your approach.

Like?
 
Thoughts

> Surely once the crossover points are chosen, they are set

Yes. The whole point of a digital crossover, though, is :
1- sounds better than any analog (active/passive) could ever hope to
reasons : active (no L, no C, no R, no impedance variations) ; digital (no opamps, pick any filter curve you wish, phase alignment is straightforward).

2- a lot easier to experiment.
You can change the filters in about 10 seconds to any specification. No clip leads. Thus you can make a lot of design iterations in an evening. You can ABX crossovers. You can do things you would never do with analog (exotic slopes, phase correction...)
Thus you reach good sound a LOT faster than with clip leads. I tried. It did.

>with the system skewed to work from the PC when it clearly isn't necessary

The point is also to store music on harddisks which is a lot more convenient and archival-friendly than CDs. Not to mention, compatible with any future format with a simple software update. Now that I have a music PC I'd hate to go back to these un-user-friendly CDs. It would also like to store vinyl in something like 24-192 quality on harddisks, using digital RIAA correction too.

Interface it with Xine and you get a DVD player too. In the same way that I don't use slides anymore for my photography, even though I loved Velvia, and I now use a video projector to show my digital pictures. Quality is excellent, and you can use Photoshop.

>Even though that is not necessarily the best place to perform said tasks?

A PC is more versatile, cheaper, more flexible, faster, easier to develop on, that any DSP boards. DSP wins on size, power efficiency, and price on large quantities, which are all non-concerns in our application.

Why would I bother taking months to design and custom program a DSP board when I can draw a filter with an open-source tool, make some calculations on it with scientific python, give it to BruteFIR and listen to it in a matter of minutes ?

On a DSP, you'd do a non-FFT convolution, which would severely limit the filter length. a FFT implementation like BruteFIR's would be incredibly complex to implement.

To get good results you need knowledge. DSPs are generally 32 bits fixed or floating point which means issues with rounding. BruteFIR does everything in double precision if you ask it to, and finally dithers down to 24 bits.

> once you're happy with the crossover points you probably don't fiddle

I'd have several configurations :
- Normal stereo (maximizes sound quality)
- Party stereo (shifts crossover points upwards / uses higher orders) to save tweeters from meltdown
- Multichannel for DVD/whatever
- Compensation for certain badly recorded albums (tame screaming treble for instance)

So I'd still need a way to switch easily between filter sets.

I'd also need a loudness corrector (boost some frequencies according to volume) to simply match the reality of hearing perception which is easily implemented with a set of different coefficients.

It would really be interesting to explore all the possibilities.

> Is there any chance that these 6 channels can lose perfect synchrony with each other

If three stereo USB DAC chips are used : Yes
If a custom solution is used (USB -> FIFO whatever) : No
With ADAT : No

> BruteFIR algorithms for crossover filtering are capable of lossless volume control?

Yes. These is a command line interface while the program is running which allows that. I'd go with an analog control though, as digital is not lossless. Are you sure your delta-sigma's converter resolution is really 24 bits ? I'd say definitely NO.

> USB

Yes, you need to write drivers (take an open source driver for some USB gear and hack into it).
-> windows : i wouldn't even try
-> linux : should be a weekend's project, but I really don't know

You also need to write code for some microcontroller to put the data in the right format somewhere. You will also probably need some form of high-speed programmable logic. A FPGA might be overkill, a PLD can probably do it. Not that hard to do. After all it's just a bunch of serial/parallel/serial conversions. The USB chips already integrate a DMA controller and FIFO. We only have to take advantage of these.

> SPDIF, ADAT, Soundcards :

I'd like to use the PC for oversampling. People have reported dramatic changes in sound quality when using on-chip settings to change the oversampling filter used in DACs. I think there's potential here, and a PC is the best platform to experiment. But we need a way to get 24 bits at a VERY high data rate to the DAC chip, a lot higher than any soundcard would allow. Hence the USB2 solution.

And I like the idea of hacking a USB2 compactflash/memorystick/whatever reader with a DAC pretending to be a memory card : no drivers, no need to get that unobtainium USB chip... Use linux for raw access to the device and hoopla !

Gotta think about it...
 
Re:digital volume control

MWP said:



There is no such thing.
You are always going to loose resolution by doing digital volume control... there is no way around that.


The performance of a digital volume control actually has nothing to do with the algorithm used (assuming it's at least sane) if you're using 24+bits of resolution. It has everything to do with your DAC and the other sources of noise/distortion in your system.

Digital volume control on a 24 bit word length produces distortion/noise products that are -144 dB down - in other words they are insignificant. The 'problem' is that no DAC is actually linear down to that level, and so your signal disappears into the noise/distortion floor of your DAC, which tends to be around -105 to -110 in most cases.
*IF* you set up your system properly, your amp will probably be the limiting factor on distortion performance, and so a digital approach should be completely transparent.

The main problem with digital volume control from the PC is that you run the risk of some uncontrolled program sending full-range full-volume signals out straight into your drivers. With a well-designed Linux approach, this is probably not an issue.

If you're talking multi-channel digital xovers, I think digital is the best compromise at the moment. An analog-domain approach that is better than a good digital approach will be either VERY expensive or else rather inconvenient. If this is a cost-is-REALLY-no-object approach then it might make sense, but digital has a lot to recommend it.
 
When did PC ownership become a religion? Afterall how else can one explain this dogmatic approach as regards DSP. There is NOTHING one can do on PC that cannot be done on a DSP development board. Even my stone age EVM56002 development board and s/w can do FFTs with ease. If you want do FFTs on your PC's be my guest but spare me this only-a-pc-can-do-it rubbish. You might want to have a look at the BDTI benchmarks for the AD Tigersharc compared to the P4 for a dose of reality.
As for moving data off the PC and audio data is only data, GbE and HIPPI are two options and if you must use a dedicated audio protocol there is AES10, AES47 and SuperMAC.

ray
 
Ray,

Nobody in this thread should be regarded as "dogmatic" or "pc worshippers" quite yet. Everyone has their own experience and assumptions, but nobody yet has been appointed THE AUTHORITY. So please realize you are providing a very important stream of opinion but so are peufeu and MWP and Neutron7 and others. At least I appreciate finding out about GbE and HIPPI (still don't know what they are btw) and it is very legitimate to be advocating an external dsp solution, even if some of us seem to be in disagreement.

However, with that said, you have not really defended your position very well. The main contention of peufeu and MWP is that you are going to have the pc storing all the music anyway (don't you agree?) and there is already software that is demonstrably and freely available for it that does most of what we want anyway. Why do you then advocate a more difficult solution? How will it be sonically superior?

peufeu -

Check this link for usb2.0 to ata -

TI USB2.0 to ATA bridge controller

MWP -

In every case so far that you have "disagreed" with my summary or interpretation, we actually agreed 100%. My terminology may be the problem. For example, I am using the term soundcard a lot but am not assuming that is a pci device. Anyway, just wanted to mention this without going point by point. Also, I think peufeu and I both have been assuming 1 usb2.0 carries all 6 channels (for example) and the "soundcard" "sorts it out", in rfbrw's words.

Nobody has yet (although you tried) explained sufficiently why we can't have nearly lossless dsp volume attenuation. Consider this:
1. The initial data is 16 bit samples derived from cd. It is plain old stereo music.
2. This 16 bit samples get converted to 24 bits (perhaps by BruteFIR).
3. This creates no new information, leaving 8 bits of meaningless data per sample. The only reason these meaningless bits are created at all is so we can use a dac that is also capable of higher resolution formats of sampling that use more than 16 bit resolution, right? Strictly speaking, if we're only interested in playing music derived from cd's and nothing else ever, we would design a 16 bit system and it could not be improved on, right?
4. If we pretend that the 24 bit code is strictly linear and continuous, then if all 24 bits are 1's our dac outputs full scale, perhaps 1V. If only the bottom 8 bits are 1's, then the output SHOULD be 0V, since there's no information in those 8 bits they are don't cares. Maybe it's not designed that way, but I'm asking why wouldn't we set it up this way. Then, as we reduce volume by sliding the word to the right, we don't lose any information until we have shifted more than 8 bits to the right.

What's wrong with that? Are you assuming we will be playing actual 24 bit music? That would be nice.

I think we've lost the general readership out there. Why is nobody calling in with info on jitter measurement and benchmarks?

-Robert

p.s. - I'm happily drilling, cutting and soldering a 4-channel BrianGT NIGC that will soon be in place to collect 4 channels out of BruteFIR (which means I'd better whip up a dedicated silent linux pc soon). Is the silent VIA Eden capable of 6 BruteFIR channel crossover filtering perhaps with room equalization and whatever and if so is it Linux compatible? I use Debian btw.
 
Robert,
This is not about authority or experience.It's about the difference between opinion and fact. It is one thing to say "you do it that way but I'll do it this way" but it is quite another to say "your way cannot work" without providing concrete proof. When the PC zealots tell me I cannot run certain DSP processes when I know the reverse to be true I have no hesitation in letting them have the whole nine yards.

RFScheer said:

However, with that said, you have not really defended your position very well. The main contention of peufeu and MWP is that you are going to have the pc storing all the music anyway (don't you agree?) and there is already software that is demonstrably and freely available for it that does most of what we want anyway. Why do you then advocate a more difficult solution? How will it be sonically superior?

The software does what MWP and Peufeu want.
For me it's about the interface. As a user interface for Cadstar or Word the PC is fine. For playing music its rubbish. To be of any use to me the PC has to be transparent. I scroll down a small LCD screen pick a track and press play in much the same way I would with a normal CD player. I don't use tone controls and I'm into headphones and mini-monitors so no need for thugfir. If I did decide to go active and plump for digital crossovers I'll knock out a eurocard or two and stick them in the amps. Put simply I'm only interested in the PC for its storage capacity.


3. This creates no new information, leaving 8 bits of meaningless data per sample. The only reason these meaningless bits are created at all is so we can use a dac that is also capable of higher resolution formats of sampling that use more than 16 bit resolution, right?
-Robert

Small point. The information may not be new but all the bits are valid. Oversampling be it by DF1704 or thugfir use digital filters.These filters require coefficients. When these coefficients act upon the data they provide the desired result. The data is acted upon by multiplying the data with these coefficients. And this is the crux of the issue. In binary mathematics if you multiply xbit data by ybit coefficients you get a (x+y)bit result. So if the filter you are designing throws out 16bit coefficients and you have 16bit data you end up with a 32bit result and ALL bits are valid. If all one wanted to do was tack on a few zeros, one would not need a DF1704 or any other oversampling filter. In the case of digital audio this 32bit result would be dithered down to 24bits witl ALL 24bits being valid.

ray.
 
Robert, This is not about authority or experience.It's about the difference between opinion and fact. It is one thing to say "you do it that way but I'll do it this way" but it is quite another to say "your way cannot work" without providing concrete proof. When the PC zealots tell me I cannot run certain DSP processes when I know the reverse to be true I have no hesitation in letting them have the whole nine yards.

We (well i anyway), are not saying that it cant all be done in a DSP... sure it can but, its going to be a hell of a lot easier to do using a PC.
I have DSP programming experience, yet i wouldnt touch such a project using a DSP... building somthing like an IDE interface, filesystem, track selection, various audio format decoders, filters, xovers into a DSP woiuld not be my idea of fun.

The software does what MWP and Peufeu want.
For me it's about the interface. As a user interface for Cadstar or Word the PC is fine. For playing music its rubbish. To be of any use to me the PC has to be transparent. I scroll down a small LCD screen pick a track and press play in much the same way I would with a normal CD player. I don't use tone controls and I'm into headphones and mini-monitors so no need for thugfir. If I did decide to go active and plump for digital crossovers I'll knock out a eurocard or two and stick them in the amps. Put simply I'm only interested in the PC for its storage capacity.

It so happens i work for this company:
http://www.crystalfontz.com

They have some rather nice products (like the 633, 631) that would be perfect for this use.
When i do build up this system, i will probably make the software i write avaliable for other people.
 
RFScheer said:

Nobody has yet (although you tried) explained sufficiently why we can't have nearly lossless dsp volume attenuation. Consider this:
1. The initial data is 16 bit samples derived from cd. It is plain old stereo music.
2. This 16 bit samples get converted to 24 bits (perhaps by BruteFIR).
3. This creates no new information, leaving 8 bits of meaningless data per sample. The only reason these meaningless bits are created at all is so we can use a dac that is also capable of higher resolution formats of sampling that use more than 16 bit resolution, right? Strictly speaking, if we're only interested in playing music derived from cd's and nothing else ever, we would design a 16 bit system and it could not be improved on, right?
4. If we pretend that the 24 bit code is strictly linear and continuous, then if all 24 bits are 1's our dac outputs full scale, perhaps 1V. If only the bottom 8 bits are 1's, then the output SHOULD be 0V, since there's no information in those 8 bits they are don't cares. Maybe it's not designed that way, but I'm asking why wouldn't we set it up this way. Then, as we reduce volume by sliding the word to the right, we don't lose any information until we have shifted more than 8 bits to the right.

What's wrong with that? Are you assuming we will be playing actual 24 bit music? That would be nice.

What ray said in his last paragraph is the point here.
Even though the original music source may only be 16bit, the filtering that 16bits then goes through results in more than 16bits (anything up to 32bits).

I know i would like to keep as many bits as possible.

Also remeber becuase PC decoder software is the source, it might also supply more than 16bit data.
For example, most lossy decoders can output to more than 16bit (24, or 32bit).

BTW, digital volume controls dont shift left/right... they multiply/divide (meaning it effects all bits).
 
Grrrr!

All of you who have "explained" the issues of dsp volume control have totally failed to convince me that it must sacrifice dynamic range. If I can preserve 16 bits of accuracy of samples presented to the dac, my music will sound no worse than the original cd. So, as long as attenuation is the last step after filtering and dithering and whatever other artificial manipulations create "extra" bits, I will be fine. I think this question needs to go to certain university profs I know or else I'm going to have to go deeper into dsp than I want.

MWP,

I would not ever propose multiplying a sample to obtain a higher volume. Only attenuation. Division by 2 is shifting right one bit, etc, etc.

rfbrw,

Your use of pc's for music is totally valid and very reasonable, however the purpose of this thread is to build or figure out what it would take to build something like the world's best music player using a pc. Note this doesn't mean the ultimate possible, just world's best for today ("oh I was worried there for a second"). Our goal and yours are not compatible.

-Robert
 
Re: Grrrr!

> Digital volume control

After a digital room correction / active crossover or any DSP calculation, you get samples at the internal DSP's resolution. Generally it's 32 bits, in the case of BruteFIR it's a double-precision floating point number.

How many meaningful bits do you have ? That's actually hard to say. If you multiply two 16 bit values (say a sample and a coefficient), you get a 32 bit values, and ALL the bits count. So, by considering the input and coefficient bitwidhts, and how the processing is done, you can calculate how many bits matter in the output. Don't ask me the numbers, I didn't do it...

What's important is that this very high precision value is dithered down to the DAC's bitwidth before playing. If you use a digital volume control, before dithering you would multiply by a value between 0 and 1 (don't consider only bit shifts, you don't want your volume in 6 dB steps !)

So how many bits do you need ?

If you dither your processed samples down to 16 bits, you'll lose sound quality. This is because dithering does not eliminate quantization noise, it merely transforms it from noise correlated to the signal (sounds bad) to additive white noise (sounds better but it's still noise). And it is standard practice and recommended by every digital recording manual to only dither down to 16 bits as the LAST step.

Taking 16 bit samples, processing them (yielding higher precision results) and dithering them back to 16 bits is known to degrade sound quality (veil, less detail, less depth...)

So you'd want to dither to 18 or 20 bits after processing. Taking 20 bits as an example, you could only multiply your output samples with values from 1 downto 1/16 (shift 4 bits) to fit your 24 bit target, which isn't a lot of amplitude for a volume control.

Also, you'd always be using the lower part of the DAC resolution... and this is the part where DACs are less good. I'd rather use the 16 upper rather than the 16 lower bits in a DAC.

Desides, most DACs which take 24 bits are delta-sigma types, and their real resolution is a lot lower than that ; it's actually hard to know because the resolution of a delta-sigma DAC depends on how many samples you average and on the kinds of lowpass filters used to measure said resolution. Thus, I wouldn't use a digital volume coltrol...

However, a hybrid digital/analog volume control would be a good idea : use a stepped attenuator (controlled with relays) in coarse 6 or 1à dB steps, and use the digital attenuation for finer control. Thus you wouldn't lose too many bits, but you'd still have a lot of control range.

I hope these explanations make it cleare for you.
 
Thanks

peufeu,

I'm on the threshold of understanding now, thanks peufeu. But it's becoming clear that there will be a rigorous dsp course in my future. Intuition says there is an opportunity here to discover a practical all-digital-domain technique. You must admit it is a shame to put any extra impediment into the analog signal path.

Are any of the existing audio dacs capable of acting as multiplying dacs? If we could scale the reference voltage or current of the dac, then we would have achieved what I want. Right?

-Robert
 
Digital volume control?

I worked for a pro - audio company which made studio mixing desks and related stuff, they also made a digital desk. all processing was digital, including the faders and eq. I didn't work on the digital desks much, but this may be an avenue of enquiry for you.
We had a "Sexy Purple Chip" which was mounted in a small purple aluminium case, 28 pin dil size, which re - clocked the data to remove jitter. It cost £80.00 from what I remember. One was used for each channel. We had a very wide bandwidth ( GHz) Le Croy scope for measuring them.
The result of jitter shows up as sidebands on a spectrum analysis,
so to measure jitter you have to interpret the spectrum analysis in some way. I'm pretty sure that this is what Miller's software does to provide a figure for jitter.
SSM made some pro audio chips of various functions, they were bought out by Analog Devices, who kept on some of their designs, and dropped others.
One chip was a digital volume control, which combined digital and analog functions for exactly the reasons discussed in the last posts. They were for digital desks. I cann't remember the mumber, SSMxxxx or something, so Analog Devices may still do it, it's worth a look. Think how they do it.
The latest digital desk - I don't know if it made it into production - had an eq which could be adjusted by moving your finger on the touch - screen. You moved your finger down and the eq curve moved down following the movement, and the eq adjustment followed suit. how cool is that!😎 This is something to develop for adjusting the digital crossovers, touch screen control of filter coefficients.😀
 
RFScheer said:
All of you who have "explained" the issues of dsp volume control have totally failed to convince me that it must sacrifice dynamic range. If I can preserve 16 bits of accuracy of samples presented to the dac, my music will sound no worse than the original cd. So, as long as attenuation is the last step after filtering and dithering and whatever other artificial manipulations create "extra" bits, I will be fine. I think this question needs to go to certain university profs I know or else I'm going to have to go deeper into dsp than I want.

Robert,
You really have to get rid of this 'extra bits tacked on the end' notion. Consider the term resolution. Not in a Stereophile or TAS reviewer sense but in a technical or dictionary sense. Now consider three rulers each 1 metre long. The first is calibrated in decimetres, so can measure up to 10dm. The second is calibrated in centimetres,so can measure up to 100 cm. The third is calibrated in millimetres, so can measure up to 1000mm. Now all these rulers can only measure up to 1 metre but can do so with increasing resolutions.
In our context the 1metre length is analogous to the full scale value of a dac. The FSV of a 16bit dac is the same as the FSV of 24bit dac in our scenario. You cannot simply take the 16 MSBs of a 24 bit word and say 'yippee we're back where we started'. In the same way the spacings between the increments change when going from the ruler calibrated in dm to one calibrated in mm, the value of the bits have changed or have been requantized to give the process its proper name.
In a nutshell oversampling, eq etc does not create extra bits it creates new words of greater resolution or finer increments and ALL bits are valid.

Originally posted by RFScheer
I would not ever propose multiplying a sample to obtain a higher volume. Only attenuation. Division by 2 is shifting right one bit, etc, etc.

Attennuation is multiplying by a number less than 1. If you simply shift and drop bits the volume steps are too coarse.

Originally posted by RFScheer
rfbrw,
Your use of pc's for music is totally valid and very reasonable, however the purpose of this thread is to build or figure out what it would take to build something like the world's best music player using a pc. Note this doesn't mean the ultimate possible, just world's best for today ("oh I was worried there for a second"). Our goal and yours are not compatible.
-Robert

:bawling: :bawling: :bawling: What !!!! Do you mean..... I'm being
.....excommunicated?????:bawling: :bawling: :bawling: :bawling:

BTW how do you chaps plan to move oversampled data across spdif or adat? I ask this because you can get players that oversample LPCM by 32 and you can probably do this on a PC.

ray
 
Raising expectations

Ray,

Thanks for the lecture on resolution and of course you are most welcome in this thread. You are the "resident cynic" of the group.

Could we raise the level of discussion a notch or two? None of us is as remedial as Ray thinks (that ruler analogy almost did me in :crackup: ). Sorry I've kept my discussion simple (like division = shifting right). If my questions seem stupid, it's just because I'm new to audio dsp and I'm challenging something that everyone believes but doesn't really understand. I can't tell you how many times I've done this successfully in my 25 years of r&d of ic's and related technology. This question of attenuation has all the hallmarks of one of these situations.

Anyway, I'm greatly enjoying the banter and am looking forward to the project.

Repeat question - need an opinion on the best fanless pc for Linux that's capable of at driving 6 crossover channels out of BruteFIR? If nobody knows, then I'll figure it out and let you know because I want to order motherboard & components next week.

-Robert
 
Re: Raising expectations

RFScheer said:
Repeat question - need an opinion on the best fanless pc for Linux that's capable of at driving 6 crossover channels out of BruteFIR? If nobody knows, then I'll figure it out and let you know because I want to order motherboard & components next week.

Ok... now we are starting to move along a little.

The question is, how much PC power is required for BruteFIR to perform its tasks, and leave enough CPU time for the player software.

Which then leads to the question, what size should the FFTs be, and what is the maximum processing audio delay?

With the recommended FFT size (for each filter), and max delay time, i should be able to come up with an approx minimum PC spec.
 
Performance

Read this :

http://www.ludd.luth.se/~torger/brutefir.html#howfast

Then again, only room correction needs a lot of power because of the very long filters involved.

For a 3-way crossover at, say, 500Hz and 4kHz, in double precision floating-point, it uses less than 20% of my Duron 1300 which has slow SDRAM PC100.

So you can try the filters tou plan to use on a low performance PC and see how much you get.

The player doesn't use much power. I use Alsaplayer. You need to connect the two with jack. it's fiddly.

And, a 2 GHz Athlon with DDR ram is extremely cheap these days.
 
How big are your FFTs?

I run 3 way xover:
sub: L+R into lowpass (->70hz)
mid: L & R bandpass (70hz->2Khz)
high: L & R highpass (2Khz->)

Each filter is 2048 samples.

On my AthlonXP 2200+ using PC3200 i use around 10% CPU time.

But i was asking because i wonder how well it would run on a Via EPIA board (=fanless).
 
MWP said:
But i was asking because i wonder how well it would run on a Via EPIA board (=fanless). [/B]

I don't remember, I did the tests a long time ago, and now I haven't made the amplifiers, so my project is a bit stalling... that's why I'm eager to help others do it, maybe it'll motivate me to find more time to finish it !

You can test this by lowering your CPU frequency in the BIOS. Underclock it to the max...

But if it only takes 10% of a 2200 CPU, it's not gonna take more than 40% of a 700 MHZ CPU, so I'd say you're clear to go.

However, why don't you simply put the PC in the next room ? Even with no fans, you'll still have harddisk noise.
 
Status
Not open for further replies.