Skip to main content

AdapterProfile

Struct AdapterProfile 

Source
pub struct AdapterProfile {
    pub adapter_kind: AdapterKind,
    pub chip: Option<String>,
    pub firmware_version: Option<String>,
    pub driver_version: Option<String>,
    pub supported_channels: Vec<u16>,
    pub supported_bandwidths_mhz: Vec<u16>,
    pub expected_subcarrier_counts: Vec<u16>,
    pub supports_live_capture: bool,
    pub supports_injection: bool,
    pub supports_monitor_mode: bool,
}
Expand description

Capability descriptor for a source — used by validation to bound frames and by health checks to flag unsupported firmware/driver state.

Fields§

§adapter_kind: AdapterKind

Adapter family.

§chip: Option<String>

Radio chip, if known ("BCM43455c0", "ESP32-S3", …).

§firmware_version: Option<String>

Firmware version string, if known.

§driver_version: Option<String>

Driver version string, if known.

§supported_channels: Vec<u16>

Channels the source can capture on.

§supported_bandwidths_mhz: Vec<u16>

Bandwidths (MHz) the source supports.

§expected_subcarrier_counts: Vec<u16>

Subcarrier counts the source is expected to emit (e.g. [52, 56, 114, 234]).

§supports_live_capture: bool

Whether live capture is possible (false for files/replay).

§supports_injection: bool

Whether frame injection is possible.

§supports_monitor_mode: bool

Whether monitor mode is available.

Implementations§

Source§

impl AdapterProfile

Source

pub fn offline(adapter_kind: AdapterKind) -> Self

A permissive profile for file/replay/synthetic sources: any channel, any bandwidth, any subcarrier count, no live capabilities.

Source

pub fn esp32_default() -> Self

A typical ESP32-S3 HT20 CSI profile (192 raw subcarriers on HT40, 64 on HT20 — both listed; channels 1–13, 2.4 GHz).

Source

pub fn nexmon_default() -> Self

A typical Nexmon (BCM43455c0) CSI profile: 802.11ac, 20/40/80 MHz.

Source

pub fn accepts_subcarrier_count(&self, count: u16) -> bool

true if count is acceptable for this profile (always true when the expected list is empty, e.g. offline sources).

Source

pub fn accepts_channel(&self, channel: u16) -> bool

true if channel is acceptable (always true when the list is empty).

Trait Implementations§

Source§

impl Clone for AdapterProfile

Source§

fn clone(&self) -> AdapterProfile

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for AdapterProfile

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for AdapterProfile

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for AdapterProfile

Source§

fn eq(&self, other: &AdapterProfile) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for AdapterProfile

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl Eq for AdapterProfile

Source§

impl StructuralPartialEq for AdapterProfile

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,