Go Back   Home > Forums > >
Home Forums Rules Articles diyAudio Store Blogs Gallery Wiki Register Donations FAQ Calendar Search Today's Posts Mark Forums Read

Digital Line Level DACs, Digital Crossovers, Equalizers, etc.

My no DAC project. FPGA and transistors.
My no DAC project. FPGA and transistors.
My no DAC project. FPGA and transistors. 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
Reply
 
Thread Tools Search this Thread
Old 10th August 2019, 02:36 PM   #1
xx3stksm is offline xx3stksm  Japan
diyAudio Member
 
xx3stksm's Avatar
 
Join Date: Jun 2017
Location: Hokkaido(north area)
My no DAC project. FPGA and transistors.
Default My no DAC project. FPGA and transistors.

My no DAC project has achieved successful result after two months trial and error, though it's still under developing. I started to design 1bitDSM(no DAC) PCB to be able to have low noise floor fluctuation because it's relevant to SQ very much in my setup. THD has almost nothing to do with SQ. Theoretically speaking, the best solution to have low fluctuation is 1bitDSM, where no linearity is required in conversion from digital to analog. You can convert PCM into 1bitDSM(DSD) with hardware and make DSD into an analog signal with discrete parts. There are many ways to realize such DAC without a DAC chip. My attempt is FPGA and transistors to satisfy excellent performance which can compete with a modern commercial chip.

Two major strategies are mandatory to achieve the goal. FPGA and transistors with them can already outperform my DIYed 5bit DSM DAC, though the 1st pic is still an experimental result. THD+N is around 113dB, which is an almost impossible number for my 5bit DSM because it has a DAC chip(AD9717). The most challenging or impossible thing for a DAC chip is to have no noise floor fluctuation. I'm sure as long as a DAC chip has a resolution, even if it's 2bit, noise floor fluctuates as the amplitude becomes large. The 2nd pic is DIYed 5bitDSM(my 3bitDSM version also has the same plot). THD+N of 5bitDSM is around 110dB. If it wouldn't have a noise floor increase, you could have the same value as pic 1. THD is excellent because this is just after calibration. It matters little, and two or three days later you can't have the same number.

The 3rd pic is ES9038 made in eBay. This isn't a real performance of the chip since PCB is poor. If you use the chip at -0.1dBFS, the performance becomes far worse(the plot is at -2dBFS). Recent commercial chips usually don't have the best performance at fullscale. PCB construction is inevitably essential. I'm sure even carefully designed PCB can't remove noise floor fluctuation. So is AK4499. AK's homepage has two plots.
TECHNOLOGY | VELVET SOUND | AKM - Asahi Kasei Microdevices
One(the former) is at -155dBFS,the other(the latter) is at 0dBFS. You can see a moderate(6 to 8dB) noise floor increase. I would say low noise floor fluctuation doesn't exist in their to-do list.

1bitDSM itself has an ordinary performance like the 4th pic, though noise floor level and absolute THD are excellent. Small signal level(-28.35dB) prevents you from high performance. One of the two necessary strategies is analog FIR, which is used by pcm1792 in DSD mode. I haven't yet fully understood why it can increase signal amplitude without degradation of THD+N. It can magically boost the signal. S becomes large by analog FIR while THD+N is intact, where you automatically have a better performance like the pic1. The 5th pic is 6taps analog FIR. Noise floor and absolute THD is almost the same as 1tap. Only the signal does increase. The 6th pic is 12taps. The magic increases only the signal again.

The rest of the two strategies is ECL like the 7th pic. If you replace T13 with a register, it's true ECL. T13 configured to constant current determines signal gain by T1. LN_0 and LP_0 are complementary 1bitDSM signal to switch two transistors of T1. When one is active, the other is inactive. Constant current defined by T13 passes through R4 or R1, where the digital signal(1bitDSM) is converted into an analog voltage. The significant advantage of ECL like conversion is PSRR. LN_0 and LP_0 are a dirty signal from the digital section. But the constant current of T13 is almost irrelevant to base voltage of two transistors of T1, which can result in noise-free transfer to the analog voltage across R4 or R1.

There may be several solutions to have isolation between the digital section and the analog one to have low residual noise. No DAC(1bitDSM) project usually has zero PSRR, where ends up less THD+N and prevents 1bitDSM without a DAC chip from the high-end application. If you have better isolation from the digital side, 1bitDSM can have high SNR. ECL is one of the strategies to make noDAC brilliant. ECL is easy to extend, i.e.,2taps,4taps, and more. The more, the better. The disadvantage is instability. It sometimes ends up an oscillation. I have now 24taps with moderate stability. I haven't yet fixed the oscillation problem. I'm not sure if I can have 32taps for further improvement. I'm still on the way.

The 8th pic is x128OSR in 8th order DSM. It has almost the same performance as x64. Noise shaping is, of course, better than x64. Xc6slx9 can have up to 5th order. More than 6th is done by external digital PCB(xc6slx25), which is the same one as my 5bitDSM DAC. The pulse train is transferred through an optical cable to keep high isolation. Onboard Xtal based OSC can successfully recover a clean clock(the 9th pic).
Attached Images
File Type: jpg xc6_x64.jpg (366.0 KB, 1352 views)
File Type: jpg AD9717_1k.jpg (381.5 KB, 1331 views)
File Type: jpg ESS_1kHz.jpg (411.3 KB, 1308 views)
File Type: jpg xc_1tap.jpg (319.9 KB, 1268 views)
File Type: jpg xc_6tap.jpg (320.7 KB, 1227 views)
File Type: jpg xc_12tap.jpg (321.9 KB, 250 views)
File Type: jpg dsd_42.jpg (150.6 KB, 549 views)
File Type: jpg xc6_x128.jpg (302.7 KB, 555 views)
File Type: jpg xc6slx_1.jpg (437.8 KB, 654 views)
  Reply With Quote
Old 10th August 2019, 04:18 PM   #2
JohnW is offline JohnW  Hong Kong
diyAudio Member
 
JohnW's Avatar
 
Join Date: Jan 2004
Location: Discovery Bay, Prague, Paris...
Nice work

I've worked on a discrete DAC design so know how hard it is to get these results

I suspect your odd order distortion (3rd etc.) might be due to the poor Voltage Coefficient of the small 0603 Resistors you use in the DAC (R1 to R6)... Try replacing with a Larger (1206) Thin Film resistors and see if the 3rd harmonic reduces.
__________________
Time is my worst enemy!

Last edited by JohnW; 10th August 2019 at 04:21 PM.
  Reply With Quote
Old 11th August 2019, 07:37 AM   #3
xx3stksm is offline xx3stksm  Japan
diyAudio Member
 
xx3stksm's Avatar
 
Join Date: Jun 2017
Location: Hokkaido(north area)
My no DAC project. FPGA and transistors.
Thank you for your advice. I have never thought about the voltage coefficient of the register. I'm planning to use a high drivability differential amplifier like OPA1632 when I revise the PCB. ADA4898 is a little bit inferior to such op-amp. OPA1632 guarantees 600ohm load at 3Vrms. Theoretically speaking, it's better to use small register for Johnson noise. I was under the impression that such low noise was impossible in no DAC application. OPA1632 and large SMD could be the next step for further improvement. No DAC project is a pure analog circuit. I'm sure the PCB layout and the selection of components dominate performance.
  Reply With Quote
Old 11th August 2019, 08:21 AM   #4
JohnW is offline JohnW  Hong Kong
diyAudio Member
 
JohnW's Avatar
 
Join Date: Jan 2004
Location: Discovery Bay, Prague, Paris...
I should point out first of all that like you have already said, I fully agree that THD has little if any impact to sound quality at these tiny levels, however as "Engineers" its important to understand the source of non linearity so we have a better understanding of the "systems" operation.

Ignoring the Digital noise sharpers, the noise of the 1bit DAC is dependent on :-

1. Jitter / Phase noise of the Clock (and isolation to this noise provided by the Relatching logic).

2. PSU noise on the DAC Array

3. Thermal noise of the components in the DAC array

4. Noise of the analogue circuit after the DAC Array.

I'm VERY surprised you are able to achieve these results without relatching after the FPGA, to remove the phase noise of the Spartans outputs. FPGA's I/O pin drivers are VERY dirty WRT Phase noise - being heavily correlated to the internal processing (A really really bad thing).

Relatching the FPGA outputs to your Master clock will bring huge sound quality benefits, but increase your design complexity.....

Using a balanced OPA such as the OPA1632 will resolve your even order distortion components, these are currently caused by the mismatch in current flowing though your DAC array as a result of your single ended output OPA (the current though your Inverting and non inverting paths is different, as the non inverting is referenced to Ground, while the inverting is referenced to an inverted signal on the output of the OPA, hence more current flows though this arm).

The trouble with the OPA1632 is that the noise performance via balanced outputs will be very good (about 132dB Awtd referenced to 2Vrms) - however the noise performance of its single ended output will be a little over 117dB due to the thermal noise of the effective 15K impedance of its internal feedback resistors (30K from each output phase) to the CM Diff amp.

In single ended operation this noise is purely "Flat" uncorrelated Thermal noise so is not subjectively bad, but it limits the "technical performance"...

TI has a later Fully DIff OPA the THS4551 and its internal CM feedback is reduced to an effective thermal noise source of 2.6K (see page 28 of the Datasheet), so SE noise performance will be improved to about 127dB.

Like THD, its the spectrum of the noise that's important - any correlated products are a big no no... so dont worry too much about nice / pure / clean / flat thermal noise even at 117dB its very low, the only issue is that it could be masking correlated components under the noise floor, and its my experience that we can hear correlated components buried quite deeply below the Noise floor.

If you know your noise spectrum is clean (as you would by looking at the differential outputs) then adding a flat noise is OK

I use OPA1632's on a budget discrete DAC where we dont have the space for a discrete OPA design - I'm OK with a SN of 117dB "flat noise" via the SE outputs, when I know its due 'ONLY' to 'clean' thermal noise, the DAC performance would otherwise be in the 130dB+ region (and is via internal balanced connections)
__________________
Time is my worst enemy!

Last edited by JohnW; 11th August 2019 at 08:42 AM.
  Reply With Quote
Old 11th August 2019, 12:14 PM   #5
xx3stksm is offline xx3stksm  Japan
diyAudio Member
 
xx3stksm's Avatar
 
Join Date: Jun 2017
Location: Hokkaido(north area)
My no DAC project. FPGA and transistors.
Quote:
Originally Posted by JohnW View Post

I'm VERY surprised you are able to achieve these results without relatching after the FPGA, to remove the phase noise of the Spartans outputs. FPGA's I/O pin drivers are VERY dirty WRT Phase noise - being heavily correlated to the internal processing (A really really bad thing).
I agree with you that clock accuracy is critical to have high performance in DSM DAC. But I don't think external logic is better than FPGA I/O. FPGA I/O for driving ECL is output FF, neither internal FF nor LUT logic. Output FF is driven by an internal clock spine with less skew, which is almost impossible to have such an ideal clock by an external logic ic on the PCB. The attached pic is clock skew inside FPGA. Complementary DSM signal for LN_0 and LP_0 have the optimum phase relation, where good eye pattern isn't always the best. "CLK_adj," which is used for H to L, has a fine adjustment for the best phase relation. So, a max delay is not fatal but skew between 24taps must be minimal. If Skew is larger than 0.3ns, you can't have an excellent performance from my experience. It's probably OK if the skew is 0.112ns.

Another advantage of FPGA I/O is power voltage. My current version use LVCMOS1.5V I/O with 16mA capability. Another selection(SSTL or LVDS ) is sometimes the best. You can easily change output configuration by software.
If you design clock distribution circuit by external logic, you can have neither repeatability nor accuracy better than this. Furthermore, rerouting FPGA with different parameters can bring you a successful layout if your first try doesn't have a good result. It's an effortless task. But if you use external logic, rerouting means a redesign of PCB. That's why I don't think external logic is superior to FPGA I/O.
Attached Images
File Type: jpg ck.jpg (78.8 KB, 584 views)
  Reply With Quote
Old 11th August 2019, 12:34 PM   #6
mterbekke is offline mterbekke  Netherlands
diyAudio Member
 
Join Date: Mar 2009
Location: Groningen
Nice work indeed!

Maybe the oscillation problems are due to having to build the cml output yourself. OnSemi has a cml building block that might solve this:

NB4N11M: Multi Level Clock / Data Input to CML Receiver / Buffer / Translator, 2.5 Gbps, 3.3 V

I`ll be closely following this thread !
__________________
Fewer words pls!

Last edited by mterbekke; 11th August 2019 at 12:35 PM. Reason: ecl to cml
  Reply With Quote
Old 11th August 2019, 12:36 PM   #7
mterbekke is offline mterbekke  Netherlands
diyAudio Member
 
Join Date: Mar 2009
Location: Groningen
Would you mind sharing the resistor values for R1 to R4?
__________________
Fewer words pls!
  Reply With Quote
Old 11th August 2019, 01:27 PM   #8
JohnW is offline JohnW  Hong Kong
diyAudio Member
 
JohnW's Avatar
 
Join Date: Jan 2004
Location: Discovery Bay, Prague, Paris...
I'm a retired Audio IC designer so I fully understand the limitations of Silicon when operated in such phase noise critical applications.

Your confusing Skew with Phase noise - they are not related. You can have a bunch of outputs all perfectly matched edges - but this says NOTHING about there phase noise.

FPGA are sub optimal when it comes to I/O phase noise due to the challenges of internal power and clock distribution.

Imbalances in skew are compensated by balanced design of the DAC array.

Before we start pinging back and forth as to who is correct - I'll post a few measurement result of typical FPGA I/O phase noise.

In the test below, the FPGA (Spartin 6) is simply handling a 12MHz clock I/O Passthough via one LVDSI I/O pair (there is no other operation). The Signal is clean but already a very high Nosie floor.

Dropbox - 12MHz Single IO.jpeg

The second graph shows what happens with a second pattern is begin outputted on a second LVDS pair (the second signal is being gated on / off so you can see the effect on the FFT sweep) - you can see the cross induced phase noise modulation between these 2 I/O pairs.

Dropbox - 12MHz IO Isolation.jpeg

This is just a very simple demonstration - only 2 I/O pairs involved, with no "complex" operations being involved, just a simple Clock I/O flow through.... So one imagine the phase noise with complex operations and multiple I/O being performed when its THIS BAD with just two I/Os and no core operation.

Also, ECL is NOT the lowest low phase noise logic due to the low voltage level swings and small device geometry on the input devices of the Diff pair etc.

5V AC CMOS has significantly lower phase noise close to the carrier (basically across the audio bandwidth).

Here is a graph of logic family Phase noise:-

Dropbox - Logic Phase Noise.jpg

LVDS (not shown here) has REALLY poor LF phase noise.

I MUST stress again Output Skew has NOTHING = ZERO to do with I/O Phase noise, and its Phase noise we need to be concerned about when we are directly integrating the energy of output pulses.

Here is the Zoom FFT result of an old 1 Bit SDM discrete DAC array I designed (@ -20dB Ref 4Vrms Balanced as my measurement ADC introduces THD at higher input levels even with the -30dB Pre Notch Filter) - the discrete DAC array is based on CMOS TinyLogic, you can see a noise floor of -165dB with no visible THD....

I operated the Clock and TinyLogic on 6V rails to push the Dynamic range performance

Dropbox - Discrete SDM Array -20dB Zoom FFT.jpg

On the FFT above, the spuire below 1KHz are due to mains related hum - 50Hz / 100Hz products magnetically induced into the measurement setup / lab bench.
__________________
Time is my worst enemy!

Last edited by JohnW; 11th August 2019 at 01:51 PM.
  Reply With Quote
Old 11th August 2019, 08:47 PM   #9
MarcelvdG is offline MarcelvdG  Netherlands
diyAudio Member
 
Join Date: Mar 2003
Location: Haarlem, the Netherlands
Are you measuring phase noise or all kinds of sideband noise added together? Amplitude noise is clipped off by xx3stksm's discrete output differential pairs.
  Reply With Quote
Old 11th August 2019, 09:57 PM   #10
JohnW is offline JohnW  Hong Kong
diyAudio Member
 
JohnW's Avatar
 
Join Date: Jan 2004
Location: Discovery Bay, Prague, Paris...
For the simple tests above, the measurement was made on the FPGA LVDS outputs via a LVDS to CMOS translator (Diff to SE) powered from a clean supply. The LVDS RX has lower close in phase noise then say a TEK P6248 Diff Probe - Active DIff probes are designed for speed rather then PN performance and tend to bottom out around -100dB to -120dB.... (They are really noisy at close carrier offsets).

While the test above was made with a Agilent system, I also have a Wavecreast SIA4000 PN measurement system that has Diff inputs and using passive Diff probes confirms much the same results. I tend to use the Agilent system more as I can directly dump data via GPIB to a PC and its besides my lab bench position...

But for sure, Diff outputs will help with AM to PM conversion but real life CM rejection is really not that good at such high edge speeds at the best of times, with a discrete Diff stage is going to be even harder to get effective CM rejection... Track pair Impedance matching on the PCB with physically small IC's is hard enough, PCB layout with a discrete design would have to be a work of art to achieve decent CM rejection - beyond say 20dB or so at these edge speeds.

I'm guessing that within the FPGA, the signal is routed as "single ended wiring" - I'm really not aware of differential signalling within the Spartan core (beyond the I/O Pads), so the damage to PN is already done before its converted to external Diff signals.

Its a 10 minute job for me to hook-up a PCB if somebody wanted test there design - easiest is to look at a clock output pair on the same I/O bank as the DAC Array outputs to get a picture of PN on the FPGA I/O.
__________________
Time is my worst enemy!

Last edited by JohnW; 11th August 2019 at 10:25 PM.
  Reply With Quote

Reply


My no DAC project. FPGA and transistors.Hide this!Advertise here!
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
FPGA + WM8741 and jitter marcomar82 Digital Source 4 1st May 2013 04:51 AM
how to convert wav into i2s using a fpga dasco1632 Digital Line Level 0 12th October 2011 09:25 AM
Cs4270 <-> Fpga lm317t Digital Source 3 2nd January 2007 06:19 PM
Project: Surround Sound decoder on an FPGA kevpatts Digital Source 6 9th November 2004 08:17 AM
Audio project with an FPGA? gretzteam Digital Source 11 22nd March 2002 04:28 AM


New To Site? Need Help?

All times are GMT. The time now is 06:20 PM.


Search Engine Optimisation provided by DragonByte SEO (Pro) - vBulletin Mods & Addons Copyright © 2019 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 14.29%
vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2019 DragonByte Technologies Ltd.
Copyright ©1999-2019 diyAudio
Wiki