[Top][All Lists]

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

Re: [Discuss-gnuradio] Duplex / Push-To-Talk and top_blocks

From: Johnathan Corgan
Subject: Re: [Discuss-gnuradio] Duplex / Push-To-Talk and top_blocks
Date: Mon, 3 Dec 2007 08:29:12 -0800

On 12/3/07, Martin Braun <address@hidden> wrote:

> Seems I can't have several top_blocks at the same time?

This is a somewhat artificial restriction in the code right now,
having to do with how GNU Radio starts up and shuts down, and how it
handles operating system signals while being multithreaded.  It *may*
go away in release 3.2 when the mblock/gr-block combined
infrastructure is built.

You can, however, create your transmit and receive paths as
independent hierarchical blocks, with no inputs and outputs, then
'connect' them into a single top block.

tx = transmit_path(...) # class transmit_path derives from gr.hier_block2
rx = receive_path(...) # class receive_path derives from gr.hier_block2

self.connect(tx) # self is your class derived from gr.top_block

See the USRP example usrp_nbfm_ptt.py in gnuradio-examples for an
example of this in practice.

Johnathan Corgan
Corgan Enterprises LLC

reply via email to

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