# Merge multiple complex streams

**URL:** <https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086>\
**Category:** GNU Radio\
**Created:** [May 12, 2014, 6:55pm UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086 "2014-05-12T18:55:44Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Detlef\_R](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/58f4c7/32.png) [@Detlef\_R](https://www.ruby-forum.com/u/Detlef_R)\
**Post date:** [May 12, 2014, 6:55pm UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/1 "2014-05-12T18:55:44Z")

</div>

Playing around with GRC for a few months now, sorry if this question is  
from a dummy.

I’ve a bunch of rtl dongles laying around, and wonder if it’s possible  
to  
combine more then one to a single baseband signal.

The goal is to create a super cheap full HF band web reciever like or  
for  
’ websdr’

I managed to create multiple channels, where the 2nd dongle is tuned to  
an  
offset, equal to the samplerate of the first. (for example 2 x 2 Msps =  
4  
Msps baseband)

Is such a thing possible with GRC?

Imre Biacsics

---

<div class="post-metadata">

**Author:** ![Imre\_Biacsics](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e495f1/32.png) [@Imre\_Biacsics](https://www.ruby-forum.com/u/Imre_Biacsics)\
**Post date:** [May 12, 2014, 7:55pm UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/2 "2014-05-12T19:55:24Z")

</div>

If you make an FFT block for each rtl-sdr source you can then interleave  
them all together and take your pick using the ‘M in N’ block. At the  
edges  
of each rtl-sdr frequency it will probably get quite messy as the clocks  
are not synchronised.

An example of the use of the FFT and ‘M in N’ blocks is in my scanoo\_rx  
app  
which will give you a head start. The ‘M in N’ block is used to pick  
out  
the channel from the output of the FFT block:

[https://raw.githubusercontent.com/m0mik/scanoo/master/apps/scanoo.com\_rx.grc](https://raw.githubusercontent.com/m0mik/scanoo/master/apps/scanoo.com_rx.grc)

I’ve always found that in order for it to work at first you must double  
click something in the flowgraph and then click cancel… some random  
erroneous bug in GRC.

Mike

---

<div class="post-metadata">

**Author:** ![Imre\_Biacsics](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e495f1/32.png) [@Imre\_Biacsics](https://www.ruby-forum.com/u/Imre_Biacsics)\
**Post date:** [May 13, 2014, 7:14pm UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/3 "2014-05-13T19:14:02Z")

</div>

How about the PFB synthesizer detailed by TR? I’d think all the dongles  
would have to be phase locked and references tones (or comb) used to  
calibrate the channels. If your signals are not crossing channels then  
maybe you could get away without that.

> **[PFB Channelizers and Synthesizers — Rondeau Research](http://www.trondeau.com/examples/2014/1/23/pfb-channelizers-and-synthesizers.html)**
>
> Building the Filters 
> Based on the paper presented at the  Karlsruhe Institute of Technology's  Workshop on Software Radio (WSR). 
> The paper starts off by explaining how to build the prototype filters and how these lead directly to the concept of...

Imre Biacsics wrote

> I’ve a bunch of rtl dongles laying around, and wonder if it’s possible to  
> combine more then one to a single baseband signal.

–  
View this message in context:  
[http://gnuradio.4.n7.nabble.com/Merge-multiple-complex-streams-tp48146p48187.html](http://gnuradio.4.n7.nabble.com/Merge-multiple-complex-streams-tp48146p48187.html)  
Sent from the GnuRadio mailing list archive at [Nabble.com](http://Nabble.com).

---

<div class="post-metadata">

**Author:** ![Imre\_Biacsics](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e495f1/32.png) [@Imre\_Biacsics](https://www.ruby-forum.com/u/Imre_Biacsics)\
**Post date:** [May 13, 2014, 10:15am UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/4 "2014-05-13T10:15:23Z")

</div>

On 12.05.2014 17:49, Imre Biacsics wrote:

> offset, equal to the samplerate of the first. (for example 2 x 2 Msps = 4  
> Msps baseband)
> 
> Is such a thing possible with GRC?

A couple of things, on top of what Mike said:

- HF bands go lower than the frequency of the dongles. Keep that in  
mind.
- As Mike said, clocks aren’t sync’d. So, if you’re using data from  
multiple dongles, that’ll most likely be corrupt.
- To make things worse, they drift differently too. So, little chance in  
fixing things.
- If all you want is an (inaccurate) “spectrum analyzer” for more than 2  
MHz, then this is actually not a bad idea. If you have N+1 dongles, you  
can use N of them to monitor N\*2MHz of spectrum, and the other one to  
receive at frequencies you’re interested in.

M

---

<div class="post-metadata">

**Author:** ![Imre\_Biacsics](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e495f1/32.png) [@Imre\_Biacsics](https://www.ruby-forum.com/u/Imre_Biacsics)\
**Post date:** [May 13, 2014, 9:21pm UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/5 "2014-05-13T21:21:55Z")

</div>

On 05/13/2014 03:02 PM, Imre wrote:

> [[Discuss-gnuradio] Passive radar using my hacked dual coherent channel r](http://lists.gnu.org/archive/html/discuss-gnuradio/2013-09/msg00387.html)  
> View this message in context:  
> [http://gnuradio.4.n7.nabble.com/Merge-multiple-complex-streams-tp48146p48191.html](http://gnuradio.4.n7.nabble.com/Merge-multiple-complex-streams-tp48146p48191.html)  
> Sent from the GnuRadio mailing list archive at [Nabble.com](http://Nabble.com).
> 
> * * *
> 
> Discuss-gnuradio mailing list  
> [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
> [Discuss-gnuradio Info Page](https://lists.gnu.org/mailman/listinfo/discuss-gnuradio)  
> All you channels will not only need to be phase-coherent, but also have  
> zero phase offset. That’s the only way you can reasonably simulate  
> having much wider bandwidth by “gluing together” a bunch of smaller  
> bandwidths.

My own experiments with the RTLSDR gear is that achieving phase  
coherence across significant bandwidth appears to not be possible, even  
with a common, high-quality master clock.

---

<div class="post-metadata">

**Author:** ![Imre\_Biacsics](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e495f1/32.png) [@Imre\_Biacsics](https://www.ruby-forum.com/u/Imre_Biacsics)\
**Post date:** [May 13, 2014, 9:03pm UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/6 "2014-05-13T21:03:28Z")

</div>

(Something went wrong with my mails, hopefully doing it right now, sorry  
Mike, replied directly to you)

Using Mike’s example and some fiddling around:

[http://www.livep2000.nl/code/grc/multichannel\_input.grc](http://www.livep2000.nl/code/grc/multichannel_input.grc)

Tuning on a FM channel shows the mentioned mess,  
interconnect the hardware clock? Maybe like this:

[http://lists.gnu.org/archive/html/discuss-gnuradio/2013-09/msg00387.html](http://lists.gnu.org/archive/html/discuss-gnuradio/2013-09/msg00387.html)

I’am give the polyphase synthesizer a look

–  
View this message in context:  
[http://gnuradio.4.n7.nabble.com/Merge-multiple-complex-streams-tp48146p48191.html](http://gnuradio.4.n7.nabble.com/Merge-multiple-complex-streams-tp48146p48191.html)  
Sent from the GnuRadio mailing list archive at [Nabble.com](http://Nabble.com).

---

<div class="post-metadata">

**Author:** ![Imre\_Biacsics](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e495f1/32.png) [@Imre\_Biacsics](https://www.ruby-forum.com/u/Imre_Biacsics)\
**Post date:** [May 14, 2014, 9:05am UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/7 "2014-05-14T09:05:05Z")

</div>

What about the passive radar - didn’t the author daisy chain the clocks  
of  
several RTLSDR?

Regards,  
Vanush

---

<div class="post-metadata">

**Author:** ![Imre\_Biacsics](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e495f1/32.png) [@Imre\_Biacsics](https://www.ruby-forum.com/u/Imre_Biacsics)\
**Post date:** [May 14, 2014, 10:25am UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/8 "2014-05-14T10:25:02Z")

</div>

On 14.05.2014 09:03, Vanush V. wrote:

> What about the passive radar - didn’t the author daisy chain the clocks  
> of several RTLSDR?

That was two dongles sharing a clock. Not exactly daisy-chained, and it  
didn’t look easily extendible 🙂

[http://kaira.sgo.fi/2013/09/passive-radar-with-16-dual-coherent.html](http://kaira.sgo.fi/2013/09/passive-radar-with-16-dual-coherent.html)

M

---

<div class="post-metadata">

**Author:** ![Imre\_Biacsics](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e495f1/32.png) [@Imre\_Biacsics](https://www.ruby-forum.com/u/Imre_Biacsics)\
**Post date:** [May 14, 2014, 8:32am UTC](https://www.ruby-forum.com/t/merge-multiple-complex-streams/241086/9 "2014-05-14T08:32:31Z")

</div>

We must not forget that each device has its own USB connection.  
One reason that getting all in sync on a ’ per sample’ base must be  
impossible.

Still a multi user system like the websdr can achieved by overlapping  
the  
channels and let the software decide what channel the user’s choice  
fits.

For a nice graphical representation (Spectrum analyzer, waterfall) this  
principle could work well.

Imre

–  
View this message in context:  
[http://gnuradio.4.n7.nabble.com/Merge-multiple-complex-streams-tp48146p48198.html](http://gnuradio.4.n7.nabble.com/Merge-multiple-complex-streams-tp48146p48198.html)  
Sent from the GnuRadio mailing list archive at [Nabble.com](http://Nabble.com).
