Thank you once again Paul. ls -la drwx------ 1 Username Username 4096 Dec 1 13:40 . drwx------ 1 Username Username 12288 Nov 30 16:21 .. -rwx------ 1 Username Username 7683964928 Nov 20 18:23 Sample-408MHz
gr_mkheader -r 1.8e6 -t sc16 -f 408e6 -l 1920991232 Sample-408MHz Now I have Sample-408MHz.hdr: gr_read_file_metadata Sample-408MHz.hdr -D HEADER 0 Version Number: 0 Sample Rate: 1800000.00 sps Seconds: 0.000000 Item size: 4 Data Type: short (1) ..... ..... .... etc. Now when I do gr_fileman Sample-408MHz Sample.cfile -o fc32 I get sample_cnt_end=500000,final_index=1920991232 Empty Header, quitting. On Thu, Dec 1, 2016 at 1:35 PM, Garver, Paul W <garv...@gatech.edu> wrote: > It probably can’t find the header. The command > > # gr_mkheader -r 1.8e6 -t sc16 -f 408e6 -l 1920991232 Sample-408MHz > > should produce the file "Sample-408MHz.hdr" > > Check that the file Sample-408MHz.hdr is produced. You can read it with > > # gr_read_file_metadata Sample-408MHz.hdr -D > > Then, > > # gr_fileman Sample-408MHz Sample-408MHz.cfile -o fc32 > > Sample-408MHz should be the raw data, and Sample-408MHz.hdr the metadata > produced with gr_mkheader. This should produce > Sample-408MHz.cfile and Sample-408MHz.cfile.hdr. > > On your copied command it appears you didn’t add the -o fc32 to specify > you want a file type conversion. > > PWG > > > > > On Dec 1, 2016, at 11:20 AM, AndroidT Tester <itestandroid2...@gmail.com> > wrote: > > Thank you Paul, > > I got this; > sample_cnt_end=500000,final_index=1920991232 > Empty Header, quitting. > > I followed all your instructions and double checked all parameters. I did > filesize / 4 for sample count. > I did this first: > > gr_mkheader -r 1.8e6 -t sc16 -f 408e6 -l 1920991232 Sample-408MHz > > > Then when I try to do: > > gr_fileman Sample-408MHz Sample.cfile > > I got the error above, what am I missing? > > On Thu, Dec 1, 2016 at 12:07 PM, Garver, Paul W <garv...@gatech.edu> > wrote: > >> There are two different metadata types: >> 1) Inline >> 2) Detached >> >> Here, you are using the detached headers. With detached, the raw samples >> are in a file, say myfile.sc16, and the metadata in myfile.sc16.hdr. See >> [1] for more information on GNURadio metadata. >> So suppose you have myfile.sc16 as your raw sample file. Then you >> generate headers for it, since you didn’t record it with any. You also need >> to give gr_mkheader -l num_samps so it knows how long the file is. For sc16 >> you just do file_size_bytes/4 to get # of samples in a file. >> >> # gr_mkheader -r 1.8e6 -t sc16 -f 408e6 myfile.sc16 >> >> This generates the file: myfile.sc16.hdr containing the file type, center >> frequency, sample rate, etc. This is simply my convention, but the metadata >> is “linked” to the raw samples by the filename >> raw data: myfile.sc16, where sc16 specifies the file format. >> metadata: myfile.sc16.hdr >> >> Then, you can give this to gr_fileman to convert the type: >> >> # gr_fileman myfile.sc16 myfile.fc32 -o fc32 >> >> gr_fileman looks for filename.hdr for the detached header info. So in >> this case, it files myfile.sc16.hdr, and should happily convert for you. >> >> PWG >> >> >> >> >> >> [1] http://gnuradio.org/doc/doxygen/page_metadata.html >> >> On Dec 1, 2016, at 9:45 AM, AndroidT Tester <itestandroid2...@gmail.com> >> wrote: >> >> Thank you Paul, I never heard of gr-analysis before. >> So I tried this: >> >> gr_mkheader -r 1.8e6 -t sc16 -f 408e6 myheader >> >> This only created myheader.hdr file. How can I link this to my actual >> recording sample which is 16-bit IQ pair and then convert it to CFile? >> Do I concatenate the files? put myheader.hdr at top of my recording? >> Sorry again for these newbie questions >> >> >> >> On Thu, Dec 1, 2016 at 11:32 AM, Garver, Paul W <garv...@gatech.edu> >> wrote: >> >>> Please copy the list next time so other folks can respond besides me. >>> >>> Just attach a file sink to the ishort to complex block. There’s also a >>> command-line tool called gr_fileman in gr-analysis [1] which will do this, >>> but the file needs headers. If you don’t have them, you can generate with >>> gr_mkheader in gr-analysis. >>> >>> [1] https://github.com/garverp/gr-analysis >>> >>> Hope this helps, >>> PWG >>> >>> On Dec 1, 2016, at 9:22 AM, AndroidT Tester <itestandroid2...@gmail.com> >>> wrote: >>> >>> Now, how can I convert this to a CFILE format where I can play it in >>> Gqrx? Thank you >>> >>> On Wed, Nov 30, 2016 at 11:34 AM, AndroidT Tester < >>> itestandroid2...@gmail.com> wrote: >>> >>>> Thank you very much! It worked :) >>>> >>>> On Wed, Nov 30, 2016 at 11:04 AM, Garver, Paul W <garv...@gatech.edu> >>>> wrote: >>>> >>>>> Use a file source block with “short” type into an “Ishort to Complex” >>>>> block. The Ishort to Complex block will de-interleave the shorts into >>>>> complex samples. >>>>> >>>>> PWG >>>>> > On Nov 30, 2016, at 8:55 AM, AndroidT Tester < >>>>> itestandroid2...@gmail.com> wrote: >>>>> > >>>>> > Hey guys, >>>>> > >>>>> > I have a sample file with IQ pairs, each I and Q is 16-bits, I want >>>>> to load this in GNURadio companion using File source sink, but I'm not >>>>> sure >>>>> how can I specify 16-bit format for I and 16-bit for Q in Gnuradio >>>>> companion and then connect it to lets say FFT or Waterfall widget. Can >>>>> someone advise a bit? >>>>> > >>>>> > Thank you! >>>>> > _______________________________________________ >>>>> > Discuss-gnuradio mailing list >>>>> > Discuss-gnuradio@gnu.org >>>>> > https://lists.gnu.org/mailman/listinfo/discuss-gnuradio >>>>> >>>>> >>>> >>> >>> >> >> > >
_______________________________________________ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org https://lists.gnu.org/mailman/listinfo/discuss-gnuradio