Skip to content

Commit

Permalink
Merge pull request #590 from SergeantSerk/parse-scan-response-data
Browse files Browse the repository at this point in the history
Correctly parse scan response from device config
  • Loading branch information
zxzxwu authored Nov 17, 2024
2 parents 5e959d6 + d0990ee commit 01dc0d5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bumble/device.py
Original file line number Diff line number Diff line change
Expand Up @@ -1542,6 +1542,10 @@ def load_from_dict(self, config: Dict[str, Any]) -> None:
)
)

# Load scan response data
if scan_response_data := config.pop('scan_response_data', None):
self.scan_response_data = bytes.fromhex(scan_response_data)

# Load advertising interval (for backward compatibility)
if advertising_interval := config.pop('advertising_interval', None):
self.advertising_interval_min = advertising_interval
Expand Down

0 comments on commit 01dc0d5

Please sign in to comment.