日誌


2017/06/29

Ubuntu 16.04 で build gnuradio

Tweet ThisSend to Facebook | by 山田洋
◆実行すると、エラーが出る。githubへのアクセスができないことが理由?
(中略)
This script will fetch Gnu Radio version 3.7/maint from the repositories, along with compatible
extras.
Is this OK?y
Fetching various packages (Gnu Radio, UHD, gr-osmosdr, gr-iqbal, etc)
via the Internet
=======> THIS MAY TAKE QUITE SOME TIME <=========
Fetching Gnu Radio via GIT...Could not find gnuradio/gnuradio-{core,runtime} after GIT checkout
GIT checkout of Gnu Radio failed!

◆build-gnuradioスクリプトの内容を書き換えた。
git clone --progress $RECURSE https://github.com/gnuradio/gnuradio >>$LOGDEV 2>&1
※URLを上記に変更した

◆実行結果
gnuradio 3.7.11.1がインストールされた。
wget http://www.sbrac.org/files/build-gnuradio && chmod a+x build-gnuradio && ./build-gnuradio
--2017-06-29 11:45:00--  http://www.sbrac.org/files/build-gnuradio
www.sbrac.org (www.sbrac.org) をDNSに問いあわせています... 67.212.80.242
www.sbrac.org (www.sbrac.org)|67.212.80.242|:80 に接続しています... 接続しました。
HTTP による接続要求を送信しました、応答を待っています... 200 OK
長さ: 41528 (41K) [text/plain]
`build-gnuradio.3' に保存中

build-gnuradio.3    100%[===================>]  40.55K  79.4KB/s    in 0.5s   

2017-06-29 11:45:01 (79.4 KB/s) - `build-gnuradio.3' へ保存完了 [41528/41528]

This script will install Gnu Radio from current GIT sources
You will require Internet access from the computer on which this
script runs. You will also require SUDO access. You will require
approximately 500MB of free disk space to perform the build.
 
This script will, as a side-effect, remove any existing Gnu Radio
installation that was installed from your Linux distribution packages.
It must do this to prevent problems due to interference between
a linux-distribution-installed Gnu Radio/UHD and one installed from GIT source.
 
The whole process may take up to two hours to complete, depending on the
capabilities of your system.

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
NOTE: if you run into problems while running this script, you can re-run it with
the --verbose option to produce lots of diagnostic output to help debug problems.
This script has been written to anticipate some of the more common problems one might
encounter building ANY large, complex software package. But it is not pefect, and
there are certainly some situations it could encounter that it cannot deal with
gracefully. Altering the system configuration from something reasonably standard,
removing parts of the filesystem, moving system libraries around arbitrarily, etc,
it likely cannot cope with. It is just a script. It isn't intuitive or artificially
intelligent. It tries to make life a little easier for you, but at the end of the day
if it runs into trouble, a certain amount of knowledge on your part about
system configuration and idiosyncrasies will inevitably be necessary.


Proceed?y
Starting all functions at: 2017年 6月 29日 木曜日 11:45:03 JST
SUDO privileges are required
Do you have SUDO privileges?y
Continuing with script
Installing prerequisites.
====> THIS MAY TAKE QUITE SOME TIME <=====
Checking for package libqwt6
Checking for package libfontconfig1-dev
Checking for package libxrender-dev
Checking for package libpulse-dev
Checking for package swig
Checking for package g++
Checking for package automake
Checking for package autoconf
Checking for package libtool
Checking for package python-dev
Checking for package libfftw3-dev
Checking for package libcppunit-dev
Checking for package libboost-all-dev
Checking for package libusb-dev
Checking for package libusb-1.0-0-dev
Checking for package fort77
Checking for package libsdl1.2-dev
Checking for package python-wxgtk2.8
Failed to find package 'python-wxgtk2.8' in known package repositories
SOME THINGS MAY NOT BUILD AS A RESULT
Checking for package git-core
Checking for package libqt4-dev
Checking for package python-numpy
Checking for package ccache
Checking for package python-opengl
Checking for package libgsl0-dev
Checking for package python-cheetah
Checking for package python-mako
Checking for package python-lxml
Checking for package doxygen
Checking for package qt4-default
Checking for package qt4-dev-tools
Checking for package libusb-1.0-0-dev
Checking for package libqwt5-qt4-dev
Checking for package libqwtplot3d-qt4-dev
Checking for package pyqt4-dev-tools
Checking for package python-qwt5-qt4
Checking for package cmake
Checking for package git-core
Checking for package wget
Checking for package libxi-dev
Checking for package python-docutils
Checking for package gtk2-engines-pixbuf
Checking for package r-base-dev
Checking for package python-tk
Checking for package liborc-0.4-0
Checking for package liborc-0.4-dev
Checking for package libasound2-dev
Checking for package python-gtk2
Checking for package libzmq
Checking for package libzmq-dev
Checking for package libzmq1
Checking for package libzmq1-dev
Failed to find package 'libzmq1-dev' in known package repositories
SOME THINGS MAY NOT BUILD AS A RESULT
Checking for package python-requests
Checking for package python-sphinx
Checking for package comedi-dev
Checking for package python-zmq
Checking for package libncurses5
Checking for package libncurses5-dev
Checking for package python-wxgtk3.0
Done checking packages
Checking for library libusb ...Found library libusb
Checking for library libboost ...Found library libboost
Checking for library libcppunit ...Found library libcppunit
Checking for library libfftw ...Found library libfftw
Checking for library libgsl ...Found library libgsl
Done
This script will fetch Gnu Radio version 3.7/maint from the repositories, along with compatible
extras.
Is this OK?y
Fetching various packages (Gnu Radio, UHD, gr-osmosdr, gr-iqbal, etc)
via the Internet
=======> THIS MAY TAKE QUITE SOME TIME <=========
Fetching Gnu Radio via GIT...Done
Fetching UHD via GIT...Fetching rtl-sdr (rtl-sdr, gr-osmosdr, gr-iqbal, hackrf, bladeRF and airspy) via GIT
Done
Starting function uhd_build at: 2017年 6月 29日 木曜日 11:47:21 JST
Building UHD...
=============> THIS WILL TAKE SOME TIME <=============

Done building/installing UHD
Done function uhd_build at: 2017年 6月 29日 木曜日 12:02:59 JST
Starting function firmware at: 2017年 6月 29日 木曜日 12:02:59 JST
Images destination:      /usr/local/share/uhd/images
Downloading images from: http://files.ettus.com/binaries/images/uhd-images_003.010.001.001-27-g47672ede.zip
Downloading images to:   /tmp/tmp4x7cc5/uhd-images_003.010.001.001-27-g47672ede.zip
57416 kB / 57416 kB (100%)

Images successfully installed to: /usr/local/share/uhd/images
Done function firmware at: 2017年 6月 29日 木曜日 12:03:18 JST
Starting function gnuradio_build at: 2017年 6月 29日 木曜日 12:03:18 JST
/usr/local/lib already in ld.so.conf.d
Doing ldconfig...
Building Gnu Radio...
=========> THIS WILL TAKE QUITE A WHILE <=============

...Doing cmake
...Cmaking
...Building
...Installing
Done building and installing Gnu Radio
GRC freedesktop icons install ...Done
Done function gnuradio_build at: 2017年 6月 29日 木曜日 12:53:49 JST
Starting function rtl_build at: 2017年 6月 29日 木曜日 12:53:49 JST
Building rtl-sdr...Done building rtl-sdr
Building hackrf...Done building hackrf
Building gr-iqbal...Done building gr-iqbal
Building bladeRF...Done building bladeRF
Done building airspy
Building gr-osmosdr...gr-osmosdr build apparently failed
Exit rtl-sdr/gr-osmosdr build

=======================================================================
If you have found this script useful and time-saving, consider a
donation to help me keep build-gnuradio, simple_ra, SIDsuite,
meteor_detector, simple_fm_rcv, and multimode maintained and up to date.
A simple paypal transfer to mleech@ripnet.com is all you need to do.
======================================================================
Send success/fail info to sbrac.org?y
Thanks

◆$ uhd_find_devices
[INFO] [UHDlinux; GNU C++ version 5.4.0 20160609; Boost_105800; UHD_3.11.0.git-233-g25fc32af]
--------------------------------------------------
-- UHD Device 0
--------------------------------------------------
Device Address:
    serial: 2743
    addr: 192.168.10.5
    name:
    type: usrp2

◆$ uhd_usrp_probe
[INFO] [UHDlinux; GNU C++ version 5.4.0 20160609; Boost_105800; UHD_3.11.0.git-233-g25fc32af]
[INFO] [USRP2] Opening a USRP2/N-Series device...
[INFO] [USRP2] Current recv frame size: 1472 bytes
[INFO] [USRP2] Current send frame size: 1472 bytes
[WARNING] [UHD] Unable to set the thread priority. Performance may be negatively affected.
Please see the general application notes in the manual for instructions.
EnvironmentError: OSError: error in pthread_setschedparam
  _____________________________________________________
 /
|       Device: USRP2 / N-Series Device
|     _____________________________________________________
|    /
|   |       Mboard: USRP2 r4
|   |   hardware: 1024
|   |   mac-addr: 00:50:c2:85:3a:b7
|   |   ip-addr: 192.168.10.5
|   |   subnet: 255.255.255.255
|   |   gateway: 255.255.255.255
|   |   gpsdo: none
|   |   serial: 2743
|   |   FW Version: 12.3
|   |   FPGA Version: 10.0
|   |  
|   |   Time sources:  none, external, _external_, mimo
|   |   Clock sources: internal, external, mimo
|   |   Sensors: mimo_locked, ref_locked
|   |     _____________________________________________________
|   |    /
|   |   |       RX DSP: 0
|   |   |  
|   |   |   Freq range: -50.000 to 50.000 MHz
|   |     _____________________________________________________
|   |    /
|   |   |       RX DSP: 1
|   |   |  
|   |   |   Freq range: -50.000 to 50.000 MHz
|   |     _____________________________________________________
|   |    /
|   |   |       RX Dboard: A
|   |   |   ID: SBX (0x0054)
|   |   |   Serial: F32FEB
|   |   |     _____________________________________________________
|   |   |    /
|   |   |   |       RX Frontend: 0
|   |   |   |   Name: SBXv3 RX
|   |   |   |   Antennas: TX/RX, RX2, CAL
|   |   |   |   Sensors: lo_locked
|   |   |   |   Freq range: 400.000 to 4400.000 MHz
|   |   |   |   Gain range PGA0: 0.0 to 31.5 step 0.5 dB
|   |   |   |   Bandwidth range: 40000000.0 to 40000000.0 step 0.0 Hz
|   |   |   |   Connection Type: IQ
|   |   |   |   Uses LO offset: No
|   |   |     _____________________________________________________
|   |   |    /
|   |   |   |       RX Codec: A
|   |   |   |   Name: ltc2284
|   |   |   |   Gain Elements: None
|   |     _____________________________________________________
|   |    /
|   |   |       TX DSP: 0
|   |   |  
|   |   |   Freq range: -50.000 to 50.000 MHz
|   |     _____________________________________________________
|   |    /
|   |   |       TX Dboard: A
|   |   |   ID: SBX (0x0055)
|   |   |   Serial: F32FEB
|   |   |     _____________________________________________________
|   |   |    /
|   |   |   |       TX Frontend: 0
|   |   |   |   Name: SBXv3 TX
|   |   |   |   Antennas: TX/RX, CAL
|   |   |   |   Sensors: lo_locked
|   |   |   |   Freq range: 400.000 to 4400.000 MHz
|   |   |   |   Gain range PGA0: 0.0 to 31.5 step 0.5 dB
|   |   |   |   Bandwidth range: 40000000.0 to 40000000.0 step 0.0 Hz
|   |   |   |   Connection Type: QI
|   |   |   |   Uses LO offset: No
|   |   |     _____________________________________________________
|   |   |    /
|   |   |   |       TX Codec: A
|   |   |   |   Name: ad9777
|   |   |   |   Gain Elements: None

[ERROR] [UHD] Exception caught in safe-call.
  in virtual usrp2_fifo_ctrl_impl::~usrp2_fifo_ctrl_impl()
  at /home/yyama/src/uhd/host/lib/usrp/usrp2/usrp2_fifo_ctrl.cpp:64
this->peek32(0); -> RuntimeError: fifo ctrl timed out looking for acks


◆2017.7.20 追記
上記エラーが出るのは、USRP2を接続した場合。USRP N200 および USRP N210では、発生しなかった。USRP2のファームウェアなどを書き換えれば、問題がなくなるかも。
13:22 | 投票する | 投票数(1) | コメント(0)