Continue to Site

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.

Regarding amplitude measurement from I and Q samples

Maitry07

Advanced Member level 4
Full Member level 1
Joined
Jun 29, 2022
Messages
102
Helped
0
Reputation
0
Reaction score
0
Trophy points
16
Activity points
897
Hello support team,

I have implemented direct conversion method to generate I and Q samples from the RF frequency. and then I am using FPGA IP core to convert I and Q samples to amplitude measurement. I am taking digital samples of measured amplitude.
My input RF-ADC has 14 bit resolution and having very high dynamic range.

When I am applying RF input power -15 dBm to -2 dBm, I am getting accurate amplitude measurement having accuracy of 0.11 dB within 1,00,000 samples.
As I am using function generator to generate 35 MHz RF input. In order to verify the lower amplitude , I have tried attenuator of 30 dB to generate -45 dBm RF input. But I have observed that with the lower power of -45 dBm, my amplitude measurement accuracy becomes poor near to 1.9 dB within 1,00,000 samples.

What should be the reason behind that? Can attenuator of 30 dB provide very high group delay which further reduce my amplitude accuracy?
because my RF-ADC has very high dynamic range. then why I am not getting good accuracy with lower amplitude?

Instead of using function generator+attenuator to generate lower RF amplitude, should I use stable signal generator like keysight that can directly provide stable lower amplitude RF signal?

Awaited your response.
 

kaz1

Full Member level 4
Full Member level 4
Joined
Aug 15, 2019
Messages
223
Helped
14
Reputation
28
Reaction score
32
Trophy points
28
Location
UK
Activity points
1,398
In order to simplify your debugging try avoid concept of dBm or dB. Just measure the mean of I^2+Q^2 and compare across RF levels. Then tell us what you are getting
 

Maitry07

Advanced Member level 4
Full Member level 1
Joined
Jun 29, 2022
Messages
102
Helped
0
Reputation
0
Reaction score
0
Trophy points
16
Activity points
897
I am getting SQRT(I^2+Q^2) which is Vpk ,

From which I am using formulla for getting it into dBm

PdBm = 10*log (10. (I^2+Q^2)
 

kaz1

Full Member level 4
Full Member level 4
Joined
Aug 15, 2019
Messages
223
Helped
14
Reputation
28
Reaction score
32
Trophy points
28
Location
UK
Activity points
1,398
I am getting SQRT(I^2+Q^2) which is Vpk ,

From which I am using formulla for getting it into dBm

PdBm = 10*log (10. (I^2+Q^2)
Avoid that calculation as well for Forum so we can help.
Just show us the mean value of I^2+Q^2
 

albbg

Advanced Member level 4
Advanced Member level 4
Joined
Nov 7, 2009
Messages
1,272
Helped
438
Reputation
876
Reaction score
396
Trophy points
1,363
Location
Italy
Activity points
9,586
I am getting SQRT(I^2+Q^2) which is Vpk ,

From which I am using formulla for getting it into dBm

PdBm = 10*log (10. (I^2+Q^2)
You have to convert first the result from Vpk to Vrms (even if I expected I and Q to be already rms). In case of sinewave just divide by sqrt(2).
Then calculate the power in mW:

P(mW) = 1000*Vrms^2/R

then take the log to convert to dBm:

P(dBm) = 10*Log(1000*Vrms^2/R)

usually R=50 thus:

P(dBm) = 10*Log(20*Vrms^2) = 13 + 20*Log(Vrms)
 

Maitry07

Advanced Member level 4
Full Member level 1
Joined
Jun 29, 2022
Messages
102
Helped
0
Reputation
0
Reaction score
0
Trophy points
16
Activity points
897
Avoid that calculation as well for Forum so we can help.
Just show us the mean value of I^2+Q^2
For I^2+Q^2 , when I am applying -4.7 dBm RF input, below are the max and min value for the conseutive 1,31,072 samples.

Min value (I^2+Q^2) = 0.033015493
Max value (I^2+Q^2) = 0.033976138
Difference in measurement = 0.00096044

For I^2+Q^2 , when I am applying -40 dBm RF input using attenuator of 30 dB at the output of function generator, below are the max and min value for the conseutive 1,31,072 samples.

Min value (I^2+Q^2) = 7.8827*10^-6
Max value (I^2+Q^2) = 2.9508*10^-5
Difference in measurement = 2.1625 *10^-5

FYI: When I have verified function generator output with spectrum analyzer, I have observed that with lower amplitude from the function generator, I am getting unstable output at spectrum. so I am suspecting that function generator itself is providing unstable output at the lower amplitude.
 

kaz1

Full Member level 4
Full Member level 4
Joined
Aug 15, 2019
Messages
223
Helped
14
Reputation
28
Reaction score
32
Trophy points
28
Location
UK
Activity points
1,398
For I^2+Q^2 , when I am applying -4.7 dBm RF input, below are the max and min value for the conseutive 1,31,072 samples.

Min value (I^2+Q^2) = 0.033015493
Max value (I^2+Q^2) = 0.033976138
Difference in measurement = 0.00096044

For I^2+Q^2 , when I am applying -40 dBm RF input using attenuator of 30 dB at the output of function generator, below are the max and min value for the conseutive 1,31,072 samples.

Min value (I^2+Q^2) = 7.8827*10^-6
Max value (I^2+Q^2) = 2.9508*10^-5
Difference in measurement = 2.1625 *10^-5

FYI: When I have verified function generator output with spectrum analyzer, I have observed that with lower amplitude from the function generator, I am getting unstable output at spectrum. so I am suspecting that function generator itself is providing unstable output at the lower amplitude.
I will assume you have divided I/Q by 2^15 to get fractional values.
-4.7dBm => 10*log10(0.033496) = -14.75 dB (average)
-40dBm => 10log10(1.8695e-05) = -47.283 dB (average)
The change of dBm is 35.3 dB
The change of dB is 32.5 dB
not that bad and if I take minimum values only it gets better.
 

albbg

Advanced Member level 4
Advanced Member level 4
Joined
Nov 7, 2009
Messages
1,272
Helped
438
Reputation
876
Reaction score
396
Trophy points
1,363
Location
Italy
Activity points
9,586
For I^2+Q^2 , when I am applying -4.7 dBm RF input, below are the max and min value for the conseutive 1,31,072 samples.

Min value (I^2+Q^2) = 0.033015493
Max value (I^2+Q^2) = 0.033976138
Difference in measurement = 0.00096044

For I^2+Q^2 , when I am applying -40 dBm RF input using attenuator of 30 dB at the output of function generator, below are the max and min value for the conseutive 1,31,072 samples.

Min value (I^2+Q^2) = 7.8827*10^-6
Max value (I^2+Q^2) = 2.9508*10^-5
Difference in measurement = 2.1625 *10^-5
Using the formula I gave, in the case Vrms = Vpk/sqrt(2):

P(dBm) = 10 + 20*Log(Vpk)

and since your values are already squared we can apply:

P(dBm) = 10 + 10*Log(I^2+Q^2)

With your figures:

P1 = 10 + 10*Log(0.033015493)=-4.8dBm
P2 = 10 + 10*Log(0.033976138)=-4.7dBm

P3 = 10 + 10*Log(7.8827e-6)=-41.0dBm
P4 = 10 + 10*Log(2.9508e-5)=-35.3dBm

At low amplitude there is a huge difference between max and min value. What about the waveform ?
In the first post you said the low amplitude was obtained by means of an attenuator, but in post #6 it seems that the low amplitude was obtained regualating the generator itself (and it seems it's no working properly). In this last case try to lock the output power of the generator and change the level by means of attenuators. Or, better, use another generator.
 

FvM

Super Moderator
Staff member
Advanced Member level 7
Joined
Jan 22, 2008
Messages
51,002
Helped
14,633
Reputation
29,542
Reaction score
13,742
Trophy points
1,393
Location
Bochum, Germany
Activity points
291,790
Possible reasons for measurement error with lower manitude are DC offset and noise. Analysing the output with zero input will clarify.
 

kaz1

Full Member level 4
Full Member level 4
Joined
Aug 15, 2019
Messages
223
Helped
14
Reputation
28
Reaction score
32
Trophy points
28
Location
UK
Activity points
1,398
Using the formula I gave, in the case Vrms = Vpk/sqrt(2):

P(dBm) = 10 + 20*Log(Vpk)

and since your values are already squared we can apply:

P(dBm) = 10 + 10*Log(I^2+Q^2)

With your figures:

P1 = 10 + 10*Log(0.033015493)=-4.8dBm
P2 = 10 + 10*Log(0.033976138)=-4.7dBm

P3 = 10 + 10*Log(7.8827e-6)=-41.0dBm
P4 = 10 + 10*Log(2.9508e-5)=-35.3dBm

At low amplitude there is a huge difference between max and min value. What about the waveform ?
In the first post you said the low amplitude was obtained by means of an attenuator, but in post #6 it seems that the low amplitude was obtained regualating the generator itself (and it seems it's no working properly). In this last case try to lock the output power of the generator and change the level by means of attenuators. Or, better, use another generator.
isn't your first formula saying:
P(dBm) = 13 + 20*Log(Vrms)
Why changed 13 to 10 ?
 

LaTeX Commands Quick-Menu:

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top