0
$\begingroup$

I've a little question regarding interpolation in GNU Radio: I'd like to do an interpolation (by a factor of 2) and be able to change the sampling period of the samples interpolated but im having a hard time trying to do it, does someone has any idea on how to do it in GNU Radio ?

As im very knew to this, here is a little picture of what I'm trying to do.

:enter image description here

In orange my samples and in blue my samples interpolated with a different period (the aim is that I can "move" the blue samples to be closer or farther to the orange samples).

$\endgroup$
4
  • $\begingroup$ There's no such thing as "sampling period" from the perspective of GNU Radio. Every sample is just a number. Information about "rate" or "period" is not relevant to what GNU Radio does to the samples. To interpolate, you can either use a low-pass filter with the "interpolating FIR filter" block, or just use the "rational resampler" block with an interpolation of 2. $\endgroup$ Jul 4, 2022 at 10:55
  • $\begingroup$ yep, the picture really is likle the textbook picture of "you need a resampler", but there's no factor of 2 as you state in your question $\endgroup$ Jul 4, 2022 at 21:14
  • $\begingroup$ Well, thank you very much for your time Marcus! If there is no such thing as sampling period in GNU Radio, could it be possible to include a block doing a sort of delay between two samples (or even just a delay for the samples interpolated) that i can dynamically change(=like a block range)? Thank again :) $\endgroup$
    – Tyra
    Jul 5, 2022 at 9:07
  • $\begingroup$ that's a fractional delay, there's a block with that name. $\endgroup$ Jul 5, 2022 at 15:27

1 Answer 1

2
$\begingroup$

There's no such thing as "sampling period" from the perspective of GNU Radio. Every sample is just a number. Information about "rate" or "period" is not relevant to what GNU Radio does to the samples. To interpolate, you can either use a low-pass filter with the "interpolating FIR filter" block, or just use the "rational resampler" block with an interpolation of 2.

As a matter of fact, the official GNU Radio tutorials have a chapter on "Sample Rate Changes"! Since you've not found that yet, it seems you haven't done the tutorials; it's probably some very well-invested time you'd spent reading these, as you'll be much quicker doing GNU Radio stuff yourself afterwards!

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.