From bb025514e701834add3683cb8923559cb73657e8 Mon Sep 17 00:00:00 2001 From: Charlie Boutier Date: Tue, 12 Dec 2023 22:16:59 +0000 Subject: [PATCH] PandoraHost: compute advertising_interval_max with interval_range --- bumble/pandora/host.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bumble/pandora/host.py b/bumble/pandora/host.py index cb2dfbb3..c270f676 100644 --- a/bumble/pandora/host.py +++ b/bumble/pandora/host.py @@ -286,10 +286,10 @@ async def Advertise( "TODO: add support for extended advertising in Bumble" ) if advertising_interval := request.interval: - self.device.config.advertising_interval_min = advertising_interval - self.device.config.advertising_interval_max = advertising_interval - if request.interval_range: - raise NotImplementedError("TODO: add support for `request.interval_range`") + self.device.config.advertising_interval_min = int(advertising_interval) + self.device.config.advertising_interval_max = int(advertising_interval) + if interval_range := request.interval_range: + self.device.config.advertising_interval_max += int(interval_range) if request.primary_phy: raise NotImplementedError("TODO: add support for `request.primary_phy`") if request.secondary_phy: