Where can I find a list of all the return codes?

  Kiến thức lập trình

I am using GNU Radio Companion 3.10.1.1

If the program runs without is shutting down the program, the terminal will print out “Done(return X)” where X is some number. Whenever I try to look for what this means (Since I am not getting an output, I am assuming there is something else going on) I can not find a data base for the return codes.

GNU Radio Companion Flow graph

Since I am still learning GRC, I am just trying to do a simple file sink since of a text beacon from another transceiver. (they are connected via SMA)

This is the output in the terminal:

Loading: "/home/gsr/C_to_python_source.grc"
>>> Done

Generating: '/home/gsr/C_to_python_source'

Executing: cmake .. && cmake --build . -j1 && cd ../.. && /usr/bin/x-terminal-emulator -e /home/gsr/C_to_python_source/build/C_to_python_source

-- Using GMP.
-- User set python executable /usr/bin/python3
-- Found ALSA 1.2.6.1
-- Checking for module 'jack'
--   No package 'jack' found
-- Checking for module 'portaudio-2.0'
--   No package 'portaudio-2.0' found
-- Checking for module 'Qt5Qwt6'
--   Package 'Qt5Svg', required by 'Qt5Qwt6', not found
-- QWT Version: 6.1.4
-- Build type not specified: defaulting to release.
-- Configuring done
-- Generating done
-- Build files have been written to: /home/gsr/C_to_python_source/build
[ 25%] Automatic MOC for target C_to_python_source
[ 25%] Built target C_to_python_source_autogen
Consolidate compiler generated dependencies of target C_to_python_source
[ 50%] Building CXX object CMakeFiles/C_to_python_source.dir/C_to_python_source.cpp.o
/home/gsr/C_to_python_source/C_to_python_source.cpp:39:50: warning: character constant too long for its type
   39 |         this->uhd_usrp_source_0->set_time_source('external', 0);
      |                                                  ^~~~~~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:49:82: warning: character constant too long for its type
   49 |         this->blocks_file_sink_0 = blocks::file_sink::make(sizeof(gr_complex)*1, '/home/gsr/C_to_python/C_to_Py.bin', false);
      |                                                                                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/gsr/C_to_python_source/C_to_python_source.cpp:8:
/home/gsr/C_to_python_source/C_to_python_source.hpp:44:21: error: ‘sptr’ in ‘class gr::filter::firdes’ does not name a type
   44 |     filter::firdes::sptr band_pass_filter_0;
      |                     ^~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp: In constructor ‘C_to_python_source::C_to_python_source()’:
/home/gsr/C_to_python_source/C_to_python_source.cpp:39:50: error: cannot convert ‘int’ to ‘const string&’ {aka ‘const std::__cxx11::basic_string<char>&’}
   39 |         this->uhd_usrp_source_0->set_time_source('external', 0);
      |                                                  ^~~~~~~~~~
      |                                                  |
      |                                                  int
In file included from /usr/include/gnuradio/uhd/usrp_source.h:14,
                 from /home/gsr/C_to_python_source/C_to_python_source.hpp:16,
                 from /home/gsr/C_to_python_source/C_to_python_source.cpp:8:
/usr/include/gnuradio/uhd/usrp_block.h:542:53: note:   initializing argument 1 of ‘virtual void gr::uhd::usrp_block::set_time_source(const string&, size_t)’
  542 |     virtual void set_time_source(const std::string& source, const size_t mboard = 0) = 0;
      |                                  ~~~~~~~~~~~~~~~~~~~^~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:49:82: error: invalid conversion from ‘int’ to ‘const char*’ [-fpermissive]
   49 |         this->blocks_file_sink_0 = blocks::file_sink::make(sizeof(gr_complex)*1, '/home/gsr/C_to_python/C_to_Py.bin', false);
      |                                                                                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                                                                  |
      |                                                                                  int
In file included from /home/gsr/C_to_python_source/C_to_python_source.hpp:15,
                 from /home/gsr/C_to_python_source/C_to_python_source.cpp:8:
/usr/include/gnuradio/blocks/file_sink.h:38:51: note:   initializing argument 2 of ‘static gr::blocks::file_sink::sptr gr::blocks::file_sink::make(size_t, const char*, bool)’
   38 |     static sptr make(size_t itemsize, const char* filename, bool append = false);
      |                                       ~~~~~~~~~~~~^~~~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:51:15: error: ‘class C_to_python_source’ has no member named ‘band_pass_filter_0’
   51 |         this->band_pass_filter_0 = filter::fir_filter_ccf::make(
      |               ^~~~~~~~~~~~~~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:51:44: error: ‘gr::filter::fir_filter_ccf’ has not been declared
   51 |         this->band_pass_filter_0 = filter::fir_filter_ccf::make(
      |                                            ^~~~~~~~~~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:53:13: error: ‘firdes’ was not declared in this scope; did you mean ‘gr::filter::firdes’?
   53 |             firdes.band_pass(
      |             ^~~~~~
      |             gr::filter::firdes
In file included from /home/gsr/C_to_python_source/C_to_python_source.hpp:14,
                 from /home/gsr/C_to_python_source/C_to_python_source.cpp:8:
/usr/include/gnuradio/filter/firdes.h:28:18: note: ‘gr::filter::firdes’ declared here
   28 | class FILTER_API firdes
      |                  ^~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:59:17: error: invalid use of member function ‘QWidget* QWidget::window() const’ (did you forget the ‘()’ ?)
   59 |                 window.WIN_HAMMING,
      |                 ^~~~~~
      |                       ()
/home/gsr/C_to_python_source/C_to_python_source.cpp:64:42: error: ‘class C_to_python_source’ has no member named ‘band_pass_filter_0’
   64 |     this->tb->hier_block2::connect(this->band_pass_filter_0, 0, this->blocks_file_sink_0, 0);
      |                                          ^~~~~~~~~~~~~~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:65:70: error: ‘class C_to_python_source’ has no member named ‘band_pass_filter_0’
   65 |     this->tb->hier_block2::connect(this->uhd_usrp_source_0, 0, this->band_pass_filter_0, 0);
      |                                                                      ^~~~~~~~~~~~~~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp: In member function ‘void C_to_python_source::set_samp_rate(int)’:
/home/gsr/C_to_python_source/C_to_python_source.cpp:78:11: error: ‘class C_to_python_source’ has no member named ‘band_pass_filter_0’
   78 |     this->band_pass_filter_0->set_taps(firdes::band_pass(1, this->samp_rate, 440000000, 450000000, 1, window.WIN_HAMMING, 6.76));
      |           ^~~~~~~~~~~~~~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:78:40: error: ‘firdes’ has not been declared
   78 |     this->band_pass_filter_0->set_taps(firdes::band_pass(1, this->samp_rate, 440000000, 450000000, 1, window.WIN_HAMMING, 6.76));
      |                                        ^~~~~~
/home/gsr/C_to_python_source/C_to_python_source.cpp:78:103: error: invalid use of member function ‘QWidget* QWidget::window() const’ (did you forget the ‘()’ ?)
   78 |     this->band_pass_filter_0->set_taps(firdes::band_pass(1, this->samp_rate, 440000000, 450000000, 1, window.WIN_HAMMING, 6.76));
      |                                                                                                       ^~~~~~
      |                                                                                                             ()
gmake[2]: *** [CMakeFiles/C_to_python_source.dir/build.make:90: CMakeFiles/C_to_python_source.dir/C_to_python_source.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:84: CMakeFiles/C_to_python_source.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2

>>> Done (return code 2)

My three main theories is that 1) I am not setting up my USRP source correctly 2)my Ettus B100 is obsolete, thus it may not be supported anymore by GNU and I need a different SDR 3) there are modules that are missing (seen in the print out of the terminal) and that is was the “return 2” means.

I have never used GNU before and this Ubuntu computer was set up by someone who passed away so I am unsure what is and isn’t installed. I have very little knowledge as to how to work a Linux system.
(Also please let me know if I am posting in the wrong category)

LEAVE A COMMENT