Sigma Delta simulation help

Status
Not open for further replies.

dawson

Member level 1
Joined
Oct 13, 2012
Messages
34
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Visit site
Activity points
1,537
i've done some simulations on sigma delta ADC. but i think my output is not so correct..anyone can help me out attacedh are my design and waveforms
mainly the decimation design im not sure of.


matlab simulink
1st order sigma delta adc
input: 2V Fb=1kHz , OSR=16 times

the 1 bit DAC simply is matlab m function code

function y = DAC_1_bit(u)
if u == 1;
y = 5;
else y = -5;
end
act as a DAC feedback.

i'm not sure about my output bitstream.. should i use the output from D-flipflop - Q (which will be biit stream of 1s and 0s) or from the output function i've create which have a dc valve of +5 for 1s and -5 for 0s latch from the D-flipflop.

output_1_bit code:

function y = Output_1_bit(u)
if u == 1;
y = 5;
else y = -5;
end

after which feed into FIR decimation.. i just try an error with my coefficient no sure what to put in (anyway my input are : FIR filter coefficients :fir1(16,0.015) ,dec factor of 2.

and my output waveform are as follow:


i've notice 2 things:
1) the output has a half cycle at zeros.
2) my signal max and min are not at 2 and -2..

is this acceptable or am i getting it wrong somewhere.

Regards,
Dawson

- - - Updated - - -

Analog simulation

simulation using ltspice with the coefficient calculated based on Richard schreier "understanding delta-sigma data converters"

1st order SDM


and the output bitstream waveform (blue) is


i've notice a things
1)the bit stream when at high +0.8V it should have more 1s, but my waveform seems to be inverted.

after i interface the ltspice waveform to matlab simulink decimation filter.



and the final decimation waveform is indeed inverted and also there a voltage scale up. it should be +0.8 to -0.8V

- - - Updated - - -



what could be the problem
 
Last edited:

i think is my decimation filter having error.. i dont know how to create a good lpf and decimation for my design.. my voltage is always different from my original sine wave.
 

Read in help command for the detail usage of lpf block in simulink. Study cause of error if you interest in modelling function part.
 

Can u calculate by hand before take up designing? This will be best choice I think so. Another way is using conditional opamp to shape wanted signal on Digital Signal.
 

Or, you must consult the matlab company about that error, directly. But I think you using ideal model so may try to test each block seperately to study behavior of cell.
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…