#include "cmd.h" #include "bit_container.h" #include "bitview.h" #include "core/plugin.h" #include "explorer/explorer.h" namespace satdump { void BitViewCmdHandler::reg(CLI::App *app) { CLI::App *sub_module = app->add_subcommand("bitview", "Open a file in a BitView"); sub_module->add_option("file"); sub_module->add_flag("--period", period, "Bit period to use")->default_val(256); } void BitViewCmdHandler::run(CLI::App *, CLI::App *subcom, bool) { std::string file = subcom->get_option("file")->as(); auto container = std::make_shared( // std::filesystem::path(file).stem().string() + std::filesystem::path(file).extension().string(), // file); // Set params container->d_bitperiod = period; // Init container->init_bitperiod(); eventBus->fire_event({std::make_shared(container), true}); } } // namespace satdump