Gnuradio DAB constellation using gr-dab and USRP

From Opendigitalradio
Jump to: navigation, search

Plot in live the constellation diagram of a received DAB signal using gr-dab and USRP.

DAB constellation (D-QPSK)



  • USRP or baseband recording from a file
    • WBX daughterboard or modified RFX400 (TVRX daughterboard has too much phase noise and cannot be used)
  • Linux PC with Gnuradio source (>=3.2)
  • gr-dab tools


  • Download source code of gnuradio and gr-dab tools
  • Patch peak detector of gnuradio source code with patch/not-applied-in-trunk of gr-dab
  • Patch "" with patch below
  • Configure, compile and install gnuradio and then gr-dab tools.


( -h)

Usage: [options] <filename>

  -h, --help            show this help message and exit
  -m DAB_MODE, --dab-mode=DAB_MODE
                        DAB mode [default=1]
  -F, --filter-input    Enable FFT filter at input
  -c, --correct-ffe     do fine frequency correction
  -u, --correct-ffe-usrp
                        do fine frequency correction by retuning the USRP
                        instead of in software
  -e, --equalize-magnitude
                        do magnitude equalization
  -s RESAMPLE_FIXED, --resample-fixed=RESAMPLE_FIXED
                        resample by a fixed factor (fractional interpolation)
  -S, --autocorrect-sample-rate
                        Estimate sample rate offset and resample (dynamic
                        fractional interpolation)
  -R RX_SUBDEV_SPEC, --rx-subdev-spec=RX_SUBDEV_SPEC
                        select USRP Rx side A or B [default=A]
  -f FREQ, --freq=FREQ  set frequency to FREQ [default=227360000.0]
  -r SAMPLE_RATE, --sample-rate=SAMPLE_RATE
                        set sample rate to SAMPLE_RATE [default=2000000]
  -d DECIM, --decim=DECIM
                        set decimation rate to DECIM [default=32]
  -g RX_GAIN, --rx-gain=RX_GAIN
                        set receive gain in dB (default is midpoint)
  -v, --verbose         verbose output

Example for plotting the constellation of an ensemble on 223.936MHz: -R A -f 223936000 -c -e -S

Screenshot-usrp dab gui rx-1.png Screenshot-usrp dab gui rx-2.png patch

---    (revision 203)
+++    (working copy)
@@ -91,8 +91,8 @@
        self.demod = dab.ofdm_demod(self.dab_params, self.rx_params, verbose=self.verbose)

        self.v2s = gr.vector_to_stream(gr.sizeof_gr_complex, self.dab_params.num_carriers)
-        self.scope = scopesink2.constellation_sink(self.panel, title="DAB constellation sink", sample_rate=self.dab_params.sample_rate, frame_decim=3)
+        self.scope = scopesink2.scope_sink_c(self.panel, title="DAB constellation sink", sample_rate=self.dab_params.sample_rate, frame_decim=3)
+        #"plus")

        # self.sink = gr.null_sink(gr.sizeof_char*self.dab_params.num_carriers/4)
        self.trigsink = gr.null_sink(gr.sizeof_char)
Personal tools