Struct stm32wb_hci::types::ScanWindow
source · pub struct ScanWindow { /* private fields */ }Expand description
Implementations§
source§impl ScanWindow
impl ScanWindow
sourcepub fn interval(&self) -> Duration
pub fn interval(&self) -> Duration
Returns the interval for the scanning window. The controller starts an LE scan every interval.
sourcepub fn window(&self) -> Duration
pub fn window(&self) -> Duration
Returns the amount of time the controller is scanning every interval.
sourcepub fn copy_into_slice(&self, bytes: &mut [u8])
pub fn copy_into_slice(&self, bytes: &mut [u8])
sourcepub fn start_every(
interval: Duration
) -> Result<ScanWindowBuilder, ScanWindowError>
pub fn start_every( interval: Duration ) -> Result<ScanWindowBuilder, ScanWindowError>
Begins building a ScanWindow. The scan window has the given interval. Returns a builder that can be used to set the window duration.
Errors
- ScanWindowError::TooShort if the provided interval is too short. It must be at least 2.5 ms.
- ScanWindowError::TooLong if the provided interval is too long. It must be 10.24 seconds or less.
Trait Implementations§
source§impl Clone for ScanWindow
impl Clone for ScanWindow
source§fn clone(&self) -> ScanWindow
fn clone(&self) -> ScanWindow
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for ScanWindow
impl Debug for ScanWindow
source§impl PartialEq<ScanWindow> for ScanWindow
impl PartialEq<ScanWindow> for ScanWindow
source§fn eq(&self, other: &ScanWindow) -> bool
fn eq(&self, other: &ScanWindow) -> bool
This method tests for
self and other values to be equal, and is used
by ==.impl StructuralPartialEq for ScanWindow
Auto Trait Implementations§
impl RefUnwindSafe for ScanWindow
impl Send for ScanWindow
impl Sync for ScanWindow
impl Unpin for ScanWindow
impl UnwindSafe for ScanWindow
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more