/r/GNURadio

Photograph via snooOG

A subreddit dedicated to the GNU Radio project and any software-define radio (SDR) related content (including USRP, etc. news).

Interesting technical papers or articles are particularly welcome!


Recommended subreddits

/r/GNURadio

5,238 Subscribers

2

Designing dynamic hardware gain control

Hi

I am looking for an efficient method to get an agc-alike functionality but for the harware instead of amplifying in software.

My method would be to use a python block after a complex to mag block and check what the maximum amplitude is. Then, change the gain to get it as close to 1 as possible. However, this is quite slow and even causes samples to be dropped. I thus need a faster solution.

Suggestions? Thanks!

0 Comments
2024/04/19
09:45 UTC

4

Continuous 'U' Output When Using USRP B210

Hi everyone,

I'm working with a USRP B200 SDR and encountering an issue where I receive a continuous stream of 'U's in the console output. This happens when I'm trying to transmit a signal. I understand this usually indicates an overflow, I'm looking for more detailed insights and potential solutions. Here's a snapshot of the output:

https://preview.redd.it/3dpjb53zb7vc1.png?width=524&format=png&auto=webp&s=a577192980bfc22ce0949bb91de07cecc56709c9

3 Comments
2024/04/18
09:21 UTC

2

Issue with BladeRF FPGA Configuration in Gqrx

I'm encountering an issue with configuring the FPGA for my BladeRF device in Gqrx. When I try to open Gqrx, I receive the following error message:

init: The FPGA is not configured! Provide device argument fpga=/path/to/the/bitstream.rbf to load it.

Please select another device.

Can anyone help me understand how to properly configure the FPGA for BladeRF in Gqrx?

1 Comment
2024/04/15
13:26 UTC

0

Python OOT module not found

I created a new header payload demux using cpp file,

This is how I installed the module:

cmake -DMAKE_INSTALL_PREFIX=$(gnuradio-config-info - -prefix) .. make -j10 sudo make install sudo ldconfig

This error msg came out, can someone help out?

Happy to provide ymal, cpp, h files if needed;)

16 Comments
2024/04/12
04:06 UTC

2

FMCW radar does not work. is it for the settings or a misunderstanding?

9 Comments
2024/04/11
18:45 UTC

1

An OOT Module fails building

Hello there,
I was trying to install an OOT but I struggled a lot with error raised in the .cc file.
The module is built over a famous module called (gr IEEE 802.11). this module was already installed at my machine but the other OOT raises so many errors. I don't know whether that's because of overlapping dependencies or what but i really needed that OOT.
Here is a link for the OOT needed : https://github.com/reysam93/OMICRON-GNURadio/tree/master

and that's the IEEE 802.11(which is already working well for me) : https://github.com/bastibl/gr-ieee802-11

And here is part of the error that appears when I try building the OOT.

/home/youssef/OMICRON-GNURadio/gr-adaptiveOFDM/lib/constellations_impl.cc:31:30: error: return type ‘gr::adaptiveOFDM::constellation_bpsk::sptr’ {aka ‘class boost::shared_ptr<gr::adaptiveOFDM::constellation_bpsk>’} is incomplete
  31 |    constellation_bpsk::make() {
     |                             ^
/home/youssef/OMICRON-GNURadio/gr-adaptiveOFDM/lib/constellations_impl.cc: In static member function ‘static void gr::adaptiveOFDM::constellation_bpsk::make()’:
/home/youssef/OMICRON-GNURadio/gr-adaptiveOFDM/lib/constellations_impl.cc:32:68: error: invalid use of incomplete type ‘gr::adaptiveOFDM::constellation_bpsk::sptr’ {aka ‘class boost::shared_ptr<gr::adaptiveOFDM::constellation_bpsk>’}
  32 |      return constellation_bpsk::sptr(new constellation_bpsk_impl());
     |                                                                   ^
In file included from /usr/include/boost/throw_exception.hpp:73,
                from /usr/include/boost/type_index/stl_type_index.hpp:33,
                from /usr/include/boost/type_index.hpp:29,
                from /usr/include/boost/any.hpp:18,
                from /usr/include/pmt/pmt.h:15,
                from /usr/include/gnuradio/digital/constellation.h:17,
                from /home/youssef/OMICRON-GNURadio/gr-adaptiveOFDM/include/ 

I would really appreciate any help, As I was stuck in that problem for a long while.

4 Comments
2024/04/11
11:50 UTC

2

Packet encoder/decoder alternative

I was following this tutorial for a simple file transmitter but the packet encoder and decoder modules have been depreciated for a while now. so is there any simple (relatively) alternative to them that my relatively new to gnuradio brain can understand? or will I have to track down a version of gnuradio from back then when the modules existed?

5 Comments
2024/04/09
22:14 UTC

1

Using both RF frontends to receive using B210

Hi,

I have been using rx_samples_to_file to capture signal on a USRP B210. By default, it uses the RF frontend A RX2 antenna to receive.
Is it possible to use both the RF A and RF B RX2 antennas simultaneously to capture signal from the same frequency using the rx_samples_to_files?

I have been trying to find the flag/parameter, but no luck so far. I know that "--ant ___ " can change the antenna used. But I'm unable to get both the Rx2 antennas active at the same time.

3 Comments
2024/04/09
18:13 UTC

1

Controlling the rate of a File Source

I'm trying to transmit and receive video between two SDRs. The video enters the flowchart via a File Source. The File Source feeds the video in at the sample rate of the project which is higher than the consuming rate at the receiving end. This is leading to a large buffer at the receiving end in FFPlay. The receiver gives its data to FFPlay via a UDP Sink.

So far, I have tried the following:

  • Throttle at the File Source but this leads to a lot of underflow.
  • Feeding the video in via UDP with FFMPEG and a UDP Source. This leads to underflow as before.
  • Unpacking K bits. I don't see a 16QAM constellation (just a single point).

Sometimes I get a burst of errors saying 'dvbt_energy_dispersal :warning: Malformed MPEG-TS!' when trying the above solutions.

Is there a way I can control the rate at which the bytes from the video file enter the flowchart so that the video doesn't get bunched up at the receiver end?

https://preview.redd.it/czd1u3sp6gtc1.jpg?width=1190&format=pjpg&auto=webp&s=6cf3f219c3a120e2b23f9d7de04ef2ab66ff098b

1 Comment
2024/04/09
12:33 UTC

2

What's the best way to decode tone signals?

3 Comments
2024/04/09
11:03 UTC

2

Is there a way to visualise signals from separate flowcharts in one window?

I have signals in separate GNU Radio flowcharts that I run at the same time that I would like to plot in one window.

Is there a way to send the data to an external Python script or make the graphs from separate GNU Radio flowcharts appear in the same window? So far, I've tried using UDP sockets but this doesn't seem to work for all plots (for example QT Frequency Sinks).

0 Comments
2024/04/08
16:13 UTC

3

How can I reduce the computation power needed by my flowchart?

I have a flowchart that uses three B210s and my Intel Xeon PC is struggling to handle it. I have a convolutional encoder/decoder and DVB-T (de)mapper which I assume is the main culprit.

Is there a way to run some or all of the code directly on the B210s? Also, are there any more general ways to reduce the compute power needed by the flowchart?

I've already tried to generate C++ code rather than Python but I get an error when I try to run this.

3 Comments
2024/04/04
17:33 UTC

2

Debugging Embedded Python Block

Hi, I'm trying to write a Manchester decoder for GNU Radio and i'm using the embedded python block to do so.

I'm trying to make the decoder use the self clocking property of Manchester Encoding by calculating number of samples between between transitions, to syncronise my output.

I keep getting index out of range and i can't see why.Usually with python, I would run in debug mode and manually track the problem, but I can't figure out how to get VS Code (My default IDE) to run in debug mode while the python block is running in GNU Radio.

Any tips on debugging and writing embedded python blocks would be greatly appreciated as the GNU Radio WiKi isn't very comprehensive in this area.

Also, if you can think of an easier way to achieve what i am trying to achieve please let me know. I'm not the best programmer so all help is great :)Thanks alot.

Code:

"""
Embedded Python Blocks:

Each time this file is saved, GRC will instantiate the first class it finds
to get ports and parameters of your block. The arguments to __init__  will
be the parameters. All of them are required to have default values!
"""

import numpy as np
from gnuradio import gr
import pmt

class blk(gr.sync_block):  # other base classes are basic_block, decim_block, interp_block
    """Embedded Python Block example - Manchester Encoding attempt"""

    def __init__(self):  # only default arguments here
        """arguments to this function show up as parameters in GRC"""
        gr.sync_block.__init__(
            self,
            name='Embedded Python Block',   # will show up in GRC
            in_sig=[np.float32],
            out_sig=[np.float32, np.float32]

        )
        self._transition_indices = []
        self._symbol_buffer = []
        self.sym = 0


    def work(self, input_items, output_items):
        
        samples = input_items[0]


        for i, sample in enumerate(samples):
            # Detect transitions and record their indices
            if i > 0 and samples[i] != samples[i-1]:
                self._transition_indices.append(i)

            # Add the sample to the symbol buffer
            self._symbol_buffer.append(sample)

            # Calculate symbol length dynamically
            if len(self._transition_indices) >= 2:
                symbol_lengths = [self._transition_indices[i] - self._transition_indices[i-1] for i in range(1, len(self._transition_indices))]
                symbol_length = sum(symbol_lengths) / len(symbol_lengths)
                symbol_length = round(symbol_length)

                # Decode symbol if enough samples have accumulated
                if len(self._symbol_buffer) >= symbol_length:
                    symbol_length = int(symbol_length)
                    symbol = self._symbol_buffer[:symbol_length]
                    self._symbol_buffer = self._symbol_buffer[symbol_length:]

                    midpoint = symbol_length // 2
                    if (midpoint < len(symbol)):
                        self.sym = int(symbol[midpoint] == 1)

            # Convert decoded bits to np.int8 and assign to the output
            output_items[0][i] = input_items[0][i]      # Output original signal for comparrison
            output_items[1][i] = float(self.sym)        # Output decoded signal

        return len(output_items[0])

Error Message:
thread_body_wrapper :error: ERROR thread[thread-per-block[6]: <block Embedded Python Block(4)>]: IndexError: list index out of range
At:
~/Documents/GNU Radio Flows/LimeSDR-Setups/LimeSDR_Car_Key_Reader/LimeSDR_Car_Key_Reader_epy_block_0.py(57): work

/usr/lib/python3/dist-packages/gnuradio/gr/gateway.py(199): handle_general_work

7 Comments
2024/04/04
17:19 UTC

2

Feature request : Adding dropdown option to parameters in an embedded python block or embedded python block , configuration with yaml files

Whether something like this is possible using embedded python block , How it can be implemented ?? . You may think that this is irrelevant if we already have gr_modtool , but in some cases embedded python block comes in really handy . As for using a gr_modtool we need to install that module locally to our system . But in the case of embedded python block , just the grc file will be more than enough to share between users.

Edit: Sorry for the poor title

dropdown menu for parameters in embedded python block

2 Comments
2024/04/04
11:03 UTC

4

PlutoSDR choosing the right sample rate and Rf bandwidth

Hi, I’m trying to make a fmcw radar using a PlutoSDR. I don’t know if I’m missing something or I chose incorrectly the parameters, but I don’t get any results or change in frequency even when I tried with high-speed sources (60mph). I appreciate any feedback

2 Comments
2024/04/03
05:11 UTC

1

Help with Frequency sink parameters!!!

I’m new using gnu radio and I’m trying to set up the center frequency and the bandwidth of the QT GUI frequency sink but the signal is still appearing at the center of the plot with the same size no matter the parameters I set. Am I misunderstanding the use of the parameters?

3 Comments
2024/04/03
03:15 UTC

1

What is a corresponding block to WX GUI Slider than QT has?

I am working on my fm receiver on gnu radio companion and the wx GUI slider block is gone, along with the other wx GUI widgets. i am aware that it is no longer supported and QT is recommended, but what is a alternative widget to WX GUI Slider?

1 Comment
2024/04/03
00:00 UTC

2

Are there any "high" powered transceiver options?

Howdy folks,

I have been messing around with GNU Radio for a bit with my HackRF and wanted to see if anyone could answer a question about high power transceivers. Do they exist? Everything referenced in the GNU Radio Hardware matrix is very low power. Has anyone had any success connecting to SDR hardware that is in the scale of watts rather than milliwatts?

Any help or pointers would be greatly appreciated. Thanks!

5 Comments
2024/04/02
17:47 UTC

1

Strange results with networked flows - tips on network optimisation needed

Hi,

I have an app, a radar, the conjugated signals then go (stream-vector > FFT > complex - mag > vector - stream) then i can read the output in numerical form, from here i run a threshold block and a custom Py module i wrote to handle the output as i need it, all is well in a single flowgraph, between 4 systems / gnuradio installs the numbers are the same but the moment i split the flow graph into 2 flows connected by either a tcp or udp block the number outputed on the client side is different to the 'stable' number i saw in a single flow, various systems give various outputs but the one thing i cant get is the same magnitude over networking as i see in a single graph.

1 Comment
2024/04/02
11:46 UTC

2

sample rate and bandwidth of pluto sdr

Hi,

I am working on capturing the telemetry data using PlutoSDR and GNU radio. Transmitter is having center frequency as 915Mhz & bandwidth of 26Mhz(902MHz - 928MHz) and has 64kbps air data rate. And it uses 4 FSK modulation.

I need the following parameters for capturing the data through pluto sdr - LO frequency, sample rate, RF Bandwidth, buffer size. I will set the LO frequency at 915 MHz and bandwidth to 30Mhz. Can someone tell me what should be the sample rate and buffer size for the above requirement. And what is the relation between the RF bandwidth, sample rate and buffer size?

3 Comments
2024/04/01
06:36 UTC

1

Any idea what kind of modulation this is and how to decode to Hex/ASCII?

Hi i've been playing around with my SDR and an old key fob I had laying around and I've been trying to figure out how I can view the code it emmits.

So far, i've realised that the fob uses a form of On/Off Keying, so I used the "Complex to Mag^2" block to output RF Power. I then used the threshold block to clamp the value to a 1 or a 0 in an attempt to view a binary stream.
On close inspection of the signal, I can see 2 pulse lengths are used. I'll cal them "Wide" and "Narrow" to keep things simple.
I've noticed that both pulse types are used for logic high and logic low, however a wide logic high pulse is not always followed by a wide logic low, and visa versa.

I'm struggling to figure out a pattern that can successfully turn this into binary data, so any guidance would be greatly appreciated.

Note. in a very similar GNU Radio flow, I added the "Unpacked to Packed" block after the threshold and sent that to a "File Sink" writing to "/dev/stdout", in hopes to see some data print in the terminal, however I got a Unicode error: invalid start bit.

Please let me know if you have any ideas,Thanks for reading :)

GNU Radio Flow Graph and Output

1 Comment
2024/03/31
21:32 UTC

1

Channel Utilization in GNU Radio

0 Comments
2024/03/28
21:05 UTC

1

MPSK SNR Estimator or Tag Debug seems to "lag" behind

Hello,

I am trying to measure how the SNR changes when I move the antennas of my two SDRs. For this I use the following setup in Gnu Radio (Excerpt):

https://preview.redd.it/yh79g2ku5vqc1.png?width=1226&format=png&auto=webp&s=244576cfe33000b1e41644761e44b02c694bee4c

To see the SNR I use the Tag Debug since I can't get a File sink working (I get unintelligible Binary data which I cant use since I cant figure out the format of the data). Does someone have an idea on how to get it working?

The following image shows my measurement:

  1. The Program is started and after about 50 entries the SNR settles at 13dB
  2. The SNR settles at 13dB
  3. I rotate the antenna 45°
  4. After a while (15sec) I see a drop in SNR in the Debug Output. So its already lagging behind. After 500 entries it still seems like its not reaching the actual SNR Value where it should be.
  5. The antenna is rotated back to its original position. I see this in the output for it like 30secs later.
  6. It takes over 1500 Entries to climb and it still is 2dBs of from the original 13dBs. It takes forever to reajust.

Here is the data: https://ibb.co/WvVbjyh

Why is the SNR lagging behind. Why is it not faster and sharper. Is the Tag Debug at fault for neeing to long to write the data? I am just not sure.

With Entry I mean the Tag output in the terminal, and it looks like this:

----------------------------------------------------------------------
Tag Debug: 
Input Stream: 00
  Offset: 2206000000  Source: mpsk_snr_est_cc4     Key: snr   Value: 11.3321
----------------------------------------------------------------------

----------------------------------------------------------------------
Tag Debug: 
Input Stream: 00
  Offset: 2207000000  Source: mpsk_snr_est_cc4     Key: snr   Value: 11.3341
----------------------------------------------------------------------

----------------------------------------------------------------------
Tag Debug: 
Input Stream: 00
  Offset: 2208000000  Source: mpsk_snr_est_cc4     Key: snr   Value: 11.336
----------------------------------------------------------------------

Thanks for any help.

4 Comments
2024/03/27
11:46 UTC

1

Finding range of an object using BladerRF as a RADAR

Here I am getting an error regarding the connectivity between Stream to vector that Source IO size"8" doesnot match Sink IO size"16384". Not been able to resolve this...please help

1 Comment
2024/03/27
06:02 UTC

1

Theoretical TDOA, How to generate .dat files without actual recording

Im experimenting with TODA signals with chirp spread spectrum, and my hardware is not so effective in picking up the signals or the synchronisation is not accurate. Is there any way that i can generate these data without performing an actual experiment say, computer stimulation data etc. If you please do suggest me how to do it. Im really new, some blogs or writeups will be really helpful. Thank you!

0 Comments
2024/03/26
02:31 UTC

1

How to determine bitrate of a BPSK modem

I have a BPSK modem example working with 2 Plutos. The bits come in unaligned but I can align them in post process (if anyone knows a trick to wait for a preamble before saving data Ill give you an M&M). The real question is, how do I determine bitrate? I am trying to do BER when I transmit noise near the rx antenna.

BPSK modem, kind of working.

7 Comments
2024/03/18
23:20 UTC

1

Sensor 'ref_locked' failed to lock within timeout on motherboard 0.

Hi, while running the following flow graph, I am getting the warning: "usrp_sink :warning: Sensor 'ref_locked' failed to lock within timeout on motherboard 0.". How can I fix this and what is exactly the issue? The LO doesn't get to the requested frequency before some timeout?

https://preview.redd.it/4d52yrtou5pc1.png?width=1121&format=png&auto=webp&s=533f31ac1aa4e32fb87864a9a925d0af40c08814

2 Comments
2024/03/18
21:31 UTC

2

Using gr-ais on GnuRadio 3.10 ?

how can i use gr-ais (https://github.com/bistromath/gr-ais/tree/grc) tool on GnuRadio 3.10 ? should i switch to gnuradio 3.8 ?

5 Comments
2024/03/18
13:32 UTC

1

is there a block to see the polar plot?

6 Comments
2024/03/16
06:39 UTC

Back To Top