Run a top block within a block!

Hi GNURadiores,

I was thinking about how to change dynamically the blocks connected in
my
top block when it’s running!
After a long time, I reach to this point that I may have a top block is
running within a block! (Also another top block runs* the block*
itself.

is that possible?
If it is, I could change the top block which is in a block.

Best,
Mostafa

On Sat, May 31, 2014 at 12:11 PM, Mostafa A.
[email protected]
wrote:

Hi GNURadiores,
I was thinking about how to change dynamically the blocks connected in my
top block when it’s running!

What do you want to change; the block parameters, or the links
connecting
the blocks (which is the flowgraph itself)?
Basically both are possible, you may need to enhance your flowgraph in
python code by hand. During execution, lock the flowgraph, modify it
accordingly, and then unlock it to proceed with the flowgraph execution.

After a long time, I reach to this point that I may have a top block is
running within a block!

Probably you are referring to “hierarchical block” …?

On Sat, May 31, 2014 at 5:53 PM, Mostafa A.
[email protected]
wrote:

Hi Activecat,
I wanna change both block parameters and their connections also adding or
removing some blocks.
This is interesting if it’s possible to build a flowgraph within the
work function of a block which allows me to change a part of the main
flowgraph!

In my knowledge, hierarchical blocks do not have “work()” function.
They are usually coded in python, consisting “self.connect()” to connect
up
its building blocks.

However, the problem is the source and sink for the flowgraph within the
block (or work function). I think this also possible to have a source
(sink) which simply gives a pointer, which points to the input(output) of
the block(with this dynamic flowgraph) and a number of items to produce
(consume).

This is more than just a hier_block.

I don’t really understand your statements but I hope you could
accomplish
what you want.
Thanks.