discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] how to manage time!


From: Marcus Müller
Subject: Re: [Discuss-gnuradio] how to manage time!
Date: Fri, 09 May 2014 15:34:38 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0

Hi Activecat, hi Mostafa,

>> The only thing I don't know here is how could I generate these
>> different-rate data?
The rate of data is really just a property of the values of the samples.
For example, a sine with a frequency of 1000 will have a period of 32
samples for a sample rate of 32000, if you have the same sine at a
sample rate of 64000, its period will be 64 samples... note that
frequency and sample rate are all nothing but relative numbers.

If you have two things in your flow graph that produce signals related
to a different sampling rate (again, there is no awareness of any
sampling rate at all in GNU Radio, it's just that frequencies you
specify relate to a sample rate that you or your device specify
themselves), you will have to match one sample rate to the other.
That means resampling. To explain using aforementioned example: if you
want to make sense while adding up the two sines, you would resample the
32k sampling rate to 64k, and then add the two sample streams.

This is the very basic idea of digital signal processing: you don't
really care about the rates at which signals occur - you just math them
hard enough until they match your model.
>>
> To accomplish this, you need to forecast() and consume() different rates at
> different ports.
Not really. Usually, you use one of the existing resampler blocks. Then
you just use whatever block type with the then equally-sampled streams.

There is *very* rarely the need for implementing your own forecast with
these kind of streams. For fixed ratio integral resamplers, just use the
decimator or interpolator block types.

I hope to conclude this thread with this. The information-theory
sampling rate vs. processing item rate vs. real time problem is a tough
one to get one's head around; however, I think trying, playing around
and reading up on things is the right way to go from here for you,
Mostafa; it's not very useful to discuss this on a mailing list like
this, I'm afraid.

Greetings,
Marcus



reply via email to

[Prev in Thread] Current Thread [Next in Thread]