|
From: | Marcus Müller |
Subject: | Re: [Discuss-gnuradio] CPFSK mod/demod + strange behavior |
Date: | Fri, 10 Jun 2016 10:52:47 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 |
Hi Olivier, On 10.06.2016 03:06, Olivier Goyette
wrote:
2x312.5kHz, your FSK deviation, and what looks like to be about your filter bandwidth! Thanks! Yes, I try to keep that in mind and hence I tried to illustrate my considerations :) Also, that's why I stress that you should first get your simulation running. Real world radio is hard enough as is, and the beauty of SDR really is that you can develop in simulation before you bring it to the air. I like that approach :) Huh, I wasn't aware of me being overly opinionated, aside from my opinion whether you can call a single-sample FSK "FSK". The point is really that the RRC doesn't make sense after CPFSK, mathematically (not an opinion). To show that we really don't want to put you down or so, and don't act based on opinion and preference, but math: OK. Let's look at the spectrum of an FSK transmission like yours. Let's first build a slightly simplified one, so that the math doesn't kill us. So first of all, let's look at your data stream, and define it to be a square wave (alternating -1, 1,-1,...) . Let us keep the frequency of this signal a bit variable, first. Let's now decompose that data stream into two other square waves: , which is 1 whenever , else 0, and , which is 1 whenever , else 0. We immediately see that . Let's also define the two tones of your FSK as signals (H for "high") and (L for "low") simply the complex conjugate of . Since we know that will be sent exactly when is "on", and the same goes for the and , we know that we can write the FSK signal as: . So, what's the spectrum of this? . Since the Fourier Transform is linear: Bear in mind that , so this reduces to So let's look at the first component: It's the Fourier Transform of a product of two functions, and by the convolution/multiplication duality for the Fourier Transform: , with being the convolution operator. is easy, it's a dirac at . That makes convolution a lot easier, too – it reduces convolution to a frequency shift by . That leaves us with finding the Fourier Transform of our "positive bit stream". That is just an offset, scaled standard square wave. I won't derive that in completeness now, you can probably look up a good derivation of it in every introduction to signals and systems, but put it down how I memorized it. So what is the Fourier series that describes a square wave like this one? So what you can see from this formula, or most importantly from the sum, is that a square wave's spectrum consists of the spectral components at every odd (hence, the ) multiple of the square wave Not only that, but the energy contained at that th harmonic just goes down with , which means that if you low-pass filter early, you lose a lot of the original signal's energy. Rule of thumb: To get something that "visually" resembles a square wave, you need to keep the DC, the first and third harmonic. Everything else will just look very much like a somehow distorted sine. Usually, you'd try to keep at least the fifth, too. Now, the third harmonic of your signal is at 3.125 MHz. You have to shift that with your deviation , i.e. by 312.5 kHz, and you end up with the third harmonic of the positive data wave at + 3.4375 MHz, and for symmetry reasons, the third harmonic of your negative data wave is - 3.4375 MHz. Now, that leads to a total bandwidth of MHz. Even your sampling rate is lower than that, so you're neglecting the Nyquist/Shannon sampling theorem. And if you use a filter after the FSK modulation, you will cut off even more of your signal, and that means there's nothing you can do to recover it. This, again, points to the fact that if you do any pulse shaping with a RRC, you do it with the data signal, and hence filter $s_{data}$, not $s_{FSK}$. Best regards, Marcus |
[Prev in Thread] | Current Thread | [Next in Thread] |