Hello All! I am a new gnu radio user and am stuck with an elementary problem...
I am trying to generate a data-driven source using gr.vector_source_f() with the following code: #!/usr/bin/env python from gnuradio import gr from gnuradio import usrp def build_graph (): fg = gr.flow_graph () data = (-5000,5000) src0 = gr.vector_source_f ( data, 1 ) dst = usrp.sink_c (0,64) f2c = gr.float_to_complex() fg.connect ( src0, f2c, dst ) return fg if __name__ == '__main__': fg = build_graph () fg.start () raw_input ('Press Enter to quit: ') fg.stop () I have a few questions and would really appreciate if someone could help: 1) Is it possible to generate square waves using this function? Or any function? I just get different sinusoids for different vector inputs. For example the above code gives me a perfect sine wave (which I did not expect). And for vectors with length > 2, it is some other form of sinusoid. 2) What is the quantitative relationship between the vector and the waveform for this function? I see some trend but I am unable to quantify it perfectly. 3) As of now, I am controlling the frequency of the waveform by varying the interpolation rate as follows: output frequency = 64M/interpolation rate Is there another way? Pardon me if my queries are inane... Thanks in advance for the help! Regards, Suhrid _______________________________________________ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org http://lists.gnu.org/mailman/listinfo/discuss-gnuradio