DSPRelated.com
Forums

CORDIC based FM demodulation

Started by ma November 21, 2006
Randy Yates wrote:
> Jerry Avins <jya@ieee.org> writes: > >> ma wrote: >>> No answer to my questions or maybe nobody saw them. >>> Can you please help me to find the answer to my questions? >>> there are here: marked as [MA] >> I'm out of my depth here. What does frequency modulation at baseband >> mean? For that matter what does AM at baseband mean? > > Baseband is what you get if you filter a carrier-based signal at the > desired bandwidth and then translated the positive half frequencies of > the resulting band-limited signal so that the carrier frequency > becomes DC. > > For example, say you had an FM station at 89.7 MHz. You'd filter at > 89.6-89.8 (I'm assuming the marketing frequency is the center > frequency) and then translate the positive freequencies from 89.7 MHz > down to DC. > > This is synonymous with "quadrature downconversion." Note that > baseband signals are, in general, complex.
The positive and negative FM sidebands are symmetric only with single-signal pure sinusoidal modulation. Discard with the upper or lower sideband, and the result (except for narrow-band FM) is useless. Jerry -- Engineering is the art of making what you want from things you can get. &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;
> The quotient rule of elementary differential calculus tells us that > IQ'-QI'/(I^2+Q^2) = (Q/I)'
I know that this formula works, but for the life of me I can't remember why. Wouldn't Q/I (in which Q is related to sin(2*pi*fdev*m(t)) and I is related to cos(2*pi*fdev*m(t))) give you a term related to tan(2*pi*fdev*m(t))? Then, the derivative would give you some ugly trigonometric function of the phase term that you're looking for. Isn't an arctangent still necessary at some point? It would seem to me that you would want (arctan(Q/I))' instead of just (Q/I)'. Then, the derivative can be approximated using finite differences to get the message signal out. Am I incorrect here? Jason
cincydsp@gmail.com wrote:
> > The quotient rule of elementary differential calculus tells us that > > IQ'-QI'/(I^2+Q^2) = (Q/I)' > > I know that this formula works, but for the life of me I can't remember > why. Wouldn't Q/I (in which Q is related to sin(2*pi*fdev*m(t)) and I > is related to cos(2*pi*fdev*m(t))) give you a term related to > tan(2*pi*fdev*m(t))? Then, the derivative would give you some ugly > trigonometric function of the phase term that you're looking for. Isn't > an arctangent still necessary at some point? It would seem to me that > you would want (arctan(Q/I))' instead of just (Q/I)'. Then, the > derivative can be approximated using finite differences to get the > message signal out. Am I incorrect here? > > Jason
(Q/I)' = (QI' - IQ') / I^2 which isn't the frequency. The frequency is (atan(Q/I))'. Set I = Acoswt and Q = Asinwt and you should get w out. John John The frequency is actually (atan(Q/I)' which is
cincydsp@gmail.com wrote:
>> The quotient rule of elementary differential calculus tells us that >> IQ'-QI'/(I^2+Q^2) = (Q/I)' > > I know that this formula works, but for the life of me I can't remember > why. Wouldn't Q/I (in which Q is related to sin(2*pi*fdev*m(t)) and I > is related to cos(2*pi*fdev*m(t))) give you a term related to > tan(2*pi*fdev*m(t))? Then, the derivative would give you some ugly > trigonometric function of the phase term that you're looking for. Isn't > an arctangent still necessary at some point? It would seem to me that > you would want (arctan(Q/I))' instead of just (Q/I)'. Then, the > derivative can be approximated using finite differences to get the > message signal out. Am I incorrect here?
The quotient rule is a concatenation of the product rule and the chain rule. (Q/I)' = (Q*I^-1)' = (I^-1)*Q' + Q*(I^-1)' = Q'/I + Q*I^-2*Q'. Yes, you want arctan(Q/I), but you need to find Q/I first. If the sample rate is high enough to keep Q/I < .1, the arctan may not be needed. (Arctan(.1) = .0997) Jerry -- Engineering is the art of making what you want from things you can get. &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;
Jerry Avins wrote:
> cincydsp@gmail.com wrote: >>> The quotient rule of elementary differential calculus tells us that >>> IQ'-QI'/(I^2+Q^2) = (Q/I)' >>
Cincydsp, Shouldn't this be the following? (IQ'-QI')/I^2 = (Q/I)' ---- (1)
>> I know that this formula works, but for the life of me I can't remember >> why. Wouldn't Q/I (in which Q is related to sin(2*pi*fdev*m(t)) and I >> is related to cos(2*pi*fdev*m(t))) give you a term related to >> tan(2*pi*fdev*m(t))? Then, the derivative would give you some ugly >> trigonometric function of the phase term that you're looking for. Isn't >> an arctangent still necessary at some point? It would seem to me that >> you would want (arctan(Q/I))' instead of just (Q/I)'. Then, the >> derivative can be approximated using finite differences to get the >> message signal out. Am I incorrect here? > > The quotient rule is a concatenation of the product rule and the chain > rule. (Q/I)' = (Q*I^-1)' = (I^-1)*Q' + Q*(I^-1)' = Q'/I + Q*I^-2*Q'.
Jerry, I think you meant: (Q/I)' = (Q*I^-1)' = (I^-1)*Q' + Q*(I^-1)' = Q'/I + Q*(-I^-2)*I' This is then the same as: (Q'/I)' = (Q'*I - Q*I')/I^2 --- as in (1) above. Regards, John
John Monro wrote:

   ...

> Jerry, > I think you meant: > (Q/I)' = (Q*I^-1)' = (I^-1)*Q' + Q*(I^-1)' = Q'/I + Q*(-I^-2)*I' > This is then the same as: > (Q'/I)' = (Q'*I - Q*I')/I^2 --- as in (1) above.
Thank you, John. I should use paper and pencil before I type text like that. Jerry -- Engineering is the art of making what you want from things you can get. &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;
Jerry Avins wrote:
> John Monro wrote: > > ... > >> Jerry, >> I think you meant: >> (Q/I)' = (Q*I^-1)' = (I^-1)*Q' + Q*(I^-1)' = Q'/I + Q*(-I^-2)*I' >> This is then the same as: >> (Q'/I)' = (Q'*I - Q*I')/I^2 --- as in (1) above. > > Thank you, John. > > I should use paper and pencil before I type text like that. > > Jerry
Me too! I should have written: (Q/I)' = instead of (Q'/I)' = regards, John
Jerry Avins wrote:

(snip)

> FM modulation index is the ratio of the maximum carrier deviation to the > highest modulating frequency. When the same modulation is beat down from > the high end of the FM band (say 107 MHz) to the 10.7 MHz if the IF, the > modulation index increases by a factor of ten. At DC, it would be > infinite. There's a conceptual problem here.
I am not sure that an infinite modulation index means it doesn't work, though I don't yet understand how it would work. My thought is that there is some confusion between positive and negative frequencies that appears in the DC case, but I am not so sure about that. Reading your statement again, though, the ratio of the deviation to modulating frequency should not change when beat down to IF. I do agree that things get funny when the carrier frequency is less than the deviation, though. -- glen
ma wrote:

> Thanks for comments. > > > > "Ray Andraka" <ray@andraka.com> wrote in message > news:_tQ8h.1968$EV5.1773@newsfe16.lga... > > >>cincydsp@gmail.com wrote: >> >> >>>> I know that it is possible to demodulate an FM signal using a CORDIC >>>>ATAN core and the subtracting the current ouput of cordic from the last >>>>one. >>>>But I can not understand how carrier frequency and sampling rate would >>>>change it? What are the requirements? Where are the limitations? >>> >>> >>>Typically, carrier frequency wouldn't enter into the equation, because >>>you would never do this type of computation with a signal at the >>>carrier frequency (this would require a ridiculously-high sample rate). >>>In a real system, you would heterodyne the signal down to an >>>intermediate frequency before sampling, rendering the actual carrier >>>frequency of the signal irrelevant to your demodulator. Then, you would >>>likely mix the signal from IF down to baseband before doing any >>>calculations. If your transmitter on the other end sends an >>>IQ-modulated FM signal, then you end up with two orthogonal channels in >>>the receiver. >> >>Not necessarily. I'm just wrapping up a beamforming receiver design that >>includes an FM demodulator (among others). It samples the antenna >>elements at 500MHz and does the downconversion, filtering and beamforming >>all in the digital domain...for 240 antenna elements. > > > > > How can I do it when the signal is not in base band? For example in the case > of the system that you designed, the down converter didn't bring signal to > base band but it would bring it to some IF band ( I assume it as I believe > it is not possible to do beam forming in base band , Am I wrong). Being in > IF band means that there are some carrier frequency. Do we need another step > of down conversion or we can do FM demodulation in IF band? >
It is brought down to complex baseband by mixing with e^-jw(c)t where w(c) is the carrier. You can do beamforming at baseband if the signals are complex. If you have an IF, then you need another downconversion to get to baseband.
> > > > > > > >>But you are correct, you normally mix with a local oscillator before >>attempting to do the FM demod, That is often followed by a carrier lock >>circuit that mixes the downconverted signal with a frequency error signal >>to remove any residual offset due to tuning frequency differences between >>the transmitter and receiver. Even then there is often a little bit of >>frequency offset left due to imperfect locking and dynamic effects such as >>multi-path or doppler. >> > > > > > Is not mixing with a local oscillator means down conversion?
Well sort of. Generally speaking, there is also a low pass filter and sample rate decimation too.
> > > > Can I drop samples for down conversation? In fact I believe dropping samples > means multiplying with some square signal.
Yes, if the signal is properly filtered to band-limit it to an bandwidth appropriate to the neew sample frequency.
> > > > If I have an IQ signal at the input of an FM demodulator, how can I down > convert them to base band? And then use CORDIC FM demodulation.
Mix with a complex exponential equal to the carrier to get a complex baseband, which has I and Q components.
> > Is there any documentation that explains these things in mathematics? I am > not only interested in technology but as a student I am interested in > learning mathematics behind it. > >
Most digital communications texts discuss this. Try Marv Frerking's "Digital Signal Processing in Communication Systems"
> > > > >>>What you're left with at baseband, then, is a pair of sinusoids whose >>>instantaneous frequencies are directly related to the message waveform; >>>the sinusoids are 90 degrees out of phase. Therefore, performing an >>>atan2 operation on the ratio of the Q channel divided by the I channel >>>will yield the argument to the two sinusoids, which is your message >>>waveform multiplied by a linear ramp. Therefore, your message signal is >>>related to the total phase change per sample of the baseband waveform. >>>You can then run this signal through a differentiator filter to yield >>>an approximation to the desired message signal; demodulation complete. >>>There are other methods that may perform better (such as using the >>>Frerking method instead of using an actual differentiator), but this is >>>the most intuitive way to see what's going on. >>> >>>As was pointed out previously, the algorithm is relatively agnostic to >>>sample rate. As long as you sample quickly enough to avoid aliasing, a >>>higher sample rate will just give you finer steps in your signals every >>>step of the way. >>> >>>Jason >>> > > > > >