Forum: GNU Radio Questions on callback functions implementation of blocks in gr-trellis

3c8831e607294351d09f9e9034088512?d=identicon&s=25 Zhe Feng (Guest)
on 2014-05-03 08:33
(Received via mailing list)
Hi all,

I'm working on a system with trellis coding and I met a problem with the
python callback function generated by grc . Because there are several
parameters used in the blocks needs to be updated. I added callback
functions for those parameters in those c++ files.

For example, to add callback function for the FSM parameter in the
viterbi_combined block, I declared set_FSM function in
viterbi_combined.h ,
defined the function in viterbi_combined_impl.h, and added <callback>
set_FSM($FSM) </callback> in the viterbi_combined.xml file.

After that, I reinstalled the gnuradio and checked the trellis_swig.py
and
confirmed that python has linked these callback functions in the
viterbi_combined class.

But when I execute the grc application, this callback function wasn't
automatically generated in the resulting python file. After I added this
set_FSM function by myself, the flow graph worked as what I expected.

I've added callback functions for other blocks like repack_bits of
gr-block
module. After I've done exactly the same thing, the callback function I
added was correctly generated in python file after I executed in grc.

So my question is: why these callback functions I added in gr-trellis
weren't automatically generated in python file after execution in grc
like
the other callbacks in gr-blocks? Did I do anything wrong?

I attached my modification on gnuradio in the patch file for your
reference.

Thanks!

Best,
Zhe patch.patch
<http://gnuradio.4.n7.nabble.com/file/n47933/patch.patch>




--
View this message in context:
http://gnuradio.4.n7.nabble.com/Questions-on-callb...
Sent from the GnuRadio mailing list archive at Nabble.com.
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.