summaryrefslogblamecommitdiffstats
path: root/08.-GNU-Radio-Block.md
blob: 2dd9d37a14bbaf705f666b32198bd63d19773e5f (plain) (tree)





























                                                                                                                                                                                                                                                                                                                                                                                                         
GNU Radio is a popular and free open source toolkit that provides various digital signal processing blocks. You can use it to build demodulators, decoders and for various applications that make use of coherent data, such as interferometry and beamforming.

A source block for the KrakenSDR is available at https://github.com/krakenrf/gr-krakensdr. Please consult the readme on the gr-krakensdr repository for installation instructions.

<img src="https://user-images.githubusercontent.com/78108016/185366866-f0784cc1-4a8c-4140-add5-88c271c7494c.png" width="250">
<img src="https://user-images.githubusercontent.com/78108016/185367619-2c9baa15-186e-4b11-9133-d6cf80f53608.png" width="500">

## How the KrakenSDR Source Block Works
The gr-krakensdr block works together with the KrakenSDR Heimdall DAQ software. Heimdall is the KrakenSDR software that ensures all channel samples are coherent. It automatically handles sample and phase coherence calibration on startup, and periodically checks and confirms that coherence is maintained. The GNU Radio block receives coherent IQ data from Heimdall via a TCP socket connection.

The Heimdall server can be run either on the same machine as the GNU Radio program, or on a networked device, such as a Raspberry Pi 4. However, if a network is used, you will need to ensure that it is capable of handling the required throughput for 5-channels.

## GNU Radio KrakenSDR Example Flowgraphs

We've also included three example GRC flowgraphs, and a cross correlator and DOA MUSIC block to help users get familiar with using the source block.

### Example 1 - Simple Multichannel FFT
The first example file is provides a simple FFT display for each output channel.

![krakensdr_gnuradio_fft](https://user-images.githubusercontent.com/78108016/185366658-aaceb80a-c4a2-41cb-a1f7-770fa6007b48.png)

### Example 2 - Radio Direction Finding with the DOA MUSIC block
The second example uses the DOA MUSIC block to provide a radio direction finding bearing output, when used with an antenna array.

![krakensdr_gnuradio_music_doa](https://user-images.githubusercontent.com/78108016/185367262-217cebea-b907-493d-9867-c60000f3dcef.png)

### Example 3 - Cross Correlation Sample and Phase Coherent Check
The final example can be used to double check that the output of Heimdall is actually coherent, by running a cross correlation between channels 1-4 against the reference channel 0. To use this correlation flowgraph you'll need to modify one line in the Heimdall source to force the noise source to remain always on. How to do this is explained in the gr-krakensdr readme.

![krakensdr_gnuradio_cross_correlator](https://user-images.githubusercontent.com/78108016/185367575-6c49cc38-a996-4850-9162-740227e2bb0d.png)