Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Direct digital down conversion NCO frequency and DDC output( complex baseband I,Q)

Maitry07

Junior Member level 2
Joined
Jun 29, 2022
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
176
Hello All,

My input frequency is pure sine wave RF signal ( No modulation) . My requirement is to use direct sampling reception of the input signal, generate I,Q using DDC algorithm. and my main aim is to calculate amplitude and phase from the received I and Q samples.

Now, My input frequency is slightly varying in between 1 MHz. let's say, right now my input frequency is 40 MHz, then its variation is from 39-41 MHz. So, I am planning to set the NCO frequency as 39 MHz. Then my DDC output ( complex output spectrum) will be from DC-2 MHz based on the variation of the input frequency. also, DDC output decimation is done up to 10 MSPS. so DC-2 MHz will be within the range of the Decimation filter.

and then from the generated I,Q , We will measure the amplitude and phase. I am thinking of the above, so that I don't have to vary NCO frequency every time there is a slight change in input frequency. As my main signal is sine wave and my main aim is to measure amplitude from the received I,Q samples.
Is my above approach correct to have the DDC output variable within the DC-2 MHz range and not constant DC ?
It would be very helpful if you could suggest and provide support on the above case as soon as possible.
 

kaz1

Full Member level 2
Joined
Aug 15, 2019
Messages
139
Helped
11
Reputation
22
Reaction score
21
Trophy points
18
Location
UK
Activity points
970
Hello All,

My input frequency is pure sine wave RF signal ( No modulation) . My requirement is to use direct sampling reception of the input signal, generate I,Q using DDC algorithm. and my main aim is to calculate amplitude and phase from the received I and Q samples.

Now, My input frequency is slightly varying in between 1 MHz. let's say, right now my input frequency is 40 MHz, then its variation is from 39-41 MHz. So, I am planning to set the NCO frequency as 39 MHz. Then my DDC output ( complex output spectrum) will be from DC-2 MHz based on the variation of the input frequency. also, DDC output decimation is done up to 10 MSPS. so DC-2 MHz will be within the range of the Decimation filter.

and then from the generated I,Q , We will measure the amplitude and phase. I am thinking of the above, so that I don't have to vary NCO frequency every time there is a slight change in input frequency. As my main signal is sine wave and my main aim is to measure amplitude from the received I,Q samples.
Is my above approach correct to have the DDC output variable within the DC-2 MHz range and not constant DC ?
It would be very helpful if you could suggest and provide support on the above case as soon as possible.
depends on actual requirement.
if you target just amplitude/phase then I see your approach ok. you will get the tone at +/- 1MHz off dc. amplitude should be same within 2MHz range assuming good filter passband but phase could vary.
However if requirement is to push tone to dc correctly then you need DDC to vary and to lock to input tone
 

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
22,244
Helped
4,613
Reputation
9,242
Reaction score
4,878
Trophy points
1,393
Activity points
146,953
Hi,

sample I and Q simultaneously and you are able to do amplitude and phase calculation without caring about sampling frequency.

There are other methods. But mind that NCO frequency jitters.

Klaus
 

Maitry07

Junior Member level 2
Joined
Jun 29, 2022
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
176
Thank you for your quick response. to further elaborate,

Yes, My actual target is to get amplitude/phase from the received I,Q from the input pure sine wave RF signal and my main requirement is to do this in the shortest time possible.

So, if I try to vary NCO automatically as per input frequency variation, I have to update the NCO frequency using SPI registers every time based on the difference from DC received in the DDC output. this process will take some micro sec time. As My input frequency variation would be unknown to me. so, to lock the input tone, I need to follow the above automated process.

but as my requirement is to get the exact amplitude and phase from the received I,Q samples only. so, I thought to have variable DDC output.

So, please guide , is this approch correct or you can suggest a better way to fast the process of automation NCO frequency update based on the FFT difference. my NCO freq. is updated using SPI and will take almost 3 usec for 1 KHz frequency variation.
 

kaz1

Full Member level 2
Joined
Aug 15, 2019
Messages
139
Helped
11
Reputation
22
Reaction score
21
Trophy points
18
Location
UK
Activity points
970
Thank you for your quick response. to further elaborate,

Yes, My actual target is to get amplitude/phase from the received I,Q from the input pure sine wave RF signal and my main requirement is to do this in the shortest time possible.

So, if I try to vary NCO automatically as per input frequency variation, I have to update the NCO frequency using SPI registers every time based on the difference from DC received in the DDC output. this process will take some micro sec time. As My input frequency variation would be unknown to me. so, to lock the input tone, I need to follow the above automated process.

but as my requirement is to get the exact amplitude and phase from the received I,Q samples only. so, I thought to have variable DDC output.

So, please guide , is this approch correct or you can suggest a better way to fast the process of automation NCO frequency update based on the FFT difference. my NCO freq. is updated using SPI and will take almost 3 usec for 1 KHz frequency variation.
so is your requirement to lock to tone(carrier tracking)?
If so you need some more work. fft can do but has latency. search for Costas loop.
 

Maitry07

Junior Member level 2
Joined
Jun 29, 2022
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
176
so is your requirement to lock to tone(carrier tracking)?
If so you need some more work. fft can do but has latency. search for Costas loop.
Hi,

No , my requirement is not of carrier tracking. My requirement is to receive the input signal using direct sampling ADC and with the use of DDC algorithm , I just want to measure accurate amplitude and phase. and further provide this amplitude to control loops to generate error signal.

that is my main requirement.

So, from the pure sine wave input signal , I want to do some automatic gain control, convert it to I,Q using DDC , do the compensation of all the external gain/losses and measure correct amplitude and phase for the continuous received I and Q samples.
 

kaz1

Full Member level 2
Joined
Aug 15, 2019
Messages
139
Helped
11
Reputation
22
Reaction score
21
Trophy points
18
Location
UK
Activity points
970
so you don't need tracking. Fair enough.
Just wondered why then down convert. Can't you just deal with 40Mhz direct or is it too fast.
 

Maitry07

Junior Member level 2
Joined
Jun 29, 2022
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
176
so you don't need tracking. Fair enough.
Just wondered why then down convert. Can't you just deal with 40Mhz direct or is it too Fast?
Yes, it is fast for my further processing. I need to reduce the sampling rate to 10 MSPS. that's why i decided to use direct sampling using DDC algorithm.
 

kaz1

Full Member level 2
Joined
Aug 15, 2019
Messages
139
Helped
11
Reputation
22
Reaction score
21
Trophy points
18
Location
UK
Activity points
970
Yes, it is fast for my further processing. I need to reduce the sampling rate to 10 MSPS. that's why i decided to use direct sampling using DDC algorithm.
With such simple requirement you may also consider under sampling then using alias of tone without the need for DDC or decimation.
 

Maitry07

Junior Member level 2
Joined
Jun 29, 2022
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
176
With such simple requirement you may also consider under sampling then using alias of tone without the need for DDC or decimation.
Hello,

Oh I got your point. yes, thank you for your guidance. I will start thinking to use under sampling and aliasing of tone. But then , without the use of DDC , direct digital IQ detection process I need to identify , right?
 

kaz1

Full Member level 2
Joined
Aug 15, 2019
Messages
139
Helped
11
Reputation
22
Reaction score
21
Trophy points
18
Location
UK
Activity points
970
Hello,

Oh I got your point. yes, thank you for your guidance. I will start thinking to use under sampling and aliasing of tone. But then , without the use of DDC , direct digital IQ detection process I need to identify , right?
yes, to calculate alias frequency (fa):
fa = 2FN - F (double Nyquist minus signal tone)
for example if you sample at 30Msps you get tone at:
2*15 - 40 = -10 which if real will be +/-10Mhz
 

Maitry07

Junior Member level 2
Joined
Jun 29, 2022
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
176
yes, to calculate alias frequency (fa):
fa = 2FN - F (double Nyquist minus signal tone)
for example if you sample at 30Msps you get tone at:
2*15 - 40 = -10 which if real will be +/-10Mhz
Ok, so what I understand is that using sample rate in such a way , my input single tone is aliased back to lower frequency. and then I need to convert the digital samples to I and Q to further calculate amplitude? then which method i need to follow for I,Q detection?
 

kaz1

Full Member level 2
Joined
Aug 15, 2019
Messages
139
Helped
11
Reputation
22
Reaction score
21
Trophy points
18
Location
UK
Activity points
970
Ok, so what I understand is that using sample rate in such a way , my input single tone is aliased back to lower frequency. and then I need to convert the digital samples to I and Q to further calculate amplitude? then which method i need to follow for I,Q detection?
if you just want amplitude then you don't need IQ. You can just compute directly with some avaraging.
If you want phase then you need to explain what is it for. Because either way (I/Q method) or direct phase of tone is relative issue and depends on ADC sampling timing.

Normally IQ is obtained by using cos/sin mixing. Or in case of single tone you can shift one adc clock by 90 degrees
 

Maitry07

Junior Member level 2
Joined
Jun 29, 2022
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
176
Hello,
Yes I have to calculate phase as well. For the 2 diff. input signal , relative phase I need to measure.

Yes, As IQ obtaining from cos/sin mixing that what I had thought before using NCO only . based on that only, I have raise the query.
 

kaz1

Full Member level 2
Joined
Aug 15, 2019
Messages
139
Helped
11
Reputation
22
Reaction score
21
Trophy points
18
Location
UK
Activity points
970
Hello,
Yes I have to calculate phase as well. For the 2 diff. input signal , relative phase I need to measure.

Yes, As IQ obtaining from cos/sin mixing that what I had thought before using NCO only . based on that only, I have raise the query.
Phase of a single tone changes around full cycle. Its starting point varies with ADC capture start. when comparing two tones at same frequency then one can compare the two all along or at some agreed point of circle. when tone is complex its phase is atan2(Q,I) or "angle(x)" in matlab.
Comparing phase of two tones at different frequencies is not helpful.
 

Maitry07

Junior Member level 2
Joined
Jun 29, 2022
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
176
Phase of a single tone changes around full cycle. Its starting point varies with ADC capture start. when comparing two tones at same frequency then one can compare the two all along or at some agreed point of circle. when tone is complex its phase is atan2(Q,I) or "angle(x)" in matlab.
Comparing phase of two tones at different frequencies is not helpful.
yes, my both input signal is having same frequency. just the amplitude is different.
 

LaTeX Commands Quick-Menu:

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top