Re: Making C++ OOT module and wish to set up a parameter with different choices!

2020-06-30 Thread Ron Economos

It's done in the .yml file in gr-foo/grc. Here's a simple example:

https://github.com/gnuradio/gnuradio/blob/master/gr-analog/grc/analog_sig_source_x.block.yml#L6

And a more complex example:

https://github.com/gnuradio/gnuradio/blob/master/gr-dtv/grc/dtv_dvb_ldpc_bb.block.yml

If you use a definition from an additional project .h file, that .h file 
must be included in gr-foo/swig/foo_swig.i.


Ron

On 6/30/20 10:05, George Edwards wrote:

Hello,

I am making a C++ OOT module and wish to have an input parameter 
"frame_length" with different choices. I would like to provide short, 
medium and long frames with a value attached to each. Based on the OOT 
syntax, I can enter "frame_length" as an input argument to the model. 
Now, how can I set  up the inners of the *.cc file so that when the 
module is built into a Gnuradio block, I can simply click on 
'frame_length' to see the choices and select one?


Thanks for the help.

Regards,
George




Re: Making C++ OOT module and wish to set up a parameter with different choices!

2020-06-30 Thread Glen Langston
Very nice document.
Thanks
Glen


> On Jun 30, 2020, at 1:17 PM, jean-michel.fri...@femto-st.fr wrote:
> 
> I do not claim to cover all aspect of OOT blocks but I tried to document the 
> basics of 
> passing parameters and public/private variables at 
> http://jmfriedt.free.fr/gr_oscilloscope_eng.pdf
> 
> Unfortunately this document only covers GNU Radio 3.7: while the French 
> version was extended to
> GNU Radio 3.8, the English version was not extended accordingly but I'd be 
> happy to do so if there
> is any interest.
> 
> JM
> 
> --
> JM Friedt, FEMTO-ST Time & Frequency/SENSeOR, 26 rue de l'Epitaphe,
> 25000 Besancon, France
> 
> June 30, 2020 7:06 PM, "George Edwards"  wrote:
> 
>> Hello,
>> 
>> I am making a C++ OOT module and wish to have an input parameter 
>> "frame_length" with different
>> choices. I would like to provide short, medium and long frames with a value 
>> attached to each. Based
>> on the OOT syntax, I can enter "frame_length" as an input argument to the 
>> model. Now, how can I set
>> up the inners of the *.cc file so that when the module is built into a 
>> Gnuradio block, I can simply
>> click on 'frame_length' to see the choices and select one?
>> 
>> Thanks for the help.
>> 
>> Regards,
>> George
> 




Re: Making C++ OOT module and wish to set up a parameter with different choices!

2020-06-30 Thread jean-michel.fri...@femto-st.fr
I do not claim to cover all aspect of OOT blocks but I tried to document the 
basics of 
passing parameters and public/private variables at 
http://jmfriedt.free.fr/gr_oscilloscope_eng.pdf

Unfortunately this document only covers GNU Radio 3.7: while the French version 
was extended to
GNU Radio 3.8, the English version was not extended accordingly but I'd be 
happy to do so if there
is any interest.

JM

--
JM Friedt, FEMTO-ST Time & Frequency/SENSeOR, 26 rue de l'Epitaphe,
25000 Besancon, France

June 30, 2020 7:06 PM, "George Edwards"  wrote:

> Hello,
> 
> I am making a C++ OOT module and wish to have an input parameter 
> "frame_length" with different
> choices. I would like to provide short, medium and long frames with a value 
> attached to each. Based
> on the OOT syntax, I can enter "frame_length" as an input argument to the 
> model. Now, how can I set
> up the inners of the *.cc file so that when the module is built into a 
> Gnuradio block, I can simply
> click on 'frame_length' to see the choices and select one?
> 
> Thanks for the help.
> 
> Regards,
> George



Making C++ OOT module and wish to set up a parameter with different choices!

2020-06-30 Thread George Edwards
Hello,

I am making a C++ OOT module and wish to have an input parameter
"frame_length" with different choices. I would like to provide short,
medium and long frames with a value attached to each. Based on the OOT
syntax, I can enter "frame_length" as an input argument to the model. Now,
how can I set  up the inners of the *.cc file so that when the module is
built into a Gnuradio block, I can simply click on 'frame_length' to see
the choices and select one?

Thanks for the help.

Regards,
George