Agora
1.2.0
Agora project
|
Go to the documentation of this file.
42 Config*
const cfg,
size_t core_offset,
47 const std::string& log_filename =
"");
160 #endif // MAC_THREAD_H_
FastRand fast_rand_
Definition: mac_thread_client.h:119
Declaration file for the UDPComm class. This class is used to send messages and receive messages from...
static constexpr char kMacRemoteHostname[]
Definition: symbols.h:324
size_t GetDLSymbolIdx(size_t symbol_number) const
Definition: framestats.cc:152
void Running(bool value)
Definition: config.h:33
size_t UeAntNum() const
Definition: config.h:41
void PinToCoreWithOffset(ThreadType thread_type, size_t core_offset, size_t thread_id, bool allow_reuse, bool verbose)
Definition: utils.cc:157
std::array< size_t, kMaxUEs > ul_bits_buffer_id_
Definition: mac_thread_client.h:144
void ProcessRxFromPhy()
Definition: mac_thread_client.cc:87
size_t MacPacketsPerframe(Direction dir) const
Definition: config.h:276
const size_t core_offset_
Definition: mac_thread_client.h:89
PtrCube< kFrameWnd, kMaxSymbols, kMaxUEs, int8_t > & decoded_buffer_
Definition: mac_thread_client.h:139
uint16_t symbol_id_
Definition: message.h:33
static constexpr size_t kFrameWnd
Definition: symbols.h:18
uint16_t Ue() const
Definition: message.h:280
MacThreadClient(Config *const cfg, size_t core_offset, PtrCube< kFrameWnd, kMaxSymbols, kMaxUEs, int8_t > &decoded_buffer, Table< int8_t > *ul_bits_buffer, Table< int8_t > *ul_bits_buffer_status, moodycamel::ConcurrentQueue< EventData > *rx_queue, moodycamel::ConcurrentQueue< EventData > *tx_queue, const std::string &log_filename="")
Definition: mac_thread_client.cc:14
static constexpr size_t kMaxPktsPerUE
Definition: mac_thread_client.h:35
struct MacThreadClient::@9 server_
static constexpr size_t kUdpRxBufferPadding
Definition: mac_thread_client.cc:12
const double freq_ghz_
Definition: mac_thread_client.h:84
The packet that contains the control information (DCI) that tells each UE which uplink resource block...
Definition: ran_config.h:30
size_t GetULSymbolIdx(size_t symbol_number) const
Definition: framestats.cc:156
void ProcessUdpPacketsFromAppsClient(const char *payload, RBIndicator ri)
Definition: mac_thread_client.cc:378
size_t MacDataBytesNumPerframe(Direction dir) const
Definition: config.h:259
Provides the UDPServer functions from the UDPComm class. Receiver only support.
The MAC thread that runs alongside the PHY processing at the Agora server or client.
Definition: mac_thread_client.h:28
std::array< std::queue< float >, kMaxUEs > snr_
Definition: mac_thread_client.h:131
std::array< size_t, kMaxTags > tags_
Definition: message.h:146
#define AGORA_LOG_ERROR(...)
Definition: logger.h:39
size_t UeMacRxPort() const
Definition: config.h:323
const FrameStats & Frame() const
Definition: config.h:340
#define AGORA_LOG_TRACE(...)
Definition: logger.h:92
uint16_t ue_id_
Definition: message.h:37
EventType event_type_
Definition: message.h:144
snr
Definition: inspect_agora_results.m:118
static constexpr size_t kHeaderSize
Definition: message.h:276
std::unique_ptr< UDPComm > udp_comm_
Definition: mac_thread_client.h:95
std::array< std::vector< std::byte >, kMaxUEs > frame_data_
Definition: mac_thread_client.h:124
size_t next_radio_id_
Definition: mac_thread_client.h:114
Definition: message.h:142
size_t scheduler_next_frame_id_
Definition: mac_thread_client.h:117
Self defined functions for message storage and passing.
FILE * log_file_
Definition: mac_thread_client.h:91
void RunEventLoop()
Definition: mac_thread_client.cc:523
moodycamel::ConcurrentQueue< EventData > * rx_queue_
Definition: mac_thread_client.h:151
void Set(const uint16_t &f, const uint16_t &s, const uint16_t &u, const uint16_t &data_size)
Definition: message.h:286
size_t ClientUlPilotSymbols() const
Definition: framestats.h:73
void ProcessCodeblocksFromPhy(EventData event)
Definition: mac_thread_client.cc:113
for i
Definition: generate_data.m:107
size_t MacPayloadMaxLength(Direction dir) const
Definition: config.h:272
size_t NumDlDataSyms() const
Definition: framestats.h:83
bool enqueue(T const &item)
Definition: concurrentqueue.h:974
void ProcessUdpPacketsFromApps(RBIndicator ri)
Definition: mac_thread_client.cc:276
Plot Rx waveform for u
Definition: inspect_single_frame.m:108
auto fprintf(std::FILE *f, const S &fmt, const T &... args) -> int
Definition: printf.h:607
double GetFrameDurationSec() const
Return the frame duration in seconds.
Definition: config.h:464
std::unique_ptr< UDPServer > udp_control_channel_
Definition: mac_thread_client.h:98
size_t FramesToTest() const
Definition: config.h:309
size_t GetDLSymbol(size_t location) const
Definition: framestats.cc:106
Table< int8_t > * ul_bits_buffer_status_
Definition: mac_thread_client.h:147
size_t last_mac_pkt_rx_tsc_
Definition: mac_thread_client.h:108
moodycamel::ConcurrentQueue< EventData > * tx_queue_
Definition: mac_thread_client.h:154
size_t MacPacketLength(Direction dir) const
Definition: config.h:268
std::string log_filename_
Definition: mac_thread_client.h:92
size_t ClientDlPilotSymbols() const
Definition: framestats.h:76
static constexpr char kDefaultLogFilename[]
Definition: mac_thread_client.h:31
size_t UeMacTxPort() const
Definition: config.h:324
size_t UeAntTotal() const
Definition: config.h:43
void ProcessControlInformation()
Definition: mac_thread_client.cc:258
static double MeasureRdtscFreq()
Definition: gettime.h:51
Config *const cfg_
Definition: mac_thread_client.h:82
void ProcessSnrReportFromPhy(EventData event)
Definition: mac_thread_client.cc:102
std::array< size_t, kMaxUEs > n_filled_in_frame_
Definition: mac_thread_client.h:128
#define AGORA_LOG_SYMBOL(...)
Definition: logger.h:82
Table< int8_t > * ul_bits_buffer_
Definition: mac_thread_client.h:146
std::vector< std::vector< size_t > > data_size_
Definition: mac_thread_client.h:134
size_t next_tx_frame_id_
Definition: mac_thread_client.h:111
#define AGORA_LOG_INFO(...)
Definition: logger.h:62
size_t GetDLSymbolLast() const
Definition: framestats.h:37
struct MacThreadClient::@10 client_
#define AGORA_LOG_FRAME(...)
Definition: logger.h:72
uint16_t PayloadLength() const
Definition: message.h:282
static void RtAssert(bool condition, const char *throw_str)
Definition: utils.h:104
const size_t tsc_delta_
Definition: mac_thread_client.h:87
static constexpr bool kLogMacPackets
Definition: symbols.h:211
std::string to_string() const
Definition: eth_common.h:64
std::vector< std::byte > udp_pkt_buf_
Definition: mac_thread_client.h:101
Declaration file for the configuration class which importants json configuration values into class va...
bool try_dequeue(U &item)
Definition: concurrentqueue.h:1104
Definition: message.h:274
~MacThreadClient()
Definition: mac_thread_client.cc:82
static constexpr size_t kMaxUEs
Definition: symbols.h:289
static constexpr size_t kSNRWindowSize
Definition: mac_thread_client.h:39
uint32_t frame_id_
Definition: message.h:32
Definition: message.h:303
static constexpr size_t kMacBaseClientPort
Definition: symbols.h:337
std::string UeServerAddr() const
Definition: config.h:298
std::unique_ptr< DoCRC > crc_obj_
Definition: mac_thread_client.h:157
std::vector< std::byte > udp_control_buf_
Definition: mac_thread_client.h:105