mirror of
https://github.com/AlexandreRouma/SDRPlusPlus.git
synced 2025-01-12 19:27:11 +01:00
Fixed broken code
This commit is contained in:
parent
f29d683918
commit
5e9486ef4c
@ -14,6 +14,7 @@ option(OPT_BUILD_PLUTOSDR_SOURCE "Build PlutoSDR Source Module (Depedencies: lib
|
||||
option(OPT_BUILD_HACKRF_SOURCE "Build HackRF Source Module (Depedencies: libhackrf)" OFF)
|
||||
option(OPT_BUILD_RTL_SDR_SOURCE "Build HackRF Source Module (Depedencies: libhackrf)" ON)
|
||||
option(OPT_BUILD_AUDIO_SINK "Build Audio Sink Module (Depedencies: rtaudio)" ON)
|
||||
option(OPT_BUILD_FALCON9_DECODER "Build the falcon9 live decoder" OFF)
|
||||
# Core of SDR++
|
||||
add_subdirectory("core")
|
||||
|
||||
@ -21,7 +22,6 @@ add_subdirectory("core")
|
||||
add_subdirectory("radio")
|
||||
add_subdirectory("recorder")
|
||||
add_subdirectory("file_source")
|
||||
add_subdirectory("falcon9_decoder")
|
||||
|
||||
# Source modules
|
||||
if (OPT_BUILD_RTL_TCP_SOURCE)
|
||||
@ -68,6 +68,10 @@ if (OPT_BUILD_AUDIO_SINK)
|
||||
add_subdirectory("audio_sink")
|
||||
endif (OPT_BUILD_AUDIO_SINK)
|
||||
|
||||
if (OPT_BUILD_FALCON9_DECODER)
|
||||
add_subdirectory("falcon9_decoder")
|
||||
endif (OPT_BUILD_FALCON9_DECODER)
|
||||
|
||||
if (MSVC)
|
||||
set(CMAKE_CXX_FLAGS "-O2 /std:c++17 /EHsc")
|
||||
else()
|
||||
@ -101,7 +105,7 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
|
||||
add_custom_target(do_always ALL cp \"$<TARGET_FILE_DIR:sdrpp_core>/libsdrpp_core.dylib\" \"$<TARGET_FILE_DIR:sdrpp>\")
|
||||
endif ()
|
||||
|
||||
# cd
|
||||
# cmake .. "-DCMAKE_TOOLCHAIN_FILE=C:/Users/Alex/vcpkg/scripts/buildsystems/vcpkg.cmake" -G "Visual Studio 15 2017 Win64"
|
||||
|
||||
# Install directives
|
||||
install(TARGETS sdrpp DESTINATION bin)
|
||||
|
@ -22,6 +22,8 @@
|
||||
|
||||
#include <gui/widgets/symbol_diagram.h>
|
||||
|
||||
#include <fstream>
|
||||
|
||||
#define CONCAT(a, b) ((std::string(a) + b).c_str())
|
||||
|
||||
SDRPP_MOD_INFO {
|
||||
@ -34,6 +36,8 @@ SDRPP_MOD_INFO {
|
||||
|
||||
#define INPUT_SAMPLE_RATE 6000000
|
||||
|
||||
std::ofstream file("test.ts", std::ios::binary);
|
||||
|
||||
class Falcon9DecoderModule : public ModuleManager::Instance {
|
||||
public:
|
||||
Falcon9DecoderModule(std::string name) {
|
||||
@ -49,7 +53,7 @@ public:
|
||||
// dsp::Threshold thr;
|
||||
|
||||
demod.init(vfo->output, INPUT_SAMPLE_RATE, 2000000.0f);
|
||||
recov.init(&demod.out, (float)INPUT_SAMPLE_RATE / 3572000.0f, 0.00765625f, 0.175f, 0.005f);
|
||||
recov.init(&demod.out, (float)INPUT_SAMPLE_RATE / 3571400.0f, powf(0.01f, 2) / 4.0f, 0.01, 100e-6f); // 0.00765625f, 0.175f, 0.005f
|
||||
split.init(&recov.out);
|
||||
split.bindStream(&reshapeInput);
|
||||
split.bindStream(&thrInput);
|
||||
@ -72,7 +76,11 @@ public:
|
||||
deframe.start();
|
||||
thr.start();
|
||||
|
||||
ffplay = _popen("ffplay -framedrop -hide_banner -loglevel panic -window_title \"Falcon 9 Cameras\" -", "wb");
|
||||
#ifdef _WIN32
|
||||
ffplay = _popen("ffplay -framedrop -infbuf -hide_banner -loglevel panic -window_title \"Falcon 9 Cameras\" -", "wb");
|
||||
#else
|
||||
ffplay = popen("ffplay -framedrop -infbuf -hide_banner -loglevel panic -window_title \"Falcon 9 Cameras\" -", "wb");
|
||||
#endif
|
||||
|
||||
gui::menu.registerEntry(name, menuHandler, this, this);
|
||||
}
|
||||
@ -189,7 +197,8 @@ private:
|
||||
_this->logsMtx.unlock();
|
||||
}
|
||||
else if (pktId == 0x01123201042E1403) {
|
||||
fwrite(data + 25, 1, 940, _this->ffplay);
|
||||
//fwrite(data + 25, 1, 940, _this->ffplay);
|
||||
file.write((char*)(data + 25), 940);
|
||||
}
|
||||
|
||||
//printf("%016" PRIX64 ": %d bytes, %d full\n", pktId, length, count);
|
||||
|
@ -50,7 +50,7 @@ public:
|
||||
RecorderModule(std::string name) : folderSelect("%ROOT%/recordings") {
|
||||
this->name = name;
|
||||
|
||||
recPath = "%ROOT%/recordings";
|
||||
recPath = "%ROOT%/recording";
|
||||
|
||||
// Init audio path
|
||||
vol.init(&dummyStream, 1.0f);
|
||||
|
Loading…
Reference in New Issue
Block a user