# Issues in Using File Source

**URL:** <https://www.ruby-forum.com/t/issues-in-using-file-source/233875>\
**Category:** GNU Radio\
**Created:** [January 19, 2015, 11:18am UTC](https://www.ruby-forum.com/t/issues-in-using-file-source/233875 "2015-01-19T11:18:38Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![addis\_a](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/c4cdca/32.png) [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Post date:** [January 19, 2015, 11:18am UTC](https://www.ruby-forum.com/t/issues-in-using-file-source/233875/1 "2015-01-19T11:18:38Z")

</div>

Greetings to all,

I am trying to send a bit stream “1110011” using file source. For that,  
I  
created a bin file using “gedit”, typed 1110011 in it and saved it.  
After  
that, I gave the path of bin file in GRC File source block and connected  
a  
scope to it. But when I ran the file, It gave zero at the output…

Am I making the bin file in a wrong way?? Please Help…

Regards  
Salman D.

---

<div class="post-metadata">

**Author:** ![Salman\_D](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/c0e974/32.png) [@Salman\_D](https://www.ruby-forum.com/u/Salman_D)\
**Post date:** [January 19, 2015, 1:46pm UTC](https://www.ruby-forum.com/t/issues-in-using-file-source/233875/2 "2015-01-19T13:46:17Z")

</div>

Hello Salman,

gedit is a text editor; 1110011 is a sequence of characters, not of  
bits; then, even if you count the 7 bytes, that would be an extremely  
short signal, no matter how you configured the file source to interpret  
the contents of your file.  
If you, for example, set the file source to “complex”, it will interpret  
the bytes in your file as pairs of 32bit floats – that would be 8 byte  
for one complex number. With your 7 byte long file, the file source  
would not produce a single item of output, and your flow graph would  
stall for the lack of input.

Generally, there’s a FAQ entry about the file “format” the file  
sink/source use [1].  
I never cease to recommend the new guided tutorials [2], which (I hope)  
will give GNU Radio beginners a bit of intuitive insight on how GNU  
Radio deals with input, item streams, and sample types.

Greetings,  
Marcus

[1]  
[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)  
[2] [https://gnuradio.org/redmine/projects/gnuradio/wiki/Guided\_Tutorials](https://gnuradio.org/redmine/projects/gnuradio/wiki/Guided_Tutorials)

---

<div class="post-metadata">

**Author:** ![Salman\_D](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/c0e974/32.png) [@Salman\_D](https://www.ruby-forum.com/u/Salman_D)\
**Post date:** [January 21, 2015, 6:11am UTC](https://www.ruby-forum.com/t/issues-in-using-file-source/233875/3 "2015-01-21T06:11:38Z")

</div>

Thanks Marcus. It helped alot 🙂

Regards  
Salman D.

On Mon, Jan 19, 2015 at 5:44 PM, Marcus Müller  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)
