Creating C++ OOT with gr-modtool: Difference between revisions

From GNU Radio
Jump to navigation Jump to search
No edit summary
Line 11: Line 11:


TODO: link back to python tutorial
TODO: link back to python tutorial
== Installation Note ==
This tutorial was written using GNU Radio v3.10.1.1 on Ubuntu 21.10, installed using the Ubuntu PPA from the [[InstallingGR|Installation Wiki Page]]. The basic GNU Radio install using:
<pre>$ sudo apt-get install gnuradio</pre>
does not come with the proper libraries needed to compile and install OOT modules. Consider installing the following packages before continuing:
<pre>$ sudo apt-get install gnuradio-dev cmake libspdlog-dev clang-format</pre>


== Adding a New Block ==
== Adding a New Block ==

Revision as of 17:11, 9 March 2022

Beginner Tutorials

Introducing GNU Radio

  1. What is GNU Radio?
  2. Installing GNU Radio
  3. Your First Flowgraph

Flowgraph Fundamentals

  1. Python Variables in GRC
  2. Variables in Flowgraphs
  3. Runtime Updating Variables
  4. Signal Data Types
  5. Converting Data Types
  6. Packing Bits
  7. Streams and Vectors
  8. Hier Blocks and Parameters

Creating and Modifying Python Blocks

  1. Creating Your First Block
  2. Python Block With Vectors
  3. Python Block Message Passing
  4. Python Block Tags

DSP Blocks

  1. Low Pass Filter Example
  2. Designing Filter Taps
  3. Sample Rate Change
  4. Frequency Shifting
  5. Reading and Writing Binary Files

SDR Hardware

  1. RTL-SDR FM Receiver
  2. B200-B205mini FM Receiver

TODO: intro material

The previous tutorial, Creating Python OOT with gr-modtool, describes how to create a Python block in an OOT module. This c++ OOT tutorial builds upon the previous Python one, so it is is suggested to at least complete the Installation Note and Creating an OOT Module portions of that tutorial before completing this one.


TODO: pick up from python OOT tutorial

TODO: link back to python tutorial

Installation Note

This tutorial was written using GNU Radio v3.10.1.1 on Ubuntu 21.10, installed using the Ubuntu PPA from the Installation Wiki Page. The basic GNU Radio install using:

$ sudo apt-get install gnuradio

does not come with the proper libraries needed to compile and install OOT modules. Consider installing the following packages before continuing:

$ sudo apt-get install gnuradio-dev cmake libspdlog-dev clang-format

Adding a New Block

Move to the gr-customModule directory:

cd your-path/gr-customModule

Add a new block named multDivSelector:

$ gr_modtool add multDivSelector

The types of blocks will be displayed:

GNU Radio module name identified: customModule
('sink', 'source', 'sync', 'decimator', 'interpolator', 'general', 'tagged_stream', 'hier', 'noblock')

Enter sync as the block type:

Enter block type: sync

Enter cpp as the language:

Language (python/cpp): cpp
Language: C++
Block/code identifier: multDivSelector

Enter the name or organization of the copyright holder:

Please specify the copyright holder: YourName