Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gnuradio 3.7.x #3

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 5 additions & 12 deletions gr-wmbus/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -82,15 +82,10 @@ set(GRC_BLOCKS_DIR ${GR_PKG_DATA_DIR}/grc/blocks)
########################################################################
# Find gnuradio build dependencies
########################################################################
find_package(Gruel)
find_package(GnuradioCore)
find_package(GnuradioRuntime)

if(NOT GRUEL_FOUND)
message(FATAL_ERROR "Gruel required to compile wmbus")
endif()

if(NOT GNURADIO_CORE_FOUND)
message(FATAL_ERROR "GnuRadio Core required to compile wmbus")
if(NOT GNURADIO_RUNTIME_FOUND)
message(FATAL_ERROR "GnuRadio Runtime required to compile wmbus")
endif()

########################################################################
Expand All @@ -99,14 +94,12 @@ endif()
include_directories(
${CMAKE_SOURCE_DIR}/include
${Boost_INCLUDE_DIRS}
${GRUEL_INCLUDE_DIRS}
${GNURADIO_CORE_INCLUDE_DIRS}
${GNURADIO_RUNTIME_INCLUDE_DIRS}
)

link_directories(
${Boost_LIBRARY_DIRS}
${GRUEL_LIBRARY_DIRS}
${GNURADIO_CORE_LIBRARY_DIRS}
${GNURADIO_RUNTIME_LIBRARY_DIRS}
)

# Set component parameters
Expand Down
15 changes: 8 additions & 7 deletions gr-wmbus/apps/wmbus_rx.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,16 @@
import struct
from array import array
import numpy
from numpy.numarray.functions import ones
from numpy import ones
from optparse import OptionParser
from gnuradio import gr
from gnuradio.extras import block_gateway
from gnuradio import blocks
from gnuradio.gr import block_gateway
from gnuradio import digital
from gnuradio.digital import packet_utils
from gnuradio.eng_option import eng_option
from gruel.pmt.pmt_swig import pmt_print
from gnuradio.extras.extras_swig import pmt_symbol_to_string
# from gruel.pmt.pmt_swig import pmt_print
from pmt import symbol_to_string
import gnuradio.gr.gr_threading as _threading
import osmosdr
import crcmod.predefined
Expand Down Expand Up @@ -150,9 +151,9 @@ def __init__(self, filename=None, capture=None, verbose=False, freq_error=-0.002
self.chip_error_threshold = 10

if None != filename:
self.source = gr.file_source(gr.sizeof_gr_complex, filename)
self.source = blocks.file_source(gr.sizeof_gr_complex, filename)
else:
self.source = osmosdr.source_c( args="nchan=" + str(1) + " " + "" )
self.source = osmosdr.source()
#print self.source.get_gain_range().to_pp_string()
self.source.set_sample_rate(1.6e6)
self.source.set_center_freq(868.95e6, 0)
Expand All @@ -163,7 +164,7 @@ def __init__(self, filename=None, capture=None, verbose=False, freq_error=-0.002
self.source.set_if_gain(42, 0)

if None != capture:
self.sink = gr.file_sink(gr.sizeof_gr_complex, capture)
self.sink = blocks.file_sink(gr.sizeof_gr_complex, capture)
else:
self.msgq = gr.msg_queue(4)
self.sink = wmbus_phy1(msgq=self.msgq, verbose=verbose, freq_error=freq_error);
Expand Down
29 changes: 0 additions & 29 deletions gr-wmbus/cmake/Modules/FindGnuradioCore.cmake

This file was deleted.

6 changes: 6 additions & 0 deletions gr-wmbus/cmake/Modules/FindGnuradioRuntime.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
INCLUDE(FindPkgConfig)
PKG_CHECK_MODULES(GNURADIO_RUNTIME gnuradio-runtime)

INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(GNURADIO_RUNTIME DEFAULT_MSG GNURADIO_RUNTIME_LIBRARIES GNURADIO_RUNTIME_INCLUDE_DIRS)
MARK_AS_ADVANCED(GNURADIO_RUNTIME_LIBRARIES GNURADIO_RUNTIME_INCLUDE_DIRS)
29 changes: 0 additions & 29 deletions gr-wmbus/cmake/Modules/FindGruel.cmake

This file was deleted.

28 changes: 14 additions & 14 deletions gr-wmbus/grc/wmbus_demod.grc
Original file line number Diff line number Diff line change
Expand Up @@ -437,10 +437,10 @@
</param>
</block>
<block>
<key>gr_quadrature_demod_cf</key>
<key>analog_quadrature_demod_cf</key>
<param>
<key>id</key>
<value>gr_quadrature_demod_cf_0</value>
<value>analog_quadrature_demod_cf_0</value>
</param>
<param>
<key>_enabled</key>
Expand Down Expand Up @@ -604,10 +604,10 @@
</param>
</block>
<block>
<key>gr_file_sink</key>
<key>blocks_file_sink</key>
<param>
<key>id</key>
<value>gr_file_sink_0</value>
<value>blocks_file_sink_0</value>
</param>
<param>
<key>_enabled</key>
Expand Down Expand Up @@ -639,10 +639,10 @@
</param>
</block>
<block>
<key>gr_file_sink</key>
<key>blocks_file_sink</key>
<param>
<key>id</key>
<value>gr_file_sink_2</value>
<value>blocks_file_sink_2</value>
</param>
<param>
<key>_enabled</key>
Expand Down Expand Up @@ -674,10 +674,10 @@
</param>
</block>
<block>
<key>gr_file_sink</key>
<key>blocks_file_sink</key>
<param>
<key>id</key>
<value>gr_file_sink_1</value>
<value>blocks_file_sink_1</value>
</param>
<param>
<key>_enabled</key>
Expand Down Expand Up @@ -792,7 +792,7 @@
<sink_key>0</sink_key>
</connection>
<connection>
<source_block_id>gr_quadrature_demod_cf_0</source_block_id>
<source_block_id>analog_quadrature_demod_cf_0</source_block_id>
<sink_block_id>gr_single_pole_iir_filter_xx_0</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
Expand All @@ -804,7 +804,7 @@
<sink_key>1</sink_key>
</connection>
<connection>
<source_block_id>gr_quadrature_demod_cf_0</source_block_id>
<source_block_id>analog_quadrature_demod_cf_0</source_block_id>
<sink_block_id>gr_sub_xx_0</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
Expand All @@ -823,7 +823,7 @@
</connection>
<connection>
<source_block_id>low_pass_filter_0</source_block_id>
<sink_block_id>gr_quadrature_demod_cf_0</sink_block_id>
<sink_block_id>analog_quadrature_demod_cf_0</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
</connection>
Expand All @@ -841,19 +841,19 @@
</connection>
<connection>
<source_block_id>gr_sub_xx_0</source_block_id>
<sink_block_id>gr_file_sink_0</sink_block_id>
<sink_block_id>blocks_file_sink_0</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
</connection>
<connection>
<source_block_id>digital_clock_recovery_mm_xx_0</source_block_id>
<sink_block_id>gr_file_sink_2</sink_block_id>
<sink_block_id>blocks_file_sink_2</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
</connection>
<connection>
<source_block_id>digital_binary_slicer_fb_0</source_block_id>
<sink_block_id>gr_file_sink_1</sink_block_id>
<sink_block_id>blocks_file_sink_1</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
</connection>
Expand Down
8 changes: 4 additions & 4 deletions gr-wmbus/grc/wmbus_phy1.grc
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@
</param>
</block>
<block>
<key>gr_complex_to_mag_squared</key>
<key>blocks_complex_to_mag_squared</key>
<param>
<key>id</key>
<value>gr_complex_to_mag_squared_0</value>
<value>blocks_complex_to_mag_squared_0</value>
</param>
<param>
<key>_enabled</key>
Expand Down Expand Up @@ -532,7 +532,7 @@
<sink_key>0</sink_key>
</connection>
<connection>
<source_block_id>gr_complex_to_mag_squared_0</source_block_id>
<source_block_id>blocks_complex_to_mag_squared_0</source_block_id>
<sink_block_id>gr_nlog10_ff_0</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
Expand All @@ -551,7 +551,7 @@
</connection>
<connection>
<source_block_id>pad_source_0</source_block_id>
<sink_block_id>gr_complex_to_mag_squared_0</sink_block_id>
<sink_block_id>blocks_complex_to_mag_squared_0</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
</connection>
Expand Down
12 changes: 6 additions & 6 deletions gr-wmbus/grc/wmbus_phy2.grc
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<flow_graph>
<timestamp>Sat Oct 13 16:35:53 2012</timestamp>
<block>
<key>gr_file_sink</key>
<key>blocks_file_sink</key>
<param>
<key>id</key>
<value>gr_file_sink_0_0</value>
<value>blocks_file_sink_0_0</value>
</param>
<param>
<key>_enabled</key>
Expand Down Expand Up @@ -91,10 +91,10 @@
</param>
</block>
<block>
<key>gr_file_sink</key>
<key>blocks_file_sink</key>
<param>
<key>id</key>
<value>gr_file_sink_0</value>
<value>blocks_file_sink_0</value>
</param>
<param>
<key>_enabled</key>
Expand Down Expand Up @@ -548,7 +548,7 @@
</connection>
<connection>
<source_block_id>gr_unpacked_to_packed_xx_0</source_block_id>
<sink_block_id>gr_file_sink_0</sink_block_id>
<sink_block_id>blocks_file_sink_0</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
</connection>
Expand All @@ -572,7 +572,7 @@
</connection>
<connection>
<source_block_id>digital_map_bb_0</source_block_id>
<sink_block_id>gr_file_sink_0_0</sink_block_id>
<sink_block_id>blocks_file_sink_0_0</sink_block_id>
<source_key>0</source_key>
<sink_key>0</sink_key>
</connection>
Expand Down
2 changes: 1 addition & 1 deletion gr-wmbus/include/wmbus_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#ifndef INCLUDED_WMBUS_API_H
#define INCLUDED_WMBUS_API_H

#include <gruel/attributes.h>
#include <gnuradio/attributes.h>

#ifdef gnuradio_wmbus_EXPORTS
# define WMBUS_API __GR_ATTR_EXPORT
Expand Down
2 changes: 1 addition & 1 deletion gr-wmbus/lib/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
include(GrPlatform) #define LIB_SUFFIX

add_library(gnuradio-wmbus SHARED )
target_link_libraries(gnuradio-wmbus ${Boost_LIBRARIES} ${GRUEL_LIBRARIES} ${GNURADIO_CORE_LIBRARIES})
target_link_libraries(gnuradio-wmbus ${Boost_LIBRARIES} ${GNURADIO_RUNTIME_LIBRARIES})
set_target_properties(gnuradio-wmbus PROPERTIES DEFINE_SYMBOL "gnuradio_wmbus_EXPORTS")

########################################################################
Expand Down
Loading