aboutsummaryrefslogtreecommitdiffstats
path: root/client/python/scan.py
blob: b5e8531156d705050266fe634c137af52b567f81 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
# Bluetooth LE scanner
# Prints the name and address of every nearby Bluetooth LE device

import asyncio
from bleak import BleakScanner

async def main():
    devices = await BleakScanner.discover()

    for device in devices:
        print(device)

asyncio.run(main())