5#ifndef PICOSCENES_PLATFORM_MAC80211INJECTIONONLYFRONTEND_HXX
6#define PICOSCENES_PLATFORM_MAC80211INJECTIONONLYFRONTEND_HXX
61 int transmit(
const ModularPicoScenesTxFrame &frame)
override;
69 int transmitFramesInBatch(
const std::vector<const ModularPicoScenesTxFrame *> &frames, uint32_t repeat)
override;
88 [[nodiscard]]
const std::string &
getDevId()
const;
94 [[nodiscard]]
const std::string &
getMonId()
const;
142 int setChannelAndBandwidth(std::optional<double> control, std::optional<double> bw, std::optional<double> center)
override;
221 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
Factory class for creating and managing front-end instances.
Frontend class for MAC80211-based devices supporting frame injection.
double getRxChannelBandwidth() override
Get receive channel bandwidth.
void setCarrierFrequency(double carrierFrequency) override
Set carrier frequency.
int transmitFramesInBatch(const std::vector< const ModularPicoScenesTxFrame * > &frames, uint32_t repeat) override
Transmit multiple frames in batch mode.
double getControlChannelFrequency() override
Get control channel frequency.
const std::vector< double > & getSystemSupportedFrequencies() const
Get system supported frequencies.
int transmit(const ModularPicoScenesTxFrame &frame) override
Transmit a single frame.
std::array< uint8_t, 6 > macAddress_MON
Monitor interface MAC address.
std::tuple< double, double, double > getChannelAndBandwidth() override
Get current channel and bandwidth configuration.
int startTx() override
Start transmission service.
std::vector< double > systemSupportedFrequencies
List of supported frequencies.
void setRxChannels(const std::vector< size_t > &rxChannels) override
Set active receive channels.
void printStatus() override
Print current frontend status.
~MAC80211InjectionOnlyFrontEnd() override
Destructor.
void setRxGain(double rxGain, uint8_t channel) override
Set receive gain for specific channel.
std::string devId
Device interface identifier.
static bool isMAC80211CompatibleFrontEnd(const std::string &referredInterfaceName)
Check if a given interface is compatible with MAC80211.
const std::array< uint8_t, 6 > & getMacAddressDev() const
Get device interface MAC address.
int stopRx() override
Stop reception service.
int setChannelAndBandwidth(std::optional< double > control, std::optional< double > bw, std::optional< double > center) override
Set channel and bandwidth with optional parameters.
double getRxGain() override
Get receive gain.
uint8_t getTxChainMask() override
Get transmit chain mask.
void setRxChannelBandwidth(double rxcbw) override
Set receive channel bandwidth.
std::vector< size_t > getTxChannels() override
Get active transmit channels.
const std::string & getMonId() const
Get monitor interface identifier.
double getTxpower() override
Get transmit power.
double getCarrierFrequency() override
Get carrier frequency.
void setSamplingRate(double samplingRate) override
Set sampling rate.
std::shared_ptr< uint8_t > txContext
Transmission context.
bool isMAC80211SupportedCarrierFrequency(double frequency) const
Check if frequency is supported by MAC80211.
int setChannelAndBandwidth(double control, double bw, double center) override
Set channel and bandwidth configuration.
void setTxpower(double txpower) override
Set transmit power.
std::string phyPath
Path to physical interface.
MAC80211InjectionOnlyFrontEnd(const std::string &referredName)
Protected constructor.
void setRxChainMask(uint8_t rxChainMask) override
Set receive chain mask.
int stopTx() override
Stop transmission service.
std::array< uint8_t, 6 > macAddress_DEV
Device interface MAC address.
std::vector< size_t > getRxChannels() override
Get active receive channels.
uint8_t getRxChainMask() override
Get receive chain mask.
void setControlChannelFrequency(double controlFrequency) override
Set control channel frequency.
uint16_t getChannelFlags() override
Get channel flags.
int startRx() override
Start reception service.
void setRxGain(double rxGain) override
Set receive gain.
const std::string & getPhyPath() const
Get physical interface path.
int transmitFramesInBatch(const std::vector< ModularPicoScenesTxFrame > &frames, uint32_t repeat) override
Transmit multiple frames in batch mode (vector version)
void setTxChainMask(uint8_t txChainMask) override
Set transmit chain mask.
const std::array< uint8_t, 6 > & getMacAddressMon() const
Get monitor interface MAC address.
const std::string & getDevId() const
Get device interface identifier.
uint16_t getPhyIdNumber() const
Get physical interface number.
double getSamplingRate() override
Get sampling rate.
std::string monId
Monitor interface identifier.
uint16_t phyIdNumber
Physical interface number.
void setTxChannels(const std::vector< size_t > &txChannels) override
Set active transmit channels.
ExtraInfo buildExtraInfo() override
Build extra information about the frontend.