5#ifndef PICOSCENES_PLATFORM_MAC80211INJECTIONONLYFRONTEND_HXX
6#define PICOSCENES_PLATFORM_MAC80211INJECTIONONLYFRONTEND_HXX
25 int transmit(
const ModularPicoScenesTxFrame &frame)
override;
27 int transmitFramesInBatch(
const std::vector<const ModularPicoScenesTxFrame *> &frames, uint32_t repeat)
override;
33 [[nodiscard]]
const std::string &
getDevId()
const;
35 [[nodiscard]]
const std::string &
getMonId()
const;
49 int setChannelAndBandwidth(std::optional<double> control, std::optional<double> bw, std::optional<double> center)
override;
75 void setRxGain(
double rxGain, uint8_t channel)
override;
The shared abstract frontend interface for both SDR and NIC.
std::string referredInterfaceName
the user specified frontend name
double getRxChannelBandwidth() override
Get the 802.11 Channel Bandwidth parameter (20e6/40e6/80e6/160e6/320e6) of the Rx path.
void setCarrierFrequency(double carrierFrequency) override
Get the RF carrier frequency.
int transmitFramesInBatch(const std::vector< const ModularPicoScenesTxFrame * > &frames, uint32_t repeat) override
Transmit frames in batch with precise inter-frame timing.
double getControlChannelFrequency() override
Get the control channel frequency of <contorlfreq-bandwidth-centerfreq> channel parameter.
const std::vector< double > & getSystemSupportedFrequencies() const
int transmit(const ModularPicoScenesTxFrame &frame) override
std::array< uint8_t, 6 > macAddress_MON
std::tuple< double, double, double > getChannelAndBandwidth() override
Get the <contorlfreq-bandwidth-centerfreq> channel parameter.
int startTx() override
Activate internal Tx service loop.
std::vector< double > systemSupportedFrequencies
void setRxChannels(const std::vector< size_t > &rxChannels) override
Set the number of the active Rx channels, starting from 0.
void printStatus() override
Print a status string to command line.
~MAC80211InjectionOnlyFrontEnd() override
void setRxGain(double rxGain, uint8_t channel) override
Set the Rx gain for the specified channel. However, currently only QCA9300 and SDR frontend support t...
static bool isMAC80211CompatibleFrontEnd(const std::string &referredInterfaceName)
const std::array< uint8_t, 6 > & getMacAddressDev() const
int stopRx() override
De-activate the Rx service loop, set rxServiceStarted to false.
int setChannelAndBandwidth(std::optional< double > control, std::optional< double > bw, std::optional< double > center) override
Set the <contorlfreq-bandwidth-centerfreq> channel parameter, but with optional.
double getRxGain() override
Get the total Rx gain. However, currently only QCA9300 and SDR frontend support this method.
uint8_t getTxChainMask() override
Get the Tx chain mask.
void setRxChannelBandwidth(double rxcbw) override
Set the Rx channel bandwidth parameter of the <contorlfreq-bandwidth-centerfreq> channel parameters.
std::vector< size_t > getTxChannels() override
Get the numbers of the active Tx channels, starting from 0.
const std::string & getMonId() const
double getTxpower() override
get the transmission power (Tx power)
double getCarrierFrequency() override
Get the RF carrier frequency.
void setSamplingRate(double samplingRate) override
set sampling rate (in Hz)
std::shared_ptr< uint8_t > txContext
bool isMAC80211SupportedCarrierFrequency(double frequency) const
int setChannelAndBandwidth(double control, double bw, double center) override
Set the <contorlfreq-bandwidth-centerfreq> channel parameter.
void setTxpower(double txpower) override
Set the Tx power (in dB)
MAC80211InjectionOnlyFrontEnd(const std::string &referredName)
void setRxChainMask(uint8_t rxChainMask) override
Set Rx chain mask. Setting Rx chain mask means to use only the selected Rx chains for signal receptio...
int stopTx() override
De-activate Tx service loop.
std::array< uint8_t, 6 > macAddress_DEV
std::vector< size_t > getRxChannels() override
Get the number of the active Rx channels, starting from 0.
uint8_t getRxChainMask() override
Get Rx chain mask.
void setControlChannelFrequency(double controlFrequency) override
Get the control channel frequency of <contorlfreq-bandwidth-centerfreq> channel parameter.
uint16_t getChannelFlags() override
Get the old ChannelFlags descriptor.
int startRx() override
Activiate the Rx service loop.
void setRxGain(double rxGain) override
Set the total Rx gain. However, currently only QCA9300 and SDR frontend support this method.
const std::string & getPhyPath() const
int transmitFramesInBatch(const std::vector< ModularPicoScenesTxFrame > &frames, uint32_t repeat) override
void setTxChainMask(uint8_t txChainMask) override
Set Tx chain mask. Setting Tx chain mask means to use only the selected Tx chain for signal transmiss...
const std::array< uint8_t, 6 > & getMacAddressMon() const
const std::string & getDevId() const
uint16_t getPhyIdNumber() const
double getSamplingRate() override
Get the baseband sampling rate.
void setTxChannels(const std::vector< size_t > &txChannels) override
This methods is fundamentally.
ExtraInfo buildExtraInfo() override
Build an ExtraInfo object describing the current frontend status.