From dc43e764058ac3ced4b50e86a9874d3dea758613 Mon Sep 17 00:00:00 2001 From: Christian Haeusler <794584+corvus-ch@users.noreply.github.com> Date: Sat, 2 Oct 2021 18:26:30 +0200 Subject: [PATCH 1/9] Document how to build on MacOS --- readme.md | 33 ++++++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/readme.md b/readme.md index 8a633c57..b990f7f3 100644 --- a/readme.md +++ b/readme.md @@ -50,7 +50,38 @@ There are currently no existing packages for other distributions, for these syst ## MacOS -TODO +You might get lucky by using the installer downloadable from [the Releases page](https://github.com/AlexandreRouma/SDRPlusPlus/releases). + +### Building it yourself + +This guide requires you to have Homebrew installed. Check out https://brew.sh/ on how to do so. + +Get yourself a copy of the source code. This can be done by downloading the +source package from [the Releases +page](https://github.com/AlexandreRouma/SDRPlusPlus/releases). Eextract it to a +location of your choice. Alternativley you can clone +https://github.com/AlexandreRouma/SDRPlusPlus.git using git. + +```sh +brew install \ + airspy \ + airspyhf \ + cmake \ + glew \ + glfw \ + hackrf \ + librtlsdr \ + portaudio \ + rt-audio \ + soapyrtlsdr \ + volk +mkdir build +cd build +cmake .. -DOPT_BUILD_PLUTOSDR_SOURCE=false +make -j$(sysctl -n hw.ncpu) +``` + +The above was tested on macOS Big Sur (11.5). ## BSD From 82cacf14bb281e4f7108bcba1adc9d8ea25f2d70 Mon Sep 17 00:00:00 2001 From: AlexandreRouma Date: Mon, 4 Oct 2021 05:07:11 +0200 Subject: [PATCH 2/9] Fixed text in M17 decoder --- decoder_modules/m17_decoder/src/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/decoder_modules/m17_decoder/src/main.cpp b/decoder_modules/m17_decoder/src/main.cpp index 941db5c5..b833b7d3 100644 --- a/decoder_modules/m17_decoder/src/main.cpp +++ b/decoder_modules/m17_decoder/src/main.cpp @@ -222,7 +222,7 @@ private: ImGui::EndTable(); } - if (ImGui::Checkbox(CONCAT("Show Reference TEST Lines##m17_showlines_", _this->name), &_this->showLines)) { + if (ImGui::Checkbox(CONCAT("Show Reference Lines##m17_showlines_", _this->name), &_this->showLines)) { if (_this->showLines) { _this->diag.lines.push_back(-0.75f); _this->diag.lines.push_back(-0.25f); @@ -312,4 +312,4 @@ MOD_EXPORT void _DELETE_INSTANCE_(void* instance) { MOD_EXPORT void _END_() { config.disableAutoSave(); config.save(); -} \ No newline at end of file +} From 4b2f3e4f6095bbe229a2909f437ed4223484a979 Mon Sep 17 00:00:00 2001 From: Ryzerth Date: Tue, 5 Oct 2021 20:57:15 +0200 Subject: [PATCH 3/9] Added new patrons to the credits + fixed patreon order list to be alphabetical --- core/src/credits.cpp | 7 +++++-- readme.md | 7 +++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/core/src/credits.cpp b/core/src/credits.cpp index fc49afd6..1970d739 100644 --- a/core/src/credits.cpp +++ b/core/src/credits.cpp @@ -36,19 +36,22 @@ namespace sdrpp_credits { const char* patrons[] = { "Bob Logan", + "Christian Häusler", "Croccydile", "Dale L Puckett (K0HYD)", "Daniele D'Agnelli", "EB3FRN", "Eric Johnson", "Flinger Films", - "W4IPA", + "Kezza", "Lee Donaghy", + ".lozenge. (Hank Hill)", "ON4MU", "Passion-Radio.com", "Scanner School", "SignalsEverywhere", - "Syne Ardwin (WI9SYN)" + "Syne Ardwin (WI9SYN)", + "W4IPA" }; const int contributorCount = sizeof(contributors) / sizeof(char*); diff --git a/readme.md b/readme.md index 8a633c57..2ad96cdd 100644 --- a/readme.md +++ b/readme.md @@ -297,7 +297,7 @@ Modules in beta are still included in releases for the most part but not enabled | Name | Stage | Dependencies | Option | Built by default| Built in Release | Enabled in SDR++ by default | |---------------------|------------|--------------|-------------------------------|:---------------:|:----------------:|:---------------------------:| | falcon9_decoder | Unfinished | ffplay | OPT_BUILD_FALCON9_DECODER | ⛔ | ⛔ | ⛔ | -| m17_decoder | Unfinished | - | OPT_BUILD_M17_DECODER | ⛔ | ⛔ | ⛔ | +| m17_decoder | Beta | - | OPT_BUILD_M17_DECODER | ⛔ | ✅ | ⛔ | | meteor_demodulator | Working | - | OPT_BUILD_METEOR_DEMODULATOR | ✅ | ✅ | ⛔ | | radio | Working | - | OPT_BUILD_RADIO | ✅ | ✅ | ✅ | | weather_sat_decoder | Unfinished | - | OPT_BUILD_WEATHER_SAT_DECODER | ⛔ | ⛔ | ⛔ | @@ -357,19 +357,22 @@ I will soon publish a contributing.md listing the code style to use. ## Patrons * Bob Logan +* [Christian Häusler](https://github.com/corvus-ch) * Croccydile * Dale L Puckett (K0HYD) * [Daniele D'Agnelli](https://linkedin.com/in/dagnelli) * [EB3FRN](https://www.eb3frn.net/) * Eric Johnson * Flinger Films -* [W4IPA](https://twitter.com/W4IPAstroke5) +* Kezza * Lee Donaghy +* .lozenge. (Hank Hill) * ON4MU * [Passion-Radio.com](https://passion-radio.com/) * [Scanner School](https://scannerschool.com/) * [SignalsEverywhere](https://signalseverywhere.com/) * Syne Ardwin (WI9SYN) +* [W4IPA](https://twitter.com/W4IPAstroke5) ## Contributors From 3fd4294afa1eee5c0707d02376e25a0eeff516a3 Mon Sep 17 00:00:00 2001 From: Thomas Gimpel Date: Fri, 8 Oct 2021 22:24:09 +0200 Subject: [PATCH 4/9] renamed SpyServer source module class AirspyHFSourceModule -> SpyServerSourceModule, so that it does not collide with the original Airspy HF source module causing massive memory corruption --- source_modules/spyserver_source/src/main.cpp | 32 ++++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/source_modules/spyserver_source/src/main.cpp b/source_modules/spyserver_source/src/main.cpp index 9ba05925..61c3ed19 100644 --- a/source_modules/spyserver_source/src/main.cpp +++ b/source_modules/spyserver_source/src/main.cpp @@ -46,9 +46,9 @@ const int streamFormatsBitCount[] = { ConfigManager config; -class AirspyHFSourceModule : public ModuleManager::Instance { +class SpyServerSourceModule : public ModuleManager::Instance { public: - AirspyHFSourceModule(std::string name) { + SpyServerSourceModule(std::string name) { this->name = name; config.acquire(); @@ -70,7 +70,7 @@ public: sigpath::sourceManager.registerSource("SpyServer", &handler); } - ~AirspyHFSourceModule() { + ~SpyServerSourceModule() { stop(this); sigpath::sourceManager.unregisterSource("SpyServer"); } @@ -105,20 +105,20 @@ private: } static void menuSelected(void* ctx) { - AirspyHFSourceModule* _this = (AirspyHFSourceModule*)ctx; + SpyServerSourceModule* _this = (SpyServerSourceModule*)ctx; core::setInputSampleRate(_this->sampleRate); gui::mainWindow.playButtonLocked = !(_this->client && _this->client->isOpen()); - spdlog::info("AirspyHFSourceModule '{0}': Menu Select!", _this->name); + spdlog::info("SpyServerSourceModule '{0}': Menu Select!", _this->name); } static void menuDeselected(void* ctx) { - AirspyHFSourceModule* _this = (AirspyHFSourceModule*)ctx; + SpyServerSourceModule* _this = (SpyServerSourceModule*)ctx; gui::mainWindow.playButtonLocked = false; - spdlog::info("AirspyHFSourceModule '{0}': Menu Deselect!", _this->name); + spdlog::info("SpyServerSourceModule '{0}': Menu Deselect!", _this->name); } static void start(void* ctx) { - AirspyHFSourceModule* _this = (AirspyHFSourceModule*)ctx; + SpyServerSourceModule* _this = (SpyServerSourceModule*)ctx; if (_this->running) { return; } int srvBits = streamFormatsBitCount[_this->iqType]; @@ -131,30 +131,30 @@ private: _this->client->startStream(); _this->running = true; - spdlog::info("AirspyHFSourceModule '{0}': Start!", _this->name); + spdlog::info("SpyServerSourceModule '{0}': Start!", _this->name); } static void stop(void* ctx) { - AirspyHFSourceModule* _this = (AirspyHFSourceModule*)ctx; + SpyServerSourceModule* _this = (SpyServerSourceModule*)ctx; if (!_this->running) { return; } _this->client->stopStream(); _this->running = false; - spdlog::info("AirspyHFSourceModule '{0}': Stop!", _this->name); + spdlog::info("SpyServerSourceModule '{0}': Stop!", _this->name); } static void tune(double freq, void* ctx) { - AirspyHFSourceModule* _this = (AirspyHFSourceModule*)ctx; + SpyServerSourceModule* _this = (SpyServerSourceModule*)ctx; if (_this->running) { _this->client->setSetting(SPYSERVER_SETTING_IQ_FREQUENCY, freq); } _this->freq = freq; - spdlog::info("AirspyHFSourceModule '{0}': Tune: {1}!", _this->name, freq); + spdlog::info("SpyServerSourceModule '{0}': Tune: {1}!", _this->name, freq); } static void menuHandler(void* ctx) { - AirspyHFSourceModule* _this = (AirspyHFSourceModule*)ctx; + SpyServerSourceModule* _this = (SpyServerSourceModule*)ctx; float menuWidth = ImGui::GetContentRegionAvailWidth(); bool connected = (_this->client && _this->client->isOpen()); @@ -321,11 +321,11 @@ MOD_EXPORT void _INIT_() { } MOD_EXPORT ModuleManager::Instance* _CREATE_INSTANCE_(std::string name) { - return new AirspyHFSourceModule(name); + return new SpyServerSourceModule(name); } MOD_EXPORT void _DELETE_INSTANCE_(ModuleManager::Instance* instance) { - delete (AirspyHFSourceModule*)instance; + delete (SpyServerSourceModule*)instance; } MOD_EXPORT void _END_() { From 011e7ca4096371d95b13821a450d27cffde16e1c Mon Sep 17 00:00:00 2001 From: Ryzerth Date: Fri, 8 Oct 2021 23:24:45 +0200 Subject: [PATCH 5/9] Added new theme --- root/res/themes/army green.json | 59 +++++++++++++++++++++++++++++++++ root/res/themes/deep blue.json | 59 +++++++++++++++++++++++++++++++++ 2 files changed, 118 insertions(+) create mode 100644 root/res/themes/army green.json create mode 100644 root/res/themes/deep blue.json diff --git a/root/res/themes/army green.json b/root/res/themes/army green.json new file mode 100644 index 00000000..6a599880 --- /dev/null +++ b/root/res/themes/army green.json @@ -0,0 +1,59 @@ +{ + "name": "Army Green", + "author": "PD0SWL", + "Border": "#6D6D7F7F", + "BorderShadow": "#00000000", + "Button": "#70707066", + "ButtonActive": "#40020066", + "ButtonHovered": "#70707072", + "CheckMark": "#3D84E0FF", + "ChildBg": "#FFFFFF00", + "DragDropTarget": "#FFFF00E5", + "FrameBg": "#4A4A4A89", + "FrameBgActive": "#40020089", + "FrameBgHovered": "#0F0F1089", + "Header": "#A0A0B24F", + "HeaderActive": "#A0A0B24F", + "HeaderHovered": "#A0A0B266", + "MenuBarBg": "#232323FF", + "ModalWindowDimBg": "#00000080", + "NavHighlight": "#999999FF", + "NavWindowingDimBg": "#CCCCCC33", + "NavWindowingHighlight": "#FFFFFFB2", + "PlotHistogram": "#BA9926FF", + "PlotHistogramHovered": "#FF9900FF", + "PlotLines": "#B1D7F2FF", + "PlotLinesHovered": "#FF6D59FF", + "PopupBg": "#141414EF", + "ResizeGrip": "#E8E8E83F", + "ResizeGripActive": "#757575F2", + "ResizeGripHovered": "#CECECEAA", + "ScrollbarBg": "#05050587", + "ScrollbarGrab": "#4F4F4FFF", + "ScrollbarGrabActive": "#828282FF", + "ScrollbarGrabHovered": "#686868FF", + "Separator": "#6D6D7F7F", + "SeparatorActive": "#828282FF", + "SeparatorHovered": "#B7B7B7C6", + "SliderGrab": "#3D84E0FF", + "SliderGrabActive": "#9d0c05FF", + "Tab": "#2D5993DB", + "TabActive": "#3268ADFF", + "TabHovered": "#4296F9CC", + "TabUnfocused": "#111A25F7", + "TabUnfocusedActive": "#22426CFF", + "TableBorderLight": "#3A3A3FFF", + "TableBorderStrong": "#4F4F59FF", + "TableHeaderBg": "#303033FF", + "TableRowBg": "#00000000", + "TableRowBgAlt": "#FFFFFF0F", + "Text": "#FFFFFFFF", + "TextDisabled": "#7F7F7FFF", + "TextSelectedBg": "#DDDDDD59", + "TitleBg": "#0A0A0AFF", + "TitleBgActive": "#494949FF", + "TitleBgCollapsed": "#00000082", + "WindowBg": "#0F0F0FEF", + "ClearColor": "#121703FF", + "WaterfallBackground": "#000000FF" +} \ No newline at end of file diff --git a/root/res/themes/deep blue.json b/root/res/themes/deep blue.json new file mode 100644 index 00000000..cc03f748 --- /dev/null +++ b/root/res/themes/deep blue.json @@ -0,0 +1,59 @@ +{ + "name": "Deep Blue", + "author": "PD0SWL", + "Border": "#6D6D7F7F", + "BorderShadow": "#00000000", + "Button": "#70707066", + "ButtonActive": "#40020066", + "ButtonHovered": "#70707072", + "CheckMark": "#3D84E0FF", + "ChildBg": "#FFFFFF00", + "DragDropTarget": "#FFFF00E5", + "FrameBg": "#4A4A4A89", + "FrameBgActive": "#40020089", + "FrameBgHovered": "#0F0F1089", + "Header": "#A0A0B24F", + "HeaderActive": "#A0A0B24F", + "HeaderHovered": "#A0A0B266", + "MenuBarBg": "#232323FF", + "ModalWindowDimBg": "#00000080", + "NavHighlight": "#999999FF", + "NavWindowingDimBg": "#CCCCCC33", + "NavWindowingHighlight": "#FFFFFFB2", + "PlotHistogram": "#BA9926FF", + "PlotHistogramHovered": "#FF9900FF", + "PlotLines": "#B1D7F2FF", + "PlotLinesHovered": "#FF6D59FF", + "PopupBg": "#141414EF", + "ResizeGrip": "#E8E8E83F", + "ResizeGripActive": "#757575F2", + "ResizeGripHovered": "#CECECEAA", + "ScrollbarBg": "#05050587", + "ScrollbarGrab": "#4F4F4FFF", + "ScrollbarGrabActive": "#828282FF", + "ScrollbarGrabHovered": "#686868FF", + "Separator": "#6D6D7F7F", + "SeparatorActive": "#828282FF", + "SeparatorHovered": "#B7B7B7C6", + "SliderGrab": "#3D84E0FF", + "SliderGrabActive": "#9d0c05FF", + "Tab": "#2D5993DB", + "TabActive": "#3268ADFF", + "TabHovered": "#4296F9CC", + "TabUnfocused": "#111A25F7", + "TabUnfocusedActive": "#22426CFF", + "TableBorderLight": "#3A3A3FFF", + "TableBorderStrong": "#4F4F59FF", + "TableHeaderBg": "#303033FF", + "TableRowBg": "#00000000", + "TableRowBgAlt": "#FFFFFF0F", + "Text": "#FFFFFFFF", + "TextDisabled": "#7F7F7FFF", + "TextSelectedBg": "#DDDDDD59", + "TitleBg": "#0A0A0AFF", + "TitleBgActive": "#494949FF", + "TitleBgCollapsed": "#00000082", + "WindowBg": "#0F0F0FEF", + "ClearColor": "#0C182EFF", + "WaterfallBackground": "#000000FF" +} \ No newline at end of file From 33b9b53328789e474df32fdf82a5b89a379c3212 Mon Sep 17 00:00:00 2001 From: Ryzerth Date: Sat, 9 Oct 2021 18:34:20 +0200 Subject: [PATCH 6/9] Added RTLD_LOCAL to the dynamic linker flags --- core/src/module.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/module.cpp b/core/src/module.cpp index 2e46247c..0bce8556 100644 --- a/core/src/module.cpp +++ b/core/src/module.cpp @@ -27,7 +27,7 @@ ModuleManager::Module_t ModuleManager::loadModule(std::string path) { mod.deleteInstance = (void(*)(Instance*))GetProcAddress(mod.handle, "_DELETE_INSTANCE_"); mod.end = (void(*)())GetProcAddress(mod.handle, "_END_"); #else - mod.handle = dlopen(path.c_str(), RTLD_LAZY); + mod.handle = dlopen(path.c_str(), RTLD_LAZY RTLD_LOCAL); if (mod.handle == NULL) { spdlog::error("Couldn't load {0}.", path); mod.handle = NULL; From 8deb01868473832493a8aaa597030567345f8385 Mon Sep 17 00:00:00 2001 From: Ryzerth Date: Sat, 9 Oct 2021 18:34:44 +0200 Subject: [PATCH 7/9] Added RTLD_LOCAL to the dynamic linker flags FIX --- core/src/module.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/module.cpp b/core/src/module.cpp index 0bce8556..255593a8 100644 --- a/core/src/module.cpp +++ b/core/src/module.cpp @@ -27,7 +27,7 @@ ModuleManager::Module_t ModuleManager::loadModule(std::string path) { mod.deleteInstance = (void(*)(Instance*))GetProcAddress(mod.handle, "_DELETE_INSTANCE_"); mod.end = (void(*)())GetProcAddress(mod.handle, "_END_"); #else - mod.handle = dlopen(path.c_str(), RTLD_LAZY RTLD_LOCAL); + mod.handle = dlopen(path.c_str(), RTLD_LAZY | RTLD_LOCAL); if (mod.handle == NULL) { spdlog::error("Couldn't load {0}.", path); mod.handle = NULL; From cf3e024fb9cdf265c22eedd47c5bf7aa5c4608fe Mon Sep 17 00:00:00 2001 From: Christian Haeusler <794584+corvus-ch@users.noreply.github.com> Date: Sat, 9 Oct 2021 21:26:35 +0200 Subject: [PATCH 8/9] Use Port Audio instead of RtAudio --- readme.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/readme.md b/readme.md index b990f7f3..4805adbb 100644 --- a/readme.md +++ b/readme.md @@ -77,7 +77,10 @@ brew install \ volk mkdir build cd build -cmake .. -DOPT_BUILD_PLUTOSDR_SOURCE=false +cmake .. \ + -DOPT_BUILD_AUDIO_SINK=false \ + -DOPT_BUILD_PLUTOSDR_SOURCE=false \ + -DOPT_BUILD_PORTAUDIO_SINK=true make -j$(sysctl -n hw.ncpu) ``` From 4d7b46b1a89fd440b99a82201cc4bb5684bf9d14 Mon Sep 17 00:00:00 2001 From: Christian Haeusler <794584+corvus-ch@users.noreply.github.com> Date: Sat, 9 Oct 2021 22:18:02 +0200 Subject: [PATCH 9/9] Sync build example with github action workflow --- readme.md | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/readme.md b/readme.md index 4805adbb..18ee4860 100644 --- a/readme.md +++ b/readme.md @@ -67,25 +67,34 @@ brew install \ airspy \ airspyhf \ cmake \ + codec2 \ + fftw \ glew \ glfw \ hackrf \ + libbladerf \ librtlsdr \ portaudio \ - rt-audio \ + rtl-sdr \ soapyrtlsdr \ volk mkdir build cd build cmake .. \ - -DOPT_BUILD_AUDIO_SINK=false \ - -DOPT_BUILD_PLUTOSDR_SOURCE=false \ - -DOPT_BUILD_PORTAUDIO_SINK=true + -DOPT_BUILD_AUDIO_SINK=OFF \ + -DOPT_BUILD_BLADERF_SOURCE=OFF \ + -DOPT_BUILD_M17_DECODER=ON \ + -DOPT_BUILD_NEW_PORTAUDIO_SINK=ON \ + -DOPT_BUILD_PLUTOSDR_SOURCE=OFF \ + -DOPT_BUILD_PORTAUDIO_SINK=ON \ + -DOPT_BUILD_SOAPY_SOURCE=OFF make -j$(sysctl -n hw.ncpu) ``` The above was tested on macOS Big Sur (11.5). +Check `jobs.build_macos` in the [build_all.yaml](https://github.com/AlexandreRouma/SDRPlusPlus/blob/master/.github/workflows/build_all.yml) workflow for the exact options used for building the package available in the [releases](https://github.com/AlexandreRouma/SDRPlusPlus/releases/tag/1.0.3) + ## BSD There are currently no BSD packages, refer to [Building on Linux / BSD](https://github.com/AlexandreRouma/SDRPlusPlus#building-on-linux--bsd) for instructions on building from source.