# Data extract from file sink block

**URL:** <https://www.ruby-forum.com/t/data-extract-from-file-sink-block/239597>\
**Category:** GNU Radio\
**Created:** [March 6, 2014, 9:45am UTC](https://www.ruby-forum.com/t/data-extract-from-file-sink-block/239597 "2014-03-06T09:45:13Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Detlef\_R](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/58f4c7/32.png) [@Detlef\_R](https://www.ruby-forum.com/u/Detlef_R)\
**Post date:** [March 6, 2014, 9:45am UTC](https://www.ruby-forum.com/t/data-extract-from-file-sink-block/239597/1 "2014-03-06T09:45:13Z")

</div>

Hi all,

How to use file sink block in GRC. I want to extract output data from  
rx\_ofdm & tx\_ofdm examples bolck in GNU radio to plot BER V/s EB/N0 in  
MATLAB. If I use file sink blocks, it’s generate a banary file which is  
not  
opening anywhere. So please tell me what type of file we can get using  
file  
sink block which is compatible to MATLAB also.

---

<div class="post-metadata">

**Author:** ![naveeng](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/a9a28c/32.png) [@naveeng](https://www.ruby-forum.com/u/naveeng)\
**Post date:** [March 6, 2014, 10:22am UTC](https://www.ruby-forum.com/t/data-extract-from-file-sink-block/239597/2 "2014-03-06T10:22:16Z")

</div>

Hi Naveen,  
the data “format” is described in the official FAQ:

[http://gnuradio.org/redmine/projects/gnuradio/wiki/FAQ#What-is-the-file-format-of-a-gr\_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-gr_file_sink-How-can-I-read-files-produced-by-a-file-sink)

It’s raw data, which can be easily read using Matlabs file io  
facilities; for reference look into matlab’s “fread” documentation.

Greetings,  
Marcus
