SatDump 2.0.0-alpha-76a915210
Loading...
Searching...
No Matches
real_to_complex.h
Go to the documentation of this file.
1#pragma once
2
6
7#include "common/dsp/complex.h"
8#include "dsp/block_simple.h"
9
10namespace satdump
11{
12 namespace ndsp
13 {
14 class RealToComplexBlock : public BlockSimple<float, complex_t>
15 {
16 public:
17 RealToComplexBlock();
18 ~RealToComplexBlock();
19
20 uint32_t process(float *input, uint32_t nsamples, complex_t *output);
21
22 void init() {}
23
24 nlohmann::json get_cfg(std::string key) { throw satdump_exception(key); }
25
26 Block::cfg_res_t set_cfg(std::string key, nlohmann::json v)
27 {
28 throw satdump_exception(key);
29 return Block::RES_OK;
30 }
31 };
32 } // namespace ndsp
33
34} // namespace satdump
cfg_res_t
set_cfg status.
Definition block.h:227
nlohmann::json get_cfg(std::string key)
Get parameters of the block as JSON.
Definition real_to_complex.h:24
uint32_t process(float *input, uint32_t nsamples, complex_t *output)
Simplified "work" function, called automatically by work(). This takes away all boilerplate work usua...
Definition real_to_complex.cpp:11
void init()
Applies current parameters to the block. This is called automatically once in start(),...
Definition real_to_complex.h:22
Block::cfg_res_t set_cfg(std::string key, nlohmann::json v)
Set parameters of the block from JSON, including potentially IO configurations for blocks that may ha...
Definition real_to_complex.h:26