discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] File format question


From: Dan Halperin
Subject: Re: [Discuss-gnuradio] File format question
Date: Wed, 15 Aug 2007 16:19:28 -0700
User-agent: Thunderbird 1.5.0.12 (X11/20070604)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Bahn William L Civ USAFA/DFCS wrote:
> Thanks, that helps some.
> 
> I figured that I could put in the literal size of the data, in bytes, but 
> that only helps if it actually matches how the GR blocks are going to process 
> those bytes.
> 
> When possible, I would prefer to use the constants that have been set up so 
> that the code is (1) more readable, and (2) more maintainable. So instead of 
> using "8" for complex, I would like to use gr.sizeof_"whatever". But I don't 
> know what "whatever" needs to be. Where do I find this?
> 
> I'll look at dbpsk.py and tunnel.py when I get my Linux box set back up. Is 
> there a module that takes time domain data and converts it to IQ pairs, or am 
> I responsible for doing that when I generate the file? If so, what LO 
> frequency would I need to use?
> 
> It would be so much simpler if I could just use the generated time domain 
> data directly.
> 
> Thanks!

From
/usr/local/lib/python2.5/site-packages/gnuradio/gr/gnuradio_swig_py_runtime.py:

sizeof_char = _gnuradio_swig_py_runtime.sizeof_char
sizeof_short = _gnuradio_swig_py_runtime.sizeof_short
sizeof_int = _gnuradio_swig_py_runtime.sizeof_int
sizeof_float = _gnuradio_swig_py_runtime.sizeof_float
sizeof_double = _gnuradio_swig_py_runtime.sizeof_double
sizeof_gr_complex = _gnuradio_swig_py_runtime.sizeof_gr_complex

Those are the constants you want.

When you say generated time domain data, are you talking about (time,
voltage) pairs off of a scope? IIRC scope data is just the I component,
and you can get the Q component from I using standard signal processing
techniques assuming your sampling rate is sufficiently high.

- -Dan
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGw4oAy9GYuuMoUJ4RAl6xAJ44btFqFjVOvdVvACG0e/0XUQEN7QCeMFBD
ftSTrvnSYrU2sPjn6hC7PeM=
=dMQB
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]