Agora
1.2.0
Agora project
|
Go to the documentation of this file.
9 #include <condition_variable>
22 TxRxWorker(
size_t core_offset,
size_t tid,
size_t interface_count,
23 size_t interface_offset,
size_t channels_per_interface,
24 Config*
const config,
size_t* rx_frame_start,
29 std::vector<RxPacket>& rx_memory,
std::byte*
const tx_memory,
30 std::mutex& sync_mutex, std::condition_variable& sync_cond,
31 std::atomic<bool>& can_proceed);
40 inline size_t Id()
const {
return tid_; }
84 #endif // TXRX_WORKER_H_
byte
Definition: core.h:388
size_t GetDLSymbolIdx(size_t symbol_number) const
Definition: framestats.cc:152
Definition: concurrentqueue.h:630
void Running(bool value)
Definition: config.h:33
size_t UeAntNum() const
Definition: config.h:41
static constexpr bool kDebugTxMemory
Definition: txrx_worker.h:20
std::byte *const tx_memory_
Definition: txrx_worker.h:73
size_t *const rx_frame_start_
Definition: txrx_worker.h:59
size_t try_dequeue_bulk_from_producer(producer_token_t const &producer, It itemFirst, size_t max)
Definition: concurrentqueue.h:1292
size_t GetTotalDataSymbolIdxUl(size_t frame_id, size_t symbol_idx_ul) const
Definition: config.h:421
size_t rx_memory_idx_
Definition: txrx_worker.h:71
std::mutex & mutex_
Owned by the parent TxRx object for sync.
Definition: txrx_worker.h:63
size_t GetULSymbolIdx(size_t symbol_number) const
Definition: framestats.cc:156
bool started_
Definition: txrx_worker.h:82
size_t Id() const
Definition: txrx_worker.h:40
size_t BsAntNum() const
Definition: config.h:35
Packet * GetTxPacket(size_t frame, size_t symbol, size_t ant)
Definition: txrx_worker.cc:160
bool Running() const
Definition: txrx_worker.h:42
#define AGORA_LOG_ERROR(...)
Definition: logger.h:39
virtual ~TxRxWorker()
Definition: txrx_worker.cc:42
const FrameStats & Frame() const
Definition: config.h:340
Packet * GetUlTxPacket(size_t frame, size_t symbol, size_t ant)
Definition: txrx_worker.cc:173
bool Started() const
Definition: txrx_worker.h:41
#define AGORA_LOG_TRACE(...)
Definition: logger.h:92
void Use()
Definition: message.h:215
void WaitSync()
Using a latch might be better but adds c++20 requirement.
Definition: txrx_worker.cc:64
void ReturnRxPacket(RxPacket &unused_packet)
Definition: txrx_worker.cc:129
std::condition_variable & cond_
Definition: txrx_worker.h:64
std::atomic< bool > & can_proceed_
Definition: txrx_worker.h:65
std::vector< EventData > GetPendingTxEvents(size_t max_events=0)
Definition: txrx_worker.cc:85
Definition: message.h:142
size_t DlPacketLength() const
Definition: config.h:242
Self defined functions for message storage and passing.
virtual void Start()
Definition: txrx_worker.cc:44
bool enqueue(T const &item)
Definition: concurrentqueue.h:974
moodycamel::ProducerToken & notify_producer_token_
Definition: txrx_worker.h:80
moodycamel::ConcurrentQueue< EventData > * tx_pending_q_
Definition: txrx_worker.h:76
Definition: message.h:164
Config * Configuration()
Definition: txrx_worker.h:46
bool NotifyComplete(const EventData &complete_event)
Definition: txrx_worker.cc:75
Definition: txrx_worker.h:18
std::vector< RxPacket > & rx_memory_
Definition: txrx_worker.h:72
virtual void Stop()
Definition: txrx_worker.cc:55
RxPacket & GetRxPacket()
Definition: txrx_worker.cc:104
const size_t channels_per_interface_
Definition: txrx_worker.h:58
const size_t tid_
Definition: txrx_worker.h:54
#define AGORA_LOG_INFO(...)
Definition: logger.h:62
Config *const cfg_
Definition: txrx_worker.h:68
moodycamel::ProducerToken & tx_producer_token_
Definition: txrx_worker.h:78
#define AGORA_LOG_FRAME(...)
Definition: logger.h:72
#define AGORA_LOG_WARN(...)
Definition: logger.h:53
size_t GetTotalDataSymbolIdxDl(size_t frame_id, size_t symbol_idx_dl) const
Definition: config.h:428
Definition: message.h:186
Declaration file for the configuration class which importants json configuration values into class va...
const size_t interface_offset_
Definition: txrx_worker.h:57
size_t PacketLength() const
Definition: config.h:238
moodycamel::ConcurrentQueue< EventData > * event_notify_q_
Definition: txrx_worker.h:75
const size_t num_interfaces_
Definition: txrx_worker.h:56
txrx worker thread definition. This is the parent / interface
const size_t core_offset_
Definition: txrx_worker.h:55
void Free()
Definition: message.h:216
std::thread thread_
Definition: txrx_worker.h:69
bool running_
Definition: txrx_worker.h:60
bool Empty() const
Definition: message.h:214