# Send custom data

**URL:** <https://www.ruby-forum.com/t/send-custom-data/227546>\
**Category:** GNU Radio\
**Created:** [March 19, 2013, 9:37am UTC](https://www.ruby-forum.com/t/send-custom-data/227546 "2013-03-19T09:37:13Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gong\_Z](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/d07c76/32.png) [@Gong\_Z](https://www.ruby-forum.com/u/Gong_Z)\
**Post date:** [March 19, 2013, 9:37am UTC](https://www.ruby-forum.com/t/send-custom-data/227546/1 "2013-03-19T09:37:13Z")

</div>

Hi,  
I wanna send custom data such as the device number or device status with  
USRP.Does it mean I should go deeply into something like  
tx\_stream-\>send()?Is there any similar example?  
Thanks in advance.

---

<div class="post-metadata">

**Author:** ![Gong\_Z](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/d07c76/32.png) [@Gong\_Z](https://www.ruby-forum.com/u/Gong_Z)\
**Post date:** [March 19, 2013, 6:48pm UTC](https://www.ruby-forum.com/t/send-custom-data/227546/2 "2013-03-19T18:48:20Z")

</div>

Isnt all data, custom data? So the streamer interface is still just  
samples, as is the gr-uhd sink’s input port. If you want to send  
arbitrary information, you still need to packet-ize and modulate the  
information.

Maybe you will find this project relevant:  
[https://github.com/jmalsbury/pre-cog/wiki](https://github.com/jmalsbury/pre-cog/wiki)

-josh

---

<div class="post-metadata">

**Author:** ![Gong\_Z](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/d07c76/32.png) [@Gong\_Z](https://www.ruby-forum.com/u/Gong_Z)\
**Post date:** [March 22, 2013, 4:01am UTC](https://www.ruby-forum.com/t/send-custom-data/227546/3 "2013-03-22T04:01:01Z")

</div>

Maybe I should cast arbitrary object to binary data followed by  
simple\_framer block and bits\_to\_symbols block.Is it correct?

---

<div class="post-metadata">

**Author:** ![Gong\_Z](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/d07c76/32.png) [@Gong\_Z](https://www.ruby-forum.com/u/Gong_Z)\
**Post date:** [June 5, 2013, 10:46am UTC](https://www.ruby-forum.com/t/send-custom-data/227546/4 "2013-06-05T10:46:38Z")

</div>

I wanna send variables, which depends on the operating environment.  
Flowgraph can only send predefined data. So maybe I should directly call  
the UHD API. Is it correct? Thanks.
