
Home  Forums  Rules  Articles  The diyAudio Store  Gallery  Blogs  Register  Donations  FAQ  Calendar  Search  Today's Posts  Mark Forums Read  Search 
Digital Source Digital Players and Recorders: CD , SACD , Tape, Memory Card, etc. 

Please consider donating to help us continue to serve you.
Ads on/off / Custom Title / More PMs / More album space / Advanced printing & mass image saving 

Thread Tools  Search this Thread 
9th April 2015, 09:45 PM  #1 
diyAudio Member
Join Date: Apr 2015

Using Centripetal Catmull–Rom spline in place of oversampling
This discussion is aimed more at people with electronic knowledge and contains such terminology.
I was reading up about DAC methodologies like R2R with some enthusiasts saying how much better it is than DeltaSigma etc. I understand that DeltaSigma is chosen for cost reasons. It is expensive to manufacture a laser trimmed R2R ladder IC which is why manufacturers look at other alternatives. It occurred to me that a VERY smooth output could be achieved by using a Centripetal Catmull–Rom spline to calculate a smooth interpolation between steps at any reasonable desired sampling rate. Instead of oversampling by 256, use the above spline formula to calculate 256 new points along a smooth curve between the known samples. It is 2015 and there are plenty of powerful low cost microcontrolers that can do the job. My idea for making a better affordable DAC is to use a PWM constant current to charge and discharge a capacitor, similar to how class D amplification works, but using a microcontroler and spline calculations to construct the PWM signal. My reason for choosing a constant current over the usual LC circuit is that it is far easier to calculate perfect PWM timings when using a constant current. LC circuits are curved and good luck trying to figure out where your pulse fits onto that curve. Any thoughts from the experts? 
10th April 2015, 10:27 AM  #2  
diyAudio Member
Join Date: Mar 2002
Location: Switzerland (Bern)

Quote:
I own a 27 WADIA and can tell you about the pleased hearing experiences... but requires high resolution speakers (Magnepan), tube gear and not boom boom music at all The benefit against traditional FIR oversampling is the smaller overshoot, no much cap's in the signal path and use of low plastic for the connection wires ... I had once a paper claiming a overshot (post & pre echo) below 1/100 of the main peak will not be hear able... just my 2 cents Hp
__________________
www.hpwworks.com 

10th April 2015, 10:32 PM  #3 
diyAudio Member
Join Date: Apr 2015

Hi HP
I just looked at the specifications of the PCM1704 DAC and it makes no mention of spline usage. Perhaps you are referring to another DAC? 
11th April 2015, 09:40 AM  #4  
diyAudio Member
Join Date: May 2007

Quote:
As a little exercise for yourself, use a spreadsheet (or Matlab etc.) to sample a 22kHz sine wave at 48kHz (or 20kHz at 44.1kHz). What sort of spline will enable you to recover the sine wave, and reject the image at a slightly higher frequency and slightly lower amplitude? 

11th April 2015, 10:13 AM  #5 
diyAudio Member
Join Date: Apr 2015

I don't think that any existing technology will accurately recover a 22kHz sine wave sampled at 40 something kHz. My point was that DeltaSigma was implemented as a cheap alternative to costly laser trimming of R2R ladders.
A microcontroler decoding SPDIF into analogue using my proposed method surely has to be better than DeltaSigma, yet just as cost effective. As for wanting smooth output, I was referring to the step staircase effect that even R2R can't avoid. Spline solves that. ( but not at 22kHz obviously) 
11th April 2015, 04:04 PM  #6 
diyAudio Member
Join Date: Apr 2010

Have you read this book? It's free online, and highly recommended:
The Scientist and Engineer's Guide to Digital Signal Processing 
11th April 2015, 06:27 PM  #7  
diyAudio Member
Join Date: May 2007

Quote:
If you want to suggest new methods for DAC it might help if you start by learning about how the current technology works. Not just the DAC itself, but also the reconstruction filter. If you draw "smooth" curves through samples where the sampling frequency is very high compared with the signal frequency you can easily fool yourself  newbies do it on here all the time. Move up nearer the Nyquist limit as I suggested and you should start to see how digital audio really works. "Smooth" curves may play a limited role, but the real issue is good filters. 

12th April 2015, 08:52 AM  #8  
diyAudio Member
Join Date: Mar 2002
Location: Switzerland (Bern)

Quote:
Really 8 times linear oversampling and then a spline... Search on wadia.com or google wadia 27 Hp
__________________
www.hpwworks.com 

12th April 2015, 09:41 PM  #9  
diyAudio Member
Join Date: Apr 2015

Thank you HP. I just looked it up and saw that WADIA 27 did use a spline for the exact reasons I want to use it for.
A quote from another discussion... Quote:
There is still no way you can accurately recover the original signal (20kHz sampled at 44.1kHz) because that equates to just two samples per cycle. Those two samples do not contain sufficient information to tell you if it was a sine wave, triangular, square or some combination of those. Reconstruction filters are therefore a compromise or an interpolation of the original signal. They assume a smooth transition from one sample to the next, and in "every CD player on the planet" the reconstruction filter boils down to a low pass filter of some sort. See the wikipedia page for The Whittaker–Shannon interpolation formula or sinc interpolation is a method to construct a continuoustime bandlimited function from a sequence of real numbers. On that page it states "This is equivalent to filtering the impulse train with an ideal (brickwall) lowpass filter." It's not that smoothing "may play a limited role", it's a case of smoothing being the entire point of the reconstruction filter. The spline formula, in my opinion (and Wadia's) should do a better job of it than "current main stream technologies". I started this thread because I was thinking about using a single microcontroler to stereo decode SPDIF, create a PWM signal and smooth it with a spline. I had googled DAC and spline and came up empty so asked on this forum expecting that someone might know something about using splines with audio. 

12th April 2015, 10:27 PM  #10  
diyAudio Moderator

Quote:
__________________
"Cities are globs. Globs are bubbling collections. Bubbling collections are hurricanes of the dead and the living all blasting subliminal stories lost in the nether of breezes." 

Thread Tools  Search this Thread 


Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
MP3 PLAYER from PC CDROM or DVDROM  Radu1984  PC Based  1  25th September 2011 05:56 PM 
Oversampling  where does it take place?  audio_tony  Digital Line Level  3  20th December 2008 08:48 AM 
CDRom controller including Remote Control and CDRom power supply  BCP99  Swap Meet  2  22nd April 2007 02:03 AM 
New To Site?  Need Help? 