0

I have series of amplitudes of a signal recieved at center frequency of 433.9MHz, sampling at 250000 Hz. I can see the information received is the packet I am after, just sampled too high. I believe the transmitter transmits at 3918bps. What is the best method to downsample from 250000 Hz to 3918 bps?

I have tried using a butterworth filter, which doesn't seem to work and I don't understand why. I've tried picking every 63 samples (because 250000/3918 = ~63), but didn't seem to work either. Please bare in mind I am a bit of a newbie regarding DSP.

craig1231
  • 103
  • 3
  • You can't sample at 250,000 bps. bps means bits per second, and its a unit of transmission rate. Sampling rate is measured in either samples per second, or (sometimes) hertz, where hertz is understood to stand for sampling frequency. Please clarify your question. – MBaz May 15 '15 at 13:54
  • Ahh ok... so I seem to be confusing 250000Hz with bps. So to clarify I am sampling at 250000Hz, to a signal that is being transmitted at 3918 bps. – craig1231 May 15 '15 at 14:16
  • If you have a signal at 433.9MHz, sampling at 250KHz could be a little risky, unless you failed to mention that first you are down converting the signal. You may "see" that you have the information but it might be not straight forward to recover it. – Moti May 15 '15 at 18:17
  • @Moti, could you explain why it's a little risky or not so straight forward to recover it? I'm using an RTL SDR, and the lowest sample rate is 250kHZ. – craig1231 May 15 '15 at 22:22
  • A too low sampling rate may introduce noise that could prevent you from proper recovery of the signal because of the effect of "folding". This relates to the Nyquist sampling rate. – Moti May 15 '15 at 23:57
  • @Moti, I've now chosen a sample rate of 1003008MHz, then for each 128 samples I find an average amplitude. A crude form of a low pass filter? So out of 77455 samples, I have 605 averaged samples. Then I compare 2 neighbouring sample amplitudes to determine the bit. If the amplitude is higher than the next the bit is 1, else 0. So then I have 302 bits... Am I going about this the right way? – craig1231 May 17 '15 at 09:17
  • What is the modulation? Why that sampling rate? Why 128 points FFT? What is the 77455? Do you use overlap? Where is the 605 from? Why the comparison in the frequency domain? What is the signal to noise ratio? – Moti May 17 '15 at 22:03
  • @Moti, It is FSK modulation. At a sampling rate of 1003008MHz, I receive roughly 77455 samples for each packet data. Each packet of data is sent by the transmitter every 6 seconds. I can determine I have received a packet by difference in amplitude, if its loud enough, then attempt to decode the packet. But demodulating/decoding the packet is what my problem is. Using FFT is shows that 2 frequencies prodominately are used, probably for bit 1 and bit 0. I've tried implementing the Goertzel algorithm to process every 128 samples, but I cannot make it work, I don't know how to apply it. – craig1231 May 18 '15 at 09:46

1 Answers1

0

Based on your information a packet length is about 77.2 millisecond. With 3918 bps, each packet contains about 302 bits. Frequency is shifting about every 0.255 millisecond. you get about 256 samples per bit, so 128 point FFT seems to be correct. I assume you have a real signal, so you need to evaluate only 64 bins. If you are synchronized properly, each two consecutive FFTs will provide you with one frequency, switching at the other. If you are not synchronized with the start of the first bit, only every other bin will provide you with a nice single frequency (assuming that you do not have noise and spurious signals)

Moti
  • 340
  • 1
  • 6