pub enum PowerProfile {
Aggressive,
Balanced,
LowPower,
Custom {
scan_interval_ms: u32,
scan_window_ms: u32,
adv_interval_ms: u32,
conn_interval_ms: u32,
},
}Expand description
Power management profile
Controls radio duty cycle and timing parameters to balance responsiveness against battery consumption.
Variants§
Aggressive
Aggressive - ~20% duty cycle, ~6 hour watch battery Use for high-activity scenarios
Balanced
Balanced - ~10% duty cycle, ~12 hour watch battery
LowPower
Low Power - ~2% duty cycle, ~20+ hour watch battery Recommended for HIVE-Lite nodes
Custom
Custom power profile with explicit parameters
Implementations§
Source§impl PowerProfile
impl PowerProfile
Sourcepub fn scan_interval_ms(&self) -> u32
pub fn scan_interval_ms(&self) -> u32
Get scan interval in milliseconds
Sourcepub fn scan_window_ms(&self) -> u32
pub fn scan_window_ms(&self) -> u32
Get scan window in milliseconds
Sourcepub fn adv_interval_ms(&self) -> u32
pub fn adv_interval_ms(&self) -> u32
Get advertisement interval in milliseconds
Sourcepub fn conn_interval_ms(&self) -> u32
pub fn conn_interval_ms(&self) -> u32
Get connection interval in milliseconds
Sourcepub fn duty_cycle_percent(&self) -> u8
pub fn duty_cycle_percent(&self) -> u8
Estimated radio duty cycle as percentage
Trait Implementations§
Source§impl Clone for PowerProfile
impl Clone for PowerProfile
Source§fn clone(&self) -> PowerProfile
fn clone(&self) -> PowerProfile
Returns a duplicate 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 PowerProfile
impl Debug for PowerProfile
Source§impl Default for PowerProfile
impl Default for PowerProfile
Source§fn default() -> PowerProfile
fn default() -> PowerProfile
Returns the “default value” for a type. Read more
Source§impl PartialEq for PowerProfile
impl PartialEq for PowerProfile
impl Copy for PowerProfile
impl Eq for PowerProfile
impl StructuralPartialEq for PowerProfile
Auto Trait Implementations§
impl Freeze for PowerProfile
impl RefUnwindSafe for PowerProfile
impl Send for PowerProfile
impl Sync for PowerProfile
impl Unpin for PowerProfile
impl UnwindSafe for PowerProfile
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