From b207aa2d76a8171681b0ff0a3b5342e8f0703ba9 Mon Sep 17 00:00:00 2001 From: Johnathan Corgan Date: Thu, 26 Jan 2012 14:06:37 -0800 Subject: uhd: add utility function to convert raw gr_message to async_metadata_t --- gr-uhd/lib/gr_uhd_amsg_source.cc | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'gr-uhd/lib/gr_uhd_amsg_source.cc') diff --git a/gr-uhd/lib/gr_uhd_amsg_source.cc b/gr-uhd/lib/gr_uhd_amsg_source.cc index f2958f115..08941584b 100644 --- a/gr-uhd/lib/gr_uhd_amsg_source.cc +++ b/gr-uhd/lib/gr_uhd_amsg_source.cc @@ -75,6 +75,11 @@ protected: bool _running; }; +uhd::async_metadata_t uhd_amsg_source::msg_to_async_metadata_t(const gr_message_sptr msg) +{ + return *(uhd::async_metadata_t *)msg->msg(); +} + /*********************************************************************** * Make UHD Asynchronous Message Source **********************************************************************/ -- cgit