pub struct DutyTracker { /* private fields */ }Implementations§
Source§impl DutyTracker
impl DutyTracker
pub const fn new() -> Self
Sourcepub fn record(&mut self, now_ms: u64, airtime_ms: u32)
pub fn record(&mut self, now_ms: u64, airtime_ms: u32)
Record airtime_ms of transmission into the current bin,
rounding up to whole 5 ms units.
Sourcepub fn usage(&mut self, now_ms: u64) -> u16
pub fn usage(&mut self, now_ms: u64) -> u16
Current usage on the PROP_PHY_DUTY_NOW scale (0-65535 for
0-100%).