Hi all, Is there an easy way to get a vector source to pass on the same signal over and over again, but with a fixed delay between each transmission? The goal is to simulate the transmission of fixed size packets with a fixed delay between each. - Einar
on 2009-04-16 12:41
on 2009-04-16 13:02
Maybe use gr.valve? Dimitris S. "If you think you're too small to make a difference, try sleeping with a mosquito!" - Amnesty International
on 2009-04-16 14:18
Dimitris S. wrote: > Maybe use gr.valve? Thank you. But still the vector source would need to be "rewinded" every time, and the delay would have to some how control it all. Do you have any more ideas or details? - Einar
on 2009-04-16 16:11
>>Is there an easy way to get a vector source to pass on the same signal >>over and over again, but with a fixed delay between each transmission? 'good practices' option: Look at the benchmark_*x.py examples, if you drill down into the packet manager you will find an example of a source block that takes messages asynchronously from your python script and converts them into a stream of bits for the modulator. You could probably use that block directly, or at least with few modifications. quick option: You could probably use vector_src_x as a starting point. All you'd have to do is append a bunch of zeros the following code builds a small frame that repeats with a 26 sample delay after each. This method relies on your modulator expecting symboled bits already: vector_src1 = (1,-1,1,-1)*6+(1,-1,-1,1,-1,-1,1,-1,1,-1,-1,-1,-1,1,-1,-1,-1,-1,-1,1,1,1,-1,1,-1,-1)+(0,)*26 src1 = gr.vector_source_c(vector_src1,True) Jason
on 2009-04-16 20:47
Jason U. wrote: > 'good practices' option: Look at the benchmark_*x.py examples, Thank you Jason. I will attempt the "good practice"-way first then :-) -- Einar T.
on 2009-04-17 06:05
> Thank you Jason. I will attempt the "good practice"-way first then :) Not to discourage you from doing things the hard way, but it's really only necessary if this project is an implementation type of thing. If all you need is some experimental data for a class project or paper, then the fast way is just as good, if not better.