mirror of https://github.com/pvnis/srsRAN_4G.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
826 B
C
38 lines
826 B
C
4 years ago
|
/**
|
||
8 years ago
|
*
|
||
4 years ago
|
* \section COPYRIGHT
|
||
8 years ago
|
*
|
||
4 years ago
|
* Copyright 2013-2021 Software Radio Systems Limited
|
||
8 years ago
|
*
|
||
4 years ago
|
* By using this file, you agree to the terms and conditions set
|
||
|
* forth in the LICENSE file which can be found at the top level of
|
||
|
* the distribution.
|
||
8 years ago
|
*
|
||
|
*/
|
||
|
|
||
4 years ago
|
#ifndef SRSRAN_MAC_PCAP_H
|
||
|
#define SRSRAN_MAC_PCAP_H
|
||
8 years ago
|
|
||
4 years ago
|
#include "srsran/common/common.h"
|
||
|
#include "srsran/common/mac_pcap_base.h"
|
||
|
#include "srsran/srsran.h"
|
||
4 years ago
|
|
||
4 years ago
|
namespace srsran {
|
||
4 years ago
|
class mac_pcap : public mac_pcap_base
|
||
8 years ago
|
{
|
||
6 years ago
|
public:
|
||
4 years ago
|
mac_pcap();
|
||
5 years ago
|
~mac_pcap();
|
||
4 years ago
|
uint32_t open(std::string filename, uint32_t ue_id = 0);
|
||
4 years ago
|
uint32_t close();
|
||
7 years ago
|
|
||
8 years ago
|
private:
|
||
4 years ago
|
void write_pdu(srsran::mac_pcap_base::pcap_pdu_t& pdu);
|
||
4 years ago
|
|
||
4 years ago
|
FILE* pcap_file = nullptr;
|
||
|
uint32_t dlt = 0; // The DLT used for the PCAP file
|
||
|
std::string filename;
|
||
8 years ago
|
};
|
||
4 years ago
|
} // namespace srsran
|
||
8 years ago
|
|
||
4 years ago
|
#endif // SRSRAN_MAC_PCAP_H
|