Hi Marcus,

I've attached the two flowgraphs I am using to record data from the Ettus
SDR; the TCP server (ettus-test.grc) which reads in the data samples, and
the TCP client (ettus-filesink.grc). I am not sure how to determine how the
sampling is terminated -- perhaps you can advise me on this? Would the TCP
block be an example of a termination, or am I misunderstanding this
concept? And if we establish that the sampling is "interrupted", from there
how do I calculate the decimation needed for my desired integration time?

Thanks so much for your help on this!

Cheers,
Ellie

On Sun, Aug 11, 2019 at 1:51 AM Marcus D. Leech <patchvonbr...@gmail.com>
wrote:

> On 08/10/2019 11:43 PM, Ellie White wrote:
>
> Hi Marcus,
>
> Thanks for the advice. So, I just tried an experiment to test out your
> suggestion, and came up with a puzzling result. I set the sample rate to 4
> MHz, and the decimation in the integrate block to 4 MHz, and recorded data
> for about 5 seconds. Instead of getting about 5 samples out, I tried to
> read the file and was told that there were "no samples" in the file. I then
> tried setting the decimation to samp_rate / fft_size, and the result there
> was the same. Any thoughts on why this might be?
>
> Thanks,
> Ellie
>
> Probably buffering in Gnu Radio.  How did you terminate the sampling?
>
> If you just interrupted it, there would have been samples "in flight" that
> never made it "home".
>
>
>
> On Sat, Aug 10, 2019 at 11:17 PM Marcus D. Leech <patchvonbr...@gmail.com>
> wrote:
>
>> On 08/10/2019 10:48 PM, Ellie White wrote:
>>
>> Hi Marcus,
>>
>> Thanks for your reply. I am not sure how the integration works, but if
>> you know how the Integrate block does the integration, then that is how my
>> flowgraph does it. I suspect it is "sum /reduce /dump" as you mentioned,
>> though perhaps we would need to investigate the Integrate block's source
>> code to be sure? Thanks in advance for any additional suggestions you might
>> have on this!
>>
>> Cheers,
>> Ellie
>>
>> Here's the documentation on the integrate block:
>>
>> https://wiki.gnuradio.org/index.php/Integrate
>>
>> So, if your samples are coming in at 1kHz, and you want 1 second of
>> integration time (and an output rate of 1Hz), you'd set the
>>   "decimation" parameter to 1000.
>>
>> This is one of the reasons I prefer single-pole-IIR filters--since I can
>> do sample-rate reduction as a separate process, via keep-one-in-N.
>>
>>
>>
>> On Sat, Aug 10, 2019 at 7:37 PM Marcus D. Leech <patchvonbr...@gmail.com>
>> wrote:
>>
>>> On 08/10/2019 03:40 PM, Ellie White wrote:
>>> > Hi all,
>>> >
>>> > I hope you're doing well! Thanks again for your help with my questions
>>> > earlier this summer. I've got another thing to ask now; I am in the
>>> > process of configuring a system to record integrated spectra using the
>>> > attached flowgraph, and I am trying to determine how to integrate for,
>>> > say, 60 seconds -- if I want to do this, what should my decimation be,
>>> > and how do I calculate that? I have been able to approximate this by
>>> > trial and error, but I would like to know the calculation behind it.
>>> >
>>> > Thanks in advance for any advice you can provide, much appreciated.
>>> > Have a good afternoon!
>>> >
>>> > Cheers,
>>> > Ellie
>>> >
>>> It kind of depends on how you're doing integration.
>>>
>>> An approach that strictly does sum/reduce/dump then you need as many
>>> samples as would occur over your desired integration time.
>>>
>>> For a single pole IIR filter, it's a bit trickier, and you'd set the
>>> "Alpha" parameter to:
>>>
>>> e^sqrt(sample-rate*integraton-time)
>>>
>>> Which will approximate an R-C integrator with  the given integration
>>> time.
>>>
>>>
>>>
>>> _______________________________________________
>>> Discuss-gnuradio mailing list
>>> Discuss-gnuradio@gnu.org
>>> https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>>>
>>
>>
>

Attachment: ettus-filesink.grc
Description: application/gnuradio-grc

Attachment: ettus-test.grc
Description: application/gnuradio-grc

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Reply via email to