Embassy
nrf-softdevice

Crates

git

Versions

s132

Flavors

pub struct ScanConfig<'a> {
    pub whitelist: Option<&'a [&'a Address]>,
    pub extended: bool,
    pub active: bool,
    pub phys: PhySet,
    pub interval: u32,
    pub window: u32,
    pub timeout: u16,
    pub tx_power: TxPower,
}

Fields§

§whitelist: Option<&'a [&'a Address]>

Whitelist of addresses to scan. If None, all advertisements will be processed when scanning.

For connecting this must be Some, and have least 1 address.

§extended: bool

Support extended advertisements.

If true, the scanner will accept extended advertising packets. If false, the scanner will not receive advertising packets on secondary advertising channels, and will not be able to receive long advertising PDUs.

§active: bool

If true, scan actively by sending scan requests. Ignored when using for connecting.

§phys: PhySet

Set of PHYs to scan

§interval: u32

Scan interval, in units of 625us

§window: u32

Scan window, in units of 625us

§timeout: u16

Timeout in units of 10ms. If set to 0, scan forever.

§tx_power: TxPower

Radio TX power. This is used for scanning, and is inherited as the connection TX power if this ScanConfig is used for connect().

Trait Implementations§

source§

impl<'a> Clone for ScanConfig<'a>

source§

fn clone(&self) -> ScanConfig<'a>

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl<'a> Default for ScanConfig<'a>

source§

fn default() -> Self

Returns the “default value” for a type. Read more
source§

impl<'a> Copy for ScanConfig<'a>

Auto Trait Implementations§

§

impl<'a> RefUnwindSafe for ScanConfig<'a>

§

impl<'a> Send for ScanConfig<'a>

§

impl<'a> Sync for ScanConfig<'a>

§

impl<'a> Unpin for ScanConfig<'a>

§

impl<'a> UnwindSafe for ScanConfig<'a>

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Az for T

source§

fn az<Dst>(self) -> Dstwhere
T: Cast<Dst>,

Casts the value.
source§

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

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

const: unstable · source§

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

Mutably borrows from an owned value. Read more
source§

impl<Src, Dst> CastFrom<Src> for Dstwhere
Src: Cast<Dst>,

source§

fn cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> CheckedAs for T

source§

fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,

source§

fn checked_cast_from(src: Src) -> Option<Dst>

Casts the value.
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

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

const: unstable · 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<Src, Dst> LosslessTryInto<Dst> for Srcwhere
Dst: LosslessTryFrom<Src>,

source§

fn lossless_try_into(self) -> Option<Dst>

Performs the conversion.
source§

impl<Src, Dst> LossyInto<Dst> for Srcwhere
Dst: LossyFrom<Src>,

source§

fn lossy_into(self) -> Dst

Performs the conversion.
source§

impl<T> OverflowingAs for T

source§

fn overflowing_as<Dst>(self) -> (Dst, bool)where
T: OverflowingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere
Src: OverflowingCast<Dst>,

source§

fn overflowing_cast_from(src: Src) -> (Dst, bool)

Casts the value.
source§

impl<T> Same<T> for T

§

type Output = T

Should always be Self
source§

impl<T> SaturatingAs for T

source§

fn saturating_as<Dst>(self) -> Dstwhere
T: SaturatingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere
Src: SaturatingCast<Dst>,

source§

fn saturating_cast_from(src: Src) -> Dst

Casts the value.
source§

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

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.
source§

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

§

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

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.
source§

impl<T> UnwrappedAs for T

source§

fn unwrapped_as<Dst>(self) -> Dstwhere
T: UnwrappedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere
Src: UnwrappedCast<Dst>,

source§

fn unwrapped_cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> WrappingAs for T

source§

fn wrapping_as<Dst>(self) -> Dstwhere
T: WrappingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere
Src: WrappingCast<Dst>,

source§

fn wrapping_cast_from(src: Src) -> Dst

Casts the value.