FLEXIBLE : A DITHER AND OVERSAMPLING BASED SOLUTION TO IMPROVE THE PERFORMANCE OF SYSTEMS J.M. Dias Pereira (1), A. Cruz Serra () ad P. Girão () (1) DSI, Escola Superior de Tecologia, Istituto Politécico de Setúbal, Portugal () DEEC, Istituto Superior Técico, Uiversidade Técica de Lisboa, Portugal Abstract: A well-kow techique that ca be used to icrease the resolutio of digitisig systems is based o ditherig, oversamplig ad oise shapig. Ditherig assures a uiform power spectral desity for the quatisatio error, oversamplig. Followed by digital filterig, it improves to oise ratio ad effective umber of bits at the expeses of the iput badwidth. Noise shapig removes quatisatio error power from badwidth. The preset paper itroduces the cocept of a flexible that ca be applied to a ordiary data acquisitio board as a solutio to optimise digitisig systems performace for differet samplig rates. Gais of te or more effective bits ca be obtaied, for low frequecy iput s, usig always the maximum samplig rate of the together with ditherig, oversamplig ad oise shapig techiques. Keywords: Dither, Oversamplig, Noise Shapig. 1 INTRODUCTION Two mai performace parameters i ay digitisig system are resolutio ad samplig rate. Ufortuately, samplig rate ad resolutio are usually competig iterests i the desig of ay acquisitio system, but for a sigle system substatial gais i resolutio ca be obtaied for iput s with low badwidth compared with samplig rate. I the preset paper, ditherig ad oise shapig techiques are used together with oversamplig to optimise the performace of a based digitisig system. Two differet hardware cofiguratios are cosidered to obtai a flexible implemetatio: oe based o a combiatio of a ad a digital processor (DSP) ad aother oe based o a ordiary data acquisitio board (DAQ) with exteral trigger ad clock capabilities. I both cofiguratios, the is used i oversamplig mode with a samplig rate equal to its maximum value. The overall digitisig system behaves, from the view poit of topology, as a multibit sigma-delta (- ) coverter, which takes advatages of digital processig techiques to icremet -to-oise relatio at the expeses of iput badwidth. Effective samplig rate of the digitised is much lower tha samplig rate due to the usage of decimatio, but its resolutio varies iversely with the iput badwidth. Sectio gives a overview of the basic cocepts related to ditherig, oversamplig ad oise shapig, highlightig the compromise betwee resolutio ad badwidth for a oversampled system, ad itroducig two differet hardware solutios to implemet the flexible. Simulated ad experimetal results are preseted i sectios 3.1 ad 3., respectively. Sectio 4 is dedicated to coclusios ad future developmets. SYSTEM DESCRIPTION Figure 1 represets two possible solutios for the hardware block diagram of a flexible. Oe of the solutios (Figure 1(a)) is based o a DAQ board coected to a persoal computer (PC) that performs filterig ad decimatio fuctios. Optioal sychroisatio betwee triggerig ad samplig ca be provided by a phase locked loop (PLL) used as a frequecy multiplier with a factor equal to the oversamplig factor (N). I this case, exteral triggerig ad clock capabilities of DAQ board must be available. Aother solutio, represeted i Figure 1(b), is based o a DSP whose fast o-chip, fixed or floatig poit, multiplier allows the device to perform fudametal digital processig operatios, such as filterig ad decimatio, with optimum efficiecy. Figure represets the coectios betwee the oise shaper block diagram ad the flexible. Noise shapig ca be used to obtai additioal reductio of quatisatio error iside the badwidth. The first order modulator, associated with the, shapes the quatisatio error power
desity so that it lies above the passbad of the digital filter. The effective umber of bits (ENOB) that ca be reached is therefor much larger tha would otherwise be expected from the oversamplig ratio without oise shapig. Aalogue DAQ iput Df I SC Tr Ck S - f FIFO FILT / DEC N f S PC (f S ) N ef NS PLL ( N) Timer (a) Aalogue iput Df I S Tr Ck - f FILT / DEC N f S DSP (f S ) N ef NS PLL ( N) Timer f S Df I (Nyquist criteria) f =Nf S (b) Figure 1. Hardware block diagram of a flexible : (a) usig a data acquisitio board ad a PC; (b) usig a ad a DSP (PC- persoal computer; SC- coditioig circuits; PLL- phase locked loop; FILT- filterig; NS- oise shapig; DEC- decimatio; FIFO- firsti first-out memory; Tr- trigger iput; f - samplig rate; f I - iput badwidth; f s - effective samplig rate; N- oversamplig factor). Aalogue iput - Flexible () PC/DSP N ef H(z) DAC (m) - NS H(z)=z -1 m Figure. Coectios betwee the oise shaper block diagram ad the flexible (NS- oise shaper; - umber of bits of the ; m- umber of bits of the DAC)..1 Oversamplig, filterig ad ditherig The samplig rate (f ) is equal to its maximum value ad the effective samplig rate (f S ), take from the PC or DSP, depeds o the iput badwidth ( f I ). The effective umber of bits (N ef ) obtaied after digital filterig varies i a logarithmic way with the oversamplig factor (N) [1]: 1 N N ef = log (1) 1 k where represets the umber of bits of the, k the ormalised dither amplitude referred to the quatisatio step (Q), ad the oversamplig factor (N) is defied by the ratio betwee samplig rate ad Nyquist rate (f N ) of the iput, defied by:
f = () N f I where ( f I ) represets the iput badwidth. From (1) we coclude that for each additioal effective bit we must icremet the oversamplig by a factor equal to four. Cosequetly, the relatio betwee iput badwidth ( f I ) ad samplig rate (f ) is give by the followig expressio: Äf Äf 1 XVI IMEKO World Cogress I I = = (3) ( ) f NfS (1 k ) From the last expressio we obtai the well kow result that the iput badwidth is reduced to oe quarter of its value for each additioal effective bit gai whe oversamplig ad filterig techiques are used. I order to assure a uiform power spectral desity of the quatisatio error [], self-ditherig provided by the oise aturally added to the ad by the iteral oise is usually eough, cosiderig that the amplitudes of those oise s are adequate for ditherig purposes. These oise s are also assumed to be ucorrelated with the aalogue iput of the coverter. If this is ot the case, or if large-scale ditherig is required to miimise o-liearities [3], a additive or subtractive topology must be cosidered (Figure 3), ad for the last case expressios (1) ad () are still valid with k=0. For determiistic ditherig with a auto-subtractive topology, dither subtractio is achieved without the eed of a actual subtractor. The subtractig effect is maitaied as log as the dither experieced by the iput exhibits a zero mea value ad the liear filter averages the digital over a iteger umber of dither periods. Aalogue iput Iput - DAC PRN DAC PRN (a) Figure 3. Dither isertio topologies: (a) additive or auto-subtractive; (b) subtractive (PRN- pseudo radom oise ).. Noise shapig Additioal gais i effective umber of bits, without so high badwidth pealties, ca be obtaied with the usage of oise shapig techiques that remove quatisatio error from badwidth (base-bad) to out-of-bad, ad is afterwards cacelled by filterig. Supposig that the quatisatio error desity is frequecy idepedet i the bad f=0 to f=f /, the total oise power associated with the quatisatio error for a first-order oise shaper (Fig. ), after filterig, is give by [4]: fs/ jð f/f S NQ = q 1 e df (4) 0 where q represets the power desity of uiform quatisatio error. Usig Euler s relatioship ad some trigometric equalities, the result of the itegratio represeted by (4) is equal to: N Q Q = 4 1 1 N 1 ð si ð N where Q represets the quatisatio step of the ad N the oversamplig factor previously defied. The -to-oise relatio gai (SNR G ) associated with filterig ad oise shapig is give by: SNR Q /1 = = 1 1 N 1 ð si G NQ 4 ð N Usig a third order Taylor series approximatio for the fuctio si(x): 1 (b) (5) ()
3 x si(x) x (7) it is possible to obtai: 3 3 1 1 1 p p 3N SNR G = - - 3 = 4 N ð N N ð ad usig logarithmic uits: -1 SNRG(dB) 30log(N) 5. db (9) From the last expressio it is possible to cofirm that for each duplicatio of the oversamplig factor ( N=), the to oise relatio gai ( SNR G ) is equal to 9 db, which correspods to a gai of 1.5 effective bits of the digitisig system. This meas that for the same oversamplig factor (N>>1), the effective umber of bits gai with oise shapig is three times higher tha the oe obtaied with oversamplig ad filterig aloe. 3 RESULTS EVALUATION A LabVIEW simulator was developed to study global effects of oversamplig, ditherig ad oise shapig techiques o digitalisatio. Experimetal results to cofirm the effective umber of bits gai as a fuctio of the iput frequecy were obtaied with a Keithley-Metrabyte data acquisitio board (DAS4) that has the followig mai characteristics: maximum samplig rate=4 MS/s; umber of bits: = (flash type); iteral samplig rates: 0.5; 1.0;.0; 4.0;.0; 1.0; 3.0; 4.0 MS/s. 3.1 Simulatio results The mai iput parameters of the simulator are: oversamplig factor (N), ad oise amplitudes, dither characteristics amplitude, period ad type, umber of bits () of the, digitalisatio optios filterig, decimatio ad oise shapig ad sie wave curve fittig covergece parameters maximum umber of iteratios ad tolerace (maximum error). The mai parameters of the simulator are: sie wave iterpolated, coversio error ad effective umber of bits of the digitised. The four parameters (amplitude, frequecy, iitial phase ad offset) least mea squares algorithm for sie wave fittig [5], usig matrix operatios, was fully implemeted i LabVIEW. No-liearity errors of the coverter ca also be easily added to the model virtual istrumet (VI). Figure 4 represets the frot pael of the virtual istrumet ad i Figure 5 are preseted simulator results for a oversamplig factor (N) betwee 4 ad 1, a six bit (=) ad a uiform dither compoet with the followig characteristics: amplitude equal to 1 LSB (least sigificat bit) ad period equal to 1. () Figure 4. Frot pael of the LabVIEW virtual istrumet used for simulatio.
9 (4) 7 () (1) (3) 5 4 Figure 5. 3 4 5 7 9 11 1 13 14 log (N) Simulated results: (1)- without dither, filterig ad oise shapig; ()- with dither, oise shapig ad o filterig; (3)- with dither, filterig ad o oise shapig; (4)- with dither, filterig ad oise shapig. As mai coclusios after several simulatios it is importat to refer that filterig ad oise shapig techiques require a miimum value of oversamplig factor i order to be effective ( amplitude variatio betwee samples less tha 1 LSB); oise shapig advatage over filterig is oly visible whe the oversamplig factor is larger tha a miimum value (i the example N= ). For each oversamplig factor value there is a optimal value of dither period ad amplitude that maximises digitisig system performace. 3. Experimetal results Experimetal results, represeted i Figure, were obtaied usig a DAQ board from Keitlley- Metrabyte (DAS4) ad a sie wave geerator with eough accuracy for a eight-bit coverter (HP33-A). Curve (a) represets the effective umber of bits (ENOB) as a fuctio of iput frequecy, assumig a maximum iteger oversamplig factor without applicatio of oise shapig techiques. Curve (b) represets the same kid of data for a oversamplig factor equal to a iteger power of two. Fially curve (c) represets the effective umber of bits (ENOB) as a fuctio of iput frequecy, assumig a maximum iteger oversamplig factor equal to a iteger power of two but with applicatio of oise shapig techiques. Effective umber of bits evaluatio was based o the sie wave curve fittig algorithm (four parameters). Sychroisatio betwee the exteral clock ad triggerig of the data acquisitio board was provided by a phase locked loop (PLL) circuit. These results clearly show the advatages that ca be obtaied with the proposed method, especially whe low frequecy s are preset at the iput of the digitisig system. 15 14 15 14 13 13 1 1 11 11 9 9 7 7 5 0 5 15 0 5 30 f I (MHz) (a) 5 0 5 15 0 5 30 f I (MHz) (b)
4 0 1 1 14 1 0 5 15 0 5 30 f I (MHz) (c) Figure. Effective umber of bits as a fuctio of iput frequecy for a bit coverter: (a) maximum iteger oversamplig factor without oise shapig; (b) maximum iteger power of two oversamplig factor without oise shapig; (c) maximum iteger power of two oversamplig factor with oise shapig (cotiuous lie theoretical results; symbol * experimetal results). Maximum relative differece betwee experimetal ad expected theoretical effective umber of bits is lower tha 5%. This differece ca be explaied takig ito cosideratio the differetial oliearity (DNL) ad itegral o-liearity (INL) errors of the DAQ board which are equal to 0. LSB, its maximum -to-oise relatio equal to 4.3 db (N ef =7.4), distortio of iput geerator ad other errors associated with digital processig, like coefficiet quatisatio ad trucatio errors of digital filters. 4 CONCLUSIONS AND FUTURE DEVELOPMENTS Simulated ad experimetal results show clearly the advatages of the proposed priciple of the flexible. The techique ca be applied to a ordiary DAQ board ad assures a complete usage of performace for all effective samplig rates. Gai of 1.5 bits ca be obtaied for each doublig of oversamplig factor (N). At the same time, usage of oversamplig miimises the accuracy requiremets of the sample-ad-hold amplifiers, eases the desig of atialiasig filters ad miimises differetial o-liearity errors (DNL) that are a serious problem for low amplitude s []. Results obtaied with the simulator, developed to study global effects of ditherig, oise shapig, filterig ad decimatio, i the presece of iput o-statioary s, poit out that for determiistic dither there is a optimum value of dither amplitude ad period for each value of oversamplig factor. As future developmets of the preset work, it will be cosidered a automatic selectio of the oversamplig factor based o the iput frequecy cotets obtaied usig a FFT algorithm. This capability, together with the flexible cocept itroduced i this paper, creates what we ca call smart with a automatic selectio of resolutio as a fuctio of the iput badwidth. REFERENCES [1] Ja Holub, Josef Vedral, Dithered Quatizer of Plug-I Card: Theoretical Model ad Practical Testig, XIV IMEKO World Cogress, Vol.IVb, pp. 7-90, Tampere, Filad, Jue 1997. [] Robert M. Gray, Quatizatio Noise Spectra, IEEE Trasactios o Iformatio Theory, Vol.3, No., Nov. 1990. [3] Paolo Carboe, Claudio Narduzzi, Dario Petri, Dither Sigal Effects o the Resolutio of Noliear Quatizers, IEEE Trasactios o Istrumetatio ad Measuremet, Vol. 43, No., pp. 139-145, April 1994. [4] Rudy va de Plassche, Itegrated Aalog-to- ad -to-aalog Coverters, Kluwer Academic Publishers, 1994. [5] Istitute of Electrical ad Electroics Egieers, Ic., IEEE Stadard for Digitizig Waveform Recorders, IEEE Std 57-1994, pp. 35-3, December 1994. [] Brad Brao, Overcomig Coverter Noliearities with Dither, Applicatio Note 4 (AN-4), Aalog Devices, 199. AUTHOR(S): Adj. Prof. Dr. J.M. Dias Pereira, Departameto de Sistemas e Iformática, Escola Superior de Tecologia, Rua do Vale de Chaves, Estefailha, 9 Setúbal, Portugal, Tel. 351-5- 790000 Ext 54, Fax 351-5-719, E-mail: joseper@est.ips.pt