pub struct ConnectionParameters {
pub interval: u16,
pub latency: u16,
pub timeout: u16,
}Expand description
What a link actually negotiated.
The counterpart to Bluetooth’s connection priority: priority
asks for a profile, this reports what came back. Not part of Web
Bluetooth, which has neither.
The units are the Bluetooth ones rather than milliseconds, because that is what the controller reports and converting would lose precision: the interval is in 1.25 ms steps and the timeout in 10 ms steps.
Fields§
§interval: u16Connection interval, in 1.25 ms steps.
latency: u16Peripheral latency: connection events the peer may skip.
timeout: u16Supervision timeout, in 10 ms steps.
Implementations§
Source§impl ConnectionParameters
impl ConnectionParameters
Sourcepub fn interval_millis(&self) -> f32
pub fn interval_millis(&self) -> f32
Connection interval in milliseconds.
Sourcepub fn timeout_millis(&self) -> u32
pub fn timeout_millis(&self) -> u32
Supervision timeout in milliseconds.
Trait Implementations§
Source§impl Clone for ConnectionParameters
impl Clone for ConnectionParameters
Source§fn clone(&self) -> ConnectionParameters
fn clone(&self) -> ConnectionParameters
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for ConnectionParameters
Source§impl Debug for ConnectionParameters
impl Debug for ConnectionParameters
impl Eq for ConnectionParameters
Source§impl PartialEq for ConnectionParameters
impl PartialEq for ConnectionParameters
impl StructuralPartialEq for ConnectionParameters
Auto Trait Implementations§
impl Forget for ConnectionParameters
impl Freeze for ConnectionParameters
impl Move for ConnectionParameters
impl RefUnwindSafe for ConnectionParameters
impl Send for ConnectionParameters
impl Sync for ConnectionParameters
impl Unpin for ConnectionParameters
impl UnsafeUnpin for ConnectionParameters
impl UnwindSafe for ConnectionParameters
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