diff --git a/CMakeLists.txt b/CMakeLists.txt index 112e1f7..7f532d9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -29,16 +29,28 @@ set (CMAKE_CXX_STANDARD 11) add_definitions(-std=c++11) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wextra") +#install to PyBOMBS target prefix if defined +if(DEFINED ENV{PYBOMBS_PREFIX}) +#IGNORE set(CMAKE_INSTALL_PREFIX $ENV{PYBOMBS_PREFIX}) + message(STATUS "PyBOMBS installed GNU Radio. Setting CMAKE_INSTALL_PREFIX to $ENV{PYBOMBS_PREFIX}") +endif() + #select the release build type by default to get optimization flags if(NOT CMAKE_BUILD_TYPE) - set(CMAKE_BUILD_TYPE "Release") +#IGNORE set(CMAKE_BUILD_TYPE "Release") message(STATUS "Build type not specified: defaulting to release.") endif(NOT CMAKE_BUILD_TYPE) -set(CMAKE_BUILD_TYPE ${CMAKE_BUILD_TYPE} CACHE STRING "") +#IGNORE set(CMAKE_BUILD_TYPE ${CMAKE_BUILD_TYPE} CACHE STRING "") #make sure our local CMake Modules path comes first list(INSERT CMAKE_MODULE_PATH 0 ${CMAKE_SOURCE_DIR}/cmake/Modules) +# Set the version information here +set(VERSION_INFO_MAJOR_VERSION 1) +set(VERSION_INFO_API_COMPAT 0) +set(VERSION_INFO_MINOR_VERSION 1) +set(VERSION_INFO_MAINT_VERSION git) + ######################################################################## # Compiler specific setup ######################################################################## @@ -139,7 +151,10 @@ endif() # caps such as FILTER or FFT) and change the version to the minimum # API compatible version required. set(GR_REQUIRED_COMPONENTS RUNTIME FFT) +set(GR_REQUIRED_COMPONENTS RUNTIME FILTER) find_package(Gnuradio "3.7.7" REQUIRED) +list(INSERT CMAKE_MODULE_PATH 0 ${CMAKE_SOURCE_DIR}/cmake/Modules) +include(GrVersion) if(NOT CPPUNIT_FOUND) message(FATAL_ERROR "CppUnit required to compile satnogs") diff --git a/README.md b/README.md index 570dd7a..28dded6 100644 --- a/README.md +++ b/README.md @@ -9,11 +9,13 @@ for decoding signals from various scientific and academic sattelites. * CMake ( > 3.1) * G++ (with C++11 support) * VOLK +* libogg +* libvorbis * git -*** Optional *** + +**Optional** * gr-osmocom (for using the flowgraphs with real SDR hardware) * libnova (for building the debug blocks) -* libvorbis (for ogg vorbis encoder block) ### Installation diff --git a/apps/flowgraphs/satellites/upsat_transceiver_qt.grc b/apps/flowgraphs/satellites/upsat_transceiver_qt.grc index da1f596..7e96555 100644 --- a/apps/flowgraphs/satellites/upsat_transceiver_qt.grc +++ b/apps/flowgraphs/satellites/upsat_transceiver_qt.grc @@ -1,12 +1,12 @@ - + Fri Jul 1 17:53:00 2016 options author - + Manolis Surligas (surligas@gmail.com) window_size @@ -22,7 +22,7 @@ description - + SATNOGS transceiver for UPSAT satellite _enabled @@ -30,7 +30,7 @@ _coordinate - (8, 8) + (8, 12) _rotation @@ -78,7 +78,7 @@ title - + UPSat Transceiver QT @@ -93,7 +93,7 @@ _coordinate - (544, 5) + (1048, 16) _rotation @@ -101,7 +101,7 @@ id - baud_rate + baud_rate_downlink value @@ -109,14 +109,10 @@ - variable_qtgui_range + variable comment - - - - value - 0 + FSK baud rate _enabled @@ -124,11 +120,7 @@ _coordinate - (1296, 1) - - - gui_hint - + (1048, 112) _rotation @@ -136,102 +128,11 @@ id - bb_gain_rx - - - label - BB Gain RX - - - min_len - 200 - - - orient - Qt.Horizontal - - - start - 0 - - - step - 0.5 - - - stop - 40 - - - rangeType - float - - - widget - counter_slider - - - - variable_qtgui_range - - comment - + baud_rate_uplink value - 0 - - - _enabled - True - - - _coordinate - (1304, 137) - - - gui_hint - - - - _rotation - 0 - - - id - bb_gain_tx - - - label - BB Gain TX - - - min_len - 200 - - - orient - Qt.Horizontal - - - start - 0 - - - step - 0.5 - - - stop - 40 - - - rangeType - float - - - widget - counter_slider + 1200 @@ -248,7 +149,7 @@ SDR received samples _coordinate - (664, 109) + (696, 20) _rotation @@ -275,7 +176,7 @@ SDR received samples _coordinate - (368, 5) + (840, 20) _rotation @@ -302,7 +203,34 @@ SDR received samples _coordinate - (8, 325) + (168, 932) + + + _rotation + 0 + + + id + first_stage_samp_rate_rx + + + value + samp_rate_rx / decimation_rx + + + + variable + + comment + + + + _enabled + True + + + _coordinate + (16, 904) _rotation @@ -317,132 +245,6 @@ SDR received samples filter.firdes.gaussian(1.0, samples_per_symbol_tx, 1.0, 4*samples_per_symbol_tx) - - variable_qtgui_range - - comment - - - - value - 0 - - - _enabled - True - - - _coordinate - (1192, 1) - - - gui_hint - - - - _rotation - 0 - - - id - if_gain_rx - - - label - IF Gain RX - - - min_len - 200 - - - orient - Qt.Horizontal - - - start - 0 - - - step - 0.5 - - - stop - 40 - - - rangeType - float - - - widget - counter_slider - - - - variable_qtgui_range - - comment - - - - value - 0 - - - _enabled - True - - - _coordinate - (1192, 137) - - - gui_hint - - - - _rotation - 0 - - - id - if_gain_tx - - - label - IF Gain TX - - - min_len - 200 - - - orient - Qt.Horizontal - - - start - 0 - - - step - 0.5 - - - stop - 40 - - - rangeType - float - - - widget - counter_slider - - variable @@ -455,7 +257,7 @@ SDR received samples _coordinate - (8, 453) + (168, 1004) _rotation @@ -474,16 +276,15 @@ SDR received samples variable comment - To avoid the SDR carrier at the DC -we shift the LO a little further + _enabled - 1 + True _coordinate - (784, 5) + (296, 16) _rotation @@ -491,11 +292,11 @@ we shift the LO a little further id - lo_offset + modulation_index_downlink value - 100e3 + deviation / (baud_rate_downlink / 2.0) @@ -510,7 +311,7 @@ we shift the LO a little further _coordinate - (8, 253) + (296, 80) _rotation @@ -518,137 +319,11 @@ we shift the LO a little further id - modulation_index + modulation_index_uplink value - deviation / (baud_rate / 2.0) - - - - variable_qtgui_range - - comment - - - - value - 0 - - - _enabled - True - - - _coordinate - (1080, 1) - - - gui_hint - - - - _rotation - 0 - - - id - rf_gain_rx - - - label - RF Gain RX - - - min_len - 200 - - - orient - Qt.Horizontal - - - start - 0 - - - step - 0.5 - - - stop - 40 - - - rangeType - float - - - widget - counter_slider - - - - variable_qtgui_range - - comment - - - - value - 0 - - - _enabled - True - - - _coordinate - (1080, 137) - - - gui_hint - - - - _rotation - 0 - - - id - rf_gain_tx - - - label - RF Gain TX - - - min_len - 200 - - - orient - Qt.Horizontal - - - start - 0 - - - step - 0.5 - - - stop - 70 - - - rangeType - float - - - widget - counter_slider + deviation / (baud_rate_uplink / 2.0) @@ -664,7 +339,7 @@ we shift the LO a little further _coordinate - (808, 109) + (1368, 16) _rotation @@ -692,7 +367,7 @@ TX sampling rate _coordinate - (528, 109) + (752, 900) _rotation @@ -704,7 +379,7 @@ TX sampling rate value - 1e6 + satnogs.hw_rx_settings[rx_sdr_device]['samp_rate'] @@ -720,7 +395,7 @@ TX sampling rate _coordinate - (248, 5) + (760, 776) _rotation @@ -732,7 +407,7 @@ TX sampling rate value - 2e6 + satnogs.hw_tx_settings[rx_sdr_device]['samp_rate'] @@ -750,7 +425,7 @@ is too great and becomes a bottlneck. _coordinate - (8, 109) + (472, 12) _rotation @@ -777,7 +452,7 @@ is too great and becomes a bottlneck. _coordinate - (8, 389) + (16, 984) _rotation @@ -812,7 +487,7 @@ is too great and becomes a bottlneck. _coordinate - (16, 762) + (16, 760) _rotation @@ -852,7 +527,7 @@ is too great and becomes a bottlneck. _coordinate - (648, 5) + (1216, 16) _rotation @@ -887,7 +562,7 @@ is too great and becomes a bottlneck. _coordinate - (1200, 308) + (792, 232) _rotation @@ -907,7 +582,7 @@ is too great and becomes a bottlneck. sensitivity - (math.pi*modulation_index) / samples_per_symbol_tx + (math.pi*modulation_index_uplink) / samples_per_symbol_tx @@ -930,7 +605,7 @@ is too great and becomes a bottlneck. _coordinate - (568, 644) + (552, 528) _rotation @@ -938,7 +613,7 @@ is too great and becomes a bottlneck. gain - ((samp_rate_rx/decimation_rx) / baud_rate)/(math.pi*modulation_index) + ((first_stage_samp_rate_rx) / baud_rate_downlink)/(math.pi*modulation_index_downlink) id @@ -981,7 +656,7 @@ is too great and becomes a bottlneck. _coordinate - (1008, 376) + (952, 272) _rotation @@ -1016,6 +691,49 @@ is too great and becomes a bottlneck. analog.GR_COS_WAVE + + parameter + + alias + + + + comment + + + + _enabled + True + + + _coordinate + (272, 756) + + + _rotation + 0 + + + id + bind_addr + + + label + + + + short_id + + + + type + string + + + value + 0.0.0.0 + + blocks_multiply_xx @@ -1036,7 +754,7 @@ is too great and becomes a bottlneck. _coordinate - (824, 464) + (832, 352) _rotation @@ -1083,7 +801,7 @@ is too great and becomes a bottlneck. _coordinate - (208, 918) + (272, 844) _rotation @@ -1130,7 +848,7 @@ is too great and becomes a bottlneck. _coordinate - (1024, 648) + (944, 528) _rotation @@ -1169,7 +887,7 @@ is too great and becomes a bottlneck. _coordinate - (776, 616) + (736, 496) _rotation @@ -1205,7 +923,7 @@ is too great and becomes a bottlneck. omega - (samp_rate_rx/decimation_rx)/baud_rate + first_stage_samp_rate_rx/baud_rate_downlink type @@ -1240,7 +958,7 @@ is too great and becomes a bottlneck. _coordinate - (304, 623) + (304, 504) _rotation @@ -1287,7 +1005,7 @@ is too great and becomes a bottlneck. _coordinate - (1472, 60) + (184, 64) _rotation @@ -1318,7 +1036,7 @@ is too great and becomes a bottlneck. _coordinate - (1480, 4) + (184, 16) _rotation @@ -1349,7 +1067,7 @@ is too great and becomes a bottlneck. _coordinate - (1480, 108) + (184, 112) _rotation @@ -1384,7 +1102,7 @@ is too great and becomes a bottlneck. _coordinate - (920, 293) + (592, 224) _rotation @@ -1419,6 +1137,50 @@ is too great and becomes a bottlneck. fff + + parameter + + alias + + + + comment + To avoid the SDR carrier at the DC +we shift the LO a little further + + + _enabled + True + + + _coordinate + (888, 772) + + + _rotation + 0 + + + id + lo_offset + + + label + + + + short_id + + + + type + eng_float + + + value + 100e3 + + osmosdr_sink @@ -1427,11 +1189,11 @@ is too great and becomes a bottlneck. ant0 - + satnogs.hw_tx_settings[tx_sdr_device]['antenna'] bb_gain0 - bb_gain_tx + satnogs.hw_tx_settings[tx_sdr_device]['bb_gain'] bw0 @@ -1447,11 +1209,11 @@ is too great and becomes a bottlneck. if_gain0 - if_gain_tx + satnogs.hw_tx_settings[tx_sdr_device]['if_gain'] gain0 - rf_gain_tx + satnogs.hw_tx_settings[tx_sdr_device]['rf_gain'] ant10 @@ -2331,7 +2093,7 @@ is too great and becomes a bottlneck. args - + satnogs.hw_tx_settings[rx_sdr_device]['dev_arg'] _enabled @@ -2339,7 +2101,7 @@ is too great and becomes a bottlneck. _coordinate - (416, 434) + (544, 312) _rotation @@ -2442,11 +2204,11 @@ is too great and becomes a bottlneck. ant0 - + satnogs.hw_rx_settings[rx_sdr_device]['antenna'] bb_gain0 - bb_gain_rx + satnogs.hw_rx_settings[rx_sdr_device]['bb_gain'] bw0 @@ -2470,7 +2232,7 @@ is too great and becomes a bottlneck. if_gain0 - if_gain_rx + satnogs.hw_rx_settings[rx_sdr_device]['if_gain'] iq_balance_mode0 @@ -2478,7 +2240,7 @@ is too great and becomes a bottlneck. gain0 - rf_gain_rx + satnogs.hw_rx_settings[rx_sdr_device]['rf_gain'] ant10 @@ -3730,7 +3492,7 @@ is too great and becomes a bottlneck. args - + satnogs.hw_rx_settings[rx_sdr_device]['dev_arg'] _enabled @@ -3738,7 +3500,7 @@ is too great and becomes a bottlneck. _coordinate - (32, 565) + (64, 440) _rotation @@ -3861,7 +3623,7 @@ is too great and becomes a bottlneck. _coordinate - (1232, 471) + (1080, 360) _rotation @@ -3885,7 +3647,7 @@ is too great and becomes a bottlneck. rrate - samp_rate_tx / (baud_rate * samples_per_symbol_tx) + samp_rate_tx / (baud_rate_uplink * samples_per_symbol_tx) samp_delay @@ -3914,6 +3676,10 @@ is too great and becomes a bottlneck. average 1.0 + + axislabels + True + bw samp_rate_rx/decimation_rx @@ -3940,7 +3706,7 @@ is too great and becomes a bottlneck. _enabled - 0 + 1 fftsize @@ -3948,7 +3714,7 @@ is too great and becomes a bottlneck. _coordinate - (552, 722) + (312, 408) gui_hint @@ -3956,7 +3722,7 @@ is too great and becomes a bottlneck. _rotation - 0 + 180 grid @@ -4182,6 +3948,10 @@ is too great and becomes a bottlneck. wintype firdes.WIN_BLACKMAN_hARRIS + + label + Relative Gain + ymax 0 @@ -4190,9 +3960,326 @@ is too great and becomes a bottlneck. ymin -140 + + units + dB + + + + qtgui_waterfall_sink_x + + axislabels + True + + + bw + 50e3 + + + alias + + + + fc + 0 + + + comment + + + + affinity + + + + _enabled + True + + + fftsize + 1024 + + + _coordinate + (296, 628) + + + gui_hint + + + + _rotation + 180 + + + grid + False + + + id + qtgui_waterfall_sink_x_0 + + + int_max + 10 + + + int_min + -140 + + + legend + True + + + alpha1 + 1.0 + + + color1 + 0 + + + label1 + + + + alpha10 + 1.0 + + + color10 + 0 + + + label10 + + + + alpha2 + 1.0 + + + color2 + 0 + + + label2 + + + + alpha3 + 1.0 + + + color3 + 0 + + + label3 + + + + alpha4 + 1.0 + + + color4 + 0 + + + label4 + + + + alpha5 + 1.0 + + + color5 + 0 + + + label5 + + + + alpha6 + 1.0 + + + color6 + 0 + + + label6 + + + + alpha7 + 1.0 + + + color7 + 0 + + + label7 + + + + alpha8 + 1.0 + + + color8 + 0 + + + label8 + + + + alpha9 + 1.0 + + + color9 + 0 + + + label9 + + + + maxoutbuf + 0 + + + minoutbuf + 0 + + + name + "" + + + nconnections + 1 + + + showports + True + + + freqhalf + True + + + type + complex + + + update_time + 0.10 + + + wintype + firdes.WIN_BLACKMAN_hARRIS + + + + parameter + + alias + + + + comment + + + + _enabled + True + + + _coordinate + (168, 756) + + + _rotation + 0 + + + id + recv_port + + + label + + + + short_id + + + + type + intx + + + value + 16886 + + + + parameter + + alias + + + + comment + + + + _enabled + True + + + _coordinate + (648, 900) + + + _rotation + 0 + + + id + rx_sdr_device + + + label + + + + short_id + + + + type + string + + + value + usrpb200 + satnogs_ax25_decoder_bm + + n_sync_flags + 3 + alias @@ -4215,7 +4302,7 @@ is too great and becomes a bottlneck. _coordinate - (1272, 760) + (1312, 584) _rotation @@ -4250,57 +4337,6 @@ is too great and becomes a bottlneck. 0 - - satnogs_debug_msg_source - - alias - - - - comment - - - - affinity - - - - delay - 0.4 - - - _enabled - 0 - - - _coordinate - (232, 190) - - - _rotation - 0 - - - id - satnogs_debug_msg_source_0 - - - maxoutbuf - 0 - - - msg - 'HELLO UPSAT FROM EARTH' * 3 - - - minoutbuf - 0 - - - repeat - True - - satnogs_multi_format_msg_sink @@ -4317,19 +4353,19 @@ is too great and becomes a bottlneck. _enabled - 1 + True _coordinate - (1056, 916) + (1080, 560) _rotation - 0 + 180 id - satnogs_multi_format_msg_sink_0_0_0 + satnogs_multi_format_msg_sink_0 format @@ -4356,7 +4392,7 @@ is too great and becomes a bottlneck. _coordinate - (1024, 792) + (968, 624) _rotation @@ -4399,7 +4435,7 @@ is too great and becomes a bottlneck. _coordinate - (744, 862) + (728, 672) _rotation @@ -4407,7 +4443,7 @@ is too great and becomes a bottlneck. id - satnogs_udp_msg_sink_0_0_0 + satnogs_udp_msg_sink_0_0 addr @@ -4442,7 +4478,7 @@ is too great and becomes a bottlneck. _coordinate - (744, 774) + (728, 600) _rotation @@ -4450,7 +4486,7 @@ is too great and becomes a bottlneck. id - satnogs_udp_msg_sink_0_0_0_0 + satnogs_udp_msg_sink_0_0_0 addr @@ -4487,7 +4523,7 @@ similar to produce dynamic payloads. _coordinate - (240, 294) + (16, 208) _rotation @@ -4499,7 +4535,7 @@ similar to produce dynamic payloads. addr - "0.0.0.0" + bind_addr mtu @@ -4509,13 +4545,17 @@ similar to produce dynamic payloads. maxoutbuf 0 + + msg_type + 0 + minoutbuf 0 port - 16886 + recv_port @@ -4554,7 +4594,7 @@ similar to produce dynamic payloads. _coordinate - (544, 224) + (304, 152) _rotation @@ -4621,7 +4661,7 @@ similar to produce dynamic payloads. _coordinate - (24, 918) + (168, 844) _rotation @@ -4664,7 +4704,50 @@ similar to produce dynamic payloads. _coordinate - (112, 918) + (648, 776) + + + _rotation + 0 + + + id + tx_sdr_device + + + label + + + + short_id + + + + type + string + + + value + usrpb200 + + + + parameter + + alias + + + + comment + + + + _enabled + True + + + _coordinate + (552, 780) _rotation @@ -4739,6 +4822,12 @@ similar to produce dynamic payloads. 0 0 + + freq_xlating_fir_filter_xxx_0 + qtgui_waterfall_sink_x_0 + 0 + 0 + interp_fir_filter_xxx_0 analog_frequency_modulator_fc_0 @@ -4757,39 +4846,27 @@ similar to produce dynamic payloads. 0 0 + + satnogs_ax25_decoder_bm_0 + satnogs_multi_format_msg_sink_0 + failed_pdu + in + satnogs_ax25_decoder_bm_0 satnogs_qb50_deframer_0 pdu in - - satnogs_debug_msg_source_0 - satnogs_upsat_fsk_frame_encoder_0 - msg - pdu - satnogs_qb50_deframer_0 - satnogs_multi_format_msg_sink_0_0_0 + satnogs_udp_msg_sink_0_0 out in satnogs_qb50_deframer_0 satnogs_udp_msg_sink_0_0_0 - out - in - - - satnogs_qb50_deframer_0 - satnogs_multi_format_msg_sink_0_0_0 - wod - in - - - satnogs_qb50_deframer_0 - satnogs_udp_msg_sink_0_0_0_0 wod in diff --git a/apps/flowgraphs/satellites/upsat_transceiver_qt.py b/apps/flowgraphs/satellites/upsat_transceiver_qt.py new file mode 100755 index 0000000..4a7a276 --- /dev/null +++ b/apps/flowgraphs/satellites/upsat_transceiver_qt.py @@ -0,0 +1,498 @@ +#!/usr/bin/env python2 +# -*- coding: utf-8 -*- +################################################## +# GNU Radio Python Flow Graph +# Title: UPSat Transceiver QT +# Author: Manolis Surligas (surligas@gmail.com) +# Description: SATNOGS transceiver for UPSAT satellite +# Generated: Sun Feb 5 13:59:36 2017 +################################################## + +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 PyQt4 import Qt +from gnuradio import analog +from gnuradio import blocks +from gnuradio import digital +from gnuradio import eng_notation +from gnuradio import filter +from gnuradio import gr +from gnuradio import qtgui +from gnuradio.eng_option import eng_option +from gnuradio.filter import firdes +from gnuradio.filter import pfb +from optparse import OptionParser +import math +import numpy +import osmosdr +import satnogs +import sip +import sys +import time + + +class upsat_transceiver_qt(gr.top_block, Qt.QWidget): + + def __init__(self, bind_addr='0.0.0.0', dest_addr='127.0.0.1', lo_offset=100e3, recv_port=16886, rx_sdr_device='usrpb200', send_port=5022, tx_sdr_device='usrpb200', wod_port=5023): + gr.top_block.__init__(self, "UPSat Transceiver QT") + Qt.QWidget.__init__(self) + self.setWindowTitle("UPSat Transceiver QT") + try: + self.setWindowIcon(Qt.QIcon.fromTheme('gnuradio-grc')) + except: + pass + self.top_scroll_layout = Qt.QVBoxLayout() + self.setLayout(self.top_scroll_layout) + self.top_scroll = Qt.QScrollArea() + self.top_scroll.setFrameStyle(Qt.QFrame.NoFrame) + self.top_scroll_layout.addWidget(self.top_scroll) + self.top_scroll.setWidgetResizable(True) + self.top_widget = Qt.QWidget() + self.top_scroll.setWidget(self.top_widget) + self.top_layout = Qt.QVBoxLayout(self.top_widget) + self.top_grid_layout = Qt.QGridLayout() + self.top_layout.addLayout(self.top_grid_layout) + + self.settings = Qt.QSettings("GNU Radio", "upsat_transceiver_qt") + self.restoreGeometry(self.settings.value("geometry").toByteArray()) + + ################################################## + # Parameters + ################################################## + self.bind_addr = bind_addr + self.dest_addr = dest_addr + self.lo_offset = lo_offset + self.recv_port = recv_port + self.rx_sdr_device = rx_sdr_device + self.send_port = send_port + self.tx_sdr_device = tx_sdr_device + self.wod_port = wod_port + + ################################################## + # Variables + ################################################## + self.samples_per_symbol_tx = samples_per_symbol_tx = 4*8 + self.sq_wave = sq_wave = (1.0, ) * samples_per_symbol_tx + self.samp_rate_rx = samp_rate_rx = satnogs.hw_rx_settings[rx_sdr_device]['samp_rate'] + self.gaussian_taps = gaussian_taps = filter.firdes.gaussian(1.0, samples_per_symbol_tx, 1.0, 4*samples_per_symbol_tx) + self.deviation = deviation = 3.9973e3 + self.decimation_rx = decimation_rx = 20 + self.baud_rate_uplink = baud_rate_uplink = 1200 + self.baud_rate_downlink = baud_rate_downlink = 9600 + self.tx_frequency = tx_frequency = 145.835e6 + + self.taps = taps = firdes.low_pass(1.0, samp_rate_rx, 20000, 60000, firdes.WIN_HAMMING, 6.76) + + self.samp_rate_tx = samp_rate_tx = satnogs.hw_tx_settings[rx_sdr_device]['samp_rate'] + self.rx_frequency = rx_frequency = 435.765e6 + self.modulation_index_uplink = modulation_index_uplink = deviation / (baud_rate_uplink / 2.0) + self.modulation_index_downlink = modulation_index_downlink = deviation / (baud_rate_downlink / 2.0) + self.interp_taps = interp_taps = numpy.convolve(numpy.array(gaussian_taps), numpy.array(sq_wave)) + self.first_stage_samp_rate_rx = first_stage_samp_rate_rx = samp_rate_rx / decimation_rx + + ################################################## + # Blocks + ################################################## + self.satnogs_upsat_fsk_frame_encoder_0 = satnogs.upsat_fsk_frame_encoder([0x33]*8 , [0x7A, 0x0E], False, False, False, True, True, 'ABCD', 0, 'ON02GR', 0, 64) + self.satnogs_udp_msg_source_0 = satnogs.udp_msg_source(bind_addr, recv_port, 1500, 0) + self.satnogs_udp_msg_sink_0_0_0 = satnogs.udp_msg_sink(dest_addr, wod_port, 1500) + self.satnogs_udp_msg_sink_0_0 = satnogs.udp_msg_sink(dest_addr, send_port, 1500) + self.satnogs_qb50_deframer_0 = satnogs.qb50_deframer(0xe) + self.satnogs_multi_format_msg_sink_0 = satnogs.multi_format_msg_sink(1) + self.satnogs_ax25_decoder_bm_0 = satnogs.ax25_decoder_bm('GND', 0, False, True, 256, 3) + self.qtgui_waterfall_sink_x_0 = qtgui.waterfall_sink_c( + 1024, #size + firdes.WIN_BLACKMAN_hARRIS, #wintype + 0, #fc + 50e3, #bw + "", #name + 1 #number of inputs + ) + self.qtgui_waterfall_sink_x_0.set_update_time(0.10) + self.qtgui_waterfall_sink_x_0.enable_grid(False) + self.qtgui_waterfall_sink_x_0.enable_axis_labels(True) + + if not True: + self.qtgui_waterfall_sink_x_0.disable_legend() + + if "complex" == "float" or "complex" == "msg_float": + self.qtgui_waterfall_sink_x_0.set_plot_pos_half(not True) + + labels = ['', '', '', '', '', + '', '', '', '', ''] + colors = [0, 0, 0, 0, 0, + 0, 0, 0, 0, 0] + alphas = [1.0, 1.0, 1.0, 1.0, 1.0, + 1.0, 1.0, 1.0, 1.0, 1.0] + for i in xrange(1): + if len(labels[i]) == 0: + self.qtgui_waterfall_sink_x_0.set_line_label(i, "Data {0}".format(i)) + else: + self.qtgui_waterfall_sink_x_0.set_line_label(i, labels[i]) + self.qtgui_waterfall_sink_x_0.set_color_map(i, colors[i]) + self.qtgui_waterfall_sink_x_0.set_line_alpha(i, alphas[i]) + + self.qtgui_waterfall_sink_x_0.set_intensity_range(-140, 10) + + self._qtgui_waterfall_sink_x_0_win = sip.wrapinstance(self.qtgui_waterfall_sink_x_0.pyqwidget(), Qt.QWidget) + self.top_layout.addWidget(self._qtgui_waterfall_sink_x_0_win) + self.qtgui_freq_sink_x_0 = qtgui.freq_sink_c( + 1024, #size + firdes.WIN_BLACKMAN_hARRIS, #wintype + 0, #fc + samp_rate_rx/decimation_rx, #bw + "", #name + 1 #number of inputs + ) + self.qtgui_freq_sink_x_0.set_update_time(0.01) + self.qtgui_freq_sink_x_0.set_y_axis(-140, 0) + self.qtgui_freq_sink_x_0.set_y_label('Relative Gain', 'dB') + self.qtgui_freq_sink_x_0.set_trigger_mode(qtgui.TRIG_MODE_FREE, 0.0, 0, "") + self.qtgui_freq_sink_x_0.enable_autoscale(False) + self.qtgui_freq_sink_x_0.enable_grid(True) + self.qtgui_freq_sink_x_0.set_fft_average(1.0) + self.qtgui_freq_sink_x_0.enable_axis_labels(True) + self.qtgui_freq_sink_x_0.enable_control_panel(True) + + if not True: + self.qtgui_freq_sink_x_0.disable_legend() + + if "complex" == "float" or "complex" == "msg_float": + self.qtgui_freq_sink_x_0.set_plot_pos_half(not True) + + labels = ['', '', '', '', '', + '', '', '', '', ''] + widths = [1, 1, 1, 1, 1, + 1, 1, 1, 1, 1] + colors = ["blue", "red", "green", "black", "cyan", + "magenta", "yellow", "dark red", "dark green", "dark blue"] + alphas = [1.0, 1.0, 1.0, 1.0, 1.0, + 1.0, 1.0, 1.0, 1.0, 1.0] + for i in xrange(1): + if len(labels[i]) == 0: + self.qtgui_freq_sink_x_0.set_line_label(i, "Data {0}".format(i)) + else: + self.qtgui_freq_sink_x_0.set_line_label(i, labels[i]) + self.qtgui_freq_sink_x_0.set_line_width(i, widths[i]) + self.qtgui_freq_sink_x_0.set_line_color(i, colors[i]) + self.qtgui_freq_sink_x_0.set_line_alpha(i, alphas[i]) + + self._qtgui_freq_sink_x_0_win = sip.wrapinstance(self.qtgui_freq_sink_x_0.pyqwidget(), Qt.QWidget) + self.top_layout.addWidget(self._qtgui_freq_sink_x_0_win) + self.pfb_arb_resampler_xxx_0 = pfb.arb_resampler_ccf( + samp_rate_tx / (baud_rate_uplink * samples_per_symbol_tx), + taps=(firdes.low_pass_2(32, 32, 0.8, 0.1, 60)), + flt_size=32) + self.pfb_arb_resampler_xxx_0.declare_sample_delay(0) + + self.osmosdr_source_0 = osmosdr.source( args="numchan=" + str(1) + " " + satnogs.hw_rx_settings[rx_sdr_device]['dev_arg'] ) + self.osmosdr_source_0.set_sample_rate(samp_rate_rx) + self.osmosdr_source_0.set_center_freq(rx_frequency - lo_offset, 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(satnogs.hw_rx_settings[rx_sdr_device]['rf_gain'], 0) + self.osmosdr_source_0.set_if_gain(satnogs.hw_rx_settings[rx_sdr_device]['if_gain'], 0) + self.osmosdr_source_0.set_bb_gain(satnogs.hw_rx_settings[rx_sdr_device]['bb_gain'], 0) + self.osmosdr_source_0.set_antenna(satnogs.hw_rx_settings[rx_sdr_device]['antenna'], 0) + self.osmosdr_source_0.set_bandwidth(samp_rate_rx, 0) + + self.osmosdr_sink_0 = osmosdr.sink( args="numchan=" + str(1) + " " + satnogs.hw_tx_settings[rx_sdr_device]['dev_arg'] ) + self.osmosdr_sink_0.set_sample_rate(samp_rate_tx) + self.osmosdr_sink_0.set_center_freq(tx_frequency - lo_offset, 0) + self.osmosdr_sink_0.set_freq_corr(0, 0) + self.osmosdr_sink_0.set_gain(satnogs.hw_tx_settings[tx_sdr_device]['rf_gain'], 0) + self.osmosdr_sink_0.set_if_gain(satnogs.hw_tx_settings[tx_sdr_device]['if_gain'], 0) + self.osmosdr_sink_0.set_bb_gain(satnogs.hw_tx_settings[tx_sdr_device]['bb_gain'], 0) + self.osmosdr_sink_0.set_antenna(satnogs.hw_tx_settings[tx_sdr_device]['antenna'], 0) + self.osmosdr_sink_0.set_bandwidth(samp_rate_tx, 0) + + self.interp_fir_filter_xxx_0 = filter.interp_fir_filter_fff(samples_per_symbol_tx, (interp_taps)) + self.interp_fir_filter_xxx_0.declare_sample_delay(0) + self.freq_xlating_fir_filter_xxx_0 = filter.freq_xlating_fir_filter_ccc(decimation_rx, (taps), lo_offset, samp_rate_rx) + self.digital_clock_recovery_mm_xx_0 = digital.clock_recovery_mm_ff(first_stage_samp_rate_rx/baud_rate_downlink, 0.25*0.175*0.175, 0.5, 0.175, 0.005) + self.digital_binary_slicer_fb_0 = digital.binary_slicer_fb() + self.blocks_multiply_xx_0 = blocks.multiply_vcc(1) + self.analog_sig_source_x_0 = analog.sig_source_c(samp_rate_tx, analog.GR_COS_WAVE, lo_offset , 1, 0) + self.analog_quadrature_demod_cf_0_0 = analog.quadrature_demod_cf(((first_stage_samp_rate_rx) / baud_rate_downlink)/(math.pi*modulation_index_downlink)) + self.analog_frequency_modulator_fc_0 = analog.frequency_modulator_fc((math.pi*modulation_index_uplink) / samples_per_symbol_tx) + + ################################################## + # Connections + ################################################## + self.msg_connect((self.satnogs_ax25_decoder_bm_0, 'failed_pdu'), (self.satnogs_multi_format_msg_sink_0, 'in')) + self.msg_connect((self.satnogs_ax25_decoder_bm_0, 'pdu'), (self.satnogs_qb50_deframer_0, 'in')) + self.msg_connect((self.satnogs_qb50_deframer_0, 'out'), (self.satnogs_udp_msg_sink_0_0, 'in')) + self.msg_connect((self.satnogs_qb50_deframer_0, 'wod'), (self.satnogs_udp_msg_sink_0_0_0, 'in')) + self.msg_connect((self.satnogs_udp_msg_source_0, 'msg'), (self.satnogs_upsat_fsk_frame_encoder_0, 'pdu')) + self.connect((self.analog_frequency_modulator_fc_0, 0), (self.pfb_arb_resampler_xxx_0, 0)) + self.connect((self.analog_quadrature_demod_cf_0_0, 0), (self.digital_clock_recovery_mm_xx_0, 0)) + self.connect((self.analog_sig_source_x_0, 0), (self.blocks_multiply_xx_0, 1)) + self.connect((self.blocks_multiply_xx_0, 0), (self.osmosdr_sink_0, 0)) + self.connect((self.digital_binary_slicer_fb_0, 0), (self.satnogs_ax25_decoder_bm_0, 0)) + self.connect((self.digital_clock_recovery_mm_xx_0, 0), (self.digital_binary_slicer_fb_0, 0)) + self.connect((self.freq_xlating_fir_filter_xxx_0, 0), (self.analog_quadrature_demod_cf_0_0, 0)) + self.connect((self.freq_xlating_fir_filter_xxx_0, 0), (self.qtgui_freq_sink_x_0, 0)) + self.connect((self.freq_xlating_fir_filter_xxx_0, 0), (self.qtgui_waterfall_sink_x_0, 0)) + self.connect((self.interp_fir_filter_xxx_0, 0), (self.analog_frequency_modulator_fc_0, 0)) + self.connect((self.osmosdr_source_0, 0), (self.freq_xlating_fir_filter_xxx_0, 0)) + self.connect((self.pfb_arb_resampler_xxx_0, 0), (self.blocks_multiply_xx_0, 0)) + self.connect((self.satnogs_upsat_fsk_frame_encoder_0, 0), (self.interp_fir_filter_xxx_0, 0)) + + def closeEvent(self, event): + self.settings = Qt.QSettings("GNU Radio", "upsat_transceiver_qt") + self.settings.setValue("geometry", self.saveGeometry()) + event.accept() + + def get_bind_addr(self): + return self.bind_addr + + def set_bind_addr(self, bind_addr): + self.bind_addr = bind_addr + + def get_dest_addr(self): + return self.dest_addr + + def set_dest_addr(self, dest_addr): + self.dest_addr = dest_addr + + def get_lo_offset(self): + return self.lo_offset + + def set_lo_offset(self, lo_offset): + self.lo_offset = lo_offset + self.osmosdr_source_0.set_center_freq(self.rx_frequency - self.lo_offset, 0) + self.osmosdr_sink_0.set_center_freq(self.tx_frequency - self.lo_offset, 0) + self.freq_xlating_fir_filter_xxx_0.set_center_freq(self.lo_offset) + self.analog_sig_source_x_0.set_frequency(self.lo_offset ) + + def get_recv_port(self): + return self.recv_port + + def set_recv_port(self, recv_port): + self.recv_port = recv_port + + def get_rx_sdr_device(self): + return self.rx_sdr_device + + def set_rx_sdr_device(self, rx_sdr_device): + self.rx_sdr_device = rx_sdr_device + self.set_samp_rate_tx(satnogs.hw_tx_settings[self.rx_sdr_device]['samp_rate']) + self.set_samp_rate_rx(satnogs.hw_rx_settings[self.rx_sdr_device]['samp_rate']) + self.osmosdr_source_0.set_gain(satnogs.hw_rx_settings[self.rx_sdr_device]['rf_gain'], 0) + self.osmosdr_source_0.set_if_gain(satnogs.hw_rx_settings[self.rx_sdr_device]['if_gain'], 0) + self.osmosdr_source_0.set_bb_gain(satnogs.hw_rx_settings[self.rx_sdr_device]['bb_gain'], 0) + self.osmosdr_source_0.set_antenna(satnogs.hw_rx_settings[self.rx_sdr_device]['antenna'], 0) + + def get_send_port(self): + return self.send_port + + def set_send_port(self, send_port): + self.send_port = send_port + + def get_tx_sdr_device(self): + return self.tx_sdr_device + + def set_tx_sdr_device(self, tx_sdr_device): + self.tx_sdr_device = tx_sdr_device + self.osmosdr_sink_0.set_gain(satnogs.hw_tx_settings[self.tx_sdr_device]['rf_gain'], 0) + self.osmosdr_sink_0.set_if_gain(satnogs.hw_tx_settings[self.tx_sdr_device]['if_gain'], 0) + self.osmosdr_sink_0.set_bb_gain(satnogs.hw_tx_settings[self.tx_sdr_device]['bb_gain'], 0) + self.osmosdr_sink_0.set_antenna(satnogs.hw_tx_settings[self.tx_sdr_device]['antenna'], 0) + + def get_wod_port(self): + return self.wod_port + + def set_wod_port(self, wod_port): + self.wod_port = wod_port + + def get_samples_per_symbol_tx(self): + return self.samples_per_symbol_tx + + def set_samples_per_symbol_tx(self, samples_per_symbol_tx): + self.samples_per_symbol_tx = samples_per_symbol_tx + self.set_sq_wave((1.0, ) * self.samples_per_symbol_tx) + self.pfb_arb_resampler_xxx_0.set_rate(self.samp_rate_tx / (self.baud_rate_uplink * self.samples_per_symbol_tx)) + self.set_gaussian_taps(filter.firdes.gaussian(1.0, self.samples_per_symbol_tx, 1.0, 4*self.samples_per_symbol_tx)) + self.analog_frequency_modulator_fc_0.set_sensitivity((math.pi*self.modulation_index_uplink) / self.samples_per_symbol_tx) + + def get_sq_wave(self): + return self.sq_wave + + def set_sq_wave(self, sq_wave): + self.sq_wave = sq_wave + self.set_interp_taps(numpy.convolve(numpy.array(self.gaussian_taps), numpy.array(self.sq_wave))) + + def get_samp_rate_rx(self): + return self.samp_rate_rx + + def set_samp_rate_rx(self, samp_rate_rx): + self.samp_rate_rx = samp_rate_rx + self.set_first_stage_samp_rate_rx(self.samp_rate_rx / self.decimation_rx) + self.qtgui_freq_sink_x_0.set_frequency_range(0, self.samp_rate_rx/self.decimation_rx) + self.osmosdr_source_0.set_sample_rate(self.samp_rate_rx) + self.osmosdr_source_0.set_bandwidth(self.samp_rate_rx, 0) + + def get_gaussian_taps(self): + return self.gaussian_taps + + def set_gaussian_taps(self, gaussian_taps): + self.gaussian_taps = gaussian_taps + self.set_interp_taps(numpy.convolve(numpy.array(self.gaussian_taps), numpy.array(self.sq_wave))) + + def get_deviation(self): + return self.deviation + + def set_deviation(self, deviation): + self.deviation = deviation + self.set_modulation_index_uplink(self.deviation / (self.baud_rate_uplink / 2.0)) + self.set_modulation_index_downlink(self.deviation / (self.baud_rate_downlink / 2.0)) + + def get_decimation_rx(self): + return self.decimation_rx + + def set_decimation_rx(self, decimation_rx): + self.decimation_rx = decimation_rx + self.set_first_stage_samp_rate_rx(self.samp_rate_rx / self.decimation_rx) + self.qtgui_freq_sink_x_0.set_frequency_range(0, self.samp_rate_rx/self.decimation_rx) + + def get_baud_rate_uplink(self): + return self.baud_rate_uplink + + def set_baud_rate_uplink(self, baud_rate_uplink): + self.baud_rate_uplink = baud_rate_uplink + self.set_modulation_index_uplink(self.deviation / (self.baud_rate_uplink / 2.0)) + self.pfb_arb_resampler_xxx_0.set_rate(self.samp_rate_tx / (self.baud_rate_uplink * self.samples_per_symbol_tx)) + + def get_baud_rate_downlink(self): + return self.baud_rate_downlink + + def set_baud_rate_downlink(self, baud_rate_downlink): + self.baud_rate_downlink = baud_rate_downlink + self.set_modulation_index_downlink(self.deviation / (self.baud_rate_downlink / 2.0)) + self.digital_clock_recovery_mm_xx_0.set_omega(self.first_stage_samp_rate_rx/self.baud_rate_downlink) + self.analog_quadrature_demod_cf_0_0.set_gain(((self.first_stage_samp_rate_rx) / self.baud_rate_downlink)/(math.pi*self.modulation_index_downlink)) + + def get_tx_frequency(self): + return self.tx_frequency + + def set_tx_frequency(self, tx_frequency): + self.tx_frequency = tx_frequency + self.osmosdr_sink_0.set_center_freq(self.tx_frequency - self.lo_offset, 0) + + def get_taps(self): + return self.taps + + def set_taps(self, taps): + self.taps = taps + self.freq_xlating_fir_filter_xxx_0.set_taps((self.taps)) + + def get_samp_rate_tx(self): + return self.samp_rate_tx + + def set_samp_rate_tx(self, samp_rate_tx): + self.samp_rate_tx = samp_rate_tx + self.pfb_arb_resampler_xxx_0.set_rate(self.samp_rate_tx / (self.baud_rate_uplink * self.samples_per_symbol_tx)) + self.osmosdr_sink_0.set_sample_rate(self.samp_rate_tx) + self.osmosdr_sink_0.set_bandwidth(self.samp_rate_tx, 0) + self.analog_sig_source_x_0.set_sampling_freq(self.samp_rate_tx) + + def get_rx_frequency(self): + return self.rx_frequency + + def set_rx_frequency(self, rx_frequency): + self.rx_frequency = rx_frequency + self.osmosdr_source_0.set_center_freq(self.rx_frequency - self.lo_offset, 0) + + def get_modulation_index_uplink(self): + return self.modulation_index_uplink + + def set_modulation_index_uplink(self, modulation_index_uplink): + self.modulation_index_uplink = modulation_index_uplink + self.analog_frequency_modulator_fc_0.set_sensitivity((math.pi*self.modulation_index_uplink) / self.samples_per_symbol_tx) + + def get_modulation_index_downlink(self): + return self.modulation_index_downlink + + def set_modulation_index_downlink(self, modulation_index_downlink): + self.modulation_index_downlink = modulation_index_downlink + self.analog_quadrature_demod_cf_0_0.set_gain(((self.first_stage_samp_rate_rx) / self.baud_rate_downlink)/(math.pi*self.modulation_index_downlink)) + + def get_interp_taps(self): + return self.interp_taps + + def set_interp_taps(self, interp_taps): + self.interp_taps = interp_taps + self.interp_fir_filter_xxx_0.set_taps((self.interp_taps)) + + def get_first_stage_samp_rate_rx(self): + return self.first_stage_samp_rate_rx + + def set_first_stage_samp_rate_rx(self, first_stage_samp_rate_rx): + self.first_stage_samp_rate_rx = first_stage_samp_rate_rx + self.digital_clock_recovery_mm_xx_0.set_omega(self.first_stage_samp_rate_rx/self.baud_rate_downlink) + self.analog_quadrature_demod_cf_0_0.set_gain(((self.first_stage_samp_rate_rx) / self.baud_rate_downlink)/(math.pi*self.modulation_index_downlink)) + + +def argument_parser(): + description = 'SATNOGS transceiver for UPSAT satellite' + parser = OptionParser(usage="%prog: [options]", option_class=eng_option, description=description) + parser.add_option( + "", "--bind-addr", dest="bind_addr", type="string", default='0.0.0.0', + help="Set bind_addr [default=%default]") + parser.add_option( + "", "--dest-addr", dest="dest_addr", type="string", default='127.0.0.1', + help="Set dest_addr [default=%default]") + parser.add_option( + "", "--lo-offset", dest="lo_offset", type="eng_float", default=eng_notation.num_to_str(100e3), + help="Set lo_offset [default=%default]") + parser.add_option( + "", "--recv-port", dest="recv_port", type="intx", default=16886, + help="Set recv_port [default=%default]") + parser.add_option( + "", "--rx-sdr-device", dest="rx_sdr_device", type="string", default='usrpb200', + help="Set rx_sdr_device [default=%default]") + parser.add_option( + "", "--send-port", dest="send_port", type="intx", default=5022, + help="Set send_port [default=%default]") + parser.add_option( + "", "--tx-sdr-device", dest="tx_sdr_device", type="string", default='usrpb200', + help="Set tx_sdr_device [default=%default]") + parser.add_option( + "", "--wod-port", dest="wod_port", type="intx", default=5023, + help="Set wod_port [default=%default]") + return parser + + +def main(top_block_cls=upsat_transceiver_qt, options=None): + if options is None: + options, _ = argument_parser().parse_args() + + from distutils.version import StrictVersion + if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): + style = gr.prefs().get_string('qtgui', 'style', 'raster') + Qt.QApplication.setGraphicsSystem(style) + qapp = Qt.QApplication(sys.argv) + + tb = top_block_cls(bind_addr=options.bind_addr, dest_addr=options.dest_addr, lo_offset=options.lo_offset, recv_port=options.recv_port, rx_sdr_device=options.rx_sdr_device, send_port=options.send_port, tx_sdr_device=options.tx_sdr_device, wod_port=options.wod_port) + tb.start() + tb.show() + + def quitting(): + tb.stop() + tb.wait() + qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) + qapp.exec_() + + +if __name__ == '__main__': + main() diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 15bcb14..cd5e06a 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -93,32 +93,11 @@ endif(APPLE) ######################################################################## # Install built library files ######################################################################## -install(TARGETS gnuradio-satnogs - LIBRARY DESTINATION lib${LIB_SUFFIX} # .so/.dylib file - ARCHIVE DESTINATION lib${LIB_SUFFIX} # .lib file - RUNTIME DESTINATION bin # .dll file -) +include(GrMiscUtils) +GR_LIBRARY_FOO(gnuradio-satnogs RUNTIME_COMPONENT "satnogs_runtime" DEVEL_COMPONENT "satnogs_devel") ######################################################################## -# Build and register unit test +# Print summary ######################################################################## -include(GrTest) - -#include_directories(${CPPUNIT_INCLUDE_DIRS}) - -#list(APPEND test_satnogs_sources -# ${CMAKE_CURRENT_SOURCE_DIR}/test_satnogs.cc -# ${CMAKE_CURRENT_SOURCE_DIR}/qa_satnogs.cc -#) - -#add_executable(test-satnogs ${test_satnogs_sources}) - -#target_link_libraries( -# test-satnogs -# ${GNURADIO_RUNTIME_LIBRARIES} -# ${Boost_LIBRARIES} -# ${CPPUNIT_LIBRARIES} -# gnuradio-satnogs -#) - -#GR_ADD_TEST(test_satnogs test-satnogs) +message(STATUS "Using install prefix: ${CMAKE_INSTALL_PREFIX}") +message(STATUS "Building for version: ${VERSION} / ${LIBVER}") diff --git a/lib/tcp_rigctl_msg_source_impl.cc b/lib/tcp_rigctl_msg_source_impl.cc index 6368741..1680f34 100644 --- a/lib/tcp_rigctl_msg_source_impl.cc +++ b/lib/tcp_rigctl_msg_source_impl.cc @@ -71,12 +71,12 @@ namespace gr { message_port_register_out (pmt::mp ("freq")); if(d_is_server) { - boost::shared_ptr ( + d_thread = boost::shared_ptr ( new boost::thread ( boost::bind (&tcp_rigctl_msg_source_impl::rigctl_server, this))); } else{ - boost::shared_ptr ( + d_thread = boost::shared_ptr ( new boost::thread ( boost::bind (&tcp_rigctl_msg_source_impl::rigctl_client, this))); }