Agora  1.2.0
Agora project
recorder_worker_multifile.h
Go to the documentation of this file.
1 
5 #ifndef AGORA_RECORDER_WORKER_MULTIFILE_H_
6 #define AGORA_RECORDER_WORKER_MULTIFILE_H_
7 
8 #include "recorder_worker.h"
9 
10 namespace Agora_recorder {
11 
13  public:
14  explicit RecorderWorkerMultiFile(const Config* in_cfg, size_t antenna_offset,
15  size_t num_antennas, size_t record_interval,
16  Direction rx_direction);
17  ~RecorderWorkerMultiFile() override;
18 
19  void Init() final;
20  void Finalize() final;
21  int Record(const Packet* pkt) final;
22 
23  inline size_t NumAntennas() const final { return num_antennas_; }
24  inline size_t AntennaOffset() const final { return antenna_offset_; }
25 
26  private:
27  void Open();
28  void Close();
29 
30  const Config* cfg_;
31 
33  size_t num_antennas_;
34  size_t interval_;
36 };
37 }; /* End namespace Agora_recorder */
38 
39 #endif /* AGORA_RECORDER_WORKER_MULTIFILE_H_ */
FrameStats::GetDLSymbolIdx
size_t GetDLSymbolIdx(size_t symbol_number) const
Definition: framestats.cc:152
Packet::frame_id_
uint32_t frame_id_
Definition: message.h:168
Agora_recorder::RecorderWorkerMultiFile::Close
void Close()
Config::SampsPerSymbol
size_t SampsPerSymbol() const
Definition: config.h:234
fmt::v8::printf
auto printf(const S &fmt, const T &... args) -> int
Definition: printf.h:631
Agora_recorder::RecorderWorkerMultiFile::Open
void Open()
Config::RadioId
const std::vector< std::string > & RadioId() const
Definition: config.h:356
Agora_recorder::RecorderWorkerMultiFile::rx_direction_
Direction rx_direction_
Definition: recorder_worker_multifile.h:35
Agora_recorder::RecorderWorkerMultiFile::Init
void Init() final
Definition: recorder_worker_multifile.cc:32
Agora_recorder::RecorderWorker
Definition: recorder_worker.h:18
Agora_recorder::kDebugPrint
static constexpr bool kDebugPrint
Definition: recorder_worker_hdf5.cc:19
Config::UeRadioName
const std::vector< std::string > & UeRadioName() const
Definition: config.h:365
Direction
Direction
Definition: symbols.h:39
Packet::data_
short data_[]
Definition: message.h:173
recorder_worker.h
Recorder worker interface factory.
FrameStats::GetULSymbolIdx
size_t GetULSymbolIdx(size_t symbol_number) const
Definition: framestats.cc:156
Agora_recorder::RecorderWorkerMultiFile::num_antennas_
size_t num_antennas_
Definition: recorder_worker_multifile.h:33
Packet::ant_id_
uint32_t ant_id_
Definition: message.h:171
fclose
fclose(fileID)
AGORA_LOG_ERROR
#define AGORA_LOG_ERROR(...)
Definition: logger.h:39
Agora_recorder
Definition: hdf5_lib.cc:17
Config::Frame
const FrameStats & Frame() const
Definition: config.h:340
recorder_worker_multifile.h
Recorder worker to write to multiple bin files per rx symbol.
Config::OfdmDataNum
size_t OfdmDataNum() const
Definition: config.h:47
Agora_recorder::RecorderWorkerMultiFile::cfg_
const Config * cfg_
Definition: recorder_worker_multifile.h:30
Packet::cell_id_
uint32_t cell_id_
Definition: message.h:170
Agora_recorder::RecorderWorkerMultiFile
Definition: recorder_worker_multifile.h:12
Config::OfdmCaNum
size_t OfdmCaNum() const
Definition: config.h:45
u
Plot Rx waveform for u
Definition: inspect_single_frame.m:108
Packet
Definition: message.h:164
Packet::symbol_id_
uint32_t symbol_id_
Definition: message.h:169
Agora_recorder::RecorderWorkerMultiFile::interval_
size_t interval_
Definition: recorder_worker_multifile.h:34
Agora_recorder::RecorderWorkerMultiFile::RecorderWorkerMultiFile
RecorderWorkerMultiFile(const Config *in_cfg, size_t antenna_offset, size_t num_antennas, size_t record_interval, Direction rx_direction)
Definition: recorder_worker_multifile.cc:17
FrameStats::ClientDlPilotSymbols
size_t ClientDlPilotSymbols() const
Definition: framestats.h:76
Agora_recorder::kOutputFilePath
static const std::string kOutputFilePath
Definition: recorder_worker.h:16
Config::GetSymbolType
SymbolType GetSymbolType(size_t symbol_id) const
Return the symbol type of this symbol in this frame.
Definition: config.cc:1557
Config::NumUeChannels
size_t NumUeChannels() const
Definition: config.h:99
Config
Definition: config.h:26
Agora_recorder::RecorderWorkerMultiFile::Record
int Record(const Packet *pkt) final
Definition: recorder_worker_multifile.cc:35
fwrite
fwrite(fileID, pilot_f, 'float')
Agora_recorder::RecorderWorkerMultiFile::Finalize
void Finalize() final
Definition: recorder_worker_multifile.cc:33
Agora_recorder::RecorderWorkerMultiFile::NumAntennas
size_t NumAntennas() const final
Definition: recorder_worker_multifile.h:23
Agora_recorder::RecorderWorkerMultiFile::~RecorderWorkerMultiFile
~RecorderWorkerMultiFile() override
to_string
std::string to_string() const
Definition: eth_common.h:64
Agora_recorder::RecorderWorkerMultiFile::antenna_offset_
size_t antenna_offset_
Definition: recorder_worker_multifile.h:32
SymbolType::kUL
@ kUL
SymbolType::kDL
@ kDL
Agora_recorder::RecorderWorkerMultiFile::AntennaOffset
size_t AntennaOffset() const final
Definition: recorder_worker_multifile.h:24