diff options
author | Thomas Tsou <ttsou@vt.edu> | 2011-08-19 14:50:55 -0700 |
---|---|---|
committer | Thomas Tsou <ttsou@vt.edu> | 2011-08-19 18:30:38 -0700 |
commit | 893f946b7a652497994309092fe84fb33504852c (patch) | |
tree | 064fa60b78a04565ba559a29a2f7bf824b63473e /gr-uhd/grc | |
parent | dc16937c935f10a16de8969ca592b6019639d52b (diff) |
gr-uhd: add async metadata source block
Add asynchronous message "block" that is independent of normal
gnuradio scheduler. The block instantiates a thread to wait
for asynchronous messages from UHD and encapsulates them in a
gr_message posted into a message queue.
The interface is empty because the block is internally driven
and accessed through the the constructor specified message
queue.
Diffstat (limited to 'gr-uhd/grc')
-rw-r--r-- | gr-uhd/grc/Makefile.am | 1 | ||||
-rw-r--r-- | gr-uhd/grc/uhd_amsg_source.xml | 24 | ||||
-rw-r--r-- | gr-uhd/grc/uhd_block_tree.xml | 1 |
3 files changed, 26 insertions, 0 deletions
diff --git a/gr-uhd/grc/Makefile.am b/gr-uhd/grc/Makefile.am index 7e73a5b392..42a35b1c19 100644 --- a/gr-uhd/grc/Makefile.am +++ b/gr-uhd/grc/Makefile.am @@ -31,6 +31,7 @@ BUILT_SOURCES += $(generated_uhd_usrp_blocks) dist_grcblocks_DATA = \ uhd_block_tree.xml \ + uhd_amsg_source.xml \ $(BUILT_SOURCES) ######################################################################## diff --git a/gr-uhd/grc/uhd_amsg_source.xml b/gr-uhd/grc/uhd_amsg_source.xml new file mode 100644 index 0000000000..78c9d7b58e --- /dev/null +++ b/gr-uhd/grc/uhd_amsg_source.xml @@ -0,0 +1,24 @@ +<?xml version="1.0"?> +<block> + <name>UHD: USRP Async Msg Source</name> + <key>uhd_amsg_source</key> + <import>from gnuradio import uhd</import> + <make>uhd.amsg_source(device_addr=$dev_addr, msgq=$(id)_msgq_out)</make> + <param> + <name>Device Addr</name> + <key>dev_addr</key> + <value></value> + <type>string</type> + <hide> + #if $dev_addr() + none + #else + part + #end if + </hide> + </param> + <source> + <name>out</name> + <type>msg</type> + </source> +</block> diff --git a/gr-uhd/grc/uhd_block_tree.xml b/gr-uhd/grc/uhd_block_tree.xml index 8a9f62f7cb..5d3b493936 100644 --- a/gr-uhd/grc/uhd_block_tree.xml +++ b/gr-uhd/grc/uhd_block_tree.xml @@ -10,5 +10,6 @@ <name>UHD</name> <block>uhd_usrp_source</block> <block>uhd_usrp_sink</block> + <block>uhd_amsg_source</block> </cat> </cat> |