Difficulties with Gnuradio on Odroid C1

I really hope that you can help me. So I wrote a simple Programm in Gnu
Radio Companion that is able to transmit a text file with use of a
HackRf One. The Programm works fine on my two laptops (both on Ubuntu
15.10, latest GNU-Radio and Osmocom), but when I try to launch it on my
Odroid C1, the Programm seems to work normally, but there is no data
transfer. The HackRF is powered by a USB-HUB, so that can’t be the
problem. Do you have any ideas?

Transmitter(not the problem):
###########################################################################
#!/usr/bin/env python2

-- coding: utf-8 --

##################################################

GNU Radio Python Flow Graph

Title: Top Block

Generated: Tue Feb 23 19:31:30 2016

##################################################

if name == ‘main’:
import ctypes
import sys
if sys.platform.startswith(‘linux’):
try:
x11 = ctypes.cdll.LoadLibrary(‘libX11.so’)
x11.XInitThreads()
except:
print “Warning: failed to XInitThreads()”

from gnuradio import analog
from gnuradio import blocks
from gnuradio import eng_notation
from gnuradio import filter
from gnuradio import gr
from gnuradio import wxgui
from gnuradio.eng_option import eng_option
from gnuradio.fft import window
from gnuradio.filter import firdes
from gnuradio.wxgui import fftsink2
from grc_gnuradio import wxgui as grc_wxgui
from optparse import OptionParser
import wx

class top_block(grc_wxgui.top_block_gui):

def __init__(self):
    grc_wxgui.top_block_gui.__init__(self, title="Top Block")

    ##################################################
    # Variables
    ##################################################
    self.samp_rate = samp_rate = 32000

    ##################################################
    # Blocks
    ##################################################
    self.wxgui_fftsink2_0 = fftsink2.fft_sink_f(
        self.GetWin(),
        baseband_freq=0,
        y_per_div=10,
        y_divs=10,
        ref_level=0,
        ref_scale=2.0,
        sample_rate=samp_rate,
        fft_size=1024,
        fft_rate=15,
        average=False,
        avg_alpha=None,
        title="FFT Plot",
        peak_hold=False,
    )
    self.Add(self.wxgui_fftsink2_0.win)
    self.rational_resampler_xxx_0 = filter.rational_resampler_fff(
            interpolation=2000000,
            decimation=44100,
            taps=None,
            fractional_bw=None,
    )
    self.blocks_multiply_xx_0 = blocks.multiply_vff(1)
    self.blocks_file_source_0 =

blocks.file_source(gr.sizeof_float*1, “test.txt”, True)
self.analog_const_source_x_0 = analog.sig_source_f(0,
analog.GR_CONST_WAVE, 0, 0, 1)

    ##################################################
    # Connections
    ##################################################
    self.connect((self.analog_const_source_x_0, 0),

(self.blocks_multiply_xx_0, 1))
self.connect((self.blocks_file_source_0, 0),
(self.blocks_multiply_xx_0, 0))
self.connect((self.blocks_multiply_xx_0, 0),
(self.rational_resampler_xxx_0, 0))
self.connect((self.rational_resampler_xxx_0, 0),
(self.wxgui_fftsink2_0, 0))

def get_samp_rate(self):
    return self.samp_rate

def set_samp_rate(self, samp_rate):
    self.samp_rate = samp_rate
    self.wxgui_fftsink2_0.set_sample_rate(self.samp_rate)

def main(top_block_cls=top_block, options=None):

tb = top_block_cls()
tb.Start(True)
tb.Wait()

if name == ‘main’:
main()
###########################################################################

And the Receiver (does not work on Odroid):

###########################################################################

#!/usr/bin/env python2

-- coding: utf-8 --

##################################################

GNU Radio Python Flow Graph

Title: Top Block

Generated: Tue Jan 5 20:44:14 2016

##################################################

from gnuradio import blocks
from gnuradio import digital
from gnuradio import eng_notation
from gnuradio import gr
from gnuradio.eng_option import eng_option
from gnuradio.filter import firdes
from grc_gnuradio import blks2 as grc_blks2
from optparse import OptionParser
import osmosdr
import time

class top_block(gr.top_block):

def __init__(self):
    gr.top_block.__init__(self, "Top Block")

    ##################################################
    # Variables
    ##################################################
    self.samp_rate = samp_rate = 32000

    ##################################################
    # Blocks
    ##################################################
    self.osmosdr_source_0 = osmosdr.source( args="numchan=" + str(1)
  • " " + “” )
    self.osmosdr_source_0.set_sample_rate(2e6)
    self.osmosdr_source_0.set_center_freq(2400e6, 0)
    self.osmosdr_source_0.set_freq_corr(0, 0)
    self.osmosdr_source_0.set_dc_offset_mode(0, 0)
    self.osmosdr_source_0.set_iq_balance_mode(0, 0)
    self.osmosdr_source_0.set_gain_mode(False, 0)
    self.osmosdr_source_0.set_gain(0, 0)
    self.osmosdr_source_0.set_if_gain(20, 0)
    self.osmosdr_source_0.set_bb_gain(20, 0)
    self.osmosdr_source_0.set_antenna("", 0)
    self.osmosdr_source_0.set_bandwidth(1000, 0)

      self.digital_gmsk_demod_0 = digital.gmsk_demod(
          samples_per_symbol=2,
          gain_mu=0.175,
          mu=0.5,
          omega_relative_limit=0.005,
          freq_error=0.0,
          verbose=False,
          log=False,
      )
      self.blocks_multiply_const_vxx_0 = blocks.multiply_const_vcc((1,
    

))
self.blocks_file_sink_0 = blocks.file_sink(gr.sizeof_float*1,
“test”, False)
self.blocks_file_sink_0.set_unbuffered(False)
self.blks2_packet_decoder_0 =
grc_blks2.packet_demod_f(grc_blks2.packet_decoder(
access_code="",
threshold=0,
callback=lambda ok, payload:
self.blks2_packet_decoder_0.recv_pkt(ok, payload),
),
)

    ##################################################
    # Connections
    ##################################################
    self.connect((self.blks2_packet_decoder_0, 0),

(self.blocks_file_sink_0, 0))
self.connect((self.blocks_multiply_const_vxx_0, 0),
(self.digital_gmsk_demod_0, 0))
self.connect((self.digital_gmsk_demod_0, 0),
(self.blks2_packet_decoder_0, 0))
self.connect((self.osmosdr_source_0, 0),
(self.blocks_multiply_const_vxx_0, 0))

def get_samp_rate(self):
    return self.samp_rate

def set_samp_rate(self, samp_rate):
    self.samp_rate = samp_rate

def main(top_block_cls=top_block, options=None):

tb = top_block_cls()
tb.start()
try:
    raw_input('Press Enter to quit: ')
except EOFError:
    pass
tb.stop()
tb.wait()

if name == ‘main’:
main()

Thanks a Lot!

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs