Write I/Q to WAV file

Long time reader, first time poster so hopefully I’m doing this whole
mailing list thing right.

I was hoping someone could point me in a direction towards fixing this
odd
problem I am having. I have a GRC graph which outputs complex samples.
I
would like to write these samples specifically to a WAV file so I can
view
them in SDR programs on Windows such as DREAM or, more importantly,
SDR#.

I can’t seem to do so however as when I run a Complex > Float – WAV
File
sink, SDR# says the WAV file isn’t valid; and DREAM shows fullband
noise.
Playing the WAV in GNURadio also says there are “no samples”.

I have an FFT attached to the Complex > Float stage and it shows the
signal
coming out just fine. What am I doing wrong?

Any assistance is massively apprechiated.

  • Jordan.

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

Hi Jordan,

you have to be aware that WAVs are only meant to hold real-valued
data. So the question stands: how to “store” complex signals in WAVs?
Usually, this is done by mapping the real and imaginary parts to the
two stereo channels. Since I don’t know what the programs you mention
expect, I can’t really help you diagnose that. So: What does your
“complex>real” stage look like?

If the GNU Radio WAV source tells you that there are no samples,
chances are good that the file is empty, and something in your signal
generation went wrong.

If you generate a well known complex signal in GRC and output it (the
same way as you intend to do it for sdr#) to a wave file, can you then
open that file in software such as audacity?

I don’t quite see what you mean with “FFT attached to the complex >
float stage”. FFT is something you usually do to complex vectors, not
only to the real/imag parts isolated.

Looking forward to hearing from you,
Marcus

On 28.01.2014 00:35, Jordan J. wrote:

WAV File sink, SDR# says the WAV file isn’t valid; and DREAM shows

_______________________________________________ Discuss-gnuradio
mailing list [email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJS5vEcAAoJEAFxB7BbsDrLBUYIAICL2OYa0feVqKb2CJQ3FkY+
SykdNjnDBpkJTLcrgpyH0e0EZAWxDnkhVKvNQ2Ohhwjw/FPAZjKm5rncOZ2UfZfd
WQwYbseCi0QgZcfko6WqVq0cNs4SPJoIBo5Ffgye9chavzqLwS/mLrPe0uWlojzu
ND4wN6dPLZ1uTwYggAaeycOlh8K8ZHUuCEneqXnGnhS0mv8BZOxM7F9ZRCfBTmVN
aB544KEAh9wAuenFMxFW2vPMb/iUO0YZE4jn99+kUxgmW/FYZHp3kIvULpdCvnUI
zwo8bOb2YxnP0TwLSGy91BWJhYbmvoEHsNUfFJZuT5s/qai0rCHRO5HPEb1YDVU=
=vcnN
-----END PGP SIGNATURE-----

On 01/28/2014 09:56 AM, Jordan J. wrote:

My other email must’ve not made it. I’m a complete newbie to this
mailing list thing. I assumed it was Real and Imaginary. It worked for
signal sources.

But anyway there still seems to be a snag. The individual inputs work,
but once they get to the FIR filter and bandpass it makes noose in the
WAV dump, which is odd because the FFT looks fine and building a
receiver works fine too.

You might be changing the amplitude too much. WAV sinks require the
amplitude to be in [-1, 1], like the audio sinks, or you’ll clip.

MB

On 01/28/2014 10:01 AM, Jordan J. wrote:

They commonly peak at 10dB and above…even without any gain. How do I
go about decreasing it? Never explored that option but worth a shot I
suppose. I’m going to sleep now, but can up the GRC to Google Drive
later today for investigation.

Just add a multipy_const_cc.

MB

Well it indeed appears to be my graph. Tried using a simple graph.

Signal Source (32k) > Complex - Float > WAV

Dream decoded it, SDR# read it, and it was fine.
My graph of interest must have a sample-rate no lower than 360k. It
appears
to be recording something, but its almost as if it is recording the
samples
too quickly?

Here is a screenshot of the graph if it helps any.
https://lh6.googleusercontent.com/-aSbYCHxTFFk/Uub13Q-yoVI/AAAAAAAAqng/i3lBhqzp4TE/w915-h477-no/Screenshot+-+01272014+-+04%3A11%3A38+PM.png

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs