discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error with dynamically changing block parameter


From: Solomon Tan
Subject: Re: Error with dynamically changing block parameter
Date: Sun, 30 May 2021 13:16:30 +0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1

Hi all,

Just replying to my previous message for the benefit of everyone else
whos also trying to do make a OOT that responds dynamically to changes
in a parameter (e.g. through QT GUI Range).

The key is to add your setter function (which sets your parameter) to
`callback` in your block's YAML file. See
https://wiki.gnuradio.org/index.php/YAML_GRC#Templates for more
information.

In my preceding email, I had problems because I tried to use
gr_controlport. I barked up the wrong tree.

Thanks to Derek Kozel for sharing this information with me.

Cheers,
Sol

On 13/5/21 12:03 am, Solomon Tan wrote:
> Hi all,
> 
> I am trying to make my OOT block respond to changes in its parameter the
> same way the Add Const block behaves. I want my block to update its
> value as and when the user slides the qtgui range. I notice this is not
> done by default. I added the same `add_rpc_variable` function defined in
> `gr-blocks/lib/add_const_ff_impl.cc`. I replaced the appropriate
> variable/function names with my own. However, I get the following error.
> 
> ```
>  error: no matching function for call to
> ‘rpcbasic_register_set<gr::my_OOT::reactionFunction_impl,
> float>::rpcbasic_register_set(std::string, const char [9], void
> (gr::my_OOT::reactionFunction_impl::*)(int), pmt::pmt_t, pmt::pmt_t,
> pmt::pmt_t, const char [1], const char [16], priv_lvl_t, const uint32_t&)’
>   225 |
> DISPNULL)));
> ```
> 
> I imported the same header files that `add_const_ff_impl.h` and
> `add_const.h` import. What does the error mean. What have I done
> incorrectly? I couldnt find a thread describing the same problem in the
> archives.
> 
> Does someone have an easier way to do what I wanna do?
> 
> Thanks.
> Cheers,
> Sol
> 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]