Hi,
I’m trying to use “message passing” technique in order to create a block
that generates 29 Octets. Currently, I’m using a block that generates 29
Octets and then use tag streaming. In the .cc file, IO signature looks
like:
gr_sync_block (“st1_pktsrc_dummy_b”,
gr_make_io_signature (0, 0, 0),
gr_make_io_signature (MIN_OUT, MAX_OUT, sizeof (unsigned
char)))
While, the stream tags looks like this:
add_item_tag(0, tag_pos,
d_burst_start_key,
pmt_sob,
d_my_unique_id)
Now, I want to change this approach to message passing as it is
explained
here:
Blocks Coding Guide · guruofquality/grextras Wiki · GitHub.
So, I changed the lines indicated above, for the following:
: gr_sync_block (“test_temporal”,
gr_make_io_signature(0, 0, 0),
gr_make_io_signature(0, 0, 0),
msg_signature(false, 1))
and I am passing the message as follows:
this->post_msg(0, tag_pos,
d_burst_start_key,
pmt_sob,
d_my_unique_id);
However, when I compile my code after these changes, it complains about
the
class ‘asrp_test_temporal’ does not have any field named block (see the
errors attached below).
’
asrp_test_temporal.cc:113:5: error: class ‘asrp_test_temporal’ does not
have any field named ‘block’
asrp_test_temporal.cc:120:42: error: ‘msg_signature’ was not declared in
this scope
asrp_test_temporal.cc:120:42: note: suggested alternative:
/usr/local/include/gnuradio/block.h:58:22: note:
‘gnuradio::msg_signature’
So, I would like to ask you:
- Do I need to use the IO signature for message passing?, because in
the
example provide in the
Blocks Coding Guide · guruofquality/grextras Wiki · GitHub only
uses msg_signature, but not gr_make_io_signature (0, 0, 0).
I would really appreciate your help, sorry for the punctuation or
grammar
mistake, English is my second language. Please let me know if you need
more
information, I will be happy to provide it.
Regards,
Jose