Hi Salman: In regard to your first question, I suggest looking at the “hexdump” utility under UNIX. It will allow you to view binary files, and then you can analyze the actual bit stream. It dumps any file in hexadecimal format. There are a number of options, but as you make more progress and actually want to see ASCII characters in your files, the “-C” option will allow you to do that.
Enter: man hexdump for some docs. Generally, pipe the output through “more” so you see a screenful at a time, e.g.: hexdump filename | more The 80-digit hex value on the left hand side of the output is the offset of the bytes within the file. Hope this helps, Kevin > On Mar 4, 2016, at 8:08 AM, Salman Dinani <[email protected]> wrote: > > Hi Marcus, > > Thank you very much for introducing me with "Screenshot" option in GRC :) I > checked the provided link and what I understood is that the file sink is > saving bits correctly but in a different format (32 bits for floating point > data). However, I have few confusions: > > 1. The ASCII equivalent of "#" or "?" is not equal to "1010" so why the saved > data is "##??" ? > > 2. In-order to further comprehend this concept, I designed a DPSK MOD/De-MOD > using GRC DPSK blocks as shown in DPSK_loopback image. The data "1010" is > provided via file source shown in Data_Tx image and demodulated data is saved > using file sink. To my surprise, the demodulated data is successfully saved > in desired Byte format in file i.e. "101010" as shown in Rx_Data snapshot. > > 3. To verify this, I designed an another design, which just takes the same > data from file and converts it into "10" and save back to file as shown in > Data_save_try. But this time, the saved file format was unrecognizable and > the file didn't even opened as shown in Rx_file. > > My application requires to display and save the "Telemetry data" coming from > a Satellite in binary form i.e. 1010 etc as happening in DPSK_loopback. How > should I achieve this in my design shown in my previous email? > > Need your expert opinion :) > > Best Regards > Salman > > On Thu, Mar 3, 2016 at 9:06 PM, Marcus Müller <[email protected] > <mailto:[email protected]>> wrote: > Hi Salman, > > awesome application! As a hint for the future: GRC has a very handy > "screenshot" function that just saves an image of your flowgraph as PNG > (easier than taking a screenshot of your whole desktop). It's what happens > when you use File->Screen Capture or click on the "Printer" button :) > > To your question: > The files sink correctly saves your numbers to a file -- but that's not going > to be a text file, but a binary file: > > http://gnuradio.org/redmine/projects/gnuradio/wiki/FAQ#What-is-the-file-format-of-a-file_sink-How-can-I-read-files-produced-by-a-file-sink > > <http://gnuradio.org/redmine/projects/gnuradio/wiki/FAQ#What-is-the-file-format-of-a-file_sink-How-can-I-read-files-produced-by-a-file-sink> > > Best regards, > Marcus > > > On 03/03/2016 05:01 PM, Salman Dinani wrote: >> Hello every one, >> >> I am trying to build a transmitter and receiver for satellite application >> based on dual modulation technique (PM/BPSK). I have used discrete blocks >> for BPSK modulation and quadrature demodulator and PLL for BPSK demodulation >> as shown in Figure 1. Initially square wave generator is used as data source >> of "1010" which was successfully demodulated as shown in Figure 2 and 3. >> >> But when I tried to save the demodulated "1010" bits in byte form in a file >> , it resulted in unrecognizable data as shown in Figure 4. >> >> My question is: Why I am not able to save the data "1010" in file?? >> >> Kindly guide me through the solution..?? >> >> Best regards >> Salman >> >> >> _______________________________________________ >> Discuss-gnuradio mailing list >> [email protected] <mailto:[email protected]> >> https://lists.gnu.org/mailman/listinfo/discuss-gnuradio >> <https://lists.gnu.org/mailman/listinfo/discuss-gnuradio> > > > _______________________________________________ > Discuss-gnuradio mailing list > [email protected] <mailto:[email protected]> > https://lists.gnu.org/mailman/listinfo/discuss-gnuradio > <https://lists.gnu.org/mailman/listinfo/discuss-gnuradio> > > > <Data_Tx.PNG><DPSK_loopback.png><Rx_data.PNG><RX_file.PNG><Data_save_try.png>_______________________________________________ > Discuss-gnuradio mailing list > [email protected] > https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
_______________________________________________ Discuss-gnuradio mailing list [email protected] https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
