Re: Implementation of OFDM TX and RX using GNURadio and USRP
On 27/11/2022 04:01, Marcus D. Leech wrote: >>> Could anyone please give me advice how to extract certain carriers from the FFT bins of the demodulator? > I just thought of this little "idiom" for picking a single item from a vector, that doesn't require that you write your own block. It takes advantage of "busports" (as a notational convenience). Hi, Another option for extracting one or a range of items from a vector is to use Vector to Stream followed by Keep 1 in N or Keep M in N. See near the bottom of this flowgraph for an example: https://github.com/daniestevez/reu-2022/blob/main/polyphase/polyphase_filter.grc Best, Daniel. OpenPGP_signature Description: OpenPGP digital signature
Re: Implementation of OFDM TX and RX using GNURadio and USRP
On 27/11/2022 05:26, Daniel Estévez wrote: Hi, Another option for extracting one or a range of items from a vector is to use Vector to Stream followed by Keep 1 in N or Keep M in N. See near the bottom of this flowgraph for an example: https://github.com/daniestevez/reu-2022/blob/main/polyphase/polyphase_filter.grc Best, Daniel. That would only allow the first or first-N of the streams to be captured, rather than some arbitrary single stream, no?
Re: Implementation of OFDM TX and RX using GNURadio and USRP
On 27/11/2022 17:23, Marcus D. Leech wrote: On 27/11/2022 05:26, Daniel Estévez wrote: Hi, Another option for extracting one or a range of items from a vector is to use Vector to Stream followed by Keep 1 in N or Keep M in N. See near the bottom of this flowgraph for an example: https://github.com/daniestevez/reu-2022/blob/main/polyphase/polyphase_filter.grc Best, Daniel. That would only allow the first or first-N of the streams to be captured, rather than some arbitrary single stream, no? No, because these blocks have an initial offset parameter (and if they didn't, we could use "Skip Head"). As an example, say that we have 1024-point FFTs given as vectors and we only want the FFT bin number 42. We do vector to stream, then Keep 1 in N with N = 1024 and initial offset = 42. This would give us a stream where only the FFT bin number 42 appears. Now say that w want FFT bin numbers 42, 43, 44, 45. We do vector to stream, then Keep M in N with N = 1024, M = 4, initial offset = 42. This would give us a stream that contains: bin_42(t0), bin_43(t0), bin_44(t0), bin_45(t0), bin_42(t1), bin_43(t1), bin_44(t1), bin_45(t1)... If desired, we can turn this into vectors of 4 elements using stream to vector or use a deinterleave block to separate each of the bins in its own stream. Best, Daniel. OpenPGP_signature Description: OpenPGP digital signature
Re: Implementation of OFDM TX and RX using GNURadio and USRP
On 27/11/2022 16:05, Daniel Estévez wrote: On 27/11/2022 17:23, Marcus D. Leech wrote: On 27/11/2022 05:26, Daniel Estévez wrote: Hi, Another option for extracting one or a range of items from a vector is to use Vector to Stream followed by Keep 1 in N or Keep M in N. See near the bottom of this flowgraph for an example: https://github.com/daniestevez/reu-2022/blob/main/polyphase/polyphase_filter.grc Best, Daniel. That would only allow the first or first-N of the streams to be captured, rather than some arbitrary single stream, no? No, because these blocks have an initial offset parameter (and if they didn't, we could use "Skip Head"). As an example, say that we have 1024-point FFTs given as vectors and we only want the FFT bin number 42. We do vector to stream, then Keep 1 in N with N = 1024 and initial offset = 42. This would give us a stream where only the FFT bin number 42 appears. Now say that w want FFT bin numbers 42, 43, 44, 45. We do vector to stream, then Keep M in N with N = 1024, M = 4, initial offset = 42. This would give us a stream that contains: bin_42(t0), bin_43(t0), bin_44(t0), bin_45(t0), bin_42(t1), bin_43(t1), bin_44(t1), bin_45(t1)... If desired, we can turn this into vectors of 4 elements using stream to vector or use a deinterleave block to separate each of the bins in its own stream. Best, Daniel. Hah! I've used "Keep One in N" and "Keep M in N" for *years*, and never noticed that! Color me chagrined.