프로그램 사용/rtl-sdr
gnuradio lora
구차니
2025. 9. 21. 23:59
설치하려니까 아래 패키지들이 필요했다.
$ sudo apt-get install gnuradio-dev libliquid-dev liblog4cpp5-dev |
-----
상세로그
$ cmake ../ -- The CXX compiler identification is GNU 13.3.0 -- The C compiler identification is GNU 13.3.0 -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: /usr/bin/cc - skipped -- Detecting C compile features -- Detecting C compile features - done -- Build type not specified: defaulting to release. CMake Error at CMakeLists.txt:87 (find_package): By not providing "FindGnuradio.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "Gnuradio", but CMake did not find one. Could not find a package configuration file provided by "Gnuradio" (requested version 3.9) with any of the following names: GnuradioConfig.cmake gnuradio-config.cmake Add the installation prefix of "Gnuradio" to CMAKE_PREFIX_PATH or set "Gnuradio_DIR" to a directory containing one of the above files. If "Gnuradio" provides a separate development package or SDK, be sure it has been installed. |
$ sudo apt-get install gnuradio-dev |
[ 30%] Building CXX object lib/CMakeFiles/gnuradio-lora.dir/message_socket_sink_impl.cc.o /home/minimonk/src/gr-lora/lib/decoder_impl.cc:28:10: fatal error: liquid/liquid.h: No such file or directory 28 | #include <liquid/liquid.h> | ^~~~~~~~~~~~~~~~~ compilation terminated. make[2]: *** [lib/CMakeFiles/gnuradio-lora.dir/build.make:76: lib/CMakeFiles/gnuradio-lora.dir/decoder_impl.cc.o] Error 1 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [CMakeFiles/Makefile2:234: lib/CMakeFiles/gnuradio-lora.dir/all] Error 2 make: *** [Makefile:146: all] Error 2 |
$ apt-cache search liquid libliquid-dev - signal processing library for software defined radio (development files) libliquid1 - signal processing library for software defined radio liquidctl - CLI and Python drivers for AIO liquid coolers and other devices liquidprompt - adaptative prompt for bash & zsh liquidsoap - audio streaming language liquidsoap-doc - Documentation for Liquidsoap liquidsoap-mode - Emacs mode for editing Liquidsoap code liquidwar - truly original multiplayer wargame liquidwar-data - data files for Liquid War liquidwar-server - Liquid War server ruby-jekyll-gist - Liquid tag for displaying GitHub Gists in Jekyll sites ruby-jekyll-include-cache - Jekyll plugin to cache the rendering of Liquid includes ruby-liquid - Ruby library for rendering safe HTML and email templates ruby-liquid-c - liquid performance extension in C |
[ 45%] Linking CXX shared library libgnuradio-lora.so /usr/bin/ld: cannot find -llog4cpp: No such file or directory collect2: error: ld returned 1 exit status make[2]: *** [lib/CMakeFiles/gnuradio-lora.dir/build.make:205: lib/libgnuradio-lora.so.1.0.0.0] Error 1 make[1]: *** [CMakeFiles/Makefile2:234: lib/CMakeFiles/gnuradio-lora.dir/all] Error 2 make: *** [Makefile:146: all] Error 2 |
$ apt-cache search log4cpp liblog4cpp-doc - C++ library for flexible logging (documentation) liblog4cpp5-dev - C++ library for flexible logging (development) liblog4cpp5v5 - C++ library for flexible logging (runtime) |
$ sudo apt-get install liblog4cpp5-dev |
+
2025.09.22
gr-lora
s$ ./lora_receive_file_nogui.py [?] Download test LoRa signal to decode? [y/N] y [+] Downloading https://research.edm.uhasselt.be/probyns/lora/usrp-868.1-sf7-cr4-bw125-crc-0.sigmf-data -> ./example-trace.sigmf-data . . . . . . . . . . . . . . . . . . [+] Downloading https://research.edm.uhasselt.be/probyns/lora/usrp-868.1-sf7-cr4-bw125-crc-0.sigmf-meta -> ./example-trace.sigmf-meta . . [+] Configuration: 868.1 MHz, SF 7, CR 4/8, BW 125 kHz, prlen 8, crc on, implicit off [+] Decoding. You should see a header, followed by 'deadbeef' and a CRC 5 times. Bits (nominal) per symbol: 3.5 Bins per symbol: 128 Samples per symbol: 1024 Decimation: 8 vmcircbuf_prefs::get :info: /home/minimonk/.gnuradio/prefs/vmcircbuf_default_factory failed to open: bad true, fail true, eof true 04 90 40 de ad be ef 70 0d (p) 04 90 40 de ad be ef 70 0d (p) 04 90 40 de ad be ef 70 0d (p) 04 90 40 de ad be ef 70 0d (p) 04 90 40 de ad be ef 70 0d (p) [+] Done |
실행실패
<<< Welcome to GNU Radio Companion 3.10.9.2 >>> Block paths: /usr/share/gnuradio/grc/blocks /usr/local/share/gnuradio/grc/blocks Loading: "/home/minimonk/src/gr-lora/apps/lora_receive_realtime.grc" >>> Done Generating: "/home/minimonk/src/gr-lora/apps/lora_receive_realtime.py" >>> Warning: This flow graph contains a throttle block and another rate limiting block, e.g. a hardware source or sink. This is usually undesired. Consider removing the throttle block. >>> Warning: The block 'blocks_throttle_0' is deprecated. Executing: /usr/bin/python3 -u /home/minimonk/src/gr-lora/apps/lora_receive_realtime.py qt.qpa.plugin: Could not find the Qt platform plugin "wayland" in "" [INFO] [UHD] linux; GNU C++ version 13.2.0; Boost_108300; UHD_4.6.0.0+ds1-5.1ubuntu0.24.04.1 Traceback (most recent call last): File "/home/minimonk/src/gr-lora/apps/lora_receive_realtime.py", line 234, in <module> main() File "/home/minimonk/src/gr-lora/apps/lora_receive_realtime.py", line 212, in main tb = top_block_cls() ^^^^^^^^^^^^^^^ File "/home/minimonk/src/gr-lora/apps/lora_receive_realtime.py", line 77, in __init__ self.uhd_usrp_source_0 = uhd.usrp_source( ^^^^^^^^^^^^^^^^ RuntimeError: LookupError: KeyError: No devices found for -----> Empty Device Address >>> Done (return code 1) |
귀찮아서(!) wayland에서 x.org로 변경후 실행
[링크 : https://mokhwasomssi.tistory.com/427]
UHD :USRP source에서 RTL-SDR source로 바꾸고 일단 실행하니
먼가 그래프로 나오긴 한데.. LoRa가 없어서 지금은 머가 나오는진 모르겠다.
상단에 Variable 라고 된 것을
LoRa Receiver의 설정(?)에 변수로 연결해서 사용하는데
이전에 qt로 드래그 하는 식으로 하는걸 본거 같긴한디..
$ wget http://research.edm.uhasselt.be/~probyns/lora/gr-lora-samples.zip $ unzip gr-lora-samples.zip |
파일에서 하는걸로 해서 해보니 그래프에서 두번째 peak가 뜰때 데이터가 하나씩 나온다.
[링크 : https://github.com/rpp0/gr-lora]
[링크 : https://github.com/tapparelj/gr-lora_sdr]