discuss-gnuradio
[Top][All Lists]
Advanced

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

Re: [Discuss-gnuradio] Block example that processes on another thread


From: Michael Dickens
Subject: Re: [Discuss-gnuradio] Block example that processes on another thread
Date: Sat, 18 Aug 2007 15:49:18 -0400

On Aug 18, 2007, at 2:57 PM, Eric Blossom wrote:
On Thu, Aug 16, 2007 at 04:04:40PM -0700, Chris Stankevitz wrote:

Can anyone direct me to a block that does its processing on a separate
thread (i.e. other than the thread that calls gr_sync_block::work)

There aren't any ;)

Not entirely true (just 99% looking at GNU Radio in general)! gr- audio-osx uses multiple threads, with processing done in both the scheduler thread as well as the other threads. Data is transferred via buffering, which requires a mutex to lock processing and condition to allow for waiting until data is available. Be forewarned, though, that dealing with common data (variables) in multiple threads can be difficult! And tracking down bugs is quite difficult, as per my experience yesterday fixing the use of the mutex and condition in the OSX modules for audio and USB. - MLD




reply via email to

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