From e9a73bbb3c14af340999f70146747787785f4fee Mon Sep 17 00:00:00 2001 From: Tim Redfern Date: Mon, 19 Dec 2011 18:20:33 +0000 Subject: initial commit --- pybluez/simple/inquiry.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 pybluez/simple/inquiry.py (limited to 'pybluez/simple/inquiry.py') diff --git a/pybluez/simple/inquiry.py b/pybluez/simple/inquiry.py new file mode 100644 index 0000000..8f77887 --- /dev/null +++ b/pybluez/simple/inquiry.py @@ -0,0 +1,17 @@ +# file: inquiry.py +# auth: Albert Huang +# desc: performs a simple device inquiry followed by a remote name request of +# each discovered device +# $Id: inquiry.py 401 2006-05-05 19:07:48Z albert $ +# + +import bluetooth + +print "performing inquiry..." + +nearby_devices = bluetooth.discover_devices(lookup_names = True) + +print "found %d devices" % len(nearby_devices) + +for addr, name in nearby_devices: + print " %s - %s" % (addr, name) -- cgit v1.2.3