Changes between Version 5 and Version 6 of Tutorials/k0SDR/Tutorial05
- Timestamp:
- May 20, 2013, 6:08:24 PM (12 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Tutorials/k0SDR/Tutorial05
v5 v6 135 135 * The magnitude value of the fft bins are stored in binary format. The first entry of the db file is shown above. So when dumping the file contents the fft bins data is shown as consecutive ASCII representation of the binary floating point numbers. The 1st is 84B7C43E <==> 0.38421, the 2nd bin is 2146863D <==> 0.065563, etc... 136 136 137 * To quickly visualize the data we can download and compile the following code .137 * To quickly visualize the data we can download and compile the following code (it's also in the attachment). 138 138 {{{ 139 nilanjan@console.grid:~/UHD$ wget http://www.orbit-lab.org/raw-attachment/wiki/Trials/GNURadio/OmfExperiment1/sq3_parse.cpp 140 nilanjan@console.grid:~/UHD$ gcc sq3_parse.cpp -o sq3_parse -lsqlite3 141 nilanjan@console.grid:~/UHD$ ./sq3_parse spectrum.grid.sq3 > db_dump.dat 142 }}} 139 143 144 * Parse the database file, load octave for a quick plot. 145 {{{ 146 nilanjan@console.grid:~/UHD$ ./sq3_parse spectrum.grid.sq3 > db_dump.dat 147 nilanjan@console.grid:~/UHD$ octave 148 octave:1> w = dlmread('db_dump_1500.dat',','); 149 octave:2> a = w(:,[9:136]); 150 octave:3> imagesc([1:size(a,2)] , [1:size(a,1)] , 10*log(sqrt(a)/1000)); 151 octave:4> colorbar() 140 152 }}}